Skip to content

Commit 3583521

Browse files
murzinvdennisszhou
authored andcommitted
percpu: km: ensure it is used with NOMMU (either UP or SMP)
Currently, NOMMU pull km allocator via !SMP dependency because most of them are UP, yet for SMP+NOMMU vm allocator gets pulled which: * may lead to broken build [1] * ...or not working runtime due to [2] It looks like SMP+NOMMU case was overlooked in bbddff0 ("percpu: use percpu allocator on UP too") so restore that. [1] For ARM SMP+NOMMU (R-class cores) arm-none-linux-gnueabihf-ld: mm/percpu.o: in function `pcpu_post_unmap_tlb_flush': mm/percpu-vm.c:188: undefined reference to `flush_tlb_kernel_range' [2] static inline int vmap_pages_range_noflush(unsigned long addr, unsigned long end, pgprot_t prot, struct page **pages, unsigned int page_shift) { return -EINVAL; } Signed-off-by: Vladimir Murzin <[email protected]> Tested-by: Rob Landley <[email protected]> Tested-by: Rich Felker <[email protected]> [Dennis: use depends instead of default for condition] Signed-off-by: Dennis Zhou <[email protected]>
1 parent 0fcfb00 commit 3583521

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

mm/Kconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -428,7 +428,7 @@ config THP_SWAP
428428
# UP and nommu archs use km based percpu allocator
429429
#
430430
config NEED_PER_CPU_KM
431-
depends on !SMP
431+
depends on !SMP || !MMU
432432
bool
433433
default y
434434

0 commit comments

Comments
 (0)