diff options
author | Guo Mang <mang.guo@intel.com> | 2017-04-27 11:27:21 +0800 |
---|---|---|
committer | Guo Mang <mang.guo@intel.com> | 2017-04-27 13:02:40 +0800 |
commit | 49960886c78f3011946da4dea204bc04911e69eb (patch) | |
tree | 654c52a89c751c238d895023f62a8fec2401dd43 /ArmVirtPkg/Library/ArmVirtTimerFdtClientLib | |
parent | 7e05ba1227ee2531cfb156b06f23a28d7ab8ef57 (diff) | |
download | edk2-platforms-49960886c78f3011946da4dea204bc04911e69eb.tar.xz |
ArmVirPkg: Remove unused Package
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Guo Mang <mang.guo@intel.com>
Diffstat (limited to 'ArmVirtPkg/Library/ArmVirtTimerFdtClientLib')
-rw-r--r-- | ArmVirtPkg/Library/ArmVirtTimerFdtClientLib/ArmVirtTimerFdtClientLib.c | 92 | ||||
-rw-r--r-- | ArmVirtPkg/Library/ArmVirtTimerFdtClientLib/ArmVirtTimerFdtClientLib.inf | 49 |
2 files changed, 0 insertions, 141 deletions
diff --git a/ArmVirtPkg/Library/ArmVirtTimerFdtClientLib/ArmVirtTimerFdtClientLib.c b/ArmVirtPkg/Library/ArmVirtTimerFdtClientLib/ArmVirtTimerFdtClientLib.c deleted file mode 100644 index c408386323..0000000000 --- a/ArmVirtPkg/Library/ArmVirtTimerFdtClientLib/ArmVirtTimerFdtClientLib.c +++ /dev/null @@ -1,92 +0,0 @@ -/** @file
- FDT client library for ARM's TimerDxe
-
- Copyright (c) 2016, Linaro Ltd. All rights reserved.<BR>
-
- This program and the accompanying materials
- are licensed and made available under the terms and conditions of the BSD License
- which accompanies this distribution. The full text of the license may be found at
- http://opensource.org/licenses/bsd-license.php
-
- THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
- WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-
-**/
-
-#include <Uefi.h>
-
-#include <Library/BaseLib.h>
-#include <Library/DebugLib.h>
-#include <Library/PcdLib.h>
-#include <Library/UefiBootServicesTableLib.h>
-
-#include <Protocol/FdtClient.h>
-
-#pragma pack (1)
-typedef struct {
- UINT32 Type;
- UINT32 Number;
- UINT32 Flags;
-} INTERRUPT_PROPERTY;
-#pragma pack ()
-
-RETURN_STATUS
-EFIAPI
-ArmVirtTimerFdtClientLibConstructor (
- VOID
- )
-{
- EFI_STATUS Status;
- FDT_CLIENT_PROTOCOL *FdtClient;
- CONST INTERRUPT_PROPERTY *InterruptProp;
- UINT32 PropSize;
- INT32 SecIntrNum, IntrNum, VirtIntrNum, HypIntrNum;
- RETURN_STATUS PcdStatus;
-
- Status = gBS->LocateProtocol (&gFdtClientProtocolGuid, NULL,
- (VOID **)&FdtClient);
- ASSERT_EFI_ERROR (Status);
-
- Status = FdtClient->FindCompatibleNodeProperty (FdtClient, "arm,armv7-timer",
- "interrupts", (CONST VOID **)&InterruptProp,
- &PropSize);
- if (Status == EFI_NOT_FOUND) {
- Status = FdtClient->FindCompatibleNodeProperty (FdtClient,
- "arm,armv8-timer", "interrupts",
- (CONST VOID **)&InterruptProp,
- &PropSize);
- }
-
- if (EFI_ERROR (Status)) {
- return Status;
- }
-
- //
- // - interrupts : Interrupt list for secure, non-secure, virtual and
- // hypervisor timers, in that order.
- //
- ASSERT (PropSize == 36 || PropSize == 48);
-
- SecIntrNum = SwapBytes32 (InterruptProp[0].Number)
- + (InterruptProp[0].Type ? 16 : 0);
- IntrNum = SwapBytes32 (InterruptProp[1].Number)
- + (InterruptProp[1].Type ? 16 : 0);
- VirtIntrNum = SwapBytes32 (InterruptProp[2].Number)
- + (InterruptProp[2].Type ? 16 : 0);
- HypIntrNum = PropSize < 48 ? 0 : SwapBytes32 (InterruptProp[3].Number)
- + (InterruptProp[3].Type ? 16 : 0);
-
- DEBUG ((EFI_D_INFO, "Found Timer interrupts %d, %d, %d, %d\n",
- SecIntrNum, IntrNum, VirtIntrNum, HypIntrNum));
-
- PcdStatus = PcdSet32S (PcdArmArchTimerSecIntrNum, SecIntrNum);
- ASSERT_RETURN_ERROR (PcdStatus);
- PcdStatus = PcdSet32S (PcdArmArchTimerIntrNum, IntrNum);
- ASSERT_RETURN_ERROR (PcdStatus);
- PcdStatus = PcdSet32S (PcdArmArchTimerVirtIntrNum, VirtIntrNum);
- ASSERT_RETURN_ERROR (PcdStatus);
- PcdStatus = PcdSet32S (PcdArmArchTimerHypIntrNum, HypIntrNum);
- ASSERT_RETURN_ERROR (PcdStatus);
-
- return EFI_SUCCESS;
-}
diff --git a/ArmVirtPkg/Library/ArmVirtTimerFdtClientLib/ArmVirtTimerFdtClientLib.inf b/ArmVirtPkg/Library/ArmVirtTimerFdtClientLib/ArmVirtTimerFdtClientLib.inf deleted file mode 100644 index bc7089f103..0000000000 --- a/ArmVirtPkg/Library/ArmVirtTimerFdtClientLib/ArmVirtTimerFdtClientLib.inf +++ /dev/null @@ -1,49 +0,0 @@ -#/** @file
-# FDT client library for ARM's TimerDxe
-#
-# Copyright (c) 2016, Linaro Ltd. All rights reserved.
-#
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
-#
-#**/
-
-[Defines]
- INF_VERSION = 0x00010005
- BASE_NAME = ArmVirtTimerFdtClientLib
- FILE_GUID = 77EA80CA-2EFB-4AB4-8567-230D968F6B37
- MODULE_TYPE = BASE
- VERSION_STRING = 1.0
- LIBRARY_CLASS = ArmVirtTimerFdtClientLib|DXE_DRIVER
- CONSTRUCTOR = ArmVirtTimerFdtClientLibConstructor
-
-[Sources]
- ArmVirtTimerFdtClientLib.c
-
-[Packages]
- ArmPkg/ArmPkg.dec
- ArmVirtPkg/ArmVirtPkg.dec
- MdePkg/MdePkg.dec
-
-[LibraryClasses]
- BaseLib
- DebugLib
- PcdLib
- UefiBootServicesTableLib
-
-[Protocols]
- gFdtClientProtocolGuid ## CONSUMES
-
-[Pcd]
- gArmTokenSpaceGuid.PcdArmArchTimerSecIntrNum
- gArmTokenSpaceGuid.PcdArmArchTimerIntrNum
- gArmTokenSpaceGuid.PcdArmArchTimerVirtIntrNum
- gArmTokenSpaceGuid.PcdArmArchTimerHypIntrNum
-
-[Depex]
- gFdtClientProtocolGuid
|