Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge tag 'slab-for-7.1-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/vbabka/slab

Pull slab fixes from Vlastimil Babka:

- Stable fixes for CONFIG_SMP=n where _nolock() allocations in NMI both
at kmalloc and page allocator levels are not properly protected by
the spin_trylock() semantics on !SMP (Harry Yoo)

* tag 'slab-for-7.1-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/vbabka/slab:
mm/slab: return NULL early from kmalloc_nolock() in NMI on UP
mm/page_alloc: return NULL early from alloc_frozen_pages_nolock() in NMI on UP

+9
+5
mm/page_alloc.c
··· 7737 7737 */ 7738 7738 if (IS_ENABLED(CONFIG_PREEMPT_RT) && (in_nmi() || in_hardirq())) 7739 7739 return NULL; 7740 + 7741 + /* On UP, spin_trylock() always succeeds even when it is locked */ 7742 + if (!IS_ENABLED(CONFIG_SMP) && in_nmi()) 7743 + return NULL; 7744 + 7740 7745 if (!pcp_allowed_order(order)) 7741 7746 return NULL; 7742 7747
+4
mm/slub.c
··· 5339 5339 if (IS_ENABLED(CONFIG_PREEMPT_RT) && (in_nmi() || in_hardirq())) 5340 5340 return NULL; 5341 5341 5342 + /* On UP, spin_trylock() always succeeds even when it is locked */ 5343 + if (!IS_ENABLED(CONFIG_SMP) && in_nmi()) 5344 + return NULL; 5345 + 5342 5346 retry: 5343 5347 if (unlikely(size > KMALLOC_MAX_CACHE_SIZE)) 5344 5348 return NULL;