Re: [PATCH 2/7] microblaze: Make cpuinfo structure SMP aware

Arnd Bergmann
2020-02-12T20:42:57Z

On Wed, Feb 12, 2020 at 4:42 PM Michal Simek <michal.simek@xilinx.com> wrote:

> static void __flush_icache_range_msr_irq(unsigned long start, unsigned long end)
> {
> + unsigned int cpu = smp_processor_id();
> + struct cpuinfo *cpuinfo = per_cpu_ptr(&cpu_info, cpu);

I think all the instances of smp_processor_id()/per_cpu_ptr() should
be replaced with get_cpu_ptr()/put_cpu_ptr(). Same for per_cpu_var()
-> get_cpu_var().

Arnd