完成量是基于等待队列设计的,所以显然不能在中断上下文使用完成量. struct completion { unsigned int done; wait_queue_head_t wait; }; 我们来看一个使用完成量的经典例子: struct kthread_create_info { /* Information passed to kthread() from kthreadd. */ int (*threadfn)(void *data); void *data; int node;…
今天刚刚升级至Ubuntu13.10,在终端打开gvim时提示一些出错信息,不是很雅观: (gvim:): GLib-GObject-WARNING **: Attempt to add property GnomeProgram::sm-connect after class was initialised (gvim:): GLib-GObject-WARNING **: Attempt to add property GnomeProgram::show-crash-dialog afte…