[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [PATCH v1 2/3] arm/mpu: Provide and populate MPU C data structures
On 05/06/2025 10:58, Julien Grall wrote: > Hi Michal, > > On 05/06/2025 08:44, Orzel, Michal wrote: >> >> >> On 04/06/2025 19:43, Ayan Kumar Halder wrote: >>> Do the arm32 equivalent initialization for commit id ca5df936c4. >> This is not a good commit msg. >> Also, we somewhat require passing 12 char long IDs. > > We are following the same convention as Linux. IIRC this was updated > because there was some collision with 10 characters in Linux (not sure > if we have seen it in Xen yet). > > [...] > >>> diff --git a/xen/arch/arm/include/asm/mpu/regions.inc >>> b/xen/arch/arm/include/asm/mpu/regions.inc >>> index 6b8c233e6c..943bcda346 100644 >>> --- a/xen/arch/arm/include/asm/mpu/regions.inc >>> +++ b/xen/arch/arm/include/asm/mpu/regions.inc >>> @@ -24,7 +24,13 @@ >>> #define XEN_MPUMAP_ENTRY_SHIFT 0x3 /* 8 byte structure */ >>> >>> .macro store_pair reg1, reg2, dst >>> - .word 0xe7f000f0 /* unimplemented */ >>> + str \reg1, [\dst] >>> + add \dst, \dst, #4 >>> + str \reg2, [\dst] >> AFAIR there is STM instruction to do the same > > AFAICT, one issue with stm is the ordering is forced by the instruction > rather than the user. So \reg1 could be stored first. Yes, I think it stores based on register number. So if you do {r2, r1} it will still store r1 first. > > I think it would be better to use "strd". It still has restriction > (the two registers need to have contiguous index). But I think that > would be better if we want to reduce the number of instructions. Ok ~Michal
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |