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

Re: [PATCH v2] xen/arm: AArch32-V8R: Add MPU register definitions


  • To: Julien Grall <julien@xxxxxxx>, Ayan Kumar Halder <ayan.kumar.halder@xxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxxx
  • From: Ayan Kumar Halder <ayankuma@xxxxxxx>
  • Date: Fri, 25 Apr 2025 15:16:32 +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=s8f/Vba4PZCx9DiU29wG30Mid7Pgv0sAY80tm3rZkCs=; b=MNMYN7pJwFgjam6tCoMrhIiCpbV/7wueM05c0xU/Y9CXBUQy08rdgrHdX8SYKUGtt+RX7CLbJmSuX8wyXTkU/aIr2hq8PFhaLEgzNyg3BOFnH2N+GeW7tmMmQoC0NPPFGN00MEz4R5ApZ2MRUGfYS3mEhRRORYhs+/UE/oqLf4tZAQ4SG/tJPOTerrQMnNm2AdlNj4xYL8Prd6Q1eYOgosK/W/K2Wn9ZT6da1lnfCuKeAA7US32K04pbOCfwMRVu7xxJTWAuIesFiTWEHpZZRwNkCcElBgS/jvewpygooUYzT/rw2OX6vjPvx6nqDXBL4GCHfoeuQhR8mfk9HGQLYw==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=iVjmnqg0qesrL0tlAES1LDVAKWgpKHLwlE3VPOKz4X7rmcxYvw7OoQkVeFTmuDyizQV6iqqdMcv0ZLMOzfpNS63vQzKOt7i6fTpB126e+VoApcJZS7Fbq9lugNRp2Oa8XXJZq/Dt4N8BXPd5luMz3BBeeSLiuF86Ni7Mo/CGVdso6Th2UlJ/uQ7XNjyJ9jhNfTXC3xNI4IZC1vvr6Yex9NLN3RntpVluyL/VrJltZdQ2zSdY7rPkXJhbiM0UWvuLrHNefRxQbhRLzeCkkcXHXO0geFFLuqO7i1QiJkK1EyMN8qVhJeuErogs/cYp9Px7/jRRdjdXe+8nVNcuYDXGfQ==
  • Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=amd.com;
  • Cc: Stefano Stabellini <sstabellini@xxxxxxxxxx>, Luca Fancellu <luca.fancellu@xxxxxxx>, Bertrand Marquis <bertrand.marquis@xxxxxxx>, Michal Orzel <michal.orzel@xxxxxxx>, Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>
  • Delivery-date: Fri, 25 Apr 2025 14:16:52 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>


On 25/04/2025 15:05, Julien Grall wrote:
Hi Ayan,
Hi Julien,

On 25/04/2025 13:45, Ayan Kumar Halder wrote:
Add the definitions for HPRBAR<0..31>, HPRLAR<0..31> and HPRENR.
The definitions are taken from ARM DDI 0568A.c ID110520, E2.2.3 HPRBAR<n>,
E2.2.4 HPRENR and E2.2.6 HPRLAR<n>.

Introduce pr_t typedef which is a structure having the prbar and prlar members,
each being structured as the registers of the AArch32-V8R architecture.
This is the arm32 equivalent of
"arm/mpu: Introduce MPU memory region map structure".

Few differences worth noting:-
1. The XN in HPRBAR is 1 bit in Arm32 (unlike 2 bits in Arm64).
2. PRSELR_EL2 is not used to access HPRBAR<0..31> and HPRLAR<0..31>.

Introduce macros PR{B,L}AR_EL2_(num) to generate alias for the sysregs.

Also, took the opportunity to fix the register definition of HPRLAR.

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

v1 - 1. Introduce macros for PR{B,L}AR_EL2_(num). Similar macros need to be
defined for arm64 as well.
2. Some style fixes

Comments not addressed
1. Renaming of PRBAR_EL2_XN if needed.
2. Using res0 for ns.

Why are you rushing sending a new version that doesn't address most of the comments when ...
Sorry, as there were lot of comments, so I want to show the proposed changes. I should probably have waited until we are aligned on all the changes in v1.


This patch should be applied after
"[PATCH v3 0/7] First chunk for Arm R82 and MPU support" in order to enable
compilation for AArch32 and macros need to be defined for Arm64 as well.

... this depends on a patch still under review? This is not a very good use of reviewers time.

Ack.

- Ayan


Cheers,




 


Rackspace

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