--- mm/slub.c | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) Index: linux-2.6/mm/slub.c =================================================================== --- linux-2.6.orig/mm/slub.c 2007-10-20 08:50:32.000000000 -0700 +++ linux-2.6/mm/slub.c 2007-10-20 09:01:39.000000000 -0700 @@ -1497,6 +1497,7 @@ static void *__slab_alloc(struct kmem_ca unsigned long flags; local_irq_save(flags); + preempt_enable_no_resched(); #endif if (!c->page) goto new_slab; @@ -1520,6 +1521,7 @@ unlock_out: slab_unlock(c->page); out: #ifdef FASTPATH_CMPXCHG + preempt_disable(); local_irq_restore(flags); #endif return object; @@ -1534,16 +1536,6 @@ new_slab: goto load_freelist; } -#ifdef FASTPATH_CMPXCHG - local_irq_restore(flags); - put_cpu(); - - new = new_slab(s, gfpflags, node); - - get_cpu(); - local_irq_save(flags); -#else - if (gfpflags & __GFP_WAIT) local_irq_enable(); @@ -1551,7 +1543,6 @@ new_slab: if (gfpflags & __GFP_WAIT) local_irq_disable(); -#endif if (new) { c = get_cpu_slab(s, smp_processor_id());