]> git.proxmox.com Git - mirror_edk2.git/commitdiff
Fix building issue for linux toolchain
authorklu2 <klu2@6f19259b-4bc3-4df7-8a09-765794883524>
Sat, 28 Feb 2009 18:32:46 +0000 (18:32 +0000)
committerklu2 <klu2@6f19259b-4bc3-4df7-8a09-765794883524>
Sat, 28 Feb 2009 18:32:46 +0000 (18:32 +0000)
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7735 6f19259b-4bc3-4df7-8a09-765794883524

DuetPkg/BiosVideoThunkDxe/BiosVideo.c

index c8b090cadd9d2ea0be32290067a480098f603c95..f4a962b5227e90ceb1fa91c7a3550168ef67ba8e 100644 (file)
@@ -361,7 +361,7 @@ BiosVideoDriverBindingStart (
   Status = gBS->AllocatePool (\r
                   EfiBootServicesData,\r
                   sizeof (BIOS_VIDEO_DEV),\r
-                  &BiosVideoPrivate\r
+                  (VOID**)&BiosVideoPrivate\r
                   );\r
   if (EFI_ERROR (Status)) {\r
     goto Done;\r
@@ -383,7 +383,7 @@ BiosVideoDriverBindingStart (
   Status = gBS->HandleProtocol (\r
                   Controller,\r
                   &gEfiDevicePathProtocolGuid,\r
-                  &BiosVideoPrivate->DevicePath\r
+                  (VOID**)&BiosVideoPrivate->DevicePath\r
                   );\r
   if (EFI_ERROR (Status)) {\r
     goto Done;\r
@@ -1274,7 +1274,7 @@ Returns:
     Status = gBS->AllocatePool (\r
                     EfiBootServicesData,\r
                     BiosVideoPrivate->ModeData[Index].BytesPerScanLine,\r
-                    &BiosVideoPrivate->LineBuffer\r
+                    (VOID**)&BiosVideoPrivate->LineBuffer\r
                     );\r
     if (EFI_ERROR (Status)) {\r
       return Status;\r
@@ -1292,7 +1292,7 @@ Returns:
       Status = gBS->AllocatePool (\r
                       EfiBootServicesData,\r
                       4 * 480 * 80,\r
-                      &BiosVideoPrivate->VgaFrameBuffer\r
+                      (VOID**)&BiosVideoPrivate->VgaFrameBuffer\r
                       );\r
       if (EFI_ERROR (Status)) {\r
         return Status;\r
@@ -1311,7 +1311,7 @@ Returns:
       Status = gBS->AllocatePool (\r
                       EfiBootServicesData,\r
                       BiosVideoPrivate->ModeData[Index].BytesPerScanLine * BiosVideoPrivate->ModeData[Index].VerticalResolution,\r
-                      &BiosVideoPrivate->VbeFrameBuffer\r
+                      (VOID**)&BiosVideoPrivate->VbeFrameBuffer\r
                       );\r
       if (EFI_ERROR (Status)) {\r
         return Status;\r
@@ -1738,6 +1738,8 @@ Returns:
         );\r
     }\r
     break;\r
+  default:\r
+    break;\r
   }\r
 \r
   gBS->RestoreTPL (OriginalTPL);\r
@@ -1845,7 +1847,7 @@ Returns:
                   PciIo,\r
                   EfiPciIoWidthUint8,\r
                   EFI_PCI_IO_PASS_THROUGH_BAR,\r
-                  (UINT64) Source,\r
+                  (UINT64) (UINTN)Source,\r
                   WidthInBytes,\r
                   (VOID *) Destination\r
                   );\r
@@ -2110,9 +2112,9 @@ Returns:
                 PciIo,\r
                 EfiPciIoWidthUint8,\r
                 EFI_PCI_IO_PASS_THROUGH_BAR,\r
-                (UINT64) (DestinationAddress + Offset),\r
+                (UINT64) ((UINTN)DestinationAddress + Offset),\r
                 EFI_PCI_IO_PASS_THROUGH_BAR,\r
-                (UINT64) (SourceAddress + Offset),\r
+                (UINT64) ((UINTN)SourceAddress + Offset),\r
                 Bytes\r
                 );\r
       }\r
@@ -2316,7 +2318,7 @@ Returns:
                       PciIo,\r
                       EfiPciIoWidthUint8,\r
                       EFI_PCI_IO_PASS_THROUGH_BAR,\r
-                      (UINT64) Address1,\r
+                      (UINT64) (UINTN) Address1,\r
                       1,\r
                       &Data\r
                       );\r
@@ -2325,7 +2327,7 @@ Returns:
                       PciIo,\r
                       EfiPciIoWidthUint8,\r
                       EFI_PCI_IO_PASS_THROUGH_BAR,\r
-                      (UINT64) Address1,\r
+                      (UINT64) (UINTN) Address1,\r
                       1,\r
                       &BiosVideoPrivate->LineBuffer[Index1]\r
                       );\r
@@ -2339,6 +2341,8 @@ Returns:
       }\r
     }\r
 \r
+    break;\r
+  default:\r
     break;\r
   }\r
 \r