Hi Dennis, On 17 October 2016 at 06:03, Dennis Chen <dennis.c...@arm.com> wrote: > Since ACPI spec defines the GIC base addresses (CPU interface, > Distributor and Redistributor*GICv3 only*) as 64-bit, so we > should define these corresponding base address variables as 64-bit > instead of 32-bit. This patch redefines them according to the > ACPI spec. > > Contributed-under: TianoCore Contribution Agreement 1.0 > Cc: Ard Biesheuvel <ard.biesheu...@linaro.org> > Cc: Leif Lindholm <leif.lindh...@linaro.org> > Signed-off-by: Dennis Chen <dennis.c...@arm.com> > --- > ArmPkg/Drivers/ArmGic/GicV2/ArmGicV2Dxe.c | 4 ++-- > ArmVirtPkg/Library/ArmVirtGicArchLib/ArmVirtGicArchLib.c | 8 ++++----
Could you split this patch in 2 please, and put Laszlo Ersek on cc for the ArmVirtPkg patch? > 2 files changed, 6 insertions(+), 6 deletions(-) > > diff --git a/ArmPkg/Drivers/ArmGic/GicV2/ArmGicV2Dxe.c > b/ArmPkg/Drivers/ArmGic/GicV2/ArmGicV2Dxe.c > index b9ecd55..a4ba5cf 100644 > --- a/ArmPkg/Drivers/ArmGic/GicV2/ArmGicV2Dxe.c > +++ b/ArmPkg/Drivers/ArmGic/GicV2/ArmGicV2Dxe.c > @@ -30,8 +30,8 @@ Abstract: > > extern EFI_HARDWARE_INTERRUPT_PROTOCOL gHardwareInterruptV2Protocol; > > -STATIC UINT32 mGicInterruptInterfaceBase; > -STATIC UINT32 mGicDistributorBase; > +STATIC UINTN mGicInterruptInterfaceBase; > +STATIC UINTN mGicDistributorBase; > This should be UINT64 not UINTN > /** > Enable interrupt source Source. > diff --git a/ArmVirtPkg/Library/ArmVirtGicArchLib/ArmVirtGicArchLib.c > b/ArmVirtPkg/Library/ArmVirtGicArchLib/ArmVirtGicArchLib.c > index 64afc4d..16683ef 100644 > --- a/ArmVirtPkg/Library/ArmVirtGicArchLib/ArmVirtGicArchLib.c > +++ b/ArmVirtPkg/Library/ArmVirtGicArchLib/ArmVirtGicArchLib.c > @@ -79,11 +79,11 @@ ArmVirtGicArchLibConstructor ( > > // RegProp[0..1] == { GICD base, GICD size } > DistBase = SwapBytes64 (Reg[0]); > - ASSERT (DistBase < MAX_UINT32); > + ASSERT (DistBase < MAX_UINT64); > This becomes equivalent to 'DistBase != MAX_UINT64' given that a UINT64 cannot exceed MAX_UINT64. That is a nonsensical thing to assert, so it is better to simply drop it > // RegProp[2..3] == { GICR base, GICR size } > RedistBase = SwapBytes64 (Reg[2]); > - ASSERT (RedistBase < MAX_UINT32); > + ASSERT (RedistBase < MAX_UINT64); > Likewise > PcdSet64 (PcdGicDistributorBase, DistBase); > PcdSet64 (PcdGicRedistributorsBase, RedistBase); > @@ -117,8 +117,8 @@ ArmVirtGicArchLibConstructor ( > > DistBase = SwapBytes64 (Reg[0]); > CpuBase = SwapBytes64 (Reg[2]); > - ASSERT (DistBase < MAX_UINT32); > - ASSERT (CpuBase < MAX_UINT32); > + ASSERT (DistBase < MAX_UINT64); > + ASSERT (CpuBase < MAX_UINT64); > Likewise > PcdSet64 (PcdGicDistributorBase, DistBase); > PcdSet64 (PcdGicInterruptInterfaceBase, CpuBase); > -- > 2.7.4 > _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel