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

[XEN v3 12/12] xen/Arm: GICv3: Enable GICv3 for AArch32


  • To: <xen-devel@xxxxxxxxxxxxxxxxxxxx>
  • From: Ayan Kumar Halder <ayan.kumar.halder@xxxxxxx>
  • Date: Fri, 11 Nov 2022 14:17:39 +0000
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=lists.xenproject.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; 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=rC2CEEelnbLAOBw163E+15A6DiW8jj2UsQYupwZAM2g=; b=VrudPAi4VpiDe30AjvxZbeaHW4Bek0PUq3BLpSldrtc9iA575JkIPo1G0aM3w0yBttGbpM8XV9mw9RfpM8NKm6NR0txfeci9FcaWDeof1otUsywWAxWXaXDsC01zrhjSG4R8yzOcPM8qkp5vofKXVFFtxsn1Mj8OMEd4k3vb2cZCduX8e35O1S7jUqRBjZ6qiYbfayITZNnRt0MN+l561AOxRWicj+qBsF+kf8bd5MZRd2p/8uZiJb+ztRDS7Wfsnf6jhcauReH3gD/60Qugt1t800enDnFRQ1WggqHXFS8btXRiIRyuFktvdnm7vOklf4OhSm9TSVzIwP8EWrauag==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=AUusyGVrtXgm3jfhJhYpk/ozrC3Ol+6ckGPap16FHNK0ba2z6kqBOTb+NrYpAPcFea8TETzThNqE73psy3xSqWcs9kWKOcbzGA5eJ/2gpsGrJB/Gd4SS22TELMBvLzYHK2MDWIH9aW5mhaAb7lCKZhwR77exFirE4cryN/pTRLX77PMi1hsUJNgYYi+RWxDW2CCqynFIzgdvp5r/bXXuwAmE+i9HdbYvCkzhI70XWKlie7ahEeRkP/QI8H54iAOhE4jtKMV0bqfXpe4S9DTySIQRVarbbZfdj5DYXjnBILZyl1H4cHQjjRY7zzW82cH/dw/WyJ+ZkeNWzQ7/3pDPGA==
  • Cc: <sstabellini@xxxxxxxxxx>, <stefanos@xxxxxxxxxx>, <julien@xxxxxxx>, <Volodymyr_Babchuk@xxxxxxxx>, <bertrand.marquis@xxxxxxx>, <michal.orzel@xxxxxxx>, <jgrall@xxxxxxxxxx>, <burzalodowa@xxxxxxxxx>, "Ayan Kumar Halder" <ayan.kumar.halder@xxxxxxx>
  • Delivery-date: Fri, 11 Nov 2022 14:18:41 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

One can now use GICv3 on AArch32 systems. However, ITS is not supported.
The reason being currently we are trying to validate GICv3 on an AArch32_v8R
system. Refer ARM DDI 0568A.c ID110520, B1.3.1,
"A Generic Interrupt Controller (GIC) implemented with an Armv8-R PE must not
implement LPI support."

By default GICv3 is disabled on AArch32 and enabled on AArch64.

Updated SUPPORT.md to state that GICv3 on Arm32 is not security supported.

Signed-off-by: Ayan Kumar Halder <ayan.kumar.halder@xxxxxxx>
---

Changed from :-
v1 - 1. Remove "ARM_64 || ARM_32" as it is always true.
2. Updated SUPPORT.md.

v2 - 1. GICv3 is enabled by default only on ARM_64.
2. Updated SUPPORT.md.

 SUPPORT.md                            | 7 +++++++
 xen/arch/arm/Kconfig                  | 9 +++++----
 xen/arch/arm/include/asm/cpufeature.h | 1 +
 3 files changed, 13 insertions(+), 4 deletions(-)

diff --git a/SUPPORT.md b/SUPPORT.md
index ab71464cf6..3f16d83191 100644
--- a/SUPPORT.md
+++ b/SUPPORT.md
@@ -82,6 +82,13 @@ Extension to the GICv3 interrupt controller to support MSI.
 
     Status: Experimental
 
+### ARM/GICv3
+
+GICv3 is an interrupt controller specification designed by Arm.
+
+    Status, Arm64: Security supported
+    Status, Arm32: Supported, not security supported
+
 ## Guest Type
 
 ### x86/PV
diff --git a/xen/arch/arm/Kconfig b/xen/arch/arm/Kconfig
index 1fe5faf847..b90930955b 100644
--- a/xen/arch/arm/Kconfig
+++ b/xen/arch/arm/Kconfig
@@ -9,6 +9,7 @@ config ARM_64
        select 64BIT
        select ARM_EFI
        select HAS_FAST_MULTIPLY
+       select GICV3
 
 config ARM
        def_bool y
@@ -41,16 +42,16 @@ config ARM_EFI
 
 config GICV3
        bool "GICv3 driver"
-       depends on ARM_64 && !NEW_VGIC
-       default y
+       depends on !NEW_VGIC
+       default n
        ---help---
 
          Driver for the ARM Generic Interrupt Controller v3.
-         If unsure, say Y
+         If unsure, say N
 
 config HAS_ITS
         bool "GICv3 ITS MSI controller support (UNSUPPORTED)" if UNSUPPORTED
-        depends on GICV3 && !NEW_VGIC
+        depends on GICV3 && !NEW_VGIC && !ARM_32
 
 config HVM
         def_bool y
diff --git a/xen/arch/arm/include/asm/cpufeature.h 
b/xen/arch/arm/include/asm/cpufeature.h
index c86a2e7f29..c62cf6293f 100644
--- a/xen/arch/arm/include/asm/cpufeature.h
+++ b/xen/arch/arm/include/asm/cpufeature.h
@@ -33,6 +33,7 @@
 #define cpu_has_aarch32   (cpu_has_arm || cpu_has_thumb)
 
 #ifdef CONFIG_ARM_32
+#define cpu_has_gicv3     (boot_cpu_feature32(gic) >= 1)
 #define cpu_has_gentimer  (boot_cpu_feature32(gentimer) == 1)
 /*
  * On Armv7, the value 0 is used to indicate that PMUv2 is not
-- 
2.17.1




 


Rackspace

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