]> git.proxmox.com Git - mirror_edk2.git/commitdiff
Remove DebugSupport driver for ARM and DebugSupportProtocol. In edk2 you can link...
authorandrewfish <andrewfish@6f19259b-4bc3-4df7-8a09-765794883524>
Tue, 18 May 2010 00:54:24 +0000 (00:54 +0000)
committerandrewfish <andrewfish@6f19259b-4bc3-4df7-8a09-765794883524>
Tue, 18 May 2010 00:54:24 +0000 (00:54 +0000)
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@10495 6f19259b-4bc3-4df7-8a09-765794883524

ArmPkg/ArmPkg.dec
ArmPkg/Include/Protocol/TimerDebugSupport.h [deleted file]
EmbeddedPkg/DebugSupportDxe/DebugSupport.c [deleted file]
EmbeddedPkg/DebugSupportDxe/DebugSupportDxe.inf [deleted file]
Omap35xxPkg/TimerDxe/Timer.c
Omap35xxPkg/TimerDxe/TimerDxe.inf

index cd672c427fac0c1772977c10e890afb7d9cabb4d..0b8c101c821b7c27a45687edf513d720d5db217e 100644 (file)
@@ -42,7 +42,6 @@
   gArmTokenSpaceGuid       = { 0xBB11ECFE, 0x820F, 0x4968, { 0xBB, 0xA6, 0xF7, 0x6A, 0xFE, 0x30, 0x25, 0x96 } }\r
 \r
 [Protocols.common]\r
-  gTimerDebugSupportProtocolGuid = { 0x68300561, 0x0197, 0x465d, { 0xb5, 0xa1, 0x28, 0xeb, 0xa1, 0x98, 0xdd, 0x0b } }\r
   gVirtualUncachedPagesProtocolGuid = { 0xAD651C7D, 0x3C22, 0x4DBF, { 0x92, 0xe8, 0x38, 0xa7, 0xcd, 0xae, 0x87, 0xb2 } }\r
 \r
 [PcdsFeatureFlag.common]\r
