]> git.proxmox.com Git - mirror_edk2.git/commitdiff
Fix ICC building issue for DuetPkg
authorklu2 <klu2@6f19259b-4bc3-4df7-8a09-765794883524>
Thu, 27 Nov 2008 04:37:39 +0000 (04:37 +0000)
committerklu2 <klu2@6f19259b-4bc3-4df7-8a09-765794883524>
Thu, 27 Nov 2008 04:37:39 +0000 (04:37 +0000)
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@6749 6f19259b-4bc3-4df7-8a09-765794883524

DuetPkg/IsaAcpiDxe/PcatIsaAcpi.c
DuetPkg/PciBusNoEnumerationDxe/PciEnumeratorSupport.c
DuetPkg/PciBusNoEnumerationDxe/PciIo.c
DuetPkg/PciRootBridgeNoEnumerationDxe/DeviceIo.c
DuetPkg/PciRootBridgeNoEnumerationDxe/PcatPciRootBridgeIo.c

index 674c6dfc00ae300d695daa1fde4b24bbd6ec2eac..a0f4cdfd40a0df99cc57d04552843ae072737709 100644 (file)
@@ -92,7 +92,7 @@ Returns:
   Status = gBS->OpenProtocol (\r
                   Controller,  \r
                   &gEfiPciIoProtocolGuid, \r
-                  &PciIo,\r
+                  (VOID**)&PciIo,\r
                   This->DriverBindingHandle,\r
                   Controller,\r
                   EFI_OPEN_PROTOCOL_BY_DRIVER\r
@@ -171,7 +171,7 @@ Returns:
   Status = gBS->OpenProtocol (\r
                   Controller,       \r
                   &gEfiPciIoProtocolGuid, \r
-                  &PciIo,\r
+                  (VOID**)&PciIo,\r
                   This->DriverBindingHandle,   \r
                   Controller,   \r
                   EFI_OPEN_PROTOCOL_BY_DRIVER \r
@@ -197,7 +197,7 @@ Returns:
   Status = gBS->AllocatePool (\r
                   EfiBootServicesData,\r
                   sizeof(PCAT_ISA_ACPI_DEV),\r
-                  &PcatIsaAcpiDev\r
+                  (VOID**)&PcatIsaAcpiDev\r
                   );\r
   if (EFI_ERROR (Status)) {\r
     goto Done;\r
@@ -284,7 +284,7 @@ PcatIsaAcpiDriverBindingStop (
   Status = gBS->OpenProtocol (\r
                   Controller, \r
                   &gEfiIsaAcpiProtocolGuid, \r
-                  &IsaAcpi,\r
+                  (VOID**)&IsaAcpi,\r
                   This->DriverBindingHandle,   \r
                   Controller,   \r
                   EFI_OPEN_PROTOCOL_GET_PROTOCOL\r
index 2f0a1757c06e53f568e9fd16f16ab25a029723a7..b763c6cce6b83d0a70b31e3605485fa11a935a27 100644 (file)
@@ -864,7 +864,7 @@ Returns:
 --*/\r
 {\r
   UINT32      Value;\r
-  UINT64      BarValue64;\r
+  //UINT64      BarValue64;\r
   UINT32      OriginalValue;\r
   UINT32      Mask;\r
   UINT32      Data;\r
@@ -873,7 +873,7 @@ Returns:
 \r
   OriginalValue = 0;\r
   Value         = 0;\r
-  BarValue64    = 0;\r
+  //BarValue64    = 0;\r
 \r
   Status = BarExisted (\r
             PciIoDevice,\r
@@ -923,7 +923,7 @@ Returns:
     // Need to treat it as no-bar\r
     //\r
     if (PciIoDevice->PciBar[BarIndex].Length == 0) {\r
-      PciIoDevice->PciBar[BarIndex].BarType = 0;\r
+      PciIoDevice->PciBar[BarIndex].BarType = PciBarTypeUnknown;\r
     }\r
 \r
     PciIoDevice->PciBar[BarIndex].Prefetchable  = FALSE;\r
index 55d16b64cbd36d8b54e61ea872fd0ccd487edb6b..759c61a83c3df67fc630818e8f00f45d847330e9 100644 (file)
@@ -370,7 +370,7 @@ Returns:
     Count = 1;\r
   }\r
 \r
-  Width &= 0x03;\r
+  Width = (EFI_PCI_IO_PROTOCOL_WIDTH) (Width & 0x03);\r
 \r
   if ((*Offset + Count * ((UINTN)1 << Width)) - 1 >= PciIoDevice->PciBar[BarIndex].Length) {\r
     return EFI_INVALID_PARAMETER;\r
@@ -412,7 +412,7 @@ Returns:
   // If Width is EfiPciIoWidthFifoUintX then convert to EfiPciIoWidthUintX\r
   // If Width is EfiPciIoWidthFillUintX then convert to EfiPciIoWidthUintX\r
   //\r
-  Width &= 0x03;\r
+  Width = (EFI_PCI_IO_PROTOCOL_WIDTH) (Width & 0x03);\r
 \r
   if (PciIoDevice->IsPciExp) {\r
     if ((*Offset + Count * ((UINTN)1 << Width)) - 1 >= PCI_EXP_MAX_CONFIG_OFFSET) {\r
@@ -951,7 +951,7 @@ Returns:
   }\r
 \r
   if (PciIoDevice->Attributes & EFI_PCI_IO_ATTRIBUTE_DUAL_ADDRESS_CYCLE) {\r
-    Operation = Operation + EfiPciOperationBusMasterRead64;\r
+    Operation = (EFI_PCI_IO_PROTOCOL_OPERATION) (Operation + EfiPciOperationBusMasterRead64);\r
   }\r
 \r
   Status = PciIoDevice->PciRootBridgeIo->Map (\r
@@ -1865,5 +1865,5 @@ Returns:
     return TRUE;\r
   }\r
 \r
-  return (PciDeviceExisted (PciDevice1->Parent, PciDevice2)|| PciDeviceExisted (PciDevice2->Parent, PciDevice1));\r
+  return (BOOLEAN) ((PciDeviceExisted (PciDevice1->Parent, PciDevice2)|| PciDeviceExisted (PciDevice2->Parent, PciDevice1)));\r
 }\r
index 8525b4b94e5b515ceac4798f7e33f432e055b007..67a46b9759b2a366a4cb36fec5b22535234d5b0f 100644 (file)
@@ -137,7 +137,7 @@ Returns:
     return EFI_INVALID_PARAMETER;\r
   }\r
   if (Width >= MMIO_COPY_UINT8) {\r
-    Width = Width - MMIO_COPY_UINT8;\r
+    Width = (EFI_IO_WIDTH) (Width - MMIO_COPY_UINT8);\r
     Status = Private->PciRootBridgeIo->CopyMem (\r
                                          Private->PciRootBridgeIo,\r
                                          (EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH) Width,\r
@@ -201,7 +201,7 @@ Returns:
     return EFI_INVALID_PARAMETER;\r
   }\r
   if (Width >= MMIO_COPY_UINT8) {\r
-    Width = Width - MMIO_COPY_UINT8;\r
+    Width = (EFI_IO_WIDTH) (Width - MMIO_COPY_UINT8);\r
     Status = Private->PciRootBridgeIo->CopyMem (\r
                                          Private->PciRootBridgeIo,\r
                                          (EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH) Width,\r
index 9c5ae3c400364ba49b32c4babfe74629e04118b5..d1b83ba19e2b324dc2970721ac58ab26b093cbc0 100644 (file)
@@ -1013,7 +1013,7 @@ Returns:
   UINTN  OutStride;\r
 \r
 \r
-  Width     = Width & 0x03;\r
+  Width     = (EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_WIDTH) (Width & 0x03);\r
   Stride    = (UINTN)1 << Width;\r
   InStride  = InStrideFlag  ? Stride : 0;\r
   OutStride = OutStrideFlag ? Stride : 0;\r