The functions that are never called have been removed.
They are XhcPeiReadDoorBellReg and UsbHcUnlinkMemBlock.
https://bugzilla.tianocore.org/show_bug.cgi?id=1062

Cc: Star Zeng <star.z...@intel.com>
Cc: Eric Dong <eric.d...@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: shenglei <shenglei.zh...@intel.com>
Reviewed-by: Ruiyu Ni <ruiyu.ni at intel.com>
Reviewed-by: Star Zeng <star.zeng at intel.com>
---
 MdeModulePkg/Bus/Pci/XhciPei/UsbHcMem.c | 24 ------------------------
 MdeModulePkg/Bus/Pci/XhciPei/XhcPeim.c  | 22 ----------------------
 MdeModulePkg/Bus/Pci/XhciPei/XhciReg.h  | 14 --------------
 3 files changed, 60 deletions(-)

diff --git a/MdeModulePkg/Bus/Pci/XhciPei/UsbHcMem.c 
b/MdeModulePkg/Bus/Pci/XhciPei/UsbHcMem.c
index 5d0232ca56..442a613095 100644
--- a/MdeModulePkg/Bus/Pci/XhciPei/UsbHcMem.c
+++ b/MdeModulePkg/Bus/Pci/XhciPei/UsbHcMem.c
@@ -328,31 +328,7 @@ UsbHcIsMemBlockEmpty (
   return TRUE;
 }
 
-/**
-  Unlink the memory block from the pool's list.
-
-  @param  Head          The block list head of the memory's pool.
-  @param  BlockToUnlink The memory block to unlink.
 
-**/
-VOID
-UsbHcUnlinkMemBlock (
-  IN USBHC_MEM_BLOCK    *Head,
-  IN USBHC_MEM_BLOCK    *BlockToUnlink
-  )
-{
-  USBHC_MEM_BLOCK       *Block;
-
-  ASSERT ((Head != NULL) && (BlockToUnlink != NULL));
-
-  for (Block = Head; Block != NULL; Block = Block->Next) {
-    if (Block->Next == BlockToUnlink) {
-      Block->Next         = BlockToUnlink->Next;
-      BlockToUnlink->Next = NULL;
-      break;
-    }
-  }
-}
 
 /**
   Initialize the memory management pool for the host controller.
diff --git a/MdeModulePkg/Bus/Pci/XhciPei/XhcPeim.c 
b/MdeModulePkg/Bus/Pci/XhciPei/XhcPeim.c
index c5631e87ca..ee4d1f97bd 100644
--- a/MdeModulePkg/Bus/Pci/XhciPei/XhcPeim.c
+++ b/MdeModulePkg/Bus/Pci/XhciPei/XhcPeim.c
@@ -211,29 +211,7 @@ XhcPeiReadCapRegister (
   return Data;
 }
 
-/**
-  Read XHCI door bell register.
-
-  @param  Xhc       The XHCI device.
-  @param  Offset    The offset of the door bell register.
-
-  @return The register content read
 
-**/
-UINT32
-XhcPeiReadDoorBellReg (
-  IN  PEI_XHC_DEV       *Xhc,
-  IN  UINT32            Offset
-  )
-{
-  UINT32                  Data;
-
-  ASSERT (Xhc->DBOff != 0);
-
-  Data = MmioRead32 (Xhc->UsbHostControllerBaseAddress + Xhc->DBOff + Offset);
-
-  return Data;
-}
 
 /**
   Write the data to the XHCI door bell register.
diff --git a/MdeModulePkg/Bus/Pci/XhciPei/XhciReg.h 
b/MdeModulePkg/Bus/Pci/XhciPei/XhciReg.h
index 0297072ffd..3787aeccf5 100644
--- a/MdeModulePkg/Bus/Pci/XhciPei/XhciReg.h
+++ b/MdeModulePkg/Bus/Pci/XhciPei/XhciReg.h
@@ -302,20 +302,6 @@ XhcPeiWaitOpRegBit (
   IN UINT32             Timeout
   );
 
-/**
-  Read XHCI door bell register.
-
-  @param  Xhc           The XHCI device.
-  @param  Offset        The offset of the door bell register.
-
-  @return The register content read
-
-**/
-UINT32
-XhcPeiReadDoorBellReg (
-  IN  PEI_XHC_DEV       *Xhc,
-  IN  UINT32            Offset
-  );
 
 /**
   Write the data to the XHCI door bell register.
-- 
2.18.0.windows.1

_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel

Reply via email to