Make __queue_work inlined. It just takes spinlock and calls another function. Signed-off-by: Mikulas Patocka Index: linux-2.6.26-rc5-devel/kernel/workqueue.c =================================================================== --- linux-2.6.26-rc5-devel.orig/kernel/workqueue.c 2008-06-20 19:09:54.000000000 +0200 +++ linux-2.6.26-rc5-devel/kernel/workqueue.c 2008-06-20 19:10:48.000000000 +0200 @@ -141,8 +141,8 @@ } /* Preempt must be disabled. */ -static void __queue_work(struct cpu_workqueue_struct *cwq, - struct work_struct *work) +static inline void __queue_work(struct cpu_workqueue_struct *cwq, + struct work_struct *work) { unsigned long flags;