[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[RFC PATCH v1 01/12] Arm: GICv3: Sysreg emulation is applicable for Aarch64 only
- To: <xen-devel@xxxxxxxxxxxxxxxxxxxx>
- From: Ayan Kumar Halder <ayankuma@xxxxxxx>
- Date: Mon, 24 Oct 2022 19:19:05 +0100
- 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=yeM/jQyVI4e8F7utEeCiyfeBbYsSPRRaablKg4pztz8=; b=HdmKkWR8qOc8sz7BVkkH7enI3wmE/cf2EtoM8s9H+NBVaVvMANu327JcggFW1+m5DFoXEOOdwszpvFUqcE8mDemW2XfiQzN4tK1/cuyCxEpGpv+n+2cmY5oa99CNofgotT/WgHi6yHEYx33FEiV0vKbyg9w5lGvH1mQ7dZNXwG9eO/zpN1cIpSjqIfiqGwlJvbmMou63XR7NJYg4KLjPRHBCsldBlVWDLG2gi8+r3TanhcCSa6oVCAXOhoRE0+UC1wuSwxs+qvxuPMw7eQbrlD8qzJsS1S8sH7VoOTM/h64pAKMvM1TcRadlkgvvl+cz1lfiKQQ8453lj9GcM+oMVw==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=itXPX+BDmO/hZxgNGd6itSu6N7YEwRDM3no2MNj6vE2TQBsH3p1nE0k/HBPbl46QGq3US0CdDi7byJICG4/sE6Cf0QG0e3+x43XBW3Z0AxVAGfBaUE18CkzPI6o00RBVB5pLMppyY7z6nxCdvoCuhcLbMS3ASHn7J3kJtSNvbRBmleb3FSZ0SPJTZ4kAhbtJWNLwdl9Fv4niPuNSAZDYgxKQmvqS7YebU4c8oYlNgtJW20ZoSCagFgeE2bdlbuMYdzh31xtEdYTQmeqZevkzjDQsI9X56sHTnmC3B1oewA2SROdJ0e9emctBlVf2ndHTTcCOQ+HZahLpEeI5yy0kUg==
- Cc: <sstabellini@xxxxxxxxxx>, <stefanos@xxxxxxxxxx>, <julien@xxxxxxx>, <Volodymyr_Babchuk@xxxxxxxx>, <bertrand.marquis@xxxxxxx>, <michalo@xxxxxxx>, Ayan Kumar Halder <ayankuma@xxxxxxx>
- Delivery-date: Mon, 24 Oct 2022 18:21:24 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
Refer ARM DDI 0487G.b ID072021, EC==0b011000 is supported for Aarch64 state
only. This is when MSR, MRS, System instruction execution in AArch64 state
is trapped, that is not reported using EC 0b000000, 0b000001 or 0b000111.
Signed-off-by: Ayan Kumar Halder <ayankuma@xxxxxxx>
---
xen/arch/arm/vgic-v3.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/xen/arch/arm/vgic-v3.c b/xen/arch/arm/vgic-v3.c
index 0c23f6df9d..c31140eb20 100644
--- a/xen/arch/arm/vgic-v3.c
+++ b/xen/arch/arm/vgic-v3.c
@@ -1520,6 +1520,7 @@ static bool vgic_v3_emulate_sgi1r(struct cpu_user_regs
*regs, uint64_t *r,
}
}
+#ifdef CONFIG_ARM_64
static bool vgic_v3_emulate_sysreg(struct cpu_user_regs *regs, union hsr hsr)
{
struct hsr_sysreg sysreg = hsr.sysreg;
@@ -1540,6 +1541,7 @@ static bool vgic_v3_emulate_sysreg(struct cpu_user_regs
*regs, union hsr hsr)
return false;
}
}
+#endif
static bool vgic_v3_emulate_cp64(struct cpu_user_regs *regs, union hsr hsr)
{
@@ -1563,8 +1565,10 @@ static bool vgic_v3_emulate_reg(struct cpu_user_regs
*regs, union hsr hsr)
{
switch (hsr.ec)
{
+#ifdef CONFIG_ARM_64
case HSR_EC_SYSREG:
return vgic_v3_emulate_sysreg(regs, hsr);
+#endif
case HSR_EC_CP15_64:
return vgic_v3_emulate_cp64(regs, hsr);
default:
--
2.17.1
|