From: Samer El-Haj-Mahmoud <sa...@elhajmahmoud.com>

Replace MMCHS1BASE with PcdMmcHs1BaseAddress. This is
needed in preparation for adding Raspberry Pi 4 support

Signed-off-by: Pete Batard <p...@akeo.ie>
---
 Platform/RaspberryPi/Drivers/ArasanMmcHostDxe/ArasanMmcHostDxe.inf | 1 +
 Platform/RaspberryPi/RPi3/RPi3.dsc                                 | 1 +
 Silicon/Broadcom/Bcm283x/Bcm283x.dec                               | 1 +
 Silicon/Broadcom/Bcm283x/Include/IndustryStandard/Bcm2836Sdio.h    | 3 ++-
 4 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/Platform/RaspberryPi/Drivers/ArasanMmcHostDxe/ArasanMmcHostDxe.inf 
b/Platform/RaspberryPi/Drivers/ArasanMmcHostDxe/ArasanMmcHostDxe.inf
index 034c8c449f00..0d7c57152107 100644
--- a/Platform/RaspberryPi/Drivers/ArasanMmcHostDxe/ArasanMmcHostDxe.inf
+++ b/Platform/RaspberryPi/Drivers/ArasanMmcHostDxe/ArasanMmcHostDxe.inf
@@ -44,6 +44,7 @@ [Protocols]
 [Pcd]
   gRaspberryPiTokenSpaceGuid.PcdSdIsArasan
   gBcm283xTokenSpaceGuid.PcdBcm283xRegistersAddress
+  gBcm283xTokenSpaceGuid.PcdMmcHs1BaseAddress
 
 [Depex]
   gRaspberryPiFirmwareProtocolGuid AND gRaspberryPiConfigAppliedProtocolGuid
diff --git a/Platform/RaspberryPi/RPi3/RPi3.dsc 
b/Platform/RaspberryPi/RPi3/RPi3.dsc
index 88af37e6edaa..059549068e02 100644
--- a/Platform/RaspberryPi/RPi3/RPi3.dsc
+++ b/Platform/RaspberryPi/RPi3/RPi3.dsc
@@ -378,6 +378,7 @@ [PcdsFixedAtBuild.common]
   gBcm283xTokenSpaceGuid.PcdBcm283xRegistersAddress|0x3f000000
   gBcm283xTokenSpaceGuid.PcdMboxBaseAddress|0x3f00b880
   gBcm283xTokenSpaceGuid.PcdWdogBaseAddress|0x3f100000
+  gBcm283xTokenSpaceGuid.PcdMmcHs1BaseAddress|0x3f300000
 
   ## NS16550 compatible UART
   gEfiMdeModulePkgTokenSpaceGuid.PcdSerialRegisterBase|0x3f215040
diff --git a/Silicon/Broadcom/Bcm283x/Bcm283x.dec 
b/Silicon/Broadcom/Bcm283x/Bcm283x.dec
index fe1907cb8cf1..5053077e6448 100644
--- a/Silicon/Broadcom/Bcm283x/Bcm283x.dec
+++ b/Silicon/Broadcom/Bcm283x/Bcm283x.dec
@@ -23,3 +23,4 @@ [PcdsFixedAtBuild.common]
   gBcm283xTokenSpaceGuid.PcdBcm283xRegistersAddress|0x0|UINT32|0x00000001
   gBcm283xTokenSpaceGuid.PcdMboxBaseAddress|0x0|UINT32|0x00000002
   gBcm283xTokenSpaceGuid.PcdWdogBaseAddress|0x0|UINT32|0x00000003
+  gBcm283xTokenSpaceGuid.PcdMmcHs1BaseAddress|0x0|UINT32|0x00000004
diff --git a/Silicon/Broadcom/Bcm283x/Include/IndustryStandard/Bcm2836Sdio.h 
b/Silicon/Broadcom/Bcm283x/Include/IndustryStandard/Bcm2836Sdio.h
index fb0d02904156..ac2581d4cb64 100644
--- a/Silicon/Broadcom/Bcm283x/Include/IndustryStandard/Bcm2836Sdio.h
+++ b/Silicon/Broadcom/Bcm283x/Include/IndustryStandard/Bcm2836Sdio.h
@@ -1,5 +1,6 @@
 /** @file
  *
+ *  Copyright (c) 2019, ARM Limited. All rights reserved.
  *  Copyright (c) Microsoft Corporation. All rights reserved.
  *
  *  SPDX-License-Identifier: BSD-2-Clause-Patent
@@ -10,7 +11,7 @@
 #define __BCM2836_SDIO_H__
 
 //MMC/SD/SDIO1 register definitions.
-#define MMCHS1BASE        0x3F300000
+#define MMCHS1BASE        (FixedPcdGet64 (PcdMmcHs1BaseAddress))
 
 #define MMCHS_BLK         (MMCHS1BASE + 0x4)
 #define BLEN_512BYTES     (0x200UL << 0)
-- 
2.21.0.windows.1


-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.

View/Reply Online (#50696): https://edk2.groups.io/g/devel/message/50696
Mute This Topic: https://groups.io/mt/57792678/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to