summaryrefslogtreecommitdiffstats
path: root/ArmVirtPkg
diff options
context:
space:
mode:
authorArd Biesheuvel <ard.biesheuvel@linaro.org>2016-04-08 11:44:57 +0200
committerArd Biesheuvel <ard.biesheuvel@linaro.org>2016-04-11 18:12:22 +0200
commit479d5c4175e77f1cd7e61855fa3c9f83c330ef4f (patch)
treef08c6a1b40b8d7a6dcd1df907c38834aecb65293 /ArmVirtPkg
parentffced3854600359049b483ee3b45f2a5a406696d (diff)
downloadedk2-479d5c4175e77f1cd7e61855fa3c9f83c330ef4f.tar.gz
edk2-479d5c4175e77f1cd7e61855fa3c9f83c330ef4f.tar.bz2
edk2-479d5c4175e77f1cd7e61855fa3c9f83c330ef4f.zip
ArmVirtPkg/VirtFdtDxe: remove timer DT node handling
The timer code no longer relies on VirtFdtDxe to set the PCDs, so remove the handling of the timer node and the references to those PCDs. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Laszlo Ersek <lersek@redhat.com>
Diffstat (limited to 'ArmVirtPkg')
-rw-r--r--ArmVirtPkg/VirtFdtDxe/VirtFdtDxe.c39
-rw-r--r--ArmVirtPkg/VirtFdtDxe/VirtFdtDxe.inf4
2 files changed, 1 insertions, 42 deletions
diff --git a/ArmVirtPkg/VirtFdtDxe/VirtFdtDxe.c b/ArmVirtPkg/VirtFdtDxe/VirtFdtDxe.c
index 4a4713cf6a..368618956b 100644
--- a/ArmVirtPkg/VirtFdtDxe/VirtFdtDxe.c
+++ b/ArmVirtPkg/VirtFdtDxe/VirtFdtDxe.c
@@ -45,7 +45,6 @@ typedef enum {
PropertyTypeRtc,
PropertyTypeVirtio,
PropertyTypeUart,
- PropertyTypeTimer,
PropertyTypeFwCfg,
PropertyTypePciHost,
PropertyTypeXen,
@@ -60,20 +59,12 @@ STATIC CONST PROPERTY CompatibleProperties[] = {
{ PropertyTypeRtc, "arm,pl031" },
{ PropertyTypeVirtio, "virtio,mmio" },
{ PropertyTypeUart, "arm,pl011" },
- { PropertyTypeTimer, "arm,armv7-timer" },
- { PropertyTypeTimer, "arm,armv8-timer" },
{ PropertyTypeFwCfg, "qemu,fw-cfg-mmio" },
{ PropertyTypePciHost, "pci-host-ecam-generic" },
{ PropertyTypeXen, "xen,xen" },
{ PropertyTypeUnknown, "" }
};
-typedef struct {
- UINT32 Type;
- UINT32 Number;
- UINT32 Flags;
-} INTERRUPT_PROPERTY;
-
STATIC
PROPERTY_TYPE
GetTypeFromNode (
@@ -288,8 +279,6 @@ InitializeVirtFdtDxe (
VIRTIO_TRANSPORT_DEVICE_PATH *DevicePath;
EFI_HANDLE Handle;
UINT64 RegBase;
- CONST INTERRUPT_PROPERTY *InterruptProp;
- INT32 SecIntrNum, IntrNum, VirtIntrNum, HypIntrNum;
UINT64 FwCfgSelectorAddress;
UINT64 FwCfgSelectorSize;
UINT64 FwCfgDataAddress;
@@ -339,7 +328,7 @@ InitializeVirtFdtDxe (
// TODO use #cells root properties instead
//
RegProp = fdt_getprop (DeviceTreeBase, Node, "reg", &Len);
- ASSERT ((RegProp != NULL) || (PropType == PropertyTypeTimer));
+ ASSERT (RegProp != NULL);
switch (PropType) {
case PropertyTypePciHost:
@@ -449,32 +438,6 @@ InitializeVirtFdtDxe (
RtcNode = Node;
break;
- case PropertyTypeTimer:
- //
- // - interrupts : Interrupt list for secure, non-secure, virtual and
- // hypervisor timers, in that order.
- //
- InterruptProp = fdt_getprop (DeviceTreeBase, Node, "interrupts", &Len);
- ASSERT (Len == 36 || Len == 48);
-
- SecIntrNum = fdt32_to_cpu (InterruptProp[0].Number)
- + (InterruptProp[0].Type ? 16 : 0);
- IntrNum = fdt32_to_cpu (InterruptProp[1].Number)
- + (InterruptProp[1].Type ? 16 : 0);
- VirtIntrNum = fdt32_to_cpu (InterruptProp[2].Number)
- + (InterruptProp[2].Type ? 16 : 0);
- HypIntrNum = Len < 48 ? 0 : fdt32_to_cpu (InterruptProp[3].Number)
- + (InterruptProp[3].Type ? 16 : 0);
-
- DEBUG ((EFI_D_INFO, "Found Timer interrupts %d, %d, %d, %d\n",
- SecIntrNum, IntrNum, VirtIntrNum, HypIntrNum));
-
- PcdSet32 (PcdArmArchTimerSecIntrNum, SecIntrNum);
- PcdSet32 (PcdArmArchTimerIntrNum, IntrNum);
- PcdSet32 (PcdArmArchTimerVirtIntrNum, VirtIntrNum);
- PcdSet32 (PcdArmArchTimerHypIntrNum, HypIntrNum);
- break;
-
case PropertyTypeXen:
ASSERT (Len == 16);
diff --git a/ArmVirtPkg/VirtFdtDxe/VirtFdtDxe.inf b/ArmVirtPkg/VirtFdtDxe/VirtFdtDxe.inf
index 5526fd1925..c928e826c2 100644
--- a/ArmVirtPkg/VirtFdtDxe/VirtFdtDxe.inf
+++ b/ArmVirtPkg/VirtFdtDxe/VirtFdtDxe.inf
@@ -53,10 +53,6 @@
gArmVirtTokenSpaceGuid.PcdFwCfgSelectorAddress
gArmVirtTokenSpaceGuid.PcdFwCfgDataAddress
gArmVirtTokenSpaceGuid.PcdFwCfgDmaAddress
- gArmTokenSpaceGuid.PcdArmArchTimerSecIntrNum
- gArmTokenSpaceGuid.PcdArmArchTimerIntrNum
- gArmTokenSpaceGuid.PcdArmArchTimerVirtIntrNum
- gArmTokenSpaceGuid.PcdArmArchTimerHypIntrNum
gArmPlatformTokenSpaceGuid.PcdPL031RtcBase
gArmPlatformTokenSpaceGuid.PcdPciBusMin
gArmPlatformTokenSpaceGuid.PcdPciBusMax