// Perform 16bit Read in PCI IO Space\r
//\r
return PciIo->Io.Read (\r
- PciIo,\r
- EfiPciIoWidthUint16,\r
- USB_BAR_INDEX,\r
- (UINT64) PortOffset,\r
- 1,\r
- Data\r
- );\r
+ PciIo,\r
+ EfiPciIoWidthUint16,\r
+ USB_BAR_INDEX,\r
+ (UINT64) PortOffset,\r
+ 1,\r
+ Data\r
+ );\r
}\r
\r
EFI_STATUS\r
// Perform 32bit Read in PCI IO Space\r
//\r
return PciIo->Io.Read (\r
- PciIo,\r
- EfiPciIoWidthUint32,\r
- USB_BAR_INDEX,\r
- (UINT64) PortOffset,\r
- 1,\r
- Data\r
- );\r
+ PciIo,\r
+ EfiPciIoWidthUint32,\r
+ USB_BAR_INDEX,\r
+ (UINT64) PortOffset,\r
+ 1,\r
+ Data\r
+ );\r
}\r
\r
EFI_STATUS\r
// Perform 16bit Write in PCI IO Space\r
//\r
return PciIo->Io.Write (\r
- PciIo,\r
- EfiPciIoWidthUint16,\r
- USB_BAR_INDEX,\r
- (UINT64) PortOffset,\r
- 1,\r
- &Data\r
- );\r
+ PciIo,\r
+ EfiPciIoWidthUint16,\r
+ USB_BAR_INDEX,\r
+ (UINT64) PortOffset,\r
+ 1,\r
+ &Data\r
+ );\r
}\r
\r
EFI_STATUS\r
// Perform 32bit Write in PCI IO Space\r
//\r
return PciIo->Io.Write (\r
- PciIo,\r
- EfiPciIoWidthUint32,\r
- USB_BAR_INDEX,\r
- (UINT64) PortOffset,\r
- 1,\r
- &Data\r
- );\r
+ PciIo,\r
+ EfiPciIoWidthUint32,\r
+ USB_BAR_INDEX,\r
+ (UINT64) PortOffset,\r
+ 1,\r
+ &Data\r
+ );\r
}\r
//\r
// USB register-base helper functions\r
EFI_STATUS Status;\r
\r
Status = ReadUHCCommandReg (\r
- HcDev->PciIo,\r
- (UINT32) (USBCMD),\r
- &CommandContent\r
- );\r
+ HcDev->PciIo,\r
+ (UINT32) (USBCMD),\r
+ &CommandContent\r
+ );\r
\r
if ((CommandContent & USBCMD_MAXP) != USBCMD_MAXP) {\r
CommandContent |= USBCMD_MAXP;\r
BufferSizeInBytes = 4096;\r
BufferSizeInPages = EFI_SIZE_TO_PAGES (BufferSizeInBytes);\r
Status = HcDev->PciIo->AllocateBuffer (\r
- HcDev->PciIo,\r
- AllocateAnyPages,\r
- EfiBootServicesData,\r
- BufferSizeInPages,\r
- &CommonBuffer,\r
- 0\r
- );\r
+ HcDev->PciIo,\r
+ AllocateAnyPages,\r
+ EfiBootServicesData,\r
+ BufferSizeInPages,\r
+ &CommonBuffer,\r
+ 0\r
+ );\r
if (EFI_ERROR (Status)) {\r
return EFI_OUT_OF_RESOURCES;\r
}\r
\r
Status = HcDev->PciIo->Map (\r
- HcDev->PciIo,\r
- EfiPciIoOperationBusMasterCommonBuffer,\r
- CommonBuffer,\r
- &BufferSizeInBytes,\r
- &MappedAddress,\r
- &Mapping\r
- );\r
+ HcDev->PciIo,\r
+ EfiPciIoOperationBusMasterCommonBuffer,\r
+ CommonBuffer,\r
+ &BufferSizeInBytes,\r
+ &MappedAddress,\r
+ &Mapping\r
+ );\r
if (EFI_ERROR (Status) || (BufferSizeInBytes != 4096)) {\r
HcDev->PciIo->FreeBuffer (HcDev->PciIo, BufferSizeInPages, CommonBuffer);\r
return EFI_UNSUPPORTED;\r
// and it is allocated as common buffer use.\r
//\r
Status = HcDev->PciIo->AllocateBuffer (\r
- HcDev->PciIo,\r
- AllocateAnyPages,\r
- EfiBootServicesData,\r
- MemoryBlockSizeInPages,\r
- &CommonBuffer,\r
- 0\r
- );\r
+ HcDev->PciIo,\r
+ AllocateAnyPages,\r
+ EfiBootServicesData,\r
+ MemoryBlockSizeInPages,\r
+ &CommonBuffer,\r
+ 0\r
+ );\r
if (EFI_ERROR (Status)) {\r
gBS->FreePool ((*MemoryHeader)->BitArrayPtr);\r
gBS->FreePool (*MemoryHeader);\r
\r
MemoryBlockSizeInBytes = EFI_PAGES_TO_SIZE (MemoryBlockSizeInPages);\r
Status = HcDev->PciIo->Map (\r
- HcDev->PciIo,\r
- EfiPciIoOperationBusMasterCommonBuffer,\r
- CommonBuffer,\r
- &MemoryBlockSizeInBytes,\r
- &MappedAddress,\r
- &Mapping\r
- );\r
+ HcDev->PciIo,\r
+ EfiPciIoOperationBusMasterCommonBuffer,\r
+ CommonBuffer,\r
+ &MemoryBlockSizeInBytes,\r
+ &MappedAddress,\r
+ &Mapping\r
+ );\r
//\r
// if returned Mapped size is less than the size we request,do not support.\r
//\r
TempHeaderPtr = TempHeaderPtr->Next) {\r
\r
Status = AllocMemInMemoryBlock (\r
- TempHeaderPtr,\r
- (VOID **) Pool,\r
- RealAllocSize / 32\r
- );\r
+ TempHeaderPtr,\r
+ (VOID **) Pool,\r
+ RealAllocSize / 32\r
+ );\r
if (!EFI_ERROR (Status)) {\r
ZeroMem (*Pool, AllocSize);\r
return EFI_SUCCESS;\r
InsertMemoryHeaderToList (MemoryHeader, NewMemoryHeader);\r
\r
Status = AllocMemInMemoryBlock (\r
- NewMemoryHeader,\r
- (VOID **) Pool,\r
- RealAllocSize / 32\r
- );\r
+ NewMemoryHeader,\r
+ (VOID **) Pool,\r
+ RealAllocSize / 32\r
+ );\r
\r
if (!EFI_ERROR (Status)) {\r
ZeroMem (*Pool, AllocSize);\r
//\r
Command = 0;\r
PciIo->Pci.Write (\r
- PciIo,\r
- EfiPciIoWidthUint16,\r
- USB_EMULATION,\r
- 1,\r
- &Command\r
- );\r
+ PciIo,\r
+ EfiPciIoWidthUint16,\r
+ USB_EMULATION,\r
+ 1,\r
+ &Command\r
+ );\r
\r
return ;\r
}\r