]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdeModulePkg/Bus/Pci/PciBusDxe/PciIo.c
MdeModulePkg/PciBus: Correct typos
[mirror_edk2.git] / MdeModulePkg / Bus / Pci / PciBusDxe / PciIo.c
index 291578c63cb9c06a2aff45706469edcc6aa02460..a197bbc6e0f08a834cb2fb0f521514fa3f3beec0 100644 (file)
@@ -1,7 +1,7 @@
 /** @file\r
   EFI PCI IO protocol functions implementation for PCI Bus module.\r
 \r
-Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>\r
+Copyright (c) 2006 - 2019, 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
@@ -1316,7 +1316,7 @@ CheckBarType (
   @param  Operation    Set or Disable.\r
 \r
   @retval  EFI_UNSUPPORTED  If root bridge does not support change attribute.\r
-  @retval  EFI_SUCCESS      Successfully set new attributs.\r
+  @retval  EFI_SUCCESS      Successfully set new attributes.\r
 \r
 **/\r
 EFI_STATUS\r
@@ -1413,13 +1413,13 @@ SupportPaletteSnoopAttributes (
   }\r
 \r
   //\r
-  // Get the boot VGA on the same segement\r
+  // Get the boot VGA on the same Host Bridge\r
   //\r
-  Temp = ActiveVGADeviceOnTheSameSegment (PciIoDevice);\r
+  Temp = LocateVgaDeviceOnHostBridge (PciIoDevice->PciRootBridgeIo->ParentHandle);\r
 \r
   if (Temp == NULL) {\r
     //\r
-    // If there is no VGA device on the segement, set\r
+    // If there is no VGA device on the segment, set\r
     // this graphics card to decode the palette range\r
     //\r
     return EFI_SUCCESS;\r
@@ -1588,7 +1588,7 @@ PciIoAttributes (
   //\r
   // Just a trick for ENABLE attribute\r
   // EFI_PCI_DEVICE_ENABLE is not defined in UEFI spec, which is the internal usage.\r
-  // So, this logic doesn't confrom to UEFI spec, which should be removed.\r
+  // So, this logic doesn't conform to UEFI spec, which should be removed.\r
   // But this trick logic is still kept for some binary drivers that depend on it.\r
   //\r
   if ((Attributes & EFI_PCI_DEVICE_ENABLE) == EFI_PCI_DEVICE_ENABLE) {\r
@@ -1668,9 +1668,9 @@ PciIoAttributes (
       //\r
       if (Operation == EfiPciIoAttributeOperationEnable) {\r
         //\r
-        // Check if there have been an active VGA device on the same segment\r
+        // Check if there have been an active VGA device on the same Host Bridge\r
         //\r
-        Temp = ActiveVGADeviceOnTheSameSegment (PciIoDevice);\r
+        Temp = LocateVgaDeviceOnHostBridge (PciIoDevice->PciRootBridgeIo->ParentHandle);\r
         if (Temp != NULL && Temp != PciIoDevice) {\r
           //\r
           // An active VGA has been detected, so can not enable another\r
@@ -1725,7 +1725,7 @@ PciIoAttributes (
     Command |= EFI_PCI_COMMAND_BUS_MASTER;\r
   }\r
   //\r
-  // The upstream bridge should be also set to revelant attribute\r
+  // The upstream bridge should be also set to relevant attribute\r
   // expect for IO, Mem and BusMaster\r
   //\r
   UpStreamAttributes = Attributes &\r
@@ -1911,7 +1911,7 @@ PciIoGetBarAttributes (
 \r
     case PciBarTypePMem32:\r
       //\r
-      // prefechable\r
+      // prefetchable\r
       //\r
       Descriptor->SpecificFlag = EFI_ACPI_MEMORY_RESOURCE_SPECIFIC_FLAG_CACHEABLE_PREFETCHABLE;\r
       //\r
@@ -1930,7 +1930,7 @@ PciIoGetBarAttributes (
 \r
     case PciBarTypePMem64:\r
       //\r
-      // prefechable\r
+      // prefetchable\r
       //\r
       Descriptor->SpecificFlag = EFI_ACPI_MEMORY_RESOURCE_SPECIFIC_FLAG_CACHEABLE_PREFETCHABLE;\r
       //\r
@@ -2042,7 +2042,7 @@ PciIoSetBarAttributes (
     return EFI_UNSUPPORTED;\r
   }\r
   //\r
-  // Attributes must be supported.  Make sure the BAR range describd by BarIndex, Offset, and\r
+  // Attributes must be supported.  Make sure the BAR range described by BarIndex, Offset, and\r
   // Length are valid for this PCI device.\r
   //\r
   NonRelativeOffset = *Offset;\r