public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* [edk2-platform][PATCH v1 1/1] Platforms/RaspberryPi: RPi4 PMU interrupts are SPI not PPI
@ 2020-11-25 15:11 Samer El-Haj-Mahmoud
  2020-11-25 15:18 ` Ard Biesheuvel
  0 siblings, 1 reply; 2+ messages in thread
From: Samer El-Haj-Mahmoud @ 2020-11-25 15:11 UTC (permalink / raw)
  To: devel; +Cc: Leif Lindholm, Pete Batard, Andrei Warkentin, Ard Biesheuvel

REF: https://github.com/pftf/RPi4/issues/103

Commit 602a7ea1ab6d changed the RPi4 PMU interrupts reported
in GICC to the PPI values recommended by SBSA specification.
This caused the PMU overflow interrupts to stop working.

The RPi documentation (Figure 7, page 111) state that the
PMU interrupts are SPI not PPI: https://www.raspberrypi.org/
documentation/hardware/raspberrypi/bcm2711/rpi_DATA_2711_1p0.pdf

Also, the BSA 1.0 spec (page 24) clarifies hat the PPI values are
recommendations, not requirements:
https://developer.arm.com/documentation/den0094/latest

Fix by reverting to the old SPI values per the RPi spec.

Cc: Leif Lindholm <leif@nuviainc.com>
Cc: Pete Batard <pete@akeo.ie>
Cc: Andrei Warkentin <awarkentin@vmware.com>
Cc: Ard Biesheuvel <ard.biesheuvel@arm.com>
Signed-off-by: Samer El-Haj-Mahmoud <Samer.El-Haj-Mahmoud@arm.com>
---
 Platform/RaspberryPi/RPi4/RPi4.dsc | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/Platform/RaspberryPi/RPi4/RPi4.dsc b/Platform/RaspberryPi/RPi4/RPi4.dsc
index 4e5a36edb76a..ddf4dd6a416e 100644
--- a/Platform/RaspberryPi/RPi4/RPi4.dsc
+++ b/Platform/RaspberryPi/RPi4/RPi4.dsc
@@ -440,10 +440,10 @@ [PcdsFixedAtBuild.common]
   gRaspberryPiTokenSpaceGuid.PcdGicInterruptInterfaceHBase|0xFF844000
   gRaspberryPiTokenSpaceGuid.PcdGicInterruptInterfaceVBase|0xFF846000
   gRaspberryPiTokenSpaceGuid.PcdGicGsivId|0x19
-  gRaspberryPiTokenSpaceGuid.PcdGicPmuIrq0|23
-  gRaspberryPiTokenSpaceGuid.PcdGicPmuIrq1|23
-  gRaspberryPiTokenSpaceGuid.PcdGicPmuIrq2|23
-  gRaspberryPiTokenSpaceGuid.PcdGicPmuIrq3|23
+  gRaspberryPiTokenSpaceGuid.PcdGicPmuIrq0|0x30
+  gRaspberryPiTokenSpaceGuid.PcdGicPmuIrq1|0x31
+  gRaspberryPiTokenSpaceGuid.PcdGicPmuIrq2|0x32
+  gRaspberryPiTokenSpaceGuid.PcdGicPmuIrq3|0x33
 
   #
   # Fixed CPU settings.
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-11-25 15:18 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-11-25 15:11 [edk2-platform][PATCH v1 1/1] Platforms/RaspberryPi: RPi4 PMU interrupts are SPI not PPI Samer El-Haj-Mahmoud
2020-11-25 15:18 ` Ard Biesheuvel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox