diff options
author | Paul Walmsley <paul.walmsley@sifive.com> | 2019-08-30 10:39:38 -0700 |
---|---|---|
committer | Paul Walmsley <paul.walmsley@sifive.com> | 2019-08-30 10:39:38 -0700 |
commit | 015b269337e66120179f2da428a5195ec7a4675f (patch) | |
tree | 66277b0dedbdef8fa76f80d334c9b55b045c4514 /arch/riscv | |
parent | a256f2e329df0773022d28df2c3d206b9aaf1e61 (diff) | |
parent | f51edcec5288556069d27ab7040a4ce8ca55b74e (diff) | |
download | linux-015b269337e66120179f2da428a5195ec7a4675f.tar.bz2 |
Merge tag 'common/for-v5.4-rc1/cpu-topology' into for-v5.4-rc1-branch
Diffstat (limited to 'arch/riscv')
-rw-r--r-- | arch/riscv/Kconfig | 1 | ||||
-rw-r--r-- | arch/riscv/kernel/smpboot.c | 3 |
2 files changed, 4 insertions, 0 deletions
diff --git a/arch/riscv/Kconfig b/arch/riscv/Kconfig index 59a4727ecd6c..86ee362a1375 100644 --- a/arch/riscv/Kconfig +++ b/arch/riscv/Kconfig @@ -48,6 +48,7 @@ config RISCV select PCI_MSI if PCI select RISCV_TIMER select GENERIC_IRQ_MULTI_HANDLER + select GENERIC_ARCH_TOPOLOGY if SMP select ARCH_HAS_PTE_SPECIAL select ARCH_HAS_MMIOWB select HAVE_EBPF_JIT if 64BIT diff --git a/arch/riscv/kernel/smpboot.c b/arch/riscv/kernel/smpboot.c index 7462a44304fe..18ae6da5115e 100644 --- a/arch/riscv/kernel/smpboot.c +++ b/arch/riscv/kernel/smpboot.c @@ -8,6 +8,7 @@ * Copyright (C) 2017 SiFive */ +#include <linux/arch_topology.h> #include <linux/module.h> #include <linux/init.h> #include <linux/kernel.h> @@ -35,6 +36,7 @@ static DECLARE_COMPLETION(cpu_running); void __init smp_prepare_boot_cpu(void) { + init_cpu_topology(); } void __init smp_prepare_cpus(unsigned int max_cpus) @@ -138,6 +140,7 @@ asmlinkage void __init smp_callin(void) trap_init(); notify_cpu_starting(smp_processor_id()); + update_siblings_masks(smp_processor_id()); set_cpu_online(smp_processor_id(), 1); /* * Remote TLB flushes are ignored while the CPU is offline, so emit |