diff --git a/ArmPkg/Include/Protocol/TimerDebugSupport.h b/ArmPkg/Include/Protocol/TimerDebugSupport.h
deleted file mode 100644 (file)
index ca2601e..0000000
+++ /dev/null
@@ -1,59 +0,0 @@
-/** @file\r
-\r
-  Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>\r
-\r
-  This program and the accompanying materials\r
-  are licensed and made available under the terms and conditions of the BSD License\r
-  which accompanies this distribution.  The full text of the license may be found at\r
-  http://opensource.org/licenses/bsd-license.php\r
-\r
-  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
-  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
-\r
-**/\r
-\r
-#ifndef __TIMERDEBUGSUPPORTPROTOCOL_H__\r
-#define __TIMERDEBUGSUPPORTPROTOCOL_H__\r
-\r
-//\r
-// Protocol GUID\r
-//\r
-#define TIMER_DEBUG_PROTOCOL_GUID { 0x68300561, 0x0197, 0x465d, { 0xb5, 0xa1, 0x28, 0xeb, 0xa1, 0x98, 0xdd, 0x0b } }\r
-\r
-\r
-\r
-//\r
-// Protocol interface structure\r
-//\r
-typedef struct _TIMER_DEBUG_SUPPORT_PROTOCOL  TIMER_DEBUG_SUPPORT_PROTOCOL;\r
-\r
-\r
-typedef\r
-EFI_STATUS\r
-(EFIAPI *TIMER_DEBUG_SUPPORT_REGISTER_PERIODIC_CALLBACK) (\r
-  IN  TIMER_DEBUG_SUPPORT_PROTOCOL  *This,\r
-  IN  EFI_PERIODIC_CALLBACK         PeriodicCallback\r
-  )\r
-/*++\r
-\r
-Routine Description:\r
-  Register a periodic callback for debug support.\r
-\r
-Arguments:\r
-  This              - pointer to protocol\r
-  PeriodicCallback  - callback to be registered\r
-  \r
-Returns:\r
-  EFI_SUCCESS - callback registered\r
-\r
---*/\r
-;\r
-\r
-struct _TIMER_DEBUG_SUPPORT_PROTOCOL {\r
-  TIMER_DEBUG_SUPPORT_REGISTER_PERIODIC_CALLBACK  RegisterPeriodicCallback;\r
-};\r
-\r
-extern EFI_GUID gTimerDebugSupportProtocolGuid;\r
-\r
-#endif // __TIMERDEBUGSUPPORTPROTOCOL_H__\r
-\r
diff --git a/EmbeddedPkg/DebugSupportDxe/DebugSupport.c b/EmbeddedPkg/DebugSupportDxe/DebugSupport.c
deleted file mode 100644 (file)
index 5498aab..0000000
+++ /dev/null
@@ -1,119 +0,0 @@
-/** @file\r
-\r
-  Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>\r
-  \r
-  This program and the accompanying materials\r
-  are licensed and made available under the terms and conditions of the BSD License\r
-  which accompanies this distribution.  The full text of the license may be found at\r
-  http://opensource.org/licenses/bsd-license.php\r
-\r
-  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
-  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
-\r
-**/\r
-\r
-#include <Uefi.h>\r
-\r
-#include <Library/CacheMaintenanceLib.h>\r
-#include <Library/DebugLib.h>\r
-#include <Library/UefiBootServicesTableLib.h>\r
-\r
-#include <Protocol/Cpu.h>\r
-#include <Protocol/DebugSupport.h>\r
-#include <Protocol/TimerDebugSupport.h>\r
-\r
-EFI_STATUS\r
-EFIAPI\r
-DebugSupportGetMaximumProcessorIndex (\r
-  IN  EFI_DEBUG_SUPPORT_PROTOCOL  *This,\r
-  OUT UINTN                       *MaxProcessorIndex\r
-  )\r
-{\r
-  if (MaxProcessorIndex == NULL) {\r
-    return EFI_INVALID_PARAMETER;\r
-  }\r
-\r
-  *MaxProcessorIndex = 0;\r
-\r
-  return EFI_SUCCESS;\r
-}\r
-\r
-EFI_STATUS\r
-EFIAPI\r
-DebugSupportRegisterPeriodicCallback (\r
-  IN  EFI_DEBUG_SUPPORT_PROTOCOL  *This,\r
-  IN  UINTN                       ProcessorIndex,\r
-  IN  EFI_PERIODIC_CALLBACK       PeriodicCallback\r
-  )\r
-{\r
-  TIMER_DEBUG_SUPPORT_PROTOCOL  *Timer;\r
-  EFI_STATUS                    Status;\r
-\r
-  Status = gBS->LocateProtocol(&gTimerDebugSupportProtocolGuid, NULL, (VOID **)&Timer);\r
-  if (EFI_ERROR(Status)) {\r
-    return Status;\r
-  }\r
-\r
-  Status = Timer->RegisterPeriodicCallback(Timer, PeriodicCallback);\r
-\r
-  return Status;\r
-}\r
-\r
-EFI_STATUS\r
-EFIAPI\r
-DebugSupportRegisterExceptionCallback (\r
-  IN  EFI_DEBUG_SUPPORT_PROTOCOL  *This,\r
-  IN  UINTN                       ProcessorIndex,\r
-  IN  EFI_EXCEPTION_CALLBACK      ExceptionCallback,\r
-  IN  EFI_EXCEPTION_TYPE          ExceptionType\r
-  )\r
-{\r
-  EFI_CPU_ARCH_PROTOCOL *Cpu;\r
-  EFI_STATUS            Status;\r
-\r
-  Status = gBS->LocateProtocol(&gEfiCpuArchProtocolGuid, NULL, (VOID **)&Cpu);\r
-  if (EFI_ERROR(Status)) {\r
-    return Status;\r
-  }\r
-\r
-  Status = Cpu->RegisterInterruptHandler(Cpu, ExceptionType, (EFI_CPU_INTERRUPT_HANDLER)ExceptionCallback);\r
-\r
-  return Status;\r
-}\r
-\r
-EFI_STATUS\r
-EFIAPI\r
-DebugSupportInvalidateInstructionCache (\r
-  IN  EFI_DEBUG_SUPPORT_PROTOCOL  *This,\r
-  IN  UINTN                       ProcessorIndex,\r
-  IN  VOID                        *Start,\r
-  IN  UINT64                      Length\r
-  )\r
-{\r
-  InvalidateInstructionCacheRange(Start, Length);\r
-  return EFI_SUCCESS;\r
-}\r
-\r
-EFI_DEBUG_SUPPORT_PROTOCOL  mDebugSupport = {\r
-  IsaArm,\r
-  DebugSupportGetMaximumProcessorIndex,\r
-  DebugSupportRegisterPeriodicCallback,\r
-  DebugSupportRegisterExceptionCallback,\r
-  DebugSupportInvalidateInstructionCache\r
-};\r
-\r
-EFI_STATUS\r
-DebugSupportDxeInitialize (\r
-  IN EFI_HANDLE         ImageHandle,\r
-  IN EFI_SYSTEM_TABLE   *SystemTable\r
-  )\r
-{\r
-  EFI_STATUS  Status;\r
-  EFI_HANDLE  Handle = NULL;\r
-\r
-  ASSERT_PROTOCOL_ALREADY_INSTALLED (NULL, &gEfiDebugSupportProtocolGuid);\r
-  Status = gBS->InstallMultipleProtocolInterfaces(&Handle, &gEfiDebugSupportProtocolGuid, &mDebugSupport, NULL);\r
-\r
-  return Status;\r
-}\r
-\r
diff --git a/EmbeddedPkg/DebugSupportDxe/DebugSupportDxe.inf b/EmbeddedPkg/DebugSupportDxe/DebugSupportDxe.inf
deleted file mode 100644 (file)
index dea40d9..0000000
+++ /dev/null
@@ -1,40 +0,0 @@
-#/** @file\r
-#  \r
-#  Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>\r
-#  This program and the accompanying materials\r
-#  are licensed and made available under the terms and conditions of the BSD License\r
-#  which accompanies this distribution.  The full text of the license may be found at\r
-#  http://opensource.org/licenses/bsd-license.php\r
-#  \r
-#  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
-#  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
-#  \r
-#**/\r
-\r
-[Defines]\r
-  INF_VERSION                    = 0x00010005\r
-  BASE_NAME                      = ArmDebugSupportDxe\r
-  FILE_GUID                      = 2e7c151b-cbd8-4df6-a0e3-cde660067c6a\r
-  MODULE_TYPE                    = DXE_DRIVER\r
-  VERSION_STRING                 = 1.0\r
-\r
-  ENTRY_POINT                    = DebugSupportDxeInitialize\r
-\r
-[Sources.common]\r
-  DebugSupport.c\r
-\r
-[Packages]\r
-  MdePkg/MdePkg.dec\r
-  EmbeddedePkg/EmbeddedePkg.dec\r
-\r
-[LibraryClasses]\r
-  BaseMemoryLib\r
-  CacheMaintenanceLib\r
-  UefiDriverEntryPoint\r
-  ArmLib\r
-\r
-[Protocols]\r
-  gEfiCpuArchProtocolGuid\r
-  gEfiDebugSupportProtocolGuid\r
-  gTimerDebugSupportProtocolGuid\r
-  \r
index b5fc6e145a9f314aed7652bf3bbffe0d848351cd..1919618ef266431c8db9f125929d59044a9aad64 100644 (file)
 
 #include <Protocol/Timer.h>
 #include <Protocol/HardwareInterrupt.h>
