From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by mx.groups.io with SMTP id smtpd.web12.8283.1606317485159093801 for ; Wed, 25 Nov 2020 07:18:05 -0800 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: arm.com, ip: 217.140.110.172, mailfrom: ard.biesheuvel@arm.com) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id D03E4106F; Wed, 25 Nov 2020 07:18:04 -0800 (PST) Received: from [192.168.1.81] (unknown [10.37.8.72]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id CC5D63F70D; Wed, 25 Nov 2020 07:18:03 -0800 (PST) Subject: Re: [edk2-platform][PATCH v1 1/1] Platforms/RaspberryPi: RPi4 PMU interrupts are SPI not PPI To: Samer El-Haj-Mahmoud , devel@edk2.groups.io Cc: Leif Lindholm , Pete Batard , Andrei Warkentin References: <20201125151108.21507-1-Samer.El-Haj-Mahmoud@arm.com> From: "Ard Biesheuvel" Message-ID: <549f4697-b565-20dd-415c-736de35a9430@arm.com> Date: Wed, 25 Nov 2020 16:18:02 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: <20201125151108.21507-1-Samer.El-Haj-Mahmoud@arm.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit On 11/25/20 4:11 PM, Samer El-Haj-Mahmoud wrote: > 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 > Cc: Pete Batard > Cc: Andrei Warkentin > Cc: Ard Biesheuvel > Signed-off-by: Samer El-Haj-Mahmoud Reviewed-by: Ard Biesheuvel Pushed as ff052d38e584..734fed7db671 > --- > 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. >