]> git.proxmox.com Git - mirror_edk2.git/blobdiff - DuetPkg/PciRootBridgeNoEnumerationDxe/PcatPciRootBridgeIo.c
ShellPkg/ShellCommandLib: Add missing EFIAPI for public library APIs
[mirror_edk2.git] / DuetPkg / PciRootBridgeNoEnumerationDxe / PcatPciRootBridgeIo.c
index 081235aa2a6907a3b4a02925297fe4b131b31672..d5d79aee2e9f9b551bf0aeab366069efb3c8bf0e 100644 (file)
@@ -1,7 +1,7 @@
 /*++\r
 \r
-Copyright (c) 2005 - 2009, Intel Corporation                                                         \r
-All rights reserved. This program and the accompanying materials                          \r
+Copyright (c) 2005 - 2012, Intel Corporation. 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
@@ -69,26 +69,6 @@ PcatRootBridgeIoMemWrite (
   IN OUT VOID                                   *Buffer\r
   );\r
 \r
-EFI_STATUS\r
-EFIAPI\r
-PcatRootBridgeIoIoRead (\r
-  IN     EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL        *This,\r
-  IN     EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH  Width,\r
-  IN     UINT64                                 UserAddress,\r
-  IN     UINTN                                  Count,\r
-  IN OUT VOID                                   *UserBuffer\r
-  );\r
-\r
-EFI_STATUS\r
-EFIAPI\r
-PcatRootBridgeIoIoWrite (\r
-  IN     EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL        *This,\r
-  IN     EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH  Width,\r
-  IN     UINT64                                 UserAddress,\r
-  IN     UINTN                                  Count,\r
-  IN OUT VOID                                   *UserBuffer\r
-  );\r
-\r
 EFI_STATUS\r
 EFIAPI\r
 PcatRootBridgeIoCopyMem (\r
@@ -276,7 +256,7 @@ PcatRootBridgeIoPollMem (
   }\r
 \r
 \r
-  if (Width < 0 || Width > EfiPciWidthUint64) {\r
+  if ((UINT32)Width > EfiPciWidthUint64) {\r
     return EFI_INVALID_PARAMETER;\r
   }\r
   //\r
@@ -339,7 +319,7 @@ PcatRootBridgeIoPollIo (
     return EFI_INVALID_PARAMETER;\r
   }\r
 \r
-  if (Width < 0 || Width > EfiPciWidthUint64) {\r
+  if ((UINT32)Width > EfiPciWidthUint64) {\r
     return EFI_INVALID_PARAMETER;\r
   }\r
   //\r
@@ -432,7 +412,7 @@ PcatRootBridgeIoMemRead (
 \r
   In.buf  = Buffer;\r
   Out.buf = (VOID *)(UINTN) Address;\r
-  if (Width >= EfiPciWidthUint8 && Width <= EfiPciWidthUint64) {\r
+  if ((UINT32)Width <= EfiPciWidthUint64) {\r
     return PcatRootBridgeIoMemRW (Width, Count, TRUE, In, TRUE, Out);\r
   }\r
   if (Width >= EfiPciWidthFifoUint8 && Width <= EfiPciWidthFifoUint64) {\r
@@ -479,7 +459,7 @@ PcatRootBridgeIoMemWrite (
 \r
   In.buf  = (VOID *)(UINTN) Address;\r
   Out.buf = Buffer;\r
-  if (Width >= EfiPciWidthUint8 && Width <= EfiPciWidthUint64) {\r
+  if ((UINT32)Width <= EfiPciWidthUint64) {\r
     return PcatRootBridgeIoMemRW (Width, Count, TRUE, In, TRUE, Out);\r
   }\r
   if (Width >= EfiPciWidthFifoUint8 && Width <= EfiPciWidthFifoUint64) {\r
@@ -509,7 +489,7 @@ PcatRootBridgeIoCopyMem (
   UINTN       Index;\r
   UINT64      Result;\r
 \r
-  if (Width < 0 || Width > EfiPciWidthUint64) {\r
+  if ((UINT32)Width > EfiPciWidthUint64) {\r
     return EFI_INVALID_PARAMETER;\r
   }       \r
 \r
@@ -629,7 +609,7 @@ PcatRootBridgeIoMap (
   //\r
   // Make sure that Operation is valid\r
   //\r
-  if (Operation < 0 || Operation >= EfiPciOperationMaximum) {\r
+  if ((UINT32)Operation >= EfiPciOperationMaximum) {\r
     return EFI_INVALID_PARAMETER;\r
   }\r
 \r