summaryrefslogtreecommitdiff
path: root/MdeModulePkg/Bus/Pci/EhciDxe
diff options
context:
space:
mode:
Diffstat (limited to 'MdeModulePkg/Bus/Pci/EhciDxe')
-rw-r--r--MdeModulePkg/Bus/Pci/EhciDxe/Ehci.c18
-rw-r--r--MdeModulePkg/Bus/Pci/EhciDxe/Ehci.h2
-rw-r--r--MdeModulePkg/Bus/Pci/EhciDxe/EhciReg.h2
-rw-r--r--MdeModulePkg/Bus/Pci/EhciDxe/UsbHcMem.h3
4 files changed, 7 insertions, 18 deletions
diff --git a/MdeModulePkg/Bus/Pci/EhciDxe/Ehci.c b/MdeModulePkg/Bus/Pci/EhciDxe/Ehci.c
index aae39b0acb..c6c7e5a519 100644
--- a/MdeModulePkg/Bus/Pci/EhciDxe/Ehci.c
+++ b/MdeModulePkg/Bus/Pci/EhciDxe/Ehci.c
@@ -46,12 +46,6 @@ gEhciDriverBinding = {
NULL
};
-///
-/// USB host controller Programming Interface.
-///
-#define PCI_CLASSC_PI_UHCI 0x00
-#define PCI_CLASSC_PI_EHCI 0x20
-
/**
Retrieves the capability of root hub ports.
@@ -1347,7 +1341,7 @@ EhcDriverBindingSupported (
Status = PciIo->Pci.Read (
PciIo,
EfiPciIoWidthUint8,
- EHC_PCI_CLASSC,
+ PCI_CLASSCODE_OFFSET,
sizeof (USB_CLASSC) / sizeof (UINT8),
&UsbClassCReg
);
@@ -1361,7 +1355,7 @@ EhcDriverBindingSupported (
// Test whether the controller belongs to Ehci type
//
if ((UsbClassCReg.BaseCode != PCI_CLASS_SERIAL) || (UsbClassCReg.SubClassCode != PCI_CLASS_SERIAL_USB)
- || ((UsbClassCReg.PI != EHC_PCI_CLASSC_PI) && (UsbClassCReg.PI !=PCI_CLASSC_PI_UHCI))) {
+ || ((UsbClassCReg.PI != PCI_IF_EHCI) && (UsbClassCReg.PI !=PCI_IF_UHCI))) {
Status = EFI_UNSUPPORTED;
}
@@ -1579,7 +1573,7 @@ EhcDriverBindingStart (
Status = PciIo->Pci.Read (
PciIo,
EfiPciIoWidthUint8,
- EHC_PCI_CLASSC,
+ PCI_CLASSCODE_OFFSET,
sizeof (USB_CLASSC) / sizeof (UINT8),
&UsbClassCReg
);
@@ -1589,7 +1583,7 @@ EhcDriverBindingStart (
goto CLOSE_PCIIO;
}
- if ((UsbClassCReg.PI == PCI_CLASSC_PI_UHCI) &&
+ if ((UsbClassCReg.PI == PCI_IF_UHCI) &&
(UsbClassCReg.BaseCode == PCI_CLASS_SERIAL) &&
(UsbClassCReg.SubClassCode == PCI_CLASS_SERIAL_USB)) {
Status = PciIo->GetLocation (
@@ -1628,7 +1622,7 @@ EhcDriverBindingStart (
Status = Instance->Pci.Read (
Instance,
EfiPciIoWidthUint8,
- EHC_PCI_CLASSC,
+ PCI_CLASSCODE_OFFSET,
sizeof (USB_CLASSC) / sizeof (UINT8),
&UsbClassCReg
);
@@ -1638,7 +1632,7 @@ EhcDriverBindingStart (
goto CLOSE_PCIIO;
}
- if ((UsbClassCReg.PI == PCI_CLASSC_PI_EHCI) &&
+ if ((UsbClassCReg.PI == PCI_IF_EHCI) &&
(UsbClassCReg.BaseCode == PCI_CLASS_SERIAL) &&
(UsbClassCReg.SubClassCode == PCI_CLASS_SERIAL_USB)) {
Status = Instance->GetLocation (
diff --git a/MdeModulePkg/Bus/Pci/EhciDxe/Ehci.h b/MdeModulePkg/Bus/Pci/EhciDxe/Ehci.h
index 2137d1cfba..2af722df4f 100644
--- a/MdeModulePkg/Bus/Pci/EhciDxe/Ehci.h
+++ b/MdeModulePkg/Bus/Pci/EhciDxe/Ehci.h
@@ -33,7 +33,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#include <Library/MemoryAllocationLib.h>
#include <Library/PcdLib.h>
-#include <IndustryStandard/Pci22.h>
+#include <IndustryStandard/Pci.h>
typedef struct _USB2_HC_DEV USB2_HC_DEV;
diff --git a/MdeModulePkg/Bus/Pci/EhciDxe/EhciReg.h b/MdeModulePkg/Bus/Pci/EhciDxe/EhciReg.h
index 23f794381f..15fd661e3d 100644
--- a/MdeModulePkg/Bus/Pci/EhciDxe/EhciReg.h
+++ b/MdeModulePkg/Bus/Pci/EhciDxe/EhciReg.h
@@ -83,8 +83,6 @@ typedef enum {
//
// PCI Configuration Registers
//
- EHC_PCI_CLASSC = 0x09,
- EHC_PCI_CLASSC_PI = 0x20,
EHC_BAR_INDEX = 0 /* how many bytes away from USB_BASE to 0x10 */
}EHCI_REGISTER_OFFSET;
diff --git a/MdeModulePkg/Bus/Pci/EhciDxe/UsbHcMem.h b/MdeModulePkg/Bus/Pci/EhciDxe/UsbHcMem.h
index d5213284ce..8152ce813b 100644
--- a/MdeModulePkg/Bus/Pci/EhciDxe/UsbHcMem.h
+++ b/MdeModulePkg/Bus/Pci/EhciDxe/UsbHcMem.h
@@ -16,9 +16,6 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#ifndef _EFI_EHCI_MEM_H_
#define _EFI_EHCI_MEM_H_
-
-#include <IndustryStandard/Pci22.h>
-
#define USB_HC_BIT(a) ((UINTN)(1 << (a)))
#define USB_HC_BIT_IS_SET(Data, Bit) \