On 14.04.2025 17:05, Oleksii Kurochko wrote: > On 4/10/25 3:10 PM, Jan Beulich wrote: >> On 08.04.2025 17:57, Oleksii Kurochko wrote: >>> +void __init smp_clear_cpu_maps(void) >>> +{ >>> + cpumask_clear(&cpu_possible_map); >>> + cpumask_clear(&cpu_online_map); >> What's the point of these? All three maps start out fully zeroed. > > It could be really dropped. I saw your patch for Arm, I'll align the current > patch with that changes. > >>> + cpumask_set_cpu(0, &cpu_possible_map); >>> + cpumask_set_cpu(0, &cpu_online_map); >> These are contradicting the name of the function. The somewhat equivalent >> function we have on x86 is smp_prepare_boot_cpu(). >> >>> + cpumask_copy(&cpu_present_map, &cpu_possible_map); >> Another cpumask_set_cpu() is probably cheaper here then. > > What do you mean by cheaper here?
Less code to execute to achieve the same effect. Jan