-#include <Protocol/TimerDebugSupport.h>
 
 #include <Omap3530/Omap3530.h>
 
 
 // The notification function to call on every timer interrupt.
 volatile EFI_TIMER_NOTIFY      mTimerNotifyFunction   = (EFI_TIMER_NOTIFY)NULL;
-volatile EFI_PERIODIC_CALLBACK mTimerPeriodicCallback = (EFI_PERIODIC_CALLBACK)NULL;
 
 
 // The current period of the timer interrupt
@@ -85,11 +83,6 @@ TimerInterruptHandler (
   //
   OriginalTPL = gBS->RaiseTPL (TPL_HIGH_LEVEL);
 
-
-  if (mTimerPeriodicCallback) {
-    mTimerPeriodicCallback(SystemContext);
-  }
-
   if (mTimerNotifyFunction) {
     mTimerNotifyFunction(mTimerPeriod);
   }
@@ -276,27 +269,6 @@ TimerDriverGenerateSoftInterrupt (
 }
 
 
-EFI_STATUS
-EFIAPI
-TimerDriverRegisterPeriodicCallback (
-  IN  TIMER_DEBUG_SUPPORT_PROTOCOL  *This,
-  IN  EFI_PERIODIC_CALLBACK         PeriodicCallback
-  )
-{
-  if ((PeriodicCallback == NULL) && (mTimerPeriodicCallback == NULL)) {
-    return EFI_INVALID_PARAMETER;
-  }
-
-  if ((PeriodicCallback != NULL) && (mTimerPeriodicCallback != NULL)) {
-    return EFI_ALREADY_STARTED;
-  }
-
-  mTimerPeriodicCallback = PeriodicCallback;
-
-  return EFI_SUCCESS;
-}
-
-
 /**
   Interface stucture for the Timer Architectural Protocol.
 
@@ -338,10 +310,6 @@ EFI_TIMER_ARCH_PROTOCOL   gTimer = {
   TimerDriverGenerateSoftInterrupt
 };
 
-TIMER_DEBUG_SUPPORT_PROTOCOL  gTimerDebugSupport = {
-  TimerDriverRegisterPeriodicCallback
-};
-
 
 /**
   Initialize the state information for the Timer Architectural Protocol and
@@ -368,11 +336,11 @@ TimerInitialize (
   UINT32      TimerBaseAddress;
 
   // Find the interrupt controller protocol.  ASSERT if not found.
-  Status = gBS->LocateProtocol(&gHardwareInterruptProtocolGuid, NULL, (VOID **)&gInterrupt);
+  Status = gBS->LocateProtocol (&gHardwareInterruptProtocolGuid, NULL, (VOID **)&gInterrupt);
   ASSERT_EFI_ERROR (Status);
 
   // Set up the timer registers
-  TimerBaseAddress = TimerBase(FixedPcdGet32(PcdOmap35xxArchTimer));
+  TimerBaseAddress = TimerBase (FixedPcdGet32(PcdOmap35xxArchTimer));
   TISR = TimerBaseAddress + GPTIMER_TISR;
   TCLR = TimerBaseAddress + GPTIMER_TCLR;
   TLDR = TimerBaseAddress + GPTIMER_TLDR;
@@ -380,23 +348,24 @@ TimerInitialize (
   TIER = TimerBaseAddress + GPTIMER_TIER;
 
   // Disable the timer
-  Status = TimerDriverSetTimerPeriod(&gTimer, 0);
+  Status = TimerDriverSetTimerPeriod (&gTimer, 0);
   ASSERT_EFI_ERROR (Status);
 
   // Install interrupt handler
-  gVector = InterruptVectorForTimer(FixedPcdGet32(PcdOmap35xxArchTimer));
-  Status = gInterrupt->RegisterInterruptSource(gInterrupt, gVector, TimerInterruptHandler);
+  gVector = InterruptVectorForTimer (FixedPcdGet32(PcdOmap35xxArchTimer));
+  Status = gInterrupt->RegisterInterruptSource (gInterrupt, gVector, TimerInterruptHandler);
   ASSERT_EFI_ERROR (Status);
 
   // Set up default timer
-  Status = TimerDriverSetTimerPeriod(&gTimer, FixedPcdGet32(PcdTimerPeriod));
+  Status = TimerDriverSetTimerPeriod (&gTimer, FixedPcdGet32(PcdTimerPeriod));
   ASSERT_EFI_ERROR (Status);
 
   // Install the Timer Architectural Protocol onto a new handle
-  Status = gBS->InstallMultipleProtocolInterfaces(&Handle,
-                                                  &gEfiTimerArchProtocolGuid,      &gTimer,
-                                                  &gTimerDebugSupportProtocolGuid, &gTimerDebugSupport,
-                                                  NULL);
+  Status = gBS->InstallMultipleProtocolInterfaces (
+                  &Handle,
+                  &gEfiTimerArchProtocolGuid,      &gTimer,
+                  NULL
+                  );
   ASSERT_EFI_ERROR(Status);
 
   return Status;
index b2b6d75f05c44a72625695e14e4e4850369b7019..eefcc49b17cf1ba281bda74d16c2e8c910ccb59b 100644 (file)
@@ -47,7 +47,6 @@
 [Protocols]
   gEfiTimerArchProtocolGuid  
   gHardwareInterruptProtocolGuid
-  gTimerDebugSupportProtocolGuid
 
 [Pcd.common]
   gEmbeddedTokenSpaceGuid.PcdTimerPeriod