[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v1 4/4] xen/arm: mpu: Disable secondary cpu bringup


  • To: Julien Grall <julien@xxxxxxx>, Ayan Kumar Halder <ayan.kumar.halder@xxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxxx
  • From: Ayan Kumar Halder <ayankuma@xxxxxxx>
  • Date: Fri, 6 Sep 2024 15:29:11 +0100
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=amd.com; dmarc=pass action=none header.from=amd.com; dkim=pass header.d=amd.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=qwcI3F3aj5JGKDfQdizb45sJ/RSF0Kon85Xde0Y8ZRY=; b=EPKXP1XiU+3UVeEeOisfiQVS7j9bzjdayQdLOLzGfGWCeY/OM2oyKgT9Vtbm+cUbcV2FWx7EoUj9R+Uv0Wjl/v4WNemIbfqk/c86EX0Ejq8RjFHLWzUZ3FdpbdaXLTuoSEJANgJkRmmGMKA4Gpk0nIC22ilk1vmja6Gbg0hlzc1BM+wxDl75RG0X+S+jJ7N8z9RU2KpkG7O39tN+LZMNN+qra8z7fldJeoFpUL/gcyAxBijElxX8QhYCV+EprprS4sJkwl7W7RqOA7dgQxL7EYyxF8o/EC6NYIL2M8d7/IcRqowEPO94sGcqeZWylpwKf7yRM+LG4Oy9FZyOOaKjIw==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=LYorFe7AdSWnaoE+6aDhT+zBO9i1NF3IzPCBqpKWuyYQEI1qGDE0Ky0VZMcBeRkerVyU7xoND39qdbmnlnMVGz5YxypxEUHdcmHiu/0xpWMMImrH4h+2w8CwrKv8vYW5nOPS9S05DONQMLUa9NNWDeKWWQXN4hmAIwLgrsjOLvM3e8R0emtUzQlIROrvfapX0Bbm0kCFZS8AApPS8ZoaaHVDd1Hm0tEAieMhVFMLpB/YlyWvjQPdJ9Fm0PNoswrAvjpesNm5Lj8YxT2R3HrwuNh2/uFjpidglu8BAAc1dHvfdHMa2Wpo/DO8wsblBI+vaWq9ajCyPo4brXis6ZBpeg==
  • Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=amd.com;
  • Cc: Stefano Stabellini <sstabellini@xxxxxxxxxx>, Bertrand Marquis <bertrand.marquis@xxxxxxx>, Michal Orzel <michal.orzel@xxxxxxx>, Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>
  • Delivery-date: Fri, 06 Sep 2024 14:29:36 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>


On 28/08/2024 20:24, Julien Grall wrote:
Hi Ayan,
Hi Julien,

The title is a bit confusing. It implies seconary CPU bringup used to work on the MPU. However, you are adding a stub for enable_secondary_cpu_mm.

Also, I am not entirely this is really sufficient to disable CPU bringup. There will be plenty of initialization done for secondary CPUs.
I agree. init_secondary() has already been invoked before this.

I would suggest to update NR_CPUS to 1 for MPU so we will fail early.
Yes, I will do this.

For the title, how about

xen/arm: mpu: Implement a dummy enable_secondary_cpu_mm

On 23/08/2024 17:31, Ayan Kumar Halder wrote:
Secondary cpus are put in WFE state. We do not support SMP at this time.

Signed-off-by: Ayan Kumar Halder <ayan.kumar.halder@xxxxxxx>
---
  xen/arch/arm/arm64/mpu/head.S | 9 +++++++++
  1 file changed, 9 insertions(+)

diff --git a/xen/arch/arm/arm64/mpu/head.S b/xen/arch/arm/arm64/mpu/head.S
index 2b023c346a..1579ac0408 100644
--- a/xen/arch/arm/arm64/mpu/head.S
+++ b/xen/arch/arm/arm64/mpu/head.S
@@ -68,3 +68,12 @@ ENTRY(enable_boot_cpu_mm)
        ret
  ENDPROC(enable_boot_cpu_mm)
+
+/*
+ * Secondary cpu has not yet been supported on MPU systems. We will block the
+ * secondary cpu bringup at this stage.
+ */
+ENTRY(enable_secondary_cpu_mm)

Can we print a message so it is easier to spot that enable_secondary_cpu_mm is not properly implemented?

yes, something like this

PRINT("- SMP NOT SUPPORTED -\r\n")

- Ayan




 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.