[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v2 02/16] xen/riscv: introduce smp_prepare_boot_cpu()
- To: Jan Beulich <jbeulich@xxxxxxxx>
- From: Oleksii Kurochko <oleksii.kurochko@xxxxxxxxx>
- Date: Fri, 16 May 2025 10:24:15 +0200
- Cc: Alistair Francis <alistair.francis@xxxxxxx>, Bob Eshleman <bobbyeshleman@xxxxxxxxx>, Connor Davis <connojdavis@xxxxxxxxx>, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, Anthony PERARD <anthony.perard@xxxxxxxxxx>, Michal Orzel <michal.orzel@xxxxxxx>, Julien Grall <julien@xxxxxxx>, Roger Pau Monné <roger.pau@xxxxxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxxx
- Delivery-date: Fri, 16 May 2025 08:24:27 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
On 5/13/25 5:48 PM, Jan Beulich wrote:
On 06.05.2025 18:51, Oleksii Kurochko wrote:
@@ -72,6 +72,8 @@ void __init noreturn start_xen(unsigned long bootcpu_id,
remove_identity_mapping();
+ smp_prepare_boot_cpu();
+
set_processor_id(0);
set_cpuid_to_hartid(0, bootcpu_id);
Is this a good placement? I'd think that smp_prepare_boot_cpu() ought to be
permitted to rely on set_processor_id() already having run, for example (even
if right now there's no such dependency). Alternatively the set_processor_id()
call may want to move into the new function?
Agree, logically it would be better to set processor id before smp_prepare_boot_cpu().
I'll move set_processor_id(0) inside smp_prepare_boot_cpu().
Thanks.
~ Oleksii
|