Re: [PATCH v4 29/34] x86/amd_nb: Trickle down 'struct cpuinfo_x86' reference
From: Ahmed S. Darwish
Date: Mon Aug 18 2025 - 10:58:31 EST
On Mon, 18 Aug 2025, kernel test robot wrote:
>
> [ 1.202568][ T1] BUG: using smp_processor_id() in preemptible [00000000] code: swapper/0/1
> [ 1.202670][ T1] caller is init_amd_nbs (arch/x86/kernel/amd_nb.c:319)
>
Hmm... This is triggered by:
static __init int init_amd_nbs(void)
{
struct cpuinfo_x86 *c = this_cpu_ptr(&cpu_info);
...
}
Since this is all __init code anyway, for the next iteration I'll use
'boot_cpu_data' instead of per-CPU cpu_info access.
Thanks!
--
Ahmed S. Darwish
Linutronix GmbH