summaryrefslogtreecommitdiffstats
path: root/ArmPkg/ArmPkg.dec
diff options
context:
space:
mode:
authorArd Biesheuvel <ard.biesheuvel@linaro.org>2016-11-12 14:02:28 +0100
committerLeif Lindholm <leif.lindholm@linaro.org>2016-11-30 16:43:14 +0000
commitbfe34275a9bf56a7f8ea9d19fe10cbbee599148d (patch)
tree9d9997bc52c2e3c450c3d85a0d6365657ddc149f /ArmPkg/ArmPkg.dec
parentdf8c2668d7277030cf98e7b218549e0466fa5f6b (diff)
downloadedk2-bfe34275a9bf56a7f8ea9d19fe10cbbee599148d.tar.gz
edk2-bfe34275a9bf56a7f8ea9d19fe10cbbee599148d.tar.bz2
edk2-bfe34275a9bf56a7f8ea9d19fe10cbbee599148d.zip
ArmPkg/ArmDmaLib: add support for fixed host-to-device DMA offset
Some devices, such as the Raspberry Pi3, have a fixed offset between memory addresses as seen by the host and as seen by the other bus masters. So add a new PCD that allows this fixed offset to be recorded, and to be used when returning device addresses from the DmaLib mapping routines. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Tested-by: Ryan Harkin <ryan.harkin@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
Diffstat (limited to 'ArmPkg/ArmPkg.dec')
-rw-r--r--ArmPkg/ArmPkg.dec8
1 files changed, 8 insertions, 0 deletions
diff --git a/ArmPkg/ArmPkg.dec b/ArmPkg/ArmPkg.dec
index 3cdb5da3d4..090ed99513 100644
--- a/ArmPkg/ArmPkg.dec
+++ b/ArmPkg/ArmPkg.dec
@@ -134,6 +134,14 @@
gArmTokenSpaceGuid.PcdFdSize|0|UINT32|0x0000002C
gArmTokenSpaceGuid.PcdFvSize|0|UINT32|0x0000002E
+ #
+ # Value to add to a host address to obtain a device address, using
+ # unsigned 64-bit integer arithmetic on both ARM and AArch64. This
+ # means we can rely on truncation on overflow to specify negative
+ # offsets.
+ #
+ gArmTokenSpaceGuid.PcdArmDmaDeviceOffset|0x0|UINT64|0x0000044
+
[PcdsFixedAtBuild.common, PcdsPatchableInModule.common]
gArmTokenSpaceGuid.PcdFdBaseAddress|0|UINT64|0x0000002B
gArmTokenSpaceGuid.PcdFvBaseAddress|0|UINT64|0x0000002D