On Tue, 3 Aug 2021 16:15:49 +0200 Sebastian Andrzej Siewior <bigeasy@xxxxxxxxxxxxx> wrote: > The functions get_online_cpus() and put_online_cpus() have been > deprecated during the CPU hotplug rework. They map directly to > cpus_read_lock() and cpus_read_unlock(). > > Replace deprecated CPU-hotplug functions with the official version. > The behavior remains unchanged. > > Cc: Steven Rostedt <rostedt@xxxxxxxxxxx> Reviewed-by: Steven Rostedt (VMware) <rostedt@xxxxxxxxxxx> -- Steve > Cc: Ingo Molnar <mingo@xxxxxxxxxx> > Cc: Karol Herbst <karolherbst@xxxxxxxxx> > Cc: Pekka Paalanen <ppaalanen@xxxxxxxxx> > Cc: Dave Hansen <dave.hansen@xxxxxxxxxxxxxxx> > Cc: Andy Lutomirski <luto@xxxxxxxxxx> > Cc: Peter Zijlstra <peterz@xxxxxxxxxxxxx> > Cc: Thomas Gleixner <tglx@xxxxxxxxxxxxx> > Cc: Borislav Petkov <bp@xxxxxxxxx> > Cc: x86@xxxxxxxxxx > Cc: "H. Peter Anvin" <hpa@xxxxxxxxx> > Cc: nouveau@xxxxxxxxxxxxxxxxxxxxx > Signed-off-by: Sebastian Andrzej Siewior <bigeasy@xxxxxxxxxxxxx> > --- > arch/x86/mm/mmio-mod.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/arch/x86/mm/mmio-mod.c b/arch/x86/mm/mmio-mod.c > index cd768dafca9e9..933a2ebad471b 100644 > --- a/arch/x86/mm/mmio-mod.c > +++ b/arch/x86/mm/mmio-mod.c > @@ -376,12 +376,12 @@ static void enter_uniprocessor(void) > goto out; > } > > - get_online_cpus(); > + cpus_read_lock(); > cpumask_copy(downed_cpus, cpu_online_mask); > cpumask_clear_cpu(cpumask_first(cpu_online_mask), downed_cpus); > if (num_online_cpus() > 1) > pr_notice("Disabling non-boot CPUs...\n"); > - put_online_cpus(); > + cpus_read_unlock(); > > for_each_cpu(cpu, downed_cpus) { > err = remove_cpu(cpu);