From mboxrd@z Thu Jan 1 00:00:00 1970 From: mulyadi.santosa@gmail.com (Mulyadi Santosa) Date: Thu, 26 May 2011 00:45:10 +0700 Subject: kernel BUG at kernel/workqueue In-Reply-To: References: Message-ID: To: kernelnewbies@lists.kernelnewbies.org List-Id: kernelnewbies.lists.kernelnewbies.org Hi... On Wed, May 25, 2011 at 16:32, sri wrote: > kernel BUG at kernel/workqueue.c:113! from http://lxr.linux.no/#linux+v2.6.18/kernel/workqueue.c, lines around 113: int fastcall queue_work(struct workqueue_struct *wq, struct work_struct *work) 107{ 108 int ret = 0, cpu = get_cpu(); 109 110 if (!test_and_set_bit(0, &work->pending)) { 111 if (unlikely(is_single_threaded(wq))) 112 cpu = singlethread_cpu; 113 BUG_ON(!list_empty(&work->entry)); 114 __queue_work(per_cpu_ptr(wq->cpu_wq, cpu), work); 115 ret = 1; 116 } 117 put_cpu(); 118 return ret; 119} So, if I interpret it correctly, that BUG_ON line means that if work->entry is not empty or null, then it is a bug. Not sure what causes that, but it could be simply due to failure of "work" initialization (as work_struct) somewhere... -- regards, Mulyadi Santosa Freelance Linux trainer and consultant blog: the-hydra.blogspot.com training: mulyaditraining.blogspot.com