aboutsummaryrefslogtreecommitdiffstats
path: root/arch/s390/kernel/smp.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/s390/kernel/smp.c')
-rw-r--r--arch/s390/kernel/smp.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/arch/s390/kernel/smp.c b/arch/s390/kernel/smp.c
index a7125b62a9a6..8827883310dd 100644
--- a/arch/s390/kernel/smp.c
+++ b/arch/s390/kernel/smp.c
@@ -773,11 +773,11 @@ void __noreturn cpu_die(void)
773 773
774void __init smp_fill_possible_mask(void) 774void __init smp_fill_possible_mask(void)
775{ 775{
776 unsigned int possible, cpu; 776 unsigned int possible, sclp, cpu;
777 777
778 possible = setup_possible_cpus; 778 sclp = sclp_get_max_cpu() ?: nr_cpu_ids;
779 if (!possible) 779 possible = setup_possible_cpus ?: nr_cpu_ids;
780 possible = MACHINE_IS_VM ? 64 : nr_cpu_ids; 780 possible = min(possible, sclp);
781 for (cpu = 0; cpu < possible && cpu < nr_cpu_ids; cpu++) 781 for (cpu = 0; cpu < possible && cpu < nr_cpu_ids; cpu++)
782 set_cpu_possible(cpu, true); 782 set_cpu_possible(cpu, true);
783} 783}