]> git.proxmox.com Git - mirror_edk2.git/commitdiff
Fixup for review
authorhfang <hfang@6f19259b-4bc3-4df7-8a09-765794883524>
Thu, 25 Dec 2008 08:59:02 +0000 (08:59 +0000)
committerhfang <hfang@6f19259b-4bc3-4df7-8a09-765794883524>
Thu, 25 Dec 2008 08:59:02 +0000 (08:59 +0000)
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7120 6f19259b-4bc3-4df7-8a09-765794883524

26 files changed:
IntelFrameworkModulePkg/Bus/Pci/IdeBusDxe/Ata.c
IntelFrameworkModulePkg/Bus/Pci/IdeBusDxe/Atapi.c
IntelFrameworkModulePkg/Bus/Pci/IdeBusDxe/ComponentName.h
IntelFrameworkModulePkg/Bus/Pci/IdeBusDxe/DriverConfiguration.c
IntelFrameworkModulePkg/Bus/Pci/IdeBusDxe/Ide.c
IntelFrameworkModulePkg/Bus/Pci/IdeBusDxe/Ide.h
IntelFrameworkModulePkg/Bus/Pci/IdeBusDxe/IdeBus.c
IntelFrameworkModulePkg/Bus/Pci/IdeBusDxe/IdeBus.h
IntelFrameworkModulePkg/Bus/Pci/PciBusDxe/PciBus.c
IntelFrameworkModulePkg/Bus/Pci/PciBusDxe/PciCommand.c
IntelFrameworkModulePkg/Bus/Pci/PciBusDxe/PciCommand.h
IntelFrameworkModulePkg/Bus/Pci/PciBusDxe/PciDeviceSupport.c
IntelFrameworkModulePkg/Bus/Pci/PciBusDxe/PciDeviceSupport.h
IntelFrameworkModulePkg/Bus/Pci/PciBusDxe/PciDriverOverride.c
IntelFrameworkModulePkg/Bus/Pci/PciBusDxe/PciDriverOverride.h
IntelFrameworkModulePkg/Bus/Pci/PciBusDxe/PciEnumerator.c
IntelFrameworkModulePkg/Bus/Pci/PciBusDxe/PciEnumerator.h
IntelFrameworkModulePkg/Bus/Pci/PciBusDxe/PciEnumeratorSupport.c
IntelFrameworkModulePkg/Bus/Pci/PciBusDxe/PciEnumeratorSupport.h
IntelFrameworkModulePkg/Bus/Pci/PciBusDxe/PciHotPlugSupport.c
IntelFrameworkModulePkg/Bus/Pci/PciBusDxe/PciHotPlugSupport.h
IntelFrameworkModulePkg/Bus/Pci/PciBusDxe/PciIo.c
IntelFrameworkModulePkg/Bus/Pci/PciBusDxe/PciIo.h
IntelFrameworkModulePkg/Bus/Pci/PciBusDxe/PciLib.c
IntelFrameworkModulePkg/Bus/Pci/PciBusDxe/PciLib.h
IntelFrameworkModulePkg/Bus/Pci/PciBusDxe/PciResourceSupport.c

index 72941e93d4691ec025e062804eb1117e4810563c..a91eb174c1fcd70b887b3b24621235e1188b9f29 100644 (file)
@@ -630,7 +630,7 @@ CheckErrorStatus (
 \r
   DEBUG_CODE_BEGIN ();\r
 \r
 \r
   DEBUG_CODE_BEGIN ();\r
 \r
-    if (StatusRegister & ATA_STSREG_DWF) {\r
+    if ((StatusRegister & ATA_STSREG_DWF) != 0) {\r
       DEBUG (\r
         (EFI_D_BLKIO,\r
         "CheckErrorStatus()-- %02x : Error : Write Fault\n",\r
       DEBUG (\r
         (EFI_D_BLKIO,\r
         "CheckErrorStatus()-- %02x : Error : Write Fault\n",\r
@@ -638,7 +638,7 @@ CheckErrorStatus (
         );\r
     }\r
 \r
         );\r
     }\r
 \r
-    if (StatusRegister & ATA_STSREG_CORR) {\r
+    if ((StatusRegister & ATA_STSREG_CORR) != 0) {\r
       DEBUG (\r
         (EFI_D_BLKIO,\r
         "CheckErrorStatus()-- %02x : Error : Corrected Data\n",\r
       DEBUG (\r
         (EFI_D_BLKIO,\r
         "CheckErrorStatus()-- %02x : Error : Corrected Data\n",\r
@@ -646,10 +646,10 @@ CheckErrorStatus (
         );\r
     }\r
 \r
         );\r
     }\r
 \r
-    if (StatusRegister & ATA_STSREG_ERR) {\r
+    if ((StatusRegister & ATA_STSREG_ERR) != 0) {\r
       ErrorRegister = IDEReadPortB (IdeDev->PciIo, IdeDev->IoPort->Reg1.Error);\r
 \r
       ErrorRegister = IDEReadPortB (IdeDev->PciIo, IdeDev->IoPort->Reg1.Error);\r
 \r
-      if (ErrorRegister & ATA_ERRREG_BBK) {\r
+      if ((ErrorRegister & ATA_ERRREG_BBK) != 0) {\r
       DEBUG (\r
         (EFI_D_BLKIO,\r
         "CheckErrorStatus()-- %02x : Error : Bad Block Detected\n",\r
       DEBUG (\r
         (EFI_D_BLKIO,\r
         "CheckErrorStatus()-- %02x : Error : Bad Block Detected\n",\r
@@ -657,7 +657,7 @@ CheckErrorStatus (
         );\r
       }\r
 \r
         );\r
       }\r
 \r
-      if (ErrorRegister & ATA_ERRREG_UNC) {\r
+      if ((ErrorRegister & ATA_ERRREG_UNC) != 0) {\r
         DEBUG (\r
           (EFI_D_BLKIO,\r
           "CheckErrorStatus()-- %02x : Error : Uncorrectable Data\n",\r
         DEBUG (\r
           (EFI_D_BLKIO,\r
           "CheckErrorStatus()-- %02x : Error : Uncorrectable Data\n",\r
@@ -665,7 +665,7 @@ CheckErrorStatus (
           );\r
       }\r
 \r
           );\r
       }\r
 \r
-      if (ErrorRegister & ATA_ERRREG_MC) {\r
+      if ((ErrorRegister & ATA_ERRREG_MC) != 0) {\r
         DEBUG (\r
           (EFI_D_BLKIO,\r
           "CheckErrorStatus()-- %02x : Error : Media Change\n",\r
         DEBUG (\r
           (EFI_D_BLKIO,\r
           "CheckErrorStatus()-- %02x : Error : Media Change\n",\r
@@ -673,7 +673,7 @@ CheckErrorStatus (
           );\r
       }\r
 \r
           );\r
       }\r
 \r
-      if (ErrorRegister & ATA_ERRREG_ABRT) {\r
+      if ((ErrorRegister & ATA_ERRREG_ABRT) != 0) {\r
         DEBUG (\r
           (EFI_D_BLKIO,\r
           "CheckErrorStatus()-- %02x : Error : Abort\n",\r
         DEBUG (\r
           (EFI_D_BLKIO,\r
           "CheckErrorStatus()-- %02x : Error : Abort\n",\r
@@ -681,7 +681,7 @@ CheckErrorStatus (
           );\r
       }\r
 \r
           );\r
       }\r
 \r
-      if (ErrorRegister & ATA_ERRREG_TK0NF) {\r
+      if ((ErrorRegister & ATA_ERRREG_TK0NF) != 0) {\r
         DEBUG (\r
           (EFI_D_BLKIO,\r
           "CheckErrorStatus()-- %02x : Error : Track 0 Not Found\n",\r
         DEBUG (\r
           (EFI_D_BLKIO,\r
           "CheckErrorStatus()-- %02x : Error : Track 0 Not Found\n",\r
@@ -689,7 +689,7 @@ CheckErrorStatus (
           );\r
       }\r
 \r
           );\r
       }\r
 \r
-      if (ErrorRegister & ATA_ERRREG_AMNF) {\r
+      if ((ErrorRegister & ATA_ERRREG_AMNF) != 0) {\r
         DEBUG (\r
           (EFI_D_BLKIO,\r
           "CheckErrorStatus()-- %02x : Error : Address Mark Not Found\n",\r
         DEBUG (\r
           (EFI_D_BLKIO,\r
           "CheckErrorStatus()-- %02x : Error : Address Mark Not Found\n",\r
@@ -1348,7 +1348,7 @@ AtaReadSectorsExt (
   @param[in] *DataBuffer\r
   A pointer to the source buffer for the data.\r
 \r
   @param[in] *DataBuffer\r
   A pointer to the source buffer for the data.\r
 \r
-  @param[in] Lba\r
+  @param[in] StartLba\r
   The starting logical block address to write onto\r
   the device media.\r
 \r
   The starting logical block address to write onto\r
   the device media.\r
 \r
@@ -1439,7 +1439,7 @@ AtaWriteSectorsExt (
   @param[in] *IdeDev pointer pointing to IDE_BLK_IO_DEV data structure, used\r
   to record all the information of the IDE device.\r
 \r
   @param[in] *IdeDev pointer pointing to IDE_BLK_IO_DEV data structure, used\r
   to record all the information of the IDE device.\r
 \r
-  @param[in,out] *Buffer  buffer contained data transferred from device to host.\r
+  @param[in, out] *Buffer  buffer contained data transferred from device to host.\r
   @param[in] ByteCount    data size in byte unit of the buffer.\r
   @param[in] AtaCommand   value of the Command Register\r
   @param[in] StartLba     the start LBA of this transaction\r
   @param[in] ByteCount    data size in byte unit of the buffer.\r
   @param[in] AtaCommand   value of the Command Register\r
   @param[in] StartLba     the start LBA of this transaction\r
@@ -1908,7 +1908,7 @@ AtaSMARTSupport (
   @param  LbaAddress The LBA address in 48-bit mode\r
 \r
   @retval  EFI_SUCCESS Reading succeed\r
   @param  LbaAddress The LBA address in 48-bit mode\r
 \r
   @retval  EFI_SUCCESS Reading succeed\r
-  @retval  EFI_DEVICE_ERROR Error executing commands on this device\r
+  @retval  EFI_DEVICE_ERROR Error executing commands on this device.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -2020,7 +2020,7 @@ AtaCommandIssueExt (
   @param  LbaAddress The LBA address in 48-bit mode\r
 \r
   @retval  EFI_SUCCESS Reading succeed\r
   @param  LbaAddress The LBA address in 48-bit mode\r
 \r
   @retval  EFI_SUCCESS Reading succeed\r
-  @retval  EFI_DEVICE_ERROR Error executing commands on this device\r
+  @retval  EFI_DEVICE_ERROR Error executing commands on this device.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -2574,8 +2574,8 @@ DoAtaUdma (
                           1,\r
                           &RegisterValue\r
                           );\r
                           1,\r
                           &RegisterValue\r
                           );\r
-      if ((RegisterValue & (BMIS_INTERRUPT | BMIS_ERROR)) || (Count == 0)) {\r
-        if ((RegisterValue & BMIS_ERROR) || (Count == 0)) {\r
+      if (((RegisterValue & (BMIS_INTERRUPT | BMIS_ERROR)) != 0) || (Count == 0)) {\r
+        if (((RegisterValue & BMIS_ERROR) != 0) || (Count == 0)) {\r
                  Status = EFI_DEVICE_ERROR;\r
                  break;\r
         }\r
                  Status = EFI_DEVICE_ERROR;\r
                  break;\r
         }\r
@@ -2637,7 +2637,7 @@ DoAtaUdma (
                         &RegisterValue\r
                         );\r
 \r
                         &RegisterValue\r
                         );\r
 \r
-    if (RegisterValue & BMIS_ERROR) {\r
+    if ((RegisterValue & BMIS_ERROR) != 0) {\r
       return EFI_DEVICE_ERROR;\r
     }\r
 \r
       return EFI_DEVICE_ERROR;\r
     }\r
 \r
index e7ddcb980ef1633951ffb79554ea6610520823e2..e3515d254769cfa7db2faed0fc2b22e01ee77ecf 100644 (file)
@@ -90,11 +90,11 @@ LS120GetMediaStatus (
   //\r
   StatusValue = IDEReadPortB (IdeDev->PciIo, IdeDev->IoPort->Reg1.Error);\r
 \r
   //\r
   StatusValue = IDEReadPortB (IdeDev->PciIo, IdeDev->IoPort->Reg1.Error);\r
 \r
-  if (StatusValue & BIT1) {\r
+  if ((StatusValue & BIT1) != 0) {\r
     return EFI_NO_MEDIA;\r
   }\r
 \r
     return EFI_NO_MEDIA;\r
   }\r
 \r
-  if (StatusValue & BIT6) {\r
+  if ((StatusValue & BIT6) != 0) {\r
     return EFI_WRITE_PROTECTED;\r
   } else {\r
     return EFI_SUCCESS;\r
     return EFI_WRITE_PROTECTED;\r
   } else {\r
     return EFI_SUCCESS;\r
@@ -803,7 +803,7 @@ PioReadWriteData (
 \r
   @param[in] *IdeDev     Pointer pointing to IDE_BLK_IO_DEV data structure, used\r
                          to record all the information of the IDE device.\r
 \r
   @param[in] *IdeDev     Pointer pointing to IDE_BLK_IO_DEV data structure, used\r
                          to record all the information of the IDE device.\r
-  @param[in] *SResult    Sense result for this packet command.\r
+  @param[out] *SResult   Sense result for this packet command.\r
 \r
   @retval EFI_SUCCESS      Device is accessible.\r
   @retval EFI_DEVICE_ERROR Device is not accessible.\r
 \r
   @retval EFI_SUCCESS      Device is accessible.\r
   @retval EFI_DEVICE_ERROR Device is not accessible.\r
@@ -851,17 +851,11 @@ AtapiTestUnitReady (
   pointer pointing to IDE_BLK_IO_DEV data structure, used\r
   to record all the information of the IDE device.\r
 \r
   pointer pointing to IDE_BLK_IO_DEV data structure, used\r
   to record all the information of the IDE device.\r
 \r
-  @param[out] **SenseBuffers\r
+  @param[out] **SenseCounts\r
   allocated in this function, and freed by the calling function.\r
   This buffer is used to accommodate all the sense data returned \r
   by the device.\r
 \r
   allocated in this function, and freed by the calling function.\r
   This buffer is used to accommodate all the sense data returned \r
   by the device.\r
 \r
-  @param[out] *BufUnit\r
-  record the unit size of the sense data block in the SenseBuffers,\r
-\r
-  @param[out] *BufNumbers\r
-  record the number of units in the SenseBuffers.\r
-\r
   @retval EFI_SUCCESS\r
   Request Sense command completes successfully.\r
   \r
   @retval EFI_SUCCESS\r
   Request Sense command completes successfully.\r
   \r
@@ -961,7 +955,7 @@ AtapiRequestSense (
 \r
   @param[in] *IdeDev    Pointer pointing to IDE_BLK_IO_DEV data structure, used\r
                         to record all the information of the IDE device.\r
 \r
   @param[in] *IdeDev    Pointer pointing to IDE_BLK_IO_DEV data structure, used\r
                         to record all the information of the IDE device.\r
-  @param[in] SResult    Sense result for this packet command\r
+  @param[out] SResult   Sense result for this packet command\r
 \r
   @retval EFI_SUCCESS      Read Capacity Command finally completes successfully.\r
   @retval EFI_DEVICE_ERROR Read Capacity Command failed because of device error.\r
 \r
   @retval EFI_SUCCESS      Read Capacity Command finally completes successfully.\r
   @retval EFI_DEVICE_ERROR Read Capacity Command failed because of device error.\r
@@ -1657,7 +1651,7 @@ AtapiSoftReset (
   This function is the ATAPI implementation for ReadBlocks in the\r
   Block I/O Protocol interface.\r
 \r
   This function is the ATAPI implementation for ReadBlocks in the\r
   Block I/O Protocol interface.\r
 \r
-  @param[in] *IdeBlkIoDev\r
+  @param[in] *IdeBlkIoDevice\r
   Indicates the calling context.\r
 \r
   @param[in] MediaId\r
   Indicates the calling context.\r
 \r
   @param[in] MediaId\r
@@ -1795,7 +1789,7 @@ AtapiBlkIoReadBlocks (
   //\r
   // save the first block to the cache for performance\r
   //\r
   //\r
   // save the first block to the cache for performance\r
   //\r
-  if (LBA == 0 && !IdeBlkIoDevice->Cache) {\r
+  if (LBA == 0 && (IdeBlkIoDevice->Cache == NULL)) {\r
     IdeBlkIoDevice->Cache = AllocatePool (BlockSize);\r
     if (IdeBlkIoDevice != NULL) {\r
       CopyMem ((UINT8 *) IdeBlkIoDevice->Cache, (UINT8 *) Buffer, BlockSize);\r
     IdeBlkIoDevice->Cache = AllocatePool (BlockSize);\r
     if (IdeBlkIoDevice != NULL) {\r
       CopyMem ((UINT8 *) IdeBlkIoDevice->Cache, (UINT8 *) Buffer, BlockSize);\r
@@ -1810,7 +1804,7 @@ AtapiBlkIoReadBlocks (
   This function is the ATAPI implementation for WriteBlocks in the\r
   Block I/O Protocol interface.\r
 \r
   This function is the ATAPI implementation for WriteBlocks in the\r
   Block I/O Protocol interface.\r
 \r
-  @param[in] *This\r
+  @param[in] *IdeBlkIoDevice\r
   Indicates the calling context.\r
 \r
   @param[in] MediaId\r
   Indicates the calling context.\r
 \r
   @param[in] MediaId\r
@@ -1869,7 +1863,7 @@ AtapiBlkIoWriteBlocks (
   EFI_STATUS          Status;\r
   BOOLEAN             MediaChange;\r
 \r
   EFI_STATUS          Status;\r
   BOOLEAN             MediaChange;\r
 \r
-  if (LBA == 0 && IdeBlkIoDevice->Cache) {\r
+  if (LBA == 0 && IdeBlkIoDevice->Cache != NULL) {\r
     gBS->FreePool (IdeBlkIoDevice->Cache);\r
     IdeBlkIoDevice->Cache = NULL;\r
   }\r
     gBS->FreePool (IdeBlkIoDevice->Cache);\r
     IdeBlkIoDevice->Cache = NULL;\r
   }\r
@@ -1890,7 +1884,7 @@ AtapiBlkIoWriteBlocks (
   Status      = AtapiDetectMedia (IdeBlkIoDevice, &MediaChange);\r
   if (EFI_ERROR (Status)) {\r
 \r
   Status      = AtapiDetectMedia (IdeBlkIoDevice, &MediaChange);\r
   if (EFI_ERROR (Status)) {\r
 \r
-    if (LBA == 0 && IdeBlkIoDevice->Cache) {\r
+    if (LBA == 0 && IdeBlkIoDevice->Cache != NULL) {\r
       gBS->FreePool (IdeBlkIoDevice->Cache);\r
       IdeBlkIoDevice->Cache = NULL;\r
     }\r
       gBS->FreePool (IdeBlkIoDevice->Cache);\r
       IdeBlkIoDevice->Cache = NULL;\r
     }\r
@@ -1906,7 +1900,7 @@ AtapiBlkIoWriteBlocks (
 \r
   if (!(Media->MediaPresent)) {\r
 \r
 \r
   if (!(Media->MediaPresent)) {\r
 \r
-    if (LBA == 0 && IdeBlkIoDevice->Cache) {\r
+    if (LBA == 0 && IdeBlkIoDevice->Cache != NULL) {\r
       gBS->FreePool (IdeBlkIoDevice->Cache);\r
       IdeBlkIoDevice->Cache = NULL;\r
     }\r
       gBS->FreePool (IdeBlkIoDevice->Cache);\r
       IdeBlkIoDevice->Cache = NULL;\r
     }\r
@@ -1915,7 +1909,7 @@ AtapiBlkIoWriteBlocks (
 \r
   if ((MediaId != Media->MediaId) || MediaChange) {\r
 \r
 \r
   if ((MediaId != Media->MediaId) || MediaChange) {\r
 \r
-    if (LBA == 0 && IdeBlkIoDevice->Cache) {\r
+    if (LBA == 0 && IdeBlkIoDevice->Cache != NULL) {\r
       gBS->FreePool (IdeBlkIoDevice->Cache);\r
       IdeBlkIoDevice->Cache = NULL;\r
     }\r
       gBS->FreePool (IdeBlkIoDevice->Cache);\r
       IdeBlkIoDevice->Cache = NULL;\r
     }\r
@@ -2073,7 +2067,7 @@ AtapiReadPendingData (
 \r
   @retval  EFI_DEVICE_ERROR TODO: Add description for return value\r
   @retval  EFI_DEVICE_ERROR TODO: Add description for return value\r
 \r
   @retval  EFI_DEVICE_ERROR TODO: Add description for return value\r
   @retval  EFI_DEVICE_ERROR TODO: Add description for return value\r
-  @retval  EFI_SUCCESS TODO: Add description for return value\r
+  @retval  EFI_SUCCESS TODO: Add description for return value.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
index f8cb60d5dc1be551f777977ff1ced22030c107a6..cce33cf36a6085bdcbebeede623f4a15a91a411d 100644 (file)
@@ -154,7 +154,7 @@ IDEBusComponentNameGetControllerName (
 \r
   @param  IdeBlkIoDevicePtr TODO: add argument description\r
 \r
 \r
   @param  IdeBlkIoDevicePtr TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 VOID\r
 \r
 **/\r
 VOID\r
index 79385b80842621bbfca0164d59878f9e76d9fd1f..1816e2d0a56460b3d0c1311e92fa711dc012be77 100644 (file)
@@ -33,9 +33,9 @@ EFI_DRIVER_CONFIGURATION_PROTOCOL gIDEBusDriverConfiguration = {
 /**\r
   TODO: Add function description\r
 \r
 /**\r
   TODO: Add function description\r
 \r
-  @retval  EFI_ABORTED TODO: Add description for return value\r
-  @retval  EFI_SUCCESS TODO: Add description for return value\r
-  @retval  EFI_NOT_FOUND TODO: Add description for return value\r
+  @retval  EFI_ABORTED TODO: Add description for return value.\r
+  @retval  EFI_SUCCESS TODO: Add description for return value.\r
+  @retval  EFI_NOT_FOUND TODO: Add description for return value.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
index 6386d7976ebf6d642001ff8696ad8f79228a715c..c6902afe0164ae239c624dcb995062a38c1c3bcf 100644 (file)
@@ -24,7 +24,7 @@ UINT8   MasterDeviceType      = INVALID_DEVICE_TYPE;
   @param  PciIo TODO: add argument description\r
   @param  Port TODO: add argument description\r
 \r
   @param  PciIo TODO: add argument description\r
   @param  Port TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 UINT8\r
 \r
 **/\r
 UINT8\r
@@ -66,7 +66,7 @@ IDEReadPortWMultiple (
   IN  EFI_PCI_IO_PROTOCOL   *PciIo,\r
   IN  UINT16                Port,\r
   IN  UINTN                 Count,\r
   IN  EFI_PCI_IO_PROTOCOL   *PciIo,\r
   IN  UINT16                Port,\r
   IN  UINTN                 Count,\r
-  IN  VOID                  *Buffer\r
+  OUT VOID                  *Buffer\r
   )\r
 {\r
   UINT16  *AlignedBuffer;\r
   )\r
 {\r
   UINT16  *AlignedBuffer;\r
@@ -115,7 +115,7 @@ IDEReadPortWMultiple (
   @param  Port TODO: add argument description\r
   @param  Data TODO: add argument description\r
 \r
   @param  Port TODO: add argument description\r
   @param  Data TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 VOID\r
 \r
 **/\r
 VOID\r
@@ -146,7 +146,7 @@ IDEWritePortB (
   @param  Port TODO: add argument description\r
   @param  Data TODO: add argument description\r
 \r
   @param  Port TODO: add argument description\r
   @param  Data TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 VOID\r
 \r
 **/\r
 VOID\r
@@ -409,7 +409,7 @@ ReassignIdeResources (
 /**\r
   Detect if there is disk connected to this port\r
 \r
 /**\r
   Detect if there is disk connected to this port\r
 \r
-  @param  IdeDev The BLK_IO private data which specifies the IDE device\r
+  @param  IdeDev The BLK_IO private data which specifies the IDE device.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -426,7 +426,7 @@ DiscoverIdeDevice (
   // If a channel has not been checked, check it now. Then set it to "checked" state\r
   // After this step, all devices in this channel have been checked.\r
   //\r
   // If a channel has not been checked, check it now. Then set it to "checked" state\r
   // After this step, all devices in this channel have been checked.\r
   //\r
-  if (ChannelDeviceDetected == FALSE) {\r
+  if (!ChannelDeviceDetected) {\r
     Status = DetectIDEController (IdeDev);\r
     if (EFI_ERROR (Status)) {\r
       return EFI_NOT_FOUND;\r
     Status = DetectIDEController (IdeDev);\r
     if (EFI_ERROR (Status)) {\r
       return EFI_NOT_FOUND;\r
@@ -787,7 +787,7 @@ DRQClear (
 \r
     Delay--;\r
 \r
 \r
     Delay--;\r
 \r
-  } while (Delay);\r
+  } while (Delay > 0);\r
 \r
   if (Delay == 0) {\r
     return EFI_TIMEOUT;\r
 \r
   if (Delay == 0) {\r
     return EFI_TIMEOUT;\r
@@ -861,7 +861,7 @@ DRQClear2 (
 \r
     Delay--;\r
 \r
 \r
     Delay--;\r
 \r
-  } while (Delay);\r
+  } while (Delay > 0);\r
 \r
   if (Delay == 0) {\r
     return EFI_TIMEOUT;\r
 \r
   if (Delay == 0) {\r
     return EFI_TIMEOUT;\r
@@ -939,7 +939,7 @@ DRQReady (
     gBS->Stall (30);\r
 \r
     Delay--;\r
     gBS->Stall (30);\r
 \r
     Delay--;\r
-  } while (Delay);\r
+  } while (Delay > 0);\r
 \r
   if (Delay == 0) {\r
     return EFI_TIMEOUT;\r
 \r
   if (Delay == 0) {\r
     return EFI_TIMEOUT;\r
@@ -1016,7 +1016,7 @@ DRQReady2 (
     gBS->Stall (30);\r
 \r
     Delay--;\r
     gBS->Stall (30);\r
 \r
     Delay--;\r
-  } while (Delay);\r
+  } while (Delay > 0);\r
 \r
   if (Delay == 0) {\r
     return EFI_TIMEOUT;\r
 \r
   if (Delay == 0) {\r
     return EFI_TIMEOUT;\r
@@ -1075,7 +1075,7 @@ WaitForBSYClear (
 \r
     Delay--;\r
 \r
 \r
     Delay--;\r
 \r
-  } while (Delay);\r
+  } while (Delay > 0);\r
 \r
   if (Delay == 0) {\r
     return EFI_TIMEOUT;\r
 \r
   if (Delay == 0) {\r
     return EFI_TIMEOUT;\r
@@ -1132,7 +1132,7 @@ WaitForBSYClear2 (
 \r
     Delay--;\r
 \r
 \r
     Delay--;\r
 \r
-  } while (Delay);\r
+  } while (Delay > 0);\r
 \r
   if (Delay == 0) {\r
     return EFI_TIMEOUT;\r
 \r
   if (Delay == 0) {\r
     return EFI_TIMEOUT;\r
@@ -1154,7 +1154,7 @@ WaitForBSYClear2 (
   pointer pointing to IDE_BLK_IO_DEV data structure, used\r
   to record all the information of the IDE device.\r
 \r
   pointer pointing to IDE_BLK_IO_DEV data structure, used\r
   to record all the information of the IDE device.\r
 \r
-  @param[in] UINTN     IN    TimeoutInMilliSeconds\r
+  @param[in] UINTN     IN    DelayInMilliSeconds\r
   used to designate the timeout for the DRQ ready.\r
 \r
   @retval EFI_SUCCESS\r
   used to designate the timeout for the DRQ ready.\r
 \r
   @retval EFI_SUCCESS\r
@@ -1203,7 +1203,7 @@ DRDYReady (
     gBS->Stall (30);\r
 \r
     Delay--;\r
     gBS->Stall (30);\r
 \r
     Delay--;\r
-  } while (Delay);\r
+  } while (Delay > 0);\r
 \r
   if (Delay == 0) {\r
     return EFI_TIMEOUT;\r
 \r
   if (Delay == 0) {\r
     return EFI_TIMEOUT;\r
@@ -1225,7 +1225,7 @@ DRDYReady (
   pointer pointing to IDE_BLK_IO_DEV data structure, used\r
   to record all the information of the IDE device.\r
 \r
   pointer pointing to IDE_BLK_IO_DEV data structure, used\r
   to record all the information of the IDE device.\r
 \r
-  @param[in] UINTN     IN    TimeoutInMilliSeconds\r
+  @param[in] UINTN     IN    DelayInMilliSeconds\r
   used to designate the timeout for the DRQ ready.\r
 \r
   @retval EFI_SUCCESS\r
   used to designate the timeout for the DRQ ready.\r
 \r
   @retval EFI_SUCCESS\r
@@ -1274,7 +1274,7 @@ DRDYReady2 (
     gBS->Stall (30);\r
 \r
     Delay--;\r
     gBS->Stall (30);\r
 \r
     Delay--;\r
-  } while (Delay);\r
+  } while (Delay > 0);\r
 \r
   if (Delay == 0) {\r
     return EFI_TIMEOUT;\r
 \r
   if (Delay == 0) {\r
     return EFI_TIMEOUT;\r
@@ -1401,7 +1401,7 @@ ReleaseIdeResources (
   @param[in] *IdeDev       Standard IDE device private data structure\r
   @param[in] *TransferMode The device transfer mode to be set\r
 \r
   @param[in] *IdeDev       Standard IDE device private data structure\r
   @param[in] *TransferMode The device transfer mode to be set\r
 \r
-  @return Set transfer mode Command execute status\r
+  @return Set transfer mode Command execute status.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -1450,7 +1450,7 @@ SetDeviceTransferMode (
 \r
   @retval  EFI_SUCCESS Reading succeed\r
   @retval  EFI_ABORTED Command failed\r
 \r
   @retval  EFI_SUCCESS Reading succeed\r
   @retval  EFI_ABORTED Command failed\r
-  @retval  EFI_DEVICE_ERROR Device status error\r
+  @retval  EFI_DEVICE_ERROR Device status error.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -1542,7 +1542,7 @@ AtaNonDataCommandIn (
 \r
   @retval  EFI_SUCCESS Reading succeed\r
   @retval  EFI_ABORTED Command failed\r
 \r
   @retval  EFI_SUCCESS Reading succeed\r
   @retval  EFI_ABORTED Command failed\r
-  @retval  EFI_DEVICE_ERROR Device status error\r
+  @retval  EFI_DEVICE_ERROR Device status error.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -1658,7 +1658,7 @@ AtaNonDataCommandInExt (
   @param[in] IdeDev       Standard IDE device private data structure\r
   @param[in] DriveParameters The device parameters to be set into the disk\r
 \r
   @param[in] IdeDev       Standard IDE device private data structure\r
   @param[in] DriveParameters The device parameters to be set into the disk\r
 \r
-  @return SetParameters Command execute status\r
+  @return SetParameters Command execute status.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -1708,7 +1708,7 @@ SetDriveParameters (
 \r
   @param  IdeDev TODO: add argument description\r
 \r
 \r
   @param  IdeDev TODO: add argument description\r
 \r
-  @retval  EFI_SUCCESS TODO: Add description for return value\r
+  @retval  EFI_SUCCESS TODO: Add description for return value.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
index 9fd43f551a37f16a03c509d0c95056ca9ed08579..71ab6ecd7505499b8d65a0aad65850d177b50138 100644 (file)
@@ -31,7 +31,7 @@
   @param  Controller TODO: add argument description\r
   @param  Handle TODO: add argument description\r
 \r
   @param  Controller TODO: add argument description\r
   @param  Handle TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -49,7 +49,7 @@ DeRegisterIdeDevice (
   @param  ParentDevicePath TODO: add argument description\r
   @param  RemainingDevicePath TODO: add argument description\r
 \r
   @param  ParentDevicePath TODO: add argument description\r
   @param  RemainingDevicePath TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -66,7 +66,7 @@ EnableIdeDevice (
   @param  PciIo TODO: add argument description\r
   @param  Port TODO: add argument description\r
 \r
   @param  PciIo TODO: add argument description\r
   @param  Port TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 UINT8\r
 \r
 **/\r
 UINT8\r
@@ -83,7 +83,7 @@ IDEReadPortB (
   @param  Count TODO: add argument description\r
   @param  Buffer TODO: add argument description\r
 \r
   @param  Count TODO: add argument description\r
   @param  Buffer TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 VOID\r
 \r
 **/\r
 VOID\r
@@ -101,7 +101,7 @@ IDEReadPortWMultiple (
   @param  Port TODO: add argument description\r
   @param  Data TODO: add argument description\r
 \r
   @param  Port TODO: add argument description\r
   @param  Data TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 VOID\r
 \r
 **/\r
 VOID\r
@@ -136,7 +136,7 @@ IDEWritePortW (
   @param  Count TODO: add argument description\r
   @param  Buffer TODO: add argument description\r
 \r
   @param  Count TODO: add argument description\r
   @param  Buffer TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 VOID\r
 \r
 **/\r
 VOID\r
@@ -153,7 +153,7 @@ IDEWritePortWMultiple (
   @param  PciIo TODO: add argument description\r
   @param  IdeRegsBaseAddr TODO: add argument description\r
 \r
   @param  PciIo TODO: add argument description\r
   @param  IdeRegsBaseAddr TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -167,7 +167,7 @@ GetIdeRegistersBaseAddr (
 \r
   @param  IdeDev TODO: add argument description\r
 \r
 \r
   @param  IdeDev TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -180,7 +180,7 @@ ReassignIdeResources (
 \r
   @param  IdeDev TODO: add argument description\r
 \r
 \r
   @param  IdeDev TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -205,7 +205,7 @@ InitializeIDEChannelData (
 \r
   @param  IdeDev TODO: add argument description\r
 \r
 \r
   @param  IdeDev TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -219,7 +219,7 @@ DetectIDEController (
   @param  IdeDev TODO: add argument description\r
   @param  TimeoutInMilliSeconds TODO: add argument description\r
 \r
   @param  IdeDev TODO: add argument description\r
   @param  TimeoutInMilliSeconds TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -234,7 +234,7 @@ DRQClear (
   @param  IdeDev TODO: add argument description\r
   @param  TimeoutInMilliSeconds TODO: add argument description\r
 \r
   @param  IdeDev TODO: add argument description\r
   @param  TimeoutInMilliSeconds TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -249,7 +249,7 @@ DRQClear2 (
   @param  IdeDev TODO: add argument description\r
   @param  TimeoutInMilliSeconds TODO: add argument description\r
 \r
   @param  IdeDev TODO: add argument description\r
   @param  TimeoutInMilliSeconds TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -264,7 +264,7 @@ DRQReady (
   @param  IdeDev TODO: add argument description\r
   @param  TimeoutInMilliSeconds TODO: add argument description\r
 \r
   @param  IdeDev TODO: add argument description\r
   @param  TimeoutInMilliSeconds TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -279,7 +279,7 @@ DRQReady2 (
   @param  IdeDev TODO: add argument description\r
   @param  TimeoutInMilliSeconds TODO: add argument description\r
 \r
   @param  IdeDev TODO: add argument description\r
   @param  TimeoutInMilliSeconds TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -294,7 +294,7 @@ WaitForBSYClear (
   @param  IdeDev TODO: add argument description\r
   @param  TimeoutInMilliSeconds TODO: add argument description\r
 \r
   @param  IdeDev TODO: add argument description\r
   @param  TimeoutInMilliSeconds TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -309,7 +309,7 @@ WaitForBSYClear2 (
   @param  IdeDev TODO: add argument description\r
   @param  DelayInMilliSeconds TODO: add argument description\r
 \r
   @param  IdeDev TODO: add argument description\r
   @param  DelayInMilliSeconds TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -324,7 +324,7 @@ DRDYReady (
   @param  IdeDev TODO: add argument description\r
   @param  DelayInMilliSeconds TODO: add argument description\r
 \r
   @param  IdeDev TODO: add argument description\r
   @param  DelayInMilliSeconds TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -340,7 +340,7 @@ DRDYReady2 (
   @param  Source TODO: add argument description\r
   @param  Size TODO: add argument description\r
 \r
   @param  Source TODO: add argument description\r
   @param  Size TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 VOID\r
 \r
 **/\r
 VOID\r
@@ -358,7 +358,7 @@ SwapStringChars (
 \r
   @param  IdeDev TODO: add argument description\r
 \r
 \r
   @param  IdeDev TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -371,7 +371,7 @@ ATAIdentify (
 \r
   @param  IdeDev TODO: add argument description\r
 \r
 \r
   @param  IdeDev TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 VOID\r
 \r
 **/\r
 VOID\r
@@ -392,7 +392,7 @@ PrintAtaModuleName (
   @param  CylinderLsb TODO: add argument description\r
   @param  CylinderMsb TODO: add argument description\r
 \r
   @param  CylinderLsb TODO: add argument description\r
   @param  CylinderMsb TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -421,7 +421,7 @@ AtaPioDataIn (
   @param  CylinderLsb TODO: add argument description\r
   @param  CylinderMsb TODO: add argument description\r
 \r
   @param  CylinderLsb TODO: add argument description\r
   @param  CylinderMsb TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -458,7 +458,7 @@ CheckErrorStatus (
   @param  Lba TODO: add argument description\r
   @param  NumberOfBlocks TODO: add argument description\r
 \r
   @param  Lba TODO: add argument description\r
   @param  NumberOfBlocks TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -477,7 +477,7 @@ AtaReadSectors (
   @param  Lba TODO: add argument description\r
   @param  NumberOfBlocks TODO: add argument description\r
 \r
   @param  Lba TODO: add argument description\r
   @param  NumberOfBlocks TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -493,7 +493,7 @@ AtaWriteSectors (
 \r
   @param  IdeDev TODO: add argument description\r
 \r
 \r
   @param  IdeDev TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -510,7 +510,7 @@ AtaSoftReset (
   @param  BufferSize TODO: add argument description\r
   @param  Buffer TODO: add argument description\r
 \r
   @param  BufferSize TODO: add argument description\r
   @param  Buffer TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -531,7 +531,7 @@ AtaBlkIoReadBlocks (
   @param  BufferSize TODO: add argument description\r
   @param  Buffer TODO: add argument description\r
 \r
   @param  BufferSize TODO: add argument description\r
   @param  Buffer TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -551,7 +551,7 @@ AtaBlkIoWriteBlocks (
 \r
   @param  IdeDev TODO: add argument description\r
 \r
 \r
   @param  IdeDev TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -564,7 +564,7 @@ ATAPIIdentify (
 \r
   @param  IdeDev TODO: add argument description\r
 \r
 \r
   @param  IdeDev TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -581,7 +581,7 @@ AtapiInquiry (
   @param  ByteCount TODO: add argument description\r
   @param  TimeOut TODO: add argument description\r
 \r
   @param  ByteCount TODO: add argument description\r
   @param  TimeOut TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -602,7 +602,7 @@ AtapiPacketCommandIn (
   @param  ByteCount TODO: add argument description\r
   @param  TimeOut TODO: add argument description\r
 \r
   @param  ByteCount TODO: add argument description\r
   @param  TimeOut TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -623,7 +623,7 @@ AtapiPacketCommandOut (
   @param  Read TODO: add argument description\r
   @param  TimeOut TODO: add argument description\r
 \r
   @param  Read TODO: add argument description\r
   @param  TimeOut TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -638,10 +638,10 @@ PioReadWriteData (
 /**\r
   TODO: Add function description\r
 \r
 /**\r
   TODO: Add function description\r
 \r
-  @param  IdeDev TODO: add argument description\r
-  @param  IdeDev TODO: add argument description\r
+  @param  IdeDev  TODO: add argument description\r
+  @param  SResult TODO: add argument description\r
 \r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -656,7 +656,7 @@ AtapiTestUnitReady (
   @param  IdeDev TODO: add argument description\r
   @param  SenseCounts TODO: add argument description\r
 \r
   @param  IdeDev TODO: add argument description\r
   @param  SenseCounts TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -668,10 +668,10 @@ AtapiRequestSense (
 /**\r
   TODO: Add function description\r
 \r
 /**\r
   TODO: Add function description\r
 \r
-  @param  IdeDev TODO: add argument description\r
-  @param  IdeDev TODO: add argument description\r
+  @param  IdeDev  TODO: add argument description\r
+  @param  SResult TODO: add argument description\r
 \r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -686,7 +686,7 @@ AtapiReadCapacity (
   @param  IdeDev TODO: add argument description\r
   @param  MediaChange TODO: add argument description\r
 \r
   @param  IdeDev TODO: add argument description\r
   @param  MediaChange TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -703,7 +703,7 @@ AtapiDetectMedia (
   @param  Lba TODO: add argument description\r
   @param  NumberOfBlocks TODO: add argument description\r
 \r
   @param  Lba TODO: add argument description\r
   @param  NumberOfBlocks TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -722,7 +722,7 @@ AtapiReadSectors (
   @param  Lba TODO: add argument description\r
   @param  NumberOfBlocks TODO: add argument description\r
 \r
   @param  Lba TODO: add argument description\r
   @param  NumberOfBlocks TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -738,7 +738,7 @@ AtapiWriteSectors (
 \r
   @param  IdeDev TODO: add argument description\r
 \r
 \r
   @param  IdeDev TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -755,7 +755,7 @@ AtapiSoftReset (
   @param  BufferSize TODO: add argument description\r
   @param  Buffer TODO: add argument description\r
 \r
   @param  BufferSize TODO: add argument description\r
   @param  Buffer TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -776,7 +776,7 @@ AtapiBlkIoReadBlocks (
   @param  BufferSize TODO: add argument description\r
   @param  Buffer TODO: add argument description\r
 \r
   @param  BufferSize TODO: add argument description\r
   @param  Buffer TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -795,7 +795,7 @@ AtapiBlkIoWriteBlocks (
   @param  SenseCount TODO: add argument description\r
   @param  Result TODO: add argument description\r
 \r
   @param  SenseCount TODO: add argument description\r
   @param  Result TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -810,7 +810,7 @@ ParseSenseData (
 \r
   @param  IdeDev TODO: add argument description\r
 \r
 \r
   @param  IdeDev TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -824,7 +824,7 @@ AtapiReadPendingData (
   @param  IdeDev TODO: add argument description\r
   @param  WriteProtected TODO: add argument description\r
 \r
   @param  IdeDev TODO: add argument description\r
   @param  WriteProtected TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -838,7 +838,7 @@ IsLS120orZipWriteProtected (
 \r
   @param  IdeBlkIoDevice TODO: add argument description\r
 \r
 \r
   @param  IdeBlkIoDevice TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 VOID\r
 \r
 **/\r
 VOID\r
@@ -852,7 +852,7 @@ ReleaseIdeResources (
   @param  IdeDev TODO: add argument description\r
   @param  TransferMode TODO: add argument description\r
 \r
   @param  IdeDev TODO: add argument description\r
   @param  TransferMode TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -867,7 +867,7 @@ SetDeviceTransferMode (
   @param  IdeDev TODO: add argument description\r
   @param  NativeMaxAddress TODO: add argument description\r
 \r
   @param  IdeDev TODO: add argument description\r
   @param  NativeMaxAddress TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -883,7 +883,7 @@ ReadNativeMaxAddress (
   @param  MaxAddress TODO: add argument description\r
   @param  bVolatile TODO: add argument description\r
 \r
   @param  MaxAddress TODO: add argument description\r
   @param  bVolatile TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -905,7 +905,7 @@ SetMaxAddress (
   @param  LbaMiddle TODO: add argument description\r
   @param  LbaHigh TODO: add argument description\r
 \r
   @param  LbaMiddle TODO: add argument description\r
   @param  LbaHigh TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -930,7 +930,7 @@ AtaNonDataCommandIn (
   @param  SectorCount TODO: add argument description\r
   @param  LbaAddress TODO: add argument description\r
 \r
   @param  SectorCount TODO: add argument description\r
   @param  LbaAddress TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -951,7 +951,7 @@ AtaNonDataCommandInExt (
   @param  StartLba TODO: add argument description\r
   @param  NumberOfBlocks TODO: add argument description\r
 \r
   @param  StartLba TODO: add argument description\r
   @param  NumberOfBlocks TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -970,7 +970,7 @@ AtaReadSectorsExt (
   @param  StartLba TODO: add argument description\r
   @param  NumberOfBlocks TODO: add argument description\r
 \r
   @param  StartLba TODO: add argument description\r
   @param  NumberOfBlocks TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -989,7 +989,7 @@ AtaWriteSectorsExt (
   @param  StartLba TODO: add argument description\r
   @param  NumberOfBlocks TODO: add argument description\r
 \r
   @param  StartLba TODO: add argument description\r
   @param  NumberOfBlocks TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -1008,7 +1008,7 @@ AtaUdmaReadExt (
   @param  StartLba TODO: add argument description\r
   @param  NumberOfBlocks TODO: add argument description\r
 \r
   @param  StartLba TODO: add argument description\r
   @param  NumberOfBlocks TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -1027,7 +1027,7 @@ AtaUdmaRead (
   @param  StartLba TODO: add argument description\r
   @param  NumberOfBlocks TODO: add argument description\r
 \r
   @param  StartLba TODO: add argument description\r
   @param  NumberOfBlocks TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -1081,7 +1081,7 @@ DoAtaUdma (
   @param  StartLba TODO: add argument description\r
   @param  NumberOfBlocks TODO: add argument description\r
 \r
   @param  StartLba TODO: add argument description\r
   @param  NumberOfBlocks TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -1102,7 +1102,7 @@ AtaUdmaWrite (
   @param  SectorCount TODO: add argument description\r
   @param  LbaAddress TODO: add argument description\r
 \r
   @param  SectorCount TODO: add argument description\r
   @param  LbaAddress TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -1125,7 +1125,7 @@ AtaCommandIssueExt (
   @param  SectorCount TODO: add argument description\r
   @param  LbaAddress TODO: add argument description\r
 \r
   @param  SectorCount TODO: add argument description\r
   @param  LbaAddress TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -1143,7 +1143,7 @@ AtaCommandIssue (
 \r
   @param  IdeDev TODO: add argument description\r
 \r
 \r
   @param  IdeDev TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -1157,7 +1157,7 @@ AtaAtapi6Identify (
 \r
   @param  IdeDev TODO: add argument description\r
 \r
 \r
   @param  IdeDev TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 VOID\r
 \r
 **/\r
 VOID\r
@@ -1175,7 +1175,7 @@ AtaSMARTSupport (
   @param  StartLba TODO: add argument description\r
   @param  SectorCount TODO: add argument description\r
 \r
   @param  StartLba TODO: add argument description\r
   @param  SectorCount TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -1198,7 +1198,7 @@ AtaPioDataInExt (
   @param  StartLba TODO: add argument description\r
   @param  SectorCount TODO: add argument description\r
 \r
   @param  StartLba TODO: add argument description\r
   @param  SectorCount TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -1217,7 +1217,7 @@ AtaPioDataOutExt (
   @param  IdeDev TODO: add argument description\r
   @param  DriveParameters TODO: add argument description\r
 \r
   @param  IdeDev TODO: add argument description\r
   @param  DriveParameters TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -1231,7 +1231,7 @@ SetDriveParameters (
 \r
   @param  IdeDev TODO: add argument description\r
 \r
 \r
   @param  IdeDev TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -1245,7 +1245,7 @@ EnableInterrupt (
   @param[in]  Event   Pointer to this event\r
   @param[in]  Context Event hanlder private data\r
 \r
   @param[in]  Event   Pointer to this event\r
   @param[in]  Context Event hanlder private data\r
 \r
-  @retval  EFI_SUCCESS - Interrupt cleared\r
+  @retval  EFI_SUCCESS - Interrupt cleared.\r
 \r
 **/\r
 VOID\r
 \r
 **/\r
 VOID\r
index 5b6f0de60fc61de4ed0a5c750f5c61ed7528c1bc..e864eccc31005b757bcf6d644dbec378b7ed72e5 100644 (file)
@@ -437,7 +437,7 @@ IDEBusDriverBindingStart (
       //\r
       // Check whether the configuration options allow this device\r
       //\r
       //\r
       // Check whether the configuration options allow this device\r
       //\r
-      if (!(ConfigurationOptions & (1 << (IdeChannel * 2 + IdeDevice)))) {\r
+      if ((ConfigurationOptions & (1 << (IdeChannel * 2 + IdeDevice))) == 0) {\r
         continue;\r
       }\r
 \r
         continue;\r
       }\r
 \r
@@ -822,7 +822,7 @@ ErrorExit:
   Stop this driver on Controller Handle.\r
 \r
   @param  This Protocol instance pointer.\r
   Stop this driver on Controller Handle.\r
 \r
   @param  This Protocol instance pointer.\r
-  @param  DeviceHandle Handle of device to stop driver on\r
+  @param  Controller Handle of device to stop driver on\r
   @param  NumberOfChildren Not used\r
   @param  ChildHandleBuffer Not used\r
 \r
   @param  NumberOfChildren Not used\r
   @param  ChildHandleBuffer Not used\r
 \r
index 6e540ca15a9bfbad1bf0d6a94a557421a3666d33..f4ec71594d041e301cc75635ff05bf926a3629da 100644 (file)
@@ -127,7 +127,7 @@ extern EFI_DRIVER_DIAGNOSTICS2_PROTOCOL gIDEBusDriverDiagnostics2;
   @param  ImageHandle TODO: add argument description\r
   @param  SystemTable TODO: add argument description\r
 \r
   @param  ImageHandle TODO: add argument description\r
   @param  SystemTable TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -144,7 +144,7 @@ IDEBusControllerDriverEntryPoint (
   @param  Controller TODO: add argument description\r
   @param  RemainingDevicePath TODO: add argument description\r
 \r
   @param  Controller TODO: add argument description\r
   @param  RemainingDevicePath TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -162,7 +162,7 @@ IDEBusDriverBindingSupported (
   @param  Controller TODO: add argument description\r
   @param  RemainingDevicePath TODO: add argument description\r
 \r
   @param  Controller TODO: add argument description\r
   @param  RemainingDevicePath TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -181,7 +181,7 @@ IDEBusDriverBindingStart (
   @param  NumberOfChildren TODO: add argument description\r
   @param  ChildHandleBuffer TODO: add argument description\r
 \r
   @param  NumberOfChildren TODO: add argument description\r
   @param  ChildHandleBuffer TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -245,7 +245,7 @@ IDEBusDriverDiagnosticsRunDiagnostics (
   @param  This TODO: add argument description\r
   @param  ExtendedVerification TODO: add argument description\r
 \r
   @param  This TODO: add argument description\r
   @param  ExtendedVerification TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -286,7 +286,7 @@ IDEBlkIoReadBlocks (
   @param  BufferSize TODO: add argument description\r
   @param  Buffer TODO: add argument description\r
 \r
   @param  BufferSize TODO: add argument description\r
   @param  Buffer TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -304,7 +304,7 @@ IDEBlkIoWriteBlocks (
 \r
   @param  This TODO: add argument description\r
 \r
 \r
   @param  This TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -319,7 +319,7 @@ IDEBlkIoFlushBlocks (
   @param  PciIo TODO: add argument description\r
   @param  Enable TODO: add argument description\r
 \r
   @param  PciIo TODO: add argument description\r
   @param  Enable TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -335,7 +335,7 @@ IDERegisterDecodeEnableorDisable (
   @param  InquiryData TODO: add argument description\r
   @param  IntquiryDataSize TODO: add argument description\r
 \r
   @param  InquiryData TODO: add argument description\r
   @param  IntquiryDataSize TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -353,7 +353,7 @@ IDEDiskInfoInquiry (
   @param  IdentifyData TODO: add argument description\r
   @param  IdentifyDataSize TODO: add argument description\r
 \r
   @param  IdentifyData TODO: add argument description\r
   @param  IdentifyDataSize TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -372,7 +372,7 @@ IDEDiskInfoIdentify (
   @param  SenseDataSize TODO: add argument description\r
   @param  SenseDataNumber TODO: add argument description\r
 \r
   @param  SenseDataSize TODO: add argument description\r
   @param  SenseDataNumber TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -391,7 +391,7 @@ IDEDiskInfoSenseData (
   @param  IdeChannel TODO: add argument description\r
   @param  IdeDevice TODO: add argument description\r
 \r
   @param  IdeChannel TODO: add argument description\r
   @param  IdeDevice TODO: add argument description\r
 \r
-  TODO: add return values\r
+  TODO: add return values.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
index 304a543f4485ea0ff5df42eabe08fdee6f77e6da..2a517448beede860c4b2404963fe1523c6d9d3b0 100644 (file)
@@ -1,4 +1,4 @@
-/**@file\r
+/** @file\r
    Driver Binding functions for PCI bus module.\r
    \r
 Copyright (c) 2006, Intel Corporation                                                         \r
    Driver Binding functions for PCI bus module.\r
    \r
 Copyright (c) 2006, Intel Corporation                                                         \r
@@ -44,8 +44,8 @@ EFI_PCI_PLATFORM_PROTOCOL                     *gPciPlatformProtocol;
   Initialize the global variables\r
   publish the driver binding protocol\r
 \r
   Initialize the global variables\r
   publish the driver binding protocol\r
 \r
-  @param[IN] ImageHandle,\r
-  @param[IN] *SystemTable\r
+  @param[in] ImageHandle,\r
+  @param[in] *SystemTable\r
 \r
   @retval status of installing driver binding component name protocol.\r
 \r
 \r
   @retval status of installing driver binding component name protocol.\r
 \r
index 6fa61cae291e6c259abc36489cc0a301b79d1f6f..506e1803dc3be9b5c6343bc3e3cddf925f0d1736 100644 (file)
@@ -1,4 +1,4 @@
-/**@file\r
+/** @file\r
   This module implement Pci register operation interface for \r
   Pci device.\r
   \r
   This module implement Pci register operation interface for \r
   Pci device.\r
   \r
@@ -81,7 +81,7 @@ PciOperateRegister (
   @param PciIoDevice  Pointer to instance of PCI_IO_DEVICE\r
   \r
   @retval TRUE  Support\r
   @param PciIoDevice  Pointer to instance of PCI_IO_DEVICE\r
   \r
   @retval TRUE  Support\r
-  @retval FALSE Not support\r
+  @retval FALSE Not support.\r
 **/\r
 BOOLEAN\r
 PciCapabilitySupport (\r
 **/\r
 BOOLEAN\r
 PciCapabilitySupport (\r
index 624ec50b17ecdbeb2f50b8f82ba509c9fbf651a2..3354359f5e6c135269767813beb16371ac919377 100644 (file)
@@ -1,4 +1,4 @@
-/**@file\r
+/** @file\r
 \r
 Copyright (c) 2006, Intel Corporation                                                         \r
 All rights reserved. This program and the accompanying materials                          \r
 \r
 Copyright (c) 2006, Intel Corporation                                                         \r
 All rights reserved. This program and the accompanying materials                          \r
@@ -87,7 +87,7 @@ PciOperateRegister (
   @param PciIoDevice  Pointer to instance of PCI_IO_DEVICE\r
   \r
   @retval TRUE  Support\r
   @param PciIoDevice  Pointer to instance of PCI_IO_DEVICE\r
   \r
   @retval TRUE  Support\r
-  @retval FALSE Not support\r
+  @retval FALSE Not support.\r
 **/\r
 BOOLEAN\r
 PciCapabilitySupport (\r
 **/\r
 BOOLEAN\r
 PciCapabilitySupport (\r
index 584f4f5c9ef07dffa556e22d0a4b7ce4dbf97078..3f72a71d731c6ffbbf96f091ea5b769715f351e0 100644 (file)
@@ -1,4 +1,4 @@
-/**@file\r
+/** @file\r
 \r
 Copyright (c) 2006, Intel Corporation                                                         \r
 All rights reserved. This program and the accompanying materials                          \r
 \r
 Copyright (c) 2006, Intel Corporation                                                         \r
 All rights reserved. This program and the accompanying materials                          \r
@@ -22,7 +22,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
 LIST_ENTRY  gPciDevicePool;\r
 \r
 /**\r
 LIST_ENTRY  gPciDevicePool;\r
 \r
 /**\r
-  Initialize the gPciDevicePool\r
+  Initialize the gPciDevicePool.\r
 **/\r
 EFI_STATUS\r
 InitializePciDevicePool (\r
 **/\r
 EFI_STATUS\r
 InitializePciDevicePool (\r
@@ -75,7 +75,7 @@ InsertPciDevice (
 /**\r
   Destroy root bridge and remove it from deivce tree.\r
   \r
 /**\r
   Destroy root bridge and remove it from deivce tree.\r
   \r
-  @param RootBridge   The bridge want to be removed\r
+  @param RootBridge   The bridge want to be removed.\r
   \r
 **/\r
 EFI_STATUS\r
   \r
 **/\r
 EFI_STATUS\r
@@ -174,7 +174,7 @@ DestroyRootBridgeByHandle (
 \r
   CurrentLink = gPciDevicePool.ForwardLink;\r
 \r
 \r
   CurrentLink = gPciDevicePool.ForwardLink;\r
 \r
-  while (CurrentLink && CurrentLink != &gPciDevicePool) {\r
+  while (CurrentLink != NULL && CurrentLink != &gPciDevicePool) {\r
     Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
 \r
     if (Temp->Handle == Controller) {\r
     Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
 \r
     if (Temp->Handle == Controller) {\r
@@ -456,7 +456,7 @@ DeRegisterPciDevice (
 \r
       CurrentLink = PciIoDevice->ChildList.ForwardLink;\r
 \r
 \r
       CurrentLink = PciIoDevice->ChildList.ForwardLink;\r
 \r
-      while (CurrentLink && CurrentLink != &PciIoDevice->ChildList) {\r
+      while (CurrentLink != NULL && CurrentLink != &PciIoDevice->ChildList) {\r
         Node    = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
         Status  = DeRegisterPciDevice (Controller, Node->Handle);\r
 \r
         Node    = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
         Status  = DeRegisterPciDevice (Controller, Node->Handle);\r
 \r
@@ -571,7 +571,7 @@ StartPciDevicesOnBridge (
 \r
   CurrentLink = RootBridge->ChildList.ForwardLink;\r
 \r
 \r
   CurrentLink = RootBridge->ChildList.ForwardLink;\r
 \r
-  while (CurrentLink && CurrentLink != &RootBridge->ChildList) {\r
+  while (CurrentLink != NULL && CurrentLink != &RootBridge->ChildList) {\r
 \r
     PciIoDevice = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
     if (RemainingDevicePath != NULL) {\r
 \r
     PciIoDevice = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
     if (RemainingDevicePath != NULL) {\r
@@ -728,7 +728,7 @@ StartPciDevices (
 \r
   CurrentLink = gPciDevicePool.ForwardLink;\r
 \r
 \r
   CurrentLink = gPciDevicePool.ForwardLink;\r
 \r
-  while (CurrentLink && CurrentLink != &gPciDevicePool) {\r
+  while (CurrentLink != NULL && CurrentLink != &gPciDevicePool) {\r
 \r
     RootBridge = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
     //\r
 \r
     RootBridge = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
     //\r
@@ -839,11 +839,11 @@ CreateRootBridge (
 }\r
 \r
 /**\r
 }\r
 \r
 /**\r
-  Get root bridge device instance by specific handle\r
+  Get root bridge device instance by specific handle.\r
 \r
 \r
-  @param RootBridgeHandle    Given root bridge handle\r
+  @param RootBridgeHandle    Given root bridge handle.\r
 \r
 \r
-  @return root bridge device instance\r
+  @return root bridge device instance.\r
 **/\r
 PCI_IO_DEVICE *\r
 GetRootBridgeByHandle (\r
 **/\r
 PCI_IO_DEVICE *\r
 GetRootBridgeByHandle (\r
@@ -855,7 +855,7 @@ GetRootBridgeByHandle (
 \r
   CurrentLink = gPciDevicePool.ForwardLink;\r
 \r
 \r
   CurrentLink = gPciDevicePool.ForwardLink;\r
 \r
-  while (CurrentLink && CurrentLink != &gPciDevicePool) {\r
+  while (CurrentLink != NULL && CurrentLink != &gPciDevicePool) {\r
 \r
     RootBridgeDev = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
     if (RootBridgeDev->Handle == RootBridgeHandle) {\r
 \r
     RootBridgeDev = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
     if (RootBridgeDev->Handle == RootBridgeHandle) {\r
@@ -869,12 +869,12 @@ GetRootBridgeByHandle (
 }\r
 \r
 /**\r
 }\r
 \r
 /**\r
-  Judege whether Pci device existed\r
+  Judege whether Pci device existed.\r
   \r
   \r
-  @param Bridge       Parent bridege instance \r
-  @param PciIoDevice  Device instance\r
+  @param Bridge       Parent bridege instance.\r
+  @param PciIoDevice  Device instance.\r
   \r
   \r
-  @return whether Pci device existed\r
+  @return whether Pci device existed.\r
 **/\r
 BOOLEAN\r
 PciDeviceExisted (\r
 **/\r
 BOOLEAN\r
 PciDeviceExisted (\r
@@ -888,7 +888,7 @@ PciDeviceExisted (
 \r
   CurrentLink = Bridge->ChildList.ForwardLink;\r
 \r
 \r
   CurrentLink = Bridge->ChildList.ForwardLink;\r
 \r
-  while (CurrentLink && CurrentLink != &Bridge->ChildList) {\r
+  while (CurrentLink != NULL && CurrentLink != &Bridge->ChildList) {\r
 \r
     Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
 \r
 \r
     Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
 \r
@@ -909,11 +909,11 @@ PciDeviceExisted (
 }\r
 \r
 /**\r
 }\r
 \r
 /**\r
-  Active VGA device\r
+  Active VGA device.\r
   \r
   \r
-  @param VgaDevice device instance for VGA\r
+  @param VgaDevice device instance for VGA.\r
   \r
   \r
-  @return device instance\r
+  @return device instance.\r
 **/\r
 PCI_IO_DEVICE *\r
 ActiveVGADeviceOnTheSameSegment (\r
 **/\r
 PCI_IO_DEVICE *\r
 ActiveVGADeviceOnTheSameSegment (\r
@@ -925,7 +925,7 @@ ActiveVGADeviceOnTheSameSegment (
 \r
   CurrentLink = gPciDevicePool.ForwardLink;\r
 \r
 \r
   CurrentLink = gPciDevicePool.ForwardLink;\r
 \r
-  while (CurrentLink && CurrentLink != &gPciDevicePool) {\r
+  while (CurrentLink != NULL && CurrentLink != &gPciDevicePool) {\r
 \r
     Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
 \r
 \r
     Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
 \r
@@ -945,11 +945,11 @@ ActiveVGADeviceOnTheSameSegment (
 }\r
 \r
 /**\r
 }\r
 \r
 /**\r
-  Active VGA device on root bridge\r
+  Active VGA device on root bridge.\r
   \r
   \r
-  @param RootBridge  Root bridge device instance\r
+  @param RootBridge  Root bridge device instance.\r
   \r
   \r
-  @return VGA device instance\r
+  @return VGA device instance.\r
 **/\r
 PCI_IO_DEVICE *\r
 ActiveVGADeviceOnTheRootBridge (\r
 **/\r
 PCI_IO_DEVICE *\r
 ActiveVGADeviceOnTheRootBridge (\r
@@ -961,7 +961,7 @@ ActiveVGADeviceOnTheRootBridge (
 \r
   CurrentLink = RootBridge->ChildList.ForwardLink;\r
 \r
 \r
   CurrentLink = RootBridge->ChildList.ForwardLink;\r
 \r
-  while (CurrentLink && CurrentLink != &RootBridge->ChildList) {\r
+  while (CurrentLink != NULL && CurrentLink != &RootBridge->ChildList) {\r
 \r
     Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
 \r
 \r
     Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
 \r
@@ -969,7 +969,7 @@ ActiveVGADeviceOnTheRootBridge (
         (Temp->Attributes &\r
          (EFI_PCI_IO_ATTRIBUTE_VGA_MEMORY |\r
           EFI_PCI_IO_ATTRIBUTE_VGA_IO     |\r
         (Temp->Attributes &\r
          (EFI_PCI_IO_ATTRIBUTE_VGA_MEMORY |\r
           EFI_PCI_IO_ATTRIBUTE_VGA_IO     |\r
-          EFI_PCI_IO_ATTRIBUTE_VGA_IO_16))) {\r
+          EFI_PCI_IO_ATTRIBUTE_VGA_IO_16)) != 0) {\r
       return Temp;\r
     }\r
 \r
       return Temp;\r
     }\r
 \r
@@ -989,13 +989,13 @@ ActiveVGADeviceOnTheRootBridge (
 }\r
 \r
 /**\r
 }\r
 \r
 /**\r
-  Get HPC PCI address according to its device path\r
-  @param PciRootBridgeIo   Root bridege Io instance\r
-  @param HpcDevicePath     Given searching device path\r
-  @param PciAddress        Buffer holding searched result\r
+  Get HPC PCI address according to its device path.\r
+  @param PciRootBridgeIo   Root bridege Io instance.\r
+  @param HpcDevicePath     Given searching device path.\r
+  @param PciAddress        Buffer holding searched result.\r
   \r
   @retval EFI_NOT_FOUND Can not find the specific device path.\r
   \r
   @retval EFI_NOT_FOUND Can not find the specific device path.\r
-  @retval EFI_SUCCESS   Success to get the device path\r
+  @retval EFI_SUCCESS   Success to get the device path.\r
 **/\r
 EFI_STATUS\r
 GetHpcPciAddress (\r
 **/\r
 EFI_STATUS\r
 GetHpcPciAddress (\r
@@ -1041,7 +1041,7 @@ GetHpcPciAddress (
 \r
   CurrentLink = gPciDevicePool.ForwardLink;\r
 \r
 \r
   CurrentLink = gPciDevicePool.ForwardLink;\r
 \r
-  while (CurrentLink && CurrentLink != &gPciDevicePool) {\r
+  while (CurrentLink != NULL && CurrentLink != &gPciDevicePool) {\r
 \r
     RootBridge = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
     //\r
 \r
     RootBridge = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
     //\r
@@ -1068,10 +1068,10 @@ GetHpcPciAddress (
 }\r
 \r
 /**\r
 }\r
 \r
 /**\r
-  Get HPC PCI address according to its device path\r
-  @param RootBridge           Root bridege Io instance\r
-  @param RemainingDevicePath  Given searching device path\r
-  @param PciAddress           Buffer holding searched result\r
+  Get HPC PCI address according to its device path.\r
+  @param RootBridge           Root bridege Io instance.\r
+  @param RemainingDevicePath  Given searching device path.\r
+  @param PciAddress           Buffer holding searched result.\r
   \r
   @retval EFI_NOT_FOUND Can not find the specific device path.\r
 **/\r
   \r
   @retval EFI_NOT_FOUND Can not find the specific device path.\r
 **/\r
@@ -1099,7 +1099,7 @@ GetHpcPciAddressFromRootBridge (
     CurrentLink   = RootBridge->ChildList.ForwardLink;\r
     Node.DevPath  = CurrentDevicePath;\r
 \r
     CurrentLink   = RootBridge->ChildList.ForwardLink;\r
     Node.DevPath  = CurrentDevicePath;\r
 \r
-    while (CurrentLink && CurrentLink != &RootBridge->ChildList) {\r
+    while (CurrentLink != NULL && CurrentLink != &RootBridge->ChildList) {\r
       Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
 \r
       if (Node.Pci->Device   == Temp->DeviceNumber &&\r
       Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
 \r
       if (Node.Pci->Device   == Temp->DeviceNumber &&\r
index 059077a89abf0b86b9fbbbe7ab43ff36a49f2c07..0ae7c2e3f6f410e1896282f748f0a38f96f3aa3f 100644 (file)
@@ -1,4 +1,4 @@
-/**@file\r
+/** @file\r
 \r
 Copyright (c) 2006, Intel Corporation                                                         \r
 All rights reserved. This program and the accompanying materials                          \r
 \r
 Copyright (c) 2006, Intel Corporation                                                         \r
 All rights reserved. This program and the accompanying materials                          \r
@@ -15,7 +15,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
 #define _EFI_PCI_DEVICE_SUPPORT_H\r
 \r
 /**\r
 #define _EFI_PCI_DEVICE_SUPPORT_H\r
 \r
 /**\r
-  Initialize the gPciDevicePool\r
+  Initialize the gPciDevicePool.\r
 **/\r
 EFI_STATUS\r
 InitializePciDevicePool (\r
 **/\r
 EFI_STATUS\r
 InitializePciDevicePool (\r
@@ -183,11 +183,11 @@ CreateRootBridge (
   );\r
 \r
 /**\r
   );\r
 \r
 /**\r
-  Get root bridge device instance by specific handle\r
+  Get root bridge device instance by specific handle.\r
 \r
 \r
-  @param RootBridgeHandle    Given root bridge handle\r
+  @param RootBridgeHandle    Given root bridge handle.\r
 \r
 \r
-  @return root bridge device instance\r
+  @return root bridge device instance.\r
 **/\r
 PCI_IO_DEVICE *\r
 GetRootBridgeByHandle (\r
 **/\r
 PCI_IO_DEVICE *\r
 GetRootBridgeByHandle (\r
@@ -200,12 +200,12 @@ RootBridgeExisted (
   );\r
 \r
 /**\r
   );\r
 \r
 /**\r
-  Judege whether Pci device existed\r
+  Judege whether Pci device existed.\r
   \r
   \r
-  @param Bridge       Parent bridege instance \r
-  @param PciIoDevice  Device instance\r
+  @param Bridge       Parent bridege instance. \r
+  @param PciIoDevice  Device instance.\r
   \r
   \r
-  @return whether Pci device existed\r
+  @return whether Pci device existed.\r
 **/\r
 BOOLEAN\r
 PciDeviceExisted (\r
 **/\r
 BOOLEAN\r
 PciDeviceExisted (\r
@@ -214,11 +214,11 @@ PciDeviceExisted (
   );\r
 \r
 /**\r
   );\r
 \r
 /**\r
-  Active VGA device\r
+  Active VGA device.\r
   \r
   \r
-  @param VgaDevice device instance for VGA\r
+  @param VgaDevice device instance for VGA.\r
   \r
   \r
-  @return device instance\r
+  @return device instance.\r
 **/\r
 PCI_IO_DEVICE *\r
 ActiveVGADeviceOnTheSameSegment (\r
 **/\r
 PCI_IO_DEVICE *\r
 ActiveVGADeviceOnTheSameSegment (\r
@@ -226,11 +226,11 @@ ActiveVGADeviceOnTheSameSegment (
   );\r
 \r
 /**\r
   );\r
 \r
 /**\r
-  Active VGA device on root bridge\r
+  Active VGA device on root bridge.\r
   \r
   \r
-  @param RootBridge  Root bridge device instance\r
+  @param RootBridge  Root bridge device instance.\r
   \r
   \r
-  @return VGA device instance\r
+  @return VGA device instance.\r
 **/\r
 PCI_IO_DEVICE *\r
 ActiveVGADeviceOnTheRootBridge (\r
 **/\r
 PCI_IO_DEVICE *\r
 ActiveVGADeviceOnTheRootBridge (\r
@@ -238,13 +238,13 @@ ActiveVGADeviceOnTheRootBridge (
   );\r
 \r
 /**\r
   );\r
 \r
 /**\r
-  Get HPC PCI address according to its device path\r
-  @param PciRootBridgeIo   Root bridege Io instance\r
-  @param HpcDevicePath     Given searching device path\r
-  @param PciAddress        Buffer holding searched result\r
+  Get HPC PCI address according to its device path.\r
+  @param PciRootBridgeIo   Root bridege Io instance.\r
+  @param HpcDevicePath     Given searching device path.\r
+  @param PciAddress        Buffer holding searched result.\r
   \r
   @retval EFI_NOT_FOUND Can not find the specific device path.\r
   \r
   @retval EFI_NOT_FOUND Can not find the specific device path.\r
-  @retval EFI_SUCCESS   Success to get the device path\r
+  @retval EFI_SUCCESS   Success to get the device path.\r
 **/\r
 EFI_STATUS\r
 GetHpcPciAddress (\r
 **/\r
 EFI_STATUS\r
 GetHpcPciAddress (\r
@@ -254,10 +254,10 @@ GetHpcPciAddress (
   );\r
 \r
 /**\r
   );\r
 \r
 /**\r
-  Get HPC PCI address according to its device path\r
-  @param RootBridge           Root bridege Io instance\r
-  @param RemainingDevicePath  Given searching device path\r
-  @param PciAddress           Buffer holding searched result\r
+  Get HPC PCI address according to its device path.\r
+  @param RootBridge           Root bridege Io instance.\r
+  @param RemainingDevicePath  Given searching device path.\r
+  @param PciAddress           Buffer holding searched result.\r
   \r
   @retval EFI_NOT_FOUND Can not find the specific device path.\r
 **/\r
   \r
   @retval EFI_NOT_FOUND Can not find the specific device path.\r
 **/\r
index 282f810aae37ff355b441a5c109f828f5c472f5c..b3456417e81aebca59d39202611056944f2623eb 100644 (file)
@@ -1,4 +1,4 @@
-/**@file\r
+/** @file\r
 \r
 Copyright (c) 2006, Intel Corporation                                                         \r
 All rights reserved. This program and the accompanying materials                          \r
 \r
 Copyright (c) 2006, Intel Corporation                                                         \r
 All rights reserved. This program and the accompanying materials                          \r
@@ -15,11 +15,11 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
 #include "PciBus.h"\r
 \r
 /**\r
 #include "PciBus.h"\r
 \r
 /**\r
-  Initializes a PCI Driver Override Instance\r
+  Initializes a PCI Driver Override Instance.\r
 \r
 \r
-  @param  PciIoDevice   Device instance\r
+  @param  PciIoDevice   Device instance.\r
 \r
 \r
-  @retval EFI_SUCCESS Operation success\r
+  @retval EFI_SUCCESS Operation success.\r
 **/\r
 EFI_STATUS\r
 InitializePciDriverOverrideInstance (\r
 **/\r
 EFI_STATUS\r
 InitializePciDriverOverrideInstance (\r
@@ -31,13 +31,13 @@ InitializePciDriverOverrideInstance (
 }\r
 \r
 /**\r
 }\r
 \r
 /**\r
-  Get a overriding driver image\r
-  @param  This                Pointer to instance of EFI_BUS_SPECIFIC_DRIVER_OVERRIDE_PROTOCOL\r
-  @param  DriverImageHandle   Override driver image,\r
+  Get a overriding driver image.\r
+  @param  This                Pointer to instance of EFI_BUS_SPECIFIC_DRIVER_OVERRIDE_PROTOCOL.\r
+  @param  DriverImageHandle   Override driver image.\r
   \r
   \r
-  @retval EFI_SUCCESS                 Success to get driver image handle\r
-  @retval EFI_NOT_FOUND               can not find override driver image\r
-  @retval EFI_INVALID_PARAMETER       Invalid parameter\r
+  @retval EFI_SUCCESS                 Success to get driver image handle.\r
+  @retval EFI_NOT_FOUND               can not find override driver image.\r
+  @retval EFI_INVALID_PARAMETER       Invalid parameter.\r
 **/\r
 EFI_STATUS\r
 EFIAPI\r
 **/\r
 EFI_STATUS\r
 EFIAPI\r
@@ -54,7 +54,7 @@ GetDriver (
 \r
   CurrentLink = PciIoDevice->OptionRomDriverList.ForwardLink;\r
 \r
 \r
   CurrentLink = PciIoDevice->OptionRomDriverList.ForwardLink;\r
 \r
-  while (CurrentLink && CurrentLink != &PciIoDevice->OptionRomDriverList) {\r
+  while (CurrentLink != NULL && CurrentLink != &PciIoDevice->OptionRomDriverList) {\r
 \r
     Node = DRIVER_OVERRIDE_FROM_LINK (CurrentLink);\r
 \r
 \r
     Node = DRIVER_OVERRIDE_FROM_LINK (CurrentLink);\r
 \r
index eaf7e49a08d8b786e8d5cbdc591ba4839b2eb8a0..edfb77f9c6922d3413235414276b73d11dc0bbd2 100644 (file)
@@ -1,4 +1,4 @@
-/**@file\r
+/** @file\r
 \r
 Copyright (c) 2006, Intel Corporation                                                         \r
 All rights reserved. This program and the accompanying materials                          \r
 \r
 Copyright (c) 2006, Intel Corporation                                                         \r
 All rights reserved. This program and the accompanying materials                          \r
@@ -28,11 +28,11 @@ typedef struct {
   CR (a, PCI_DRIVER_OVERRIDE_LIST, Link, DRIVER_OVERRIDE_SIGNATURE)\r
 \r
 /**\r
   CR (a, PCI_DRIVER_OVERRIDE_LIST, Link, DRIVER_OVERRIDE_SIGNATURE)\r
 \r
 /**\r
-  Initializes a PCI Driver Override Instance\r
+  Initializes a PCI Driver Override Instance.\r
 \r
 \r
-  @param  PciIoDevice   Device instance\r
+  @param  PciIoDevice   Device instance.\r
 \r
 \r
-  @retval EFI_SUCCESS Operation success\r
+  @retval EFI_SUCCESS Operation success.\r
 **/\r
 EFI_STATUS\r
 InitializePciDriverOverrideInstance (\r
 **/\r
 EFI_STATUS\r
 InitializePciDriverOverrideInstance (\r
@@ -40,13 +40,13 @@ InitializePciDriverOverrideInstance (
   );\r
 \r
 /**\r
   );\r
 \r
 /**\r
-  Add an overriding driver image\r
+  Add an overriding driver image.\r
   \r
   \r
-  @param PciIoDevice        Instance of PciIo device\r
-  @param DriverImageHandle  new added driver image\r
+  @param PciIoDevice        Instance of PciIo device.\r
+  @param DriverImageHandle  new added driver image.\r
   \r
   \r
-  @retval EFI_OUT_OF_RESOURCES no memory resource for new driver instance\r
-  @retval EFI_SUCCESS       Success add driver\r
+  @retval EFI_OUT_OF_RESOURCES no memory resource for new driver instance.\r
+  @retval EFI_SUCCESS       Success add driver.\r
 **/\r
 EFI_STATUS\r
 AddDriver (\r
 **/\r
 EFI_STATUS\r
 AddDriver (\r
@@ -56,13 +56,13 @@ AddDriver (
 \r
 \r
 /**\r
 \r
 \r
 /**\r
-  Get a overriding driver image\r
-  @param  This                Pointer to instance of EFI_BUS_SPECIFIC_DRIVER_OVERRIDE_PROTOCOL\r
-  @param  DriverImageHandle   Override driver image,\r
+  Get a overriding driver image.\r
+  @param  This                Pointer to instance of EFI_BUS_SPECIFIC_DRIVER_OVERRIDE_PROTOCOL.\r
+  @param  DriverImageHandle   Override driver image.\r
   \r
   \r
-  @retval EFI_SUCCESS                 Success to get driver image handle\r
-  @retval EFI_NOT_FOUND               can not find override driver image\r
-  @retval EFI_INVALID_PARAMETER       Invalid parameter\r
+  @retval EFI_SUCCESS                 Success to get driver image handle.\r
+  @retval EFI_NOT_FOUND               can not find override driver image.\r
+  @retval EFI_INVALID_PARAMETER       Invalid parameter.\r
 **/\r
 EFI_STATUS\r
 EFIAPI\r
 **/\r
 EFI_STATUS\r
 EFIAPI\r
index d6e37705a51888657fbeafa89beeda7981171e70..c2c4ef627655ad0d4d20ff561cbcd09fe2a59434 100644 (file)
@@ -1,4 +1,4 @@
-/**@file\r
+/** @file\r
 \r
 Copyright (c) 2006 - 2008, Intel Corporation                                                         \r
 All rights reserved. This program and the accompanying materials                          \r
 \r
 Copyright (c) 2006 - 2008, Intel Corporation                                                         \r
 All rights reserved. This program and the accompanying materials                          \r
@@ -19,11 +19,11 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
 \r
 /**\r
   This routine is used to enumerate entire pci bus system\r
 \r
 /**\r
   This routine is used to enumerate entire pci bus system\r
-  in a given platform\r
+  in a given platform.\r
 \r
 \r
-  @param Controller  Parent controller handle\r
+  @param Controller  Parent controller handle.\r
   \r
   \r
-  @return Status of enumerating\r
+  @return Status of enumerating.\r
 **/\r
 EFI_STATUS\r
 PciEnumerator (\r
 **/\r
 EFI_STATUS\r
 PciEnumerator (\r
@@ -128,11 +128,11 @@ PciEnumerator (
 /**\r
   Enumerate PCI root bridge\r
   \r
 /**\r
   Enumerate PCI root bridge\r
   \r
-  @param PciResAlloc   Pointer to protocol instance of EFI_PCI_HOST_BRIDGE_RESOURCE_ALLOCATION_PROTOCOL\r
-  @param RootBridgeDev Instance of root bridge device\r
+  @param PciResAlloc   Pointer to protocol instance of EFI_PCI_HOST_BRIDGE_RESOURCE_ALLOCATION_PROTOCOL.\r
+  @param RootBridgeDev Instance of root bridge device.\r
   \r
   \r
-  @retval EFI_SUCCESS  Success to enumerate root bridge\r
-  @retval Others       Fail to enumerate root bridge\r
+  @retval EFI_SUCCESS  Success to enumerate root bridge.\r
+  @retval Others       Fail to enumerate root bridge.\r
   \r
 **/\r
 EFI_STATUS\r
   \r
 **/\r
 EFI_STATUS\r
@@ -256,7 +256,7 @@ ProcessOptionRom (
   // Go through bridges to reach all devices\r
   //\r
   CurrentLink = Bridge->ChildList.ForwardLink;\r
   // Go through bridges to reach all devices\r
   //\r
   CurrentLink = Bridge->ChildList.ForwardLink;\r
-  while (CurrentLink && CurrentLink != &Bridge->ChildList) {\r
+  while (CurrentLink != NULL && CurrentLink != &Bridge->ChildList) {\r
     Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
     if (!IsListEmpty (&Temp->ChildList)) {\r
 \r
     Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
     if (!IsListEmpty (&Temp->ChildList)) {\r
 \r
@@ -283,11 +283,11 @@ ProcessOptionRom (
 /**\r
   This routine is used to assign bus number to the given PCI bus system\r
   \r
 /**\r
   This routine is used to assign bus number to the given PCI bus system\r
   \r
-  @param Bridge           Parent root bridge instance\r
-  @param StartBusNumber   Number of beginning\r
-  @param SubBusNumber     the number of sub bus\r
+  @param Bridge           Parent root bridge instance.\r
+  @param StartBusNumber   Number of beginning.\r
+  @param SubBusNumber     the number of sub bus.\r
   \r
   \r
-  @retval EFI_SUCCESS  Success to assign bus number\r
+  @retval EFI_SUCCESS  Success to assign bus number.\r
 **/\r
 EFI_STATUS\r
 PciAssignBusNumber (\r
 **/\r
 EFI_STATUS\r
 PciAssignBusNumber (\r
@@ -462,11 +462,11 @@ DetermineRootBridgeAttributes (
   // Currently we hardcoded for ea815\r
   //\r
 \r
   // Currently we hardcoded for ea815\r
   //\r
 \r
-  if (Attributes & EFI_PCI_HOST_BRIDGE_COMBINE_MEM_PMEM) {\r
+  if ((Attributes & EFI_PCI_HOST_BRIDGE_COMBINE_MEM_PMEM) != 0) {\r
     RootBridgeDev->Decodes |= EFI_BRIDGE_PMEM_MEM_COMBINE_SUPPORTED;\r
   }\r
 \r
     RootBridgeDev->Decodes |= EFI_BRIDGE_PMEM_MEM_COMBINE_SUPPORTED;\r
   }\r
 \r
-  if (Attributes & EFI_PCI_HOST_BRIDGE_MEM64_DECODE) {\r
+  if ((Attributes & EFI_PCI_HOST_BRIDGE_MEM64_DECODE) != 0) {\r
     RootBridgeDev->Decodes |= EFI_BRIDGE_PMEM64_DECODE_SUPPORTED;\r
   }\r
 \r
     RootBridgeDev->Decodes |= EFI_BRIDGE_PMEM64_DECODE_SUPPORTED;\r
   }\r
 \r
@@ -480,8 +480,8 @@ DetermineRootBridgeAttributes (
 /**\r
   Get Max Option Rom size on this bridge\r
   \r
 /**\r
   Get Max Option Rom size on this bridge\r
   \r
-  @param Bridge  Bridge device instance\r
-  @return Max size of option rom\r
+  @param Bridge  Bridge device instance.\r
+  @return Max size of option rom.\r
 **/\r
 UINT64\r
 GetMaxOptionRomSize (\r
 **/\r
 UINT64\r
 GetMaxOptionRomSize (\r
@@ -499,7 +499,7 @@ GetMaxOptionRomSize (
   // Go through bridges to reach all devices\r
   //\r
   CurrentLink = Bridge->ChildList.ForwardLink;\r
   // Go through bridges to reach all devices\r
   //\r
   CurrentLink = Bridge->ChildList.ForwardLink;\r
-  while (CurrentLink && CurrentLink != &Bridge->ChildList) {\r
+  while (CurrentLink != NULL && CurrentLink != &Bridge->ChildList) {\r
     Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
     if (!IsListEmpty (&Temp->ChildList)) {\r
 \r
     Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
     if (!IsListEmpty (&Temp->ChildList)) {\r
 \r
@@ -540,11 +540,11 @@ GetMaxOptionRomSize (
 /**\r
   Process attributes of devices on this host bridge\r
   \r
 /**\r
   Process attributes of devices on this host bridge\r
   \r
-  @param PciResAlloc Protocol instance of EFI_PCI_HOST_BRIDGE_RESOURCE_ALLOCATION_PROTOCOL\r
+  @param PciResAlloc Protocol instance of EFI_PCI_HOST_BRIDGE_RESOURCE_ALLOCATION_PROTOCOL.\r
   \r
   \r
-  @retval EFI_NOT_FOUND Can not find the specific root bridge device\r
-  @retval EFI_SUCCESS   Success Process attribute\r
-  @retval Others        Can not determine the root bridge device's attribute\r
+  @retval EFI_NOT_FOUND Can not find the specific root bridge device.\r
+  @retval EFI_SUCCESS   Success Process attribute.\r
+  @retval Others        Can not determine the root bridge device's attribute.\r
 **/\r
 EFI_STATUS\r
 PciHostBridgeDeviceAttribute (\r
 **/\r
 EFI_STATUS\r
 PciHostBridgeDeviceAttribute (\r
@@ -667,10 +667,10 @@ GetResourceAllocationStatus (
 /**\r
   Remove a PCI device from device pool and mark its bar\r
   \r
 /**\r
   Remove a PCI device from device pool and mark its bar\r
   \r
-  @param PciDevice Instance of Pci device\r
+  @param PciDevice Instance of Pci device.\r
   \r
   \r
-  @retval EFI_SUCCESS Success Operation\r
-  @retval EFI_ABORTED Pci device is a root bridge\r
+  @retval EFI_SUCCESS Success Operation.\r
+  @retval EFI_ABORTED Pci device is a root bridge.\r
 **/\r
 EFI_STATUS\r
 RejectPciDevice (\r
 **/\r
 EFI_STATUS\r
 RejectPciDevice (\r
@@ -685,7 +685,7 @@ RejectPciDevice (
   // Remove the padding resource from a bridge\r
   //\r
   if ( IS_PCI_BRIDGE(&PciDevice->Pci) && \\r
   // Remove the padding resource from a bridge\r
   //\r
   if ( IS_PCI_BRIDGE(&PciDevice->Pci) && \\r
-       PciDevice->ResourcePaddingDescriptors ) {\r
+       PciDevice->ResourcePaddingDescriptors != NULL ) {\r
     gBS->FreePool (PciDevice->ResourcePaddingDescriptors);\r
     PciDevice->ResourcePaddingDescriptors = NULL;\r
     return EFI_SUCCESS;\r
     gBS->FreePool (PciDevice->ResourcePaddingDescriptors);\r
     PciDevice->ResourcePaddingDescriptors = NULL;\r
     return EFI_SUCCESS;\r
@@ -694,7 +694,7 @@ RejectPciDevice (
   //\r
   // Skip RB and PPB\r
   //\r
   //\r
   // Skip RB and PPB\r
   //\r
-  if (IS_PCI_BRIDGE (&PciDevice->Pci) || (!PciDevice->Parent)) {\r
+  if (IS_PCI_BRIDGE (&PciDevice->Pci) || (PciDevice->Parent == NULL)) {\r
     return EFI_ABORTED;\r
   }\r
 \r
     return EFI_ABORTED;\r
   }\r
 \r
@@ -703,7 +703,7 @@ RejectPciDevice (
     // Get the root bridge device\r
     //\r
     Bridge = PciDevice;\r
     // Get the root bridge device\r
     //\r
     Bridge = PciDevice;\r
-    while (Bridge->Parent) {\r
+    while (Bridge->Parent != NULL) {\r
       Bridge = Bridge->Parent;\r
     }\r
 \r
       Bridge = Bridge->Parent;\r
     }\r
 \r
@@ -720,7 +720,7 @@ RejectPciDevice (
   //\r
   Bridge      = PciDevice->Parent;\r
   CurrentLink = Bridge->ChildList.ForwardLink;\r
   //\r
   Bridge      = PciDevice->Parent;\r
   CurrentLink = Bridge->ChildList.ForwardLink;\r
-  while (CurrentLink && CurrentLink != &Bridge->ChildList) {\r
+  while (CurrentLink != NULL && CurrentLink != &Bridge->ChildList) {\r
     Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
     if (Temp == PciDevice) {\r
       InitializePciDevice (Temp);\r
     Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
     if (Temp == PciDevice) {\r
       InitializePciDevice (Temp);\r
@@ -736,11 +736,11 @@ RejectPciDevice (
 }\r
 \r
 /**\r
 }\r
 \r
 /**\r
-  Determine whethter a PCI device can be rejected\r
+  Determine whethter a PCI device can be rejected.\r
   \r
   \r
-  @param PciResNode Pointer to Pci resource node instance \r
+  @param PciResNode Pointer to Pci resource node instance.\r
   \r
   \r
-  @return whethter a PCI device can be rejected\r
+  @return whethter a PCI device can be rejected.\r
 **/\r
 BOOLEAN\r
 IsRejectiveDevice (\r
 **/\r
 BOOLEAN\r
 IsRejectiveDevice (\r
@@ -754,21 +754,21 @@ IsRejectiveDevice (
   //\r
   // Ensure the device is present\r
   //\r
   //\r
   // Ensure the device is present\r
   //\r
-  if (!Temp) {\r
+  if (Temp == NULL) {\r
     return FALSE;\r
   }\r
 \r
   //\r
   // PPB and RB should go ahead\r
   //\r
     return FALSE;\r
   }\r
 \r
   //\r
   // PPB and RB should go ahead\r
   //\r
-  if (IS_PCI_BRIDGE (&Temp->Pci) || (!Temp->Parent)) {\r
+  if (IS_PCI_BRIDGE (&Temp->Pci) || (Temp->Parent == NULL)) {\r
     return TRUE;\r
   }\r
 \r
   //\r
   // Skip device on Bus0\r
   //\r
     return TRUE;\r
   }\r
 \r
   //\r
   // Skip device on Bus0\r
   //\r
-  if ((Temp->Parent) && (Temp->BusNumber == 0)) {\r
+  if ((Temp->Parent != NULL) && (Temp->BusNumber == 0)) {\r
     return FALSE;\r
   }\r
 \r
     return FALSE;\r
   }\r
 \r
@@ -796,17 +796,17 @@ GetLargerConsumerDevice (
   IN  PCI_RESOURCE_NODE   *PciResNode2\r
   )\r
 {\r
   IN  PCI_RESOURCE_NODE   *PciResNode2\r
   )\r
 {\r
-  if (!PciResNode2) {\r
+  if (PciResNode2 == NULL) {\r
     return PciResNode1;\r
   }\r
 \r
     return PciResNode1;\r
   }\r
 \r
-  if ((IS_PCI_BRIDGE(&(PciResNode2->PciDev->Pci)) || !(PciResNode2->PciDev->Parent)) \\r
+  if ((IS_PCI_BRIDGE(&(PciResNode2->PciDev->Pci)) || (PciResNode2->PciDev->Parent == NULL)) \\r
        && (PciResNode2->ResourceUsage != PciResUsagePadding) )\r
   {\r
     return PciResNode1;\r
   }\r
 \r
        && (PciResNode2->ResourceUsage != PciResUsagePadding) )\r
   {\r
     return PciResNode1;\r
   }\r
 \r
-  if (!PciResNode1) {\r
+  if (PciResNode1 == NULL) {\r
     return PciResNode2;\r
   }\r
 \r
     return PciResNode2;\r
   }\r
 \r
@@ -820,11 +820,11 @@ GetLargerConsumerDevice (
 \r
 \r
 /**\r
 \r
 \r
 /**\r
-  Get the max resource consumer in the host resource pool\r
+  Get the max resource consumer in the host resource pool.\r
   \r
   \r
-  @param ResPool  Pointer to resource pool node\r
+  @param ResPool  Pointer to resource pool node.\r
   \r
   \r
-  @return the max resource consumer in the host resource pool\r
+  @return the max resource consumer in the host resource pool.\r
 **/\r
 PCI_RESOURCE_NODE *\r
 GetMaxResourceConsumerDevice (\r
 **/\r
 PCI_RESOURCE_NODE *\r
 GetMaxResourceConsumerDevice (\r
@@ -839,7 +839,7 @@ GetMaxResourceConsumerDevice (
   PciResNode  = NULL;\r
 \r
   CurrentLink = ResPool->ChildList.ForwardLink;\r
   PciResNode  = NULL;\r
 \r
   CurrentLink = ResPool->ChildList.ForwardLink;\r
-  while (CurrentLink && CurrentLink != &ResPool->ChildList) {\r
+  while (CurrentLink != NULL && CurrentLink != &ResPool->ChildList) {\r
 \r
     Temp = RESOURCE_NODE_FROM_LINK (CurrentLink);\r
 \r
 \r
     Temp = RESOURCE_NODE_FROM_LINK (CurrentLink);\r
 \r
@@ -848,7 +848,7 @@ GetMaxResourceConsumerDevice (
       continue;\r
     }\r
 \r
       continue;\r
     }\r
 \r
-    if ((IS_PCI_BRIDGE (&(Temp->PciDev->Pci)) || (!Temp->PciDev->Parent)) \\r
+    if ((IS_PCI_BRIDGE (&(Temp->PciDev->Pci)) || (Temp->PciDev->Parent == NULL)) \\r
           && (Temp->ResourceUsage != PciResUsagePadding))\r
     {\r
       PPBResNode  = GetMaxResourceConsumerDevice (Temp);\r
           && (Temp->ResourceUsage != PciResUsagePadding))\r
     {\r
       PPBResNode  = GetMaxResourceConsumerDevice (Temp);\r
@@ -866,16 +866,16 @@ GetMaxResourceConsumerDevice (
 /**\r
   Adjust host bridge allocation so as to reduce resource requirement\r
   \r
 /**\r
   Adjust host bridge allocation so as to reduce resource requirement\r
   \r
-  @param IoPool           Pointer to instance of I/O resource Node\r
-  @param Mem32Pool        Pointer to instance of 32-bit memory resource Node\r
-  @param PMem32Pool       Pointer to instance of 32-bit Pmemory resource node\r
-  @param Mem64Pool        Pointer to instance of 64-bit memory resource node\r
-  @param PMem64Pool       Pointer to instance of 64-bit Pmemory resource node\r
-  @param IoResStatus      Status of I/O resource Node\r
-  @param Mem32ResStatus   Status of 32-bit memory resource Node\r
-  @param PMem32ResStatus  Status of 32-bit Pmemory resource node\r
-  @param Mem64ResStatus   Status of 64-bit memory resource node\r
-  @param PMem64ResStatus  Status of 64-bit Pmemory resource node\r
+  @param IoPool           Pointer to instance of I/O resource Node.\r
+  @param Mem32Pool        Pointer to instance of 32-bit memory resource Node.\r
+  @param PMem32Pool       Pointer to instance of 32-bit Pmemory resource node.\r
+  @param Mem64Pool        Pointer to instance of 64-bit memory resource node.\r
+  @param PMem64Pool       Pointer to instance of 64-bit Pmemory resource node.\r
+  @param IoResStatus      Status of I/O resource Node.\r
+  @param Mem32ResStatus   Status of 32-bit memory resource Node.\r
+  @param PMem32ResStatus  Status of 32-bit Pmemory resource node.\r
+  @param Mem64ResStatus   Status of 64-bit memory resource node.\r
+  @param PMem64ResStatus  Status of 64-bit Pmemory resource node.\r
 **/\r
 EFI_STATUS\r
 PciHostBridgeAdjustAllocation (\r
 **/\r
 EFI_STATUS\r
 PciHostBridgeAdjustAllocation (\r
@@ -937,7 +937,7 @@ PciHostBridgeAdjustAllocation (
     // Hostbridge hasn't enough resource\r
     //\r
     PciResNode = GetMaxResourceConsumerDevice (ResPool[ResType]);\r
     // Hostbridge hasn't enough resource\r
     //\r
     PciResNode = GetMaxResourceConsumerDevice (ResPool[ResType]);\r
-    if (!PciResNode) {\r
+    if (PciResNode == NULL) {\r
       continue;\r
     }\r
 \r
       continue;\r
     }\r
 \r
@@ -1091,7 +1091,7 @@ ConstructAcpiResourceRequestor (
     //\r
     // Deal with io aperture\r
     //\r
     //\r
     // Deal with io aperture\r
     //\r
-    if (Aperture & 0x01) {\r
+    if ((Aperture & 0x01) != 0) {\r
       Ptr->Desc     = ACPI_ADDRESS_SPACE_DESCRIPTOR;\r
       Ptr->Len      = sizeof (EFI_ACPI_ADDRESS_SPACE_DESCRIPTOR) - 3;\r
       //\r
       Ptr->Desc     = ACPI_ADDRESS_SPACE_DESCRIPTOR;\r
       Ptr->Len      = sizeof (EFI_ACPI_ADDRESS_SPACE_DESCRIPTOR) - 3;\r
       //\r
@@ -1110,7 +1110,7 @@ ConstructAcpiResourceRequestor (
     //\r
     // Deal with mem32 aperture\r
     //\r
     //\r
     // Deal with mem32 aperture\r
     //\r
-    if (Aperture & 0x02) {\r
+    if ((Aperture & 0x02) != 0) {\r
       Ptr->Desc     = ACPI_ADDRESS_SPACE_DESCRIPTOR;\r
       Ptr->Len      = sizeof (EFI_ACPI_ADDRESS_SPACE_DESCRIPTOR) - 3;\r
       //\r
       Ptr->Desc     = ACPI_ADDRESS_SPACE_DESCRIPTOR;\r
       Ptr->Len      = sizeof (EFI_ACPI_ADDRESS_SPACE_DESCRIPTOR) - 3;\r
       //\r
@@ -1134,7 +1134,7 @@ ConstructAcpiResourceRequestor (
     //\r
     // Deal with Pmem32 aperture\r
     //\r
     //\r
     // Deal with Pmem32 aperture\r
     //\r
-    if (Aperture & 0x04) {\r
+    if ((Aperture & 0x04) != 0) {\r
       Ptr->Desc     = ACPI_ADDRESS_SPACE_DESCRIPTOR;\r
       Ptr->Len      = sizeof (EFI_ACPI_ADDRESS_SPACE_DESCRIPTOR) - 3;\r
       //\r
       Ptr->Desc     = ACPI_ADDRESS_SPACE_DESCRIPTOR;\r
       Ptr->Len      = sizeof (EFI_ACPI_ADDRESS_SPACE_DESCRIPTOR) - 3;\r
       //\r
@@ -1157,7 +1157,7 @@ ConstructAcpiResourceRequestor (
     //\r
     // Deal with mem64 aperture\r
     //\r
     //\r
     // Deal with mem64 aperture\r
     //\r
-    if (Aperture & 0x08) {\r
+    if ((Aperture & 0x08) != 0) {\r
       Ptr->Desc     = ACPI_ADDRESS_SPACE_DESCRIPTOR;\r
       Ptr->Len      = sizeof (EFI_ACPI_ADDRESS_SPACE_DESCRIPTOR) - 3;\r
       //\r
       Ptr->Desc     = ACPI_ADDRESS_SPACE_DESCRIPTOR;\r
       Ptr->Len      = sizeof (EFI_ACPI_ADDRESS_SPACE_DESCRIPTOR) - 3;\r
       //\r
@@ -1180,7 +1180,7 @@ ConstructAcpiResourceRequestor (
     //\r
     // Deal with Pmem64 aperture\r
     //\r
     //\r
     // Deal with Pmem64 aperture\r
     //\r
-    if (Aperture & 0x10) {\r
+    if ((Aperture & 0x10) != 0) {\r
       Ptr->Desc     = ACPI_ADDRESS_SPACE_DESCRIPTOR;\r
       Ptr->Len      = sizeof (EFI_ACPI_ADDRESS_SPACE_DESCRIPTOR) - 3;\r
       //\r
       Ptr->Desc     = ACPI_ADDRESS_SPACE_DESCRIPTOR;\r
       Ptr->Len      = sizeof (EFI_ACPI_ADDRESS_SPACE_DESCRIPTOR) - 3;\r
       //\r
@@ -1238,13 +1238,13 @@ ConstructAcpiResourceRequestor (
   Get resource base from a acpi configuration descriptor.\r
   \r
   @param pConfig      an acpi configuration descriptor.\r
   Get resource base from a acpi configuration descriptor.\r
   \r
   @param pConfig      an acpi configuration descriptor.\r
-  @param IoBase       output of I/O resource base address\r
-  @param Mem32Base    output of 32-bit memory base address\r
-  @param PMem32Base   output of 32-bit pmemory base address\r
-  @param Mem64Base    output of 64-bit memory base address\r
-  @param PMem64Base   output of 64-bit pmemory base address\r
+  @param IoBase       output of I/O resource base address.\r
+  @param Mem32Base    output of 32-bit memory base address.\r
+  @param PMem32Base   output of 32-bit pmemory base address.\r
+  @param Mem64Base    output of 64-bit memory base address.\r
+  @param PMem64Base   output of 64-bit pmemory base address.\r
   \r
   \r
-  @return EFI_SUCCESS  Success operation\r
+  @return EFI_SUCCESS  Success operation.\r
 **/\r
 EFI_STATUS\r
 GetResourceBase (\r
 **/\r
 EFI_STATUS\r
 GetResourceBase (\r
@@ -1331,10 +1331,10 @@ GetResourceBase (
   Enumerate pci bridge, allocate resource and determine attribute\r
   for devices on this bridge\r
   \r
   Enumerate pci bridge, allocate resource and determine attribute\r
   for devices on this bridge\r
   \r
-  @param BridgeDev Pointer to instance of bridge device\r
+  @param BridgeDev Pointer to instance of bridge device.\r
   \r
   \r
-  @retval EFI_SUCCESS Success operation\r
-  @retval Others      Fail to enumerate\r
+  @retval EFI_SUCCESS Success operation.\r
+  @retval Others      Fail to enumerate.\r
 **/\r
 EFI_STATUS\r
 PciBridgeEnumerator (\r
 **/\r
 EFI_STATUS\r
 PciBridgeEnumerator (\r
@@ -1390,10 +1390,10 @@ PciBridgeEnumerator (
 /**\r
   Allocate all kinds of resource for bridge\r
   \r
 /**\r
   Allocate all kinds of resource for bridge\r
   \r
-  @param Bridge      Pointer to bridge instance\r
+  @param Bridge      Pointer to bridge instance.\r
   \r
   @retval EFI_SUCCESS Success operation.\r
   \r
   @retval EFI_SUCCESS Success operation.\r
-  @retval Others      Fail to allocate resource for bridge\r
+  @retval Others      Fail to allocate resource for bridge.\r
 **/\r
 EFI_STATUS\r
 PciBridgeResourceAllocator (\r
 **/\r
 EFI_STATUS\r
 PciBridgeResourceAllocator (\r
@@ -1544,14 +1544,14 @@ PciBridgeResourceAllocator (
 /**\r
   Get resource base address for a pci bridge device\r
   \r
 /**\r
   Get resource base address for a pci bridge device\r
   \r
-  @param Bridge  Given Pci driver instance\r
-  @param IoBase  output for base address of I/O type resource\r
-  @param Mem32Base  output for base address of 32-bit memory type resource\r
-  @param PMem32Base  output for base address of 32-bit Pmemory type resource\r
-  @param Mem64Base  output for base address of 64-bit memory type resource\r
-  @param PMem64Base  output for base address of 64-bit Pmemory type resource\r
+  @param Bridge  Given Pci driver instance.\r
+  @param IoBase  output for base address of I/O type resource.\r
+  @param Mem32Base  output for base address of 32-bit memory type resource.\r
+  @param PMem32Base  output for base address of 32-bit Pmemory type resource.\r
+  @param Mem64Base  output for base address of 64-bit memory type resource.\r
+  @param PMem64Base  output for base address of 64-bit Pmemory type resource.\r
   \r
   \r
-  @retval EFI_SUCCESS Succes to get resource base address\r
+  @retval EFI_SUCCESS Succes to get resource base address.\r
 **/\r
 EFI_STATUS\r
 GetResourceBaseFromBridge (\r
 **/\r
 EFI_STATUS\r
 GetResourceBaseFromBridge (\r
@@ -1575,19 +1575,19 @@ GetResourceBaseFromBridge (
 \r
   if (IS_PCI_BRIDGE (&Bridge->Pci)) {\r
 \r
 \r
   if (IS_PCI_BRIDGE (&Bridge->Pci)) {\r
 \r
-    if (Bridge->PciBar[PPB_IO_RANGE].Length) {\r
+    if (Bridge->PciBar[PPB_IO_RANGE].Length > 0) {\r
       *IoBase = Bridge->PciBar[PPB_IO_RANGE].BaseAddress;\r
     }\r
 \r
       *IoBase = Bridge->PciBar[PPB_IO_RANGE].BaseAddress;\r
     }\r
 \r
-    if (Bridge->PciBar[PPB_MEM32_RANGE].Length) {\r
+    if (Bridge->PciBar[PPB_MEM32_RANGE].Length > 0) {\r
       *Mem32Base = Bridge->PciBar[PPB_MEM32_RANGE].BaseAddress;\r
     }\r
 \r
       *Mem32Base = Bridge->PciBar[PPB_MEM32_RANGE].BaseAddress;\r
     }\r
 \r
-    if (Bridge->PciBar[PPB_PMEM32_RANGE].Length) {\r
+    if (Bridge->PciBar[PPB_PMEM32_RANGE].Length > 0) {\r
       *PMem32Base = Bridge->PciBar[PPB_PMEM32_RANGE].BaseAddress;\r
     }\r
 \r
       *PMem32Base = Bridge->PciBar[PPB_PMEM32_RANGE].BaseAddress;\r
     }\r
 \r
-    if (Bridge->PciBar[PPB_PMEM64_RANGE].Length) {\r
+    if (Bridge->PciBar[PPB_PMEM64_RANGE].Length > 0) {\r
       *PMem64Base = Bridge->PciBar[PPB_PMEM64_RANGE].BaseAddress;\r
     } else {\r
       *PMem64Base = gAllOne;\r
       *PMem64Base = Bridge->PciBar[PPB_PMEM64_RANGE].BaseAddress;\r
     } else {\r
       *PMem64Base = gAllOne;\r
@@ -1596,15 +1596,15 @@ GetResourceBaseFromBridge (
   }\r
 \r
   if (IS_CARDBUS_BRIDGE (&Bridge->Pci)) {\r
   }\r
 \r
   if (IS_CARDBUS_BRIDGE (&Bridge->Pci)) {\r
-    if (Bridge->PciBar[P2C_IO_1].Length) {\r
+    if (Bridge->PciBar[P2C_IO_1].Length > 0) {\r
       *IoBase = Bridge->PciBar[P2C_IO_1].BaseAddress;\r
     } else {\r
       *IoBase = Bridge->PciBar[P2C_IO_1].BaseAddress;\r
     } else {\r
-      if (Bridge->PciBar[P2C_IO_2].Length) {\r
+      if (Bridge->PciBar[P2C_IO_2].Length > 0) {\r
         *IoBase = Bridge->PciBar[P2C_IO_2].BaseAddress;\r
       }\r
     }\r
 \r
         *IoBase = Bridge->PciBar[P2C_IO_2].BaseAddress;\r
       }\r
     }\r
 \r
-    if (Bridge->PciBar[P2C_MEM_1].Length) {\r
+    if (Bridge->PciBar[P2C_MEM_1].Length > 0) {\r
       if (Bridge->PciBar[P2C_MEM_1].BarType == PciBarTypePMem32) {\r
         *PMem32Base = Bridge->PciBar[P2C_MEM_1].BaseAddress;\r
       }\r
       if (Bridge->PciBar[P2C_MEM_1].BarType == PciBarTypePMem32) {\r
         *PMem32Base = Bridge->PciBar[P2C_MEM_1].BaseAddress;\r
       }\r
@@ -1614,7 +1614,7 @@ GetResourceBaseFromBridge (
       }\r
     }\r
 \r
       }\r
     }\r
 \r
-    if (Bridge->PciBar[P2C_MEM_2].Length) {\r
+    if (Bridge->PciBar[P2C_MEM_2].Length > 0) {\r
       if (Bridge->PciBar[P2C_MEM_2].BarType == PciBarTypePMem32) {\r
         *PMem32Base = Bridge->PciBar[P2C_MEM_2].BaseAddress;\r
       }\r
       if (Bridge->PciBar[P2C_MEM_2].BarType == PciBarTypePMem32) {\r
         *PMem32Base = Bridge->PciBar[P2C_MEM_2].BaseAddress;\r
       }\r
@@ -1673,7 +1673,7 @@ GetResourceBaseFromBridge (
                                           required here. This notification can be used to perform any chipsetspecific\r
                                           programming.\r
       \r
                                           required here. This notification can be used to perform any chipsetspecific\r
                                           programming.\r
       \r
-   @param[in] This                The instance pointer of EFI_PCI_HOST_BRIDGE_RESOURCE_ALLOCATION_PROTOCOL\r
+   @param[in] PciResAlloc         The instance pointer of EFI_PCI_HOST_BRIDGE_RESOURCE_ALLOCATION_PROTOCOL\r
    @param[in] Phase               The phase during enumeration\r
    \r
    @retval EFI_NOT_READY          This phase cannot be entered at this time. For example, this error\r
    @param[in] Phase               The phase during enumeration\r
    \r
    @retval EFI_NOT_READY          This phase cannot be entered at this time. For example, this error\r
@@ -1822,7 +1822,7 @@ PreprocessController (
   //\r
   // Get Root Brige Handle\r
   //\r
   //\r
   // Get Root Brige Handle\r
   //\r
-  while (Bridge->Parent) {\r
+  while (Bridge->Parent != NULL) {\r
     Bridge = Bridge->Parent;\r
   }\r
 \r
     Bridge = Bridge->Parent;\r
   }\r
 \r
@@ -1882,8 +1882,8 @@ PreprocessController (
   @param NumberOfChildren     - A the number of child handle in the ChildHandleBuffer.\r
   @param ChildHandleBuffer    - A pointer to the array contain the child handle.\r
   \r
   @param NumberOfChildren     - A the number of child handle in the ChildHandleBuffer.\r
   @param ChildHandleBuffer    - A pointer to the array contain the child handle.\r
   \r
-  @retval EFI_NOT_FOUND Can not find bridge according to controller handle\r
-  @retval EFI_SUCCESS   Success operating\r
+  @retval EFI_NOT_FOUND Can not find bridge according to controller handle.\r
+  @retval EFI_SUCCESS   Success operating.\r
 **/\r
 EFI_STATUS\r
 EFIAPI\r
 **/\r
 EFI_STATUS\r
 EFIAPI\r
@@ -1922,7 +1922,7 @@ PciHotPlugRequestNotify (
   // Get root bridge handle\r
   //\r
   Temp = Bridge;\r
   // Get root bridge handle\r
   //\r
   Temp = Bridge;\r
-  while (Temp->Parent) {\r
+  while (Temp->Parent != NULL) {\r
     Temp = Temp->Parent;\r
   }\r
 \r
     Temp = Temp->Parent;\r
   }\r
 \r
@@ -2029,7 +2029,7 @@ SearchHostBridgeHandle (
 /**\r
   Add host bridge handle to global variable for enumating.\r
   \r
 /**\r
   Add host bridge handle to global variable for enumating.\r
   \r
-  @param HostBridgeHandle host bridge handle\r
+  @param HostBridgeHandle host bridge handle.\r
 **/\r
 EFI_STATUS\r
 AddHostBridgeEnumerator (\r
 **/\r
 EFI_STATUS\r
 AddHostBridgeEnumerator (\r
@@ -2038,7 +2038,7 @@ AddHostBridgeEnumerator (
 {\r
   UINTN Index;\r
 \r
 {\r
   UINTN Index;\r
 \r
-  if (!HostBridgeHandle) {\r
+  if (HostBridgeHandle == NULL) {\r
     return EFI_ABORTED;\r
   }\r
 \r
     return EFI_ABORTED;\r
   }\r
 \r
index e1f2a22b30327233a2e3137cd158d8dcfb759638..b20d8f2343f548633b9ba08f40422632db11403c 100644 (file)
@@ -1,4 +1,4 @@
-/**@file\r
+/** @file\r
   Header file declares all logic function for PCI bus enumeration.\r
   \r
 Copyright (c) 2006, Intel Corporation                                                         \r
   Header file declares all logic function for PCI bus enumeration.\r
   \r
 Copyright (c) 2006, Intel Corporation                                                         \r
@@ -22,9 +22,9 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
   This routine is used to enumerate entire pci bus system\r
   in a given platform\r
 \r
   This routine is used to enumerate entire pci bus system\r
   in a given platform\r
 \r
-  @param Controller  Parent controller handle\r
+  @param Controller  Parent controller handle.\r
   \r
   \r
-  @return Status of enumerating\r
+  @return Status of enumerating.\r
 **/\r
 EFI_STATUS\r
 PciEnumerator (\r
 **/\r
 EFI_STATUS\r
 PciEnumerator (\r
@@ -35,10 +35,10 @@ PciEnumerator (
   Enumerate PCI root bridge\r
   \r
   @param PciResAlloc   Pointer to protocol instance of EFI_PCI_HOST_BRIDGE_RESOURCE_ALLOCATION_PROTOCOL\r
   Enumerate PCI root bridge\r
   \r
   @param PciResAlloc   Pointer to protocol instance of EFI_PCI_HOST_BRIDGE_RESOURCE_ALLOCATION_PROTOCOL\r
-  @param RootBridgeDev Instance of root bridge device\r
+  @param RootBridgeDev Instance of root bridge device.\r
   \r
   \r
-  @retval EFI_SUCCESS  Success to enumerate root bridge\r
-  @retval Others       Fail to enumerate root bridge\r
+  @retval EFI_SUCCESS  Success to enumerate root bridge.\r
+  @retval Others       Fail to enumerate root bridge.\r
   \r
 **/\r
 EFI_STATUS\r
   \r
 **/\r
 EFI_STATUS\r
@@ -50,9 +50,9 @@ PciRootBridgeEnumerator (
 /**\r
   This routine is used to process option rom on a certain root bridge\r
   \r
 /**\r
   This routine is used to process option rom on a certain root bridge\r
   \r
-  @param Bridge     Given parent's root bridge\r
-  @param RomBase    Base address of ROM driver loaded from\r
-  @param MaxLength  Max rom size\r
+  @param Bridge     Given parent's root bridge.\r
+  @param RomBase    Base address of ROM driver loaded from.\r
+  @param MaxLength  Max rom size.\r
   \r
   @retval EFI_SUCCESS Success to process option rom image.\r
 **/\r
   \r
   @retval EFI_SUCCESS Success to process option rom image.\r
 **/\r
@@ -66,11 +66,11 @@ ProcessOptionRom (
 /**\r
   This routine is used to assign bus number to the given PCI bus system\r
   \r
 /**\r
   This routine is used to assign bus number to the given PCI bus system\r
   \r
-  @param Bridge           Parent root bridge instance\r
-  @param StartBusNumber   Number of beginning\r
-  @param SubBusNumber     the number of sub bus\r
+  @param Bridge           Parent root bridge instance.\r
+  @param StartBusNumber   Number of beginning.\r
+  @param SubBusNumber     the number of sub bus.\r
   \r
   \r
-  @retval EFI_SUCCESS  Success to assign bus number\r
+  @retval EFI_SUCCESS  Success to assign bus number.\r
 **/\r
 EFI_STATUS\r
 PciAssignBusNumber (\r
 **/\r
 EFI_STATUS\r
 PciAssignBusNumber (\r
@@ -83,11 +83,11 @@ PciAssignBusNumber (
   This routine is used to determine the root bridge attribute by interfacing\r
   the host bridge resource allocation protocol.\r
 \r
   This routine is used to determine the root bridge attribute by interfacing\r
   the host bridge resource allocation protocol.\r
 \r
-  @param PciResAlloc    Protocol instance of EFI_PCI_HOST_BRIDGE_RESOURCE_ALLOCATION_PROTOCOL\r
-  @param RootBridgeDev  Root bridge instance\r
+  @param PciResAlloc    Protocol instance of EFI_PCI_HOST_BRIDGE_RESOURCE_ALLOCATION_PROTOCOL.\r
+  @param RootBridgeDev  Root bridge instance.\r
   \r
   \r
-  @retval EFI_SUCCESS  Success to get root bridge's attribute\r
-  @retval Others       Fail to get attribute\r
+  @retval EFI_SUCCESS  Success to get root bridge's attribute.\r
+  @retval Others       Fail to get attribute.\r
 **/\r
 EFI_STATUS\r
 DetermineRootBridgeAttributes (\r
 **/\r
 EFI_STATUS\r
 DetermineRootBridgeAttributes (\r
@@ -98,8 +98,8 @@ DetermineRootBridgeAttributes (
 /**\r
   Get Max Option Rom size on this bridge\r
   \r
 /**\r
   Get Max Option Rom size on this bridge\r
   \r
-  @param Bridge  Bridge device instance\r
-  @return Max size of option rom\r
+  @param Bridge  Bridge device instance.\r
+  @return Max size of option rom.\r
 **/\r
 UINT64\r
 GetMaxOptionRomSize (\r
 **/\r
 UINT64\r
 GetMaxOptionRomSize (\r
@@ -111,9 +111,9 @@ GetMaxOptionRomSize (
   \r
   @param PciResAlloc Protocol instance of EFI_PCI_HOST_BRIDGE_RESOURCE_ALLOCATION_PROTOCOL\r
   \r
   \r
   @param PciResAlloc Protocol instance of EFI_PCI_HOST_BRIDGE_RESOURCE_ALLOCATION_PROTOCOL\r
   \r
-  @retval EFI_NOT_FOUND Can not find the specific root bridge device\r
-  @retval EFI_SUCCESS   Success Process attribute\r
-  @retval Others        Can not determine the root bridge device's attribute\r
+  @retval EFI_NOT_FOUND Can not find the specific root bridge device.\r
+  @retval EFI_SUCCESS   Success Process attribute.\r
+  @retval Others        Can not determine the root bridge device's attribute.\r
 **/\r
 EFI_STATUS\r
 PciHostBridgeDeviceAttribute (\r
 **/\r
 EFI_STATUS\r
 PciHostBridgeDeviceAttribute (\r
@@ -123,12 +123,12 @@ PciHostBridgeDeviceAttribute (
 /**\r
   Get resource allocation status from the ACPI pointer\r
 \r
 /**\r
   Get resource allocation status from the ACPI pointer\r
 \r
-  @param AcpiConfig       Point to Acpi configuration table\r
-  @param IoResStatus      Return the status of I/O resource\r
-  @param Mem32ResStatus   Return the status of 32-bit Memory resource\r
-  @param PMem32ResStatus  Return the status of 32-bit PMemory resource\r
-  @param Mem64ResStatus   Return the status of 64-bit Memory resource\r
-  @param PMem64ResStatus  Return the status of 64-bit PMemory resource\r
+  @param AcpiConfig       Point to Acpi configuration table.\r
+  @param IoResStatus      Return the status of I/O resource.\r
+  @param Mem32ResStatus   Return the status of 32-bit Memory resource.\r
+  @param PMem32ResStatus  Return the status of 32-bit PMemory resource.\r
+  @param Mem64ResStatus   Return the status of 64-bit Memory resource.\r
+  @param PMem64ResStatus  Return the status of 64-bit PMemory resource.\r
   \r
   @retval EFI_SUCCESS Success to get resource allocation status from ACPI configuration table.\r
 **/\r
   \r
   @retval EFI_SUCCESS Success to get resource allocation status from ACPI configuration table.\r
 **/\r
@@ -145,10 +145,10 @@ GetResourceAllocationStatus (
 /**\r
   Remove a PCI device from device pool and mark its bar\r
   \r
 /**\r
   Remove a PCI device from device pool and mark its bar\r
   \r
-  @param PciDevice Instance of Pci device\r
+  @param PciDevice Instance of Pci device.\r
   \r
   \r
-  @retval EFI_SUCCESS Success Operation\r
-  @retval EFI_ABORTED Pci device is a root bridge\r
+  @retval EFI_SUCCESS Success Operation.\r
+  @retval EFI_ABORTED Pci device is a root bridge.\r
 **/\r
 EFI_STATUS\r
 RejectPciDevice (\r
 **/\r
 EFI_STATUS\r
 RejectPciDevice (\r
@@ -158,9 +158,9 @@ RejectPciDevice (
 /**\r
   Determine whethter a PCI device can be rejected\r
   \r
 /**\r
   Determine whethter a PCI device can be rejected\r
   \r
-  @param PciResNode Pointer to Pci resource node instance \r
+  @param PciResNode Pointer to Pci resource node instance.\r
   \r
   \r
-  @return whethter a PCI device can be rejected\r
+  @return whethter a PCI device can be rejected.\r
 **/\r
 BOOLEAN\r
 IsRejectiveDevice (\r
 **/\r
 BOOLEAN\r
 IsRejectiveDevice (\r
@@ -170,8 +170,8 @@ IsRejectiveDevice (
 /**\r
   Compare two resource node and get the larger resource consumer\r
   \r
 /**\r
   Compare two resource node and get the larger resource consumer\r
   \r
-  @param PciResNode1  resource node 1 want to be compared\r
-  @param PciResNode2  resource node 2 want to be compared\r
+  @param PciResNode1  resource node 1 want to be compared.\r
+  @param PciResNode2  resource node 2 want to be compared.\r
   \r
   @return Larger resource consumer.\r
 **/\r
   \r
   @return Larger resource consumer.\r
 **/\r
@@ -184,9 +184,9 @@ GetLargerConsumerDevice (
 /**\r
   Get the max resource consumer in the host resource pool\r
   \r
 /**\r
   Get the max resource consumer in the host resource pool\r
   \r
-  @param ResPool  Pointer to resource pool node\r
+  @param ResPool  Pointer to resource pool node.\r
   \r
   \r
-  @return the max resource consumer in the host resource pool\r
+  @return the max resource consumer in the host resource pool.\r
 **/\r
 PCI_RESOURCE_NODE *\r
 GetMaxResourceConsumerDevice (\r
 **/\r
 PCI_RESOURCE_NODE *\r
 GetMaxResourceConsumerDevice (\r
@@ -196,16 +196,16 @@ GetMaxResourceConsumerDevice (
 /**\r
   Adjust host bridge allocation so as to reduce resource requirement\r
   \r
 /**\r
   Adjust host bridge allocation so as to reduce resource requirement\r
   \r
-  @param IoPool           Pointer to instance of I/O resource Node\r
-  @param Mem32Pool        Pointer to instance of 32-bit memory resource Node\r
-  @param PMem32Pool       Pointer to instance of 32-bit Pmemory resource node\r
-  @param Mem64Pool        Pointer to instance of 64-bit memory resource node\r
-  @param PMem64Pool       Pointer to instance of 64-bit Pmemory resource node\r
-  @param IoResStatus      Status of I/O resource Node\r
-  @param Mem32ResStatus   Status of 32-bit memory resource Node\r
-  @param PMem32ResStatus  Status of 32-bit Pmemory resource node\r
-  @param Mem64ResStatus   Status of 64-bit memory resource node\r
-  @param PMem64ResStatus  Status of 64-bit Pmemory resource node\r
+  @param IoPool           Pointer to instance of I/O resource Node.\r
+  @param Mem32Pool        Pointer to instance of 32-bit memory resource Node.\r
+  @param PMem32Pool       Pointer to instance of 32-bit Pmemory resource node.\r
+  @param Mem64Pool        Pointer to instance of 64-bit memory resource node.\r
+  @param PMem64Pool       Pointer to instance of 64-bit Pmemory resource node.\r
+  @param IoResStatus      Status of I/O resource Node.\r
+  @param Mem32ResStatus   Status of 32-bit memory resource Node.\r
+  @param PMem32ResStatus  Status of 32-bit Pmemory resource node.\r
+  @param Mem64ResStatus   Status of 64-bit memory resource node.\r
+  @param PMem64ResStatus  Status of 64-bit Pmemory resource node.\r
 **/\r
 EFI_STATUS\r
 PciHostBridgeAdjustAllocation (\r
 **/\r
 EFI_STATUS\r
 PciHostBridgeAdjustAllocation (\r
@@ -225,13 +225,13 @@ PciHostBridgeAdjustAllocation (
   Summary requests for all resource type, and contruct ACPI resource\r
   requestor instance.\r
   \r
   Summary requests for all resource type, and contruct ACPI resource\r
   requestor instance.\r
   \r
-  @param Bridge           detecting bridge\r
-  @param IoNode           Pointer to instance of I/O resource Node\r
-  @param Mem32Node        Pointer to instance of 32-bit memory resource Node\r
-  @param PMem32Node       Pointer to instance of 32-bit Pmemory resource node\r
-  @param Mem64Node        Pointer to instance of 64-bit memory resource node\r
-  @param PMem64Node       Pointer to instance of 64-bit Pmemory resource node\r
-  @param pConfig          outof buffer holding new constructed APCI resource requestor\r
+  @param Bridge           detecting bridge.\r
+  @param IoNode           Pointer to instance of I/O resource Node.\r
+  @param Mem32Node        Pointer to instance of 32-bit memory resource Node.\r
+  @param PMem32Node       Pointer to instance of 32-bit Pmemory resource node.\r
+  @param Mem64Node        Pointer to instance of 64-bit memory resource node.\r
+  @param PMem64Node       Pointer to instance of 64-bit Pmemory resource node.\r
+  @param pConfig          outof buffer holding new constructed APCI resource requestor.\r
 **/\r
 EFI_STATUS\r
 ConstructAcpiResourceRequestor (\r
 **/\r
 EFI_STATUS\r
 ConstructAcpiResourceRequestor (\r
@@ -248,13 +248,13 @@ ConstructAcpiResourceRequestor (
   Get resource base from a acpi configuration descriptor.\r
   \r
   @param pConfig      an acpi configuration descriptor.\r
   Get resource base from a acpi configuration descriptor.\r
   \r
   @param pConfig      an acpi configuration descriptor.\r
-  @param IoBase       output of I/O resource base address\r
-  @param Mem32Base    output of 32-bit memory base address\r
-  @param PMem32Base   output of 32-bit pmemory base address\r
-  @param Mem64Base    output of 64-bit memory base address\r
-  @param PMem64Base   output of 64-bit pmemory base address\r
+  @param IoBase       output of I/O resource base address.\r
+  @param Mem32Base    output of 32-bit memory base address.\r
+  @param PMem32Base   output of 32-bit pmemory base address.\r
+  @param Mem64Base    output of 64-bit memory base address.\r
+  @param PMem64Base   output of 64-bit pmemory base address.\r
   \r
   \r
-  @return EFI_SUCCESS  Success operation\r
+  @return EFI_SUCCESS  Success operation.\r
 **/\r
 EFI_STATUS\r
 GetResourceBase (\r
 **/\r
 EFI_STATUS\r
 GetResourceBase (\r
@@ -270,10 +270,10 @@ GetResourceBase (
   Enumerate pci bridge, allocate resource and determine attribute\r
   for devices on this bridge\r
   \r
   Enumerate pci bridge, allocate resource and determine attribute\r
   for devices on this bridge\r
   \r
-  @param BridgeDev Pointer to instance of bridge device\r
+  @param BridgeDev Pointer to instance of bridge device.\r
   \r
   \r
-  @retval EFI_SUCCESS Success operation\r
-  @retval Others      Fail to enumerate\r
+  @retval EFI_SUCCESS Success operation.\r
+  @retval Others      Fail to enumerate.\r
 **/\r
 EFI_STATUS\r
 PciBridgeEnumerator (\r
 **/\r
 EFI_STATUS\r
 PciBridgeEnumerator (\r
@@ -283,10 +283,10 @@ PciBridgeEnumerator (
 /**\r
   Allocate all kinds of resource for bridge\r
   \r
 /**\r
   Allocate all kinds of resource for bridge\r
   \r
-  @param Bridge      Pointer to bridge instance\r
+  @param Bridge      Pointer to bridge instance.\r
   \r
   @retval EFI_SUCCESS Success operation.\r
   \r
   @retval EFI_SUCCESS Success operation.\r
-  @retval Others      Fail to allocate resource for bridge\r
+  @retval Others      Fail to allocate resource for bridge.\r
 **/\r
 EFI_STATUS\r
 PciBridgeResourceAllocator (\r
 **/\r
 EFI_STATUS\r
 PciBridgeResourceAllocator (\r
@@ -296,14 +296,14 @@ PciBridgeResourceAllocator (
 /**\r
   Get resource base address for a pci bridge device\r
   \r
 /**\r
   Get resource base address for a pci bridge device\r
   \r
-  @param Bridge  Given Pci driver instance\r
-  @param IoBase  output for base address of I/O type resource\r
-  @param Mem32Base  output for base address of 32-bit memory type resource\r
-  @param PMem32Base  output for base address of 32-bit Pmemory type resource\r
-  @param Mem64Base  output for base address of 64-bit memory type resource\r
-  @param PMem64Base  output for base address of 64-bit Pmemory type resource\r
+  @param Bridge  Given Pci driver instance.\r
+  @param IoBase  output for base address of I/O type resource.\r
+  @param Mem32Base  output for base address of 32-bit memory type resource.\r
+  @param PMem32Base  output for base address of 32-bit Pmemory type resource.\r
+  @param Mem64Base  output for base address of 64-bit memory type resource.\r
+  @param PMem64Base  output for base address of 64-bit Pmemory type resource.\r
   \r
   \r
-  @retval EFI_SUCCESS Succes to get resource base address\r
+  @retval EFI_SUCCESS Succes to get resource base address.\r
 **/\r
 EFI_STATUS\r
 GetResourceBaseFromBridge (\r
 **/\r
 EFI_STATUS\r
 GetResourceBaseFromBridge (\r
@@ -318,10 +318,10 @@ GetResourceBaseFromBridge (
 /**\r
   Process Option Rom on this host bridge\r
   \r
 /**\r
   Process Option Rom on this host bridge\r
   \r
-  @param PciResAlloc Pointer to instance of EFI_PCI_HOST_BRIDGE_RESOURCE_ALLOCATION_PROTOCOL\r
+  @param PciResAlloc Pointer to instance of EFI_PCI_HOST_BRIDGE_RESOURCE_ALLOCATION_PROTOCOL.\r
   \r
   \r
-  @retval EFI_NOT_FOUND Can not find the root bridge instance\r
-  @retval EFI_SUCCESS   Success process\r
+  @retval EFI_NOT_FOUND Can not find the root bridge instance.\r
+  @retval EFI_SUCCESS   Success process.\r
 **/\r
 EFI_STATUS\r
 PciHostBridgeP2CProcess (\r
 **/\r
 EFI_STATUS\r
 PciHostBridgeP2CProcess (\r
@@ -373,7 +373,7 @@ PciHostBridgeP2CProcess (
                                           required here. This notification can be used to perform any chipsetspecific\r
                                           programming.\r
       \r
                                           required here. This notification can be used to perform any chipsetspecific\r
                                           programming.\r
       \r
-   @param[in] This                The instance pointer of EFI_PCI_HOST_BRIDGE_RESOURCE_ALLOCATION_PROTOCOL\r
+   @param[in] PciResAlloc         The instance pointer of EFI_PCI_HOST_BRIDGE_RESOURCE_ALLOCATION_PROTOCOL\r
    @param[in] Phase               The phase during enumeration\r
    \r
    @retval EFI_NOT_READY          This phase cannot be entered at this time. For example, this error\r
    @param[in] Phase               The phase during enumeration\r
    \r
    @retval EFI_NOT_READY          This phase cannot be entered at this time. For example, this error\r
@@ -438,12 +438,12 @@ PreprocessController (
   @param This                 - A pointer to the hot plug request protocol.\r
   @param Operation            - The operation.\r
   @param Controller           - A pointer to the controller.\r
   @param This                 - A pointer to the hot plug request protocol.\r
   @param Operation            - The operation.\r
   @param Controller           - A pointer to the controller.\r
-  @param RemainningDevicePath - A pointer to the device path.\r
+  @param RemainingDevicePath  - A pointer to the device path.\r
   @param NumberOfChildren     - A the number of child handle in the ChildHandleBuffer.\r
   @param ChildHandleBuffer    - A pointer to the array contain the child handle.\r
   \r
   @param NumberOfChildren     - A the number of child handle in the ChildHandleBuffer.\r
   @param ChildHandleBuffer    - A pointer to the array contain the child handle.\r
   \r
-  @retval EFI_NOT_FOUND Can not find bridge according to controller handle\r
-  @retval EFI_SUCCESS   Success operating\r
+  @retval EFI_NOT_FOUND Can not find bridge according to controller handle.\r
+  @retval EFI_SUCCESS   Success operating.\r
 **/\r
 EFI_STATUS\r
 EFIAPI\r
 **/\r
 EFI_STATUS\r
 EFIAPI\r
@@ -459,7 +459,7 @@ PciHotPlugRequestNotify (
 /**\r
   Search hostbridge according to given handle\r
   \r
 /**\r
   Search hostbridge according to given handle\r
   \r
-  @return whether found\r
+  @return whether found.\r
 **/\r
 BOOLEAN\r
 SearchHostBridgeHandle (\r
 **/\r
 BOOLEAN\r
 SearchHostBridgeHandle (\r
@@ -469,7 +469,7 @@ SearchHostBridgeHandle (
 /**\r
   Add host bridge handle to global variable for enumating.\r
   \r
 /**\r
   Add host bridge handle to global variable for enumating.\r
   \r
-  @param HostBridgeHandle host bridge handle\r
+  @param HostBridgeHandle host bridge handle.\r
 **/\r
 EFI_STATUS\r
 AddHostBridgeEnumerator (\r
 **/\r
 EFI_STATUS\r
 AddHostBridgeEnumerator (\r
index 2dceb002ed1353be7168b69db5f645ff76d723ef..a6867da0ba3b8c2d671cdacb1f5f8ef9f7001ebb 100644 (file)
@@ -1,4 +1,4 @@
-/**@file\r
+/**@ file\r
 \r
 Copyright (c) 2006, Intel Corporation\r
 All rights reserved. This program and the accompanying materials\r
 \r
 Copyright (c) 2006, Intel Corporation\r
 All rights reserved. This program and the accompanying materials\r
@@ -20,13 +20,13 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
 /**\r
   This routine is used to check whether the pci device is present.\r
   \r
 /**\r
   This routine is used to check whether the pci device is present.\r
   \r
-  @param PciRootBridgeIo   Pointer to instance of EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL\r
-  @param Pci               Output buffer for PCI device structure\r
-  @param Bus               PCI bus NO\r
-  @param Device            PCI device NO\r
-  @param Func              PCI Func NO\r
+  @param PciRootBridgeIo   Pointer to instance of EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL.\r
+  @param Pci               Output buffer for PCI device structure.\r
+  @param Bus               PCI bus NO.\r
+  @param Device            PCI device NO.\r
+  @param Func              PCI Func NO.\r
   \r
   \r
-  @retval EFI_NOT_FOUND device not present\r
+  @retval EFI_NOT_FOUND device not present.\r
   @retval EFI_SUCCESS   device is found.\r
 **/\r
 EFI_STATUS\r
   @retval EFI_SUCCESS   device is found.\r
 **/\r
 EFI_STATUS\r
@@ -84,8 +84,8 @@ PciDevicePresent (
   A database that records all the information about pci device subject to this\r
   root bridge will then be created.\r
     \r
   A database that records all the information about pci device subject to this\r
   root bridge will then be created.\r
     \r
-  @param Bridge         Parent bridge instance\r
-  @param StartBusNumer  Bus number of begining \r
+  @param Bridge         Parent bridge instance.\r
+  @param StartBusNumer  Bus number of begining. \r
 **/\r
 EFI_STATUS\r
 PciPciDeviceInfoCollector (\r
 **/\r
 EFI_STATUS\r
 PciPciDeviceInfoCollector (\r
@@ -190,12 +190,12 @@ PciPciDeviceInfoCollector (
 /**\r
   Seach required device and get PCI device info block\r
   \r
 /**\r
   Seach required device and get PCI device info block\r
   \r
-  @param Bridge     Parent bridge instance\r
-  @param Pci        Output of PCI device info block\r
+  @param Bridge     Parent bridge instance.\r
+  @param Pci        Output of PCI device info block.\r
   @param Bus        PCI bus NO.\r
   @param Device     PCI device NO.\r
   @param Func       PCI func  NO.\r
   @param Bus        PCI bus NO.\r
   @param Device     PCI device NO.\r
   @param Func       PCI func  NO.\r
-  @param PciDevice  output of searched PCI device instance\r
+  @param PciDevice  output of searched PCI device instance.\r
 **/\r
 EFI_STATUS\r
 PciSearchDevice (\r
 **/\r
 EFI_STATUS\r
 PciSearchDevice (\r
@@ -260,7 +260,7 @@ PciSearchDevice (
     }\r
   }\r
 \r
     }\r
   }\r
 \r
-  if (!PciIoDevice) {\r
+  if (PciIoDevice == NULL) {\r
     return EFI_OUT_OF_RESOURCES;\r
   }\r
 \r
     return EFI_OUT_OF_RESOURCES;\r
   }\r
 \r
@@ -307,7 +307,7 @@ PciSearchDevice (
 /**\r
   Create PCI private data for PCI device\r
   \r
 /**\r
   Create PCI private data for PCI device\r
   \r
-  @param Bridge Parent bridge instance\r
+  @param Bridge Parent bridge instance.\r
   @param Pci    PCI bar block\r
   @param Bus    PCI device Bus NO.\r
   @param Device PCI device DeviceNO.\r
   @param Pci    PCI bar block\r
   @param Bus    PCI device Bus NO.\r
   @param Device PCI device DeviceNO.\r
@@ -338,7 +338,7 @@ GatherDeviceInfo (
                   Func\r
                   );\r
 \r
                   Func\r
                   );\r
 \r
-  if (!PciIoDevice) {\r
+  if (PciIoDevice == NULL) {\r
     return NULL;\r
   }\r
 \r
     return NULL;\r
   }\r
 \r
@@ -378,7 +378,7 @@ GatherDeviceInfo (
   @param Device     Bridge device's device NO.\r
   @param Func       Bridge device's func NO.\r
   \r
   @param Device     Bridge device's device NO.\r
   @param Func       Bridge device's func NO.\r
   \r
-  @return bridge device instance\r
+  @return bridge device instance.\r
 **/\r
 PCI_IO_DEVICE *\r
 GatherPpbInfo (\r
 **/\r
 PCI_IO_DEVICE *\r
 GatherPpbInfo (\r
@@ -405,7 +405,7 @@ GatherPpbInfo (
                   Func\r
                   );\r
 \r
                   Func\r
                   );\r
 \r
-  if (!PciIoDevice) {\r
+  if (PciIoDevice == NULL) {\r
     return NULL;\r
   }\r
 \r
     return NULL;\r
   }\r
 \r
@@ -447,8 +447,8 @@ GatherPpbInfo (
   PciIoRead (PciIo, EfiPciIoWidthUint8, 0x1C, 1, &Value);\r
   PciIoWrite (PciIo, EfiPciIoWidthUint8, 0x1C, 1, &Temp);\r
 \r
   PciIoRead (PciIo, EfiPciIoWidthUint8, 0x1C, 1, &Value);\r
   PciIoWrite (PciIo, EfiPciIoWidthUint8, 0x1C, 1, &Temp);\r
 \r
-  if (Value) {\r
-    if (Value & 0x01) {\r
+  if (Value != 0) {\r
+    if ((Value & 0x01) != 0) {\r
       PciIoDevice->Decodes |= EFI_BRIDGE_IO32_DECODE_SUPPORTED;\r
     } else {\r
       PciIoDevice->Decodes |= EFI_BRIDGE_IO16_DECODE_SUPPORTED;\r
       PciIoDevice->Decodes |= EFI_BRIDGE_IO32_DECODE_SUPPORTED;\r
     } else {\r
       PciIoDevice->Decodes |= EFI_BRIDGE_IO16_DECODE_SUPPORTED;\r
@@ -501,7 +501,7 @@ GatherPpbInfo (
   @param Device hotplug bridge device's device NO.\r
   @param Func   hotplug bridge device's Func NO.\r
   \r
   @param Device hotplug bridge device's device NO.\r
   @param Func   hotplug bridge device's Func NO.\r
   \r
-  @return hotplug bridge device instance\r
+  @return hotplug bridge device instance.\r
 **/\r
 PCI_IO_DEVICE *\r
 GatherP2CInfo (\r
 **/\r
 PCI_IO_DEVICE *\r
 GatherP2CInfo (\r
@@ -524,7 +524,7 @@ GatherP2CInfo (
                   Func\r
                   );\r
 \r
                   Func\r
                   );\r
 \r
-  if (!PciIoDevice) {\r
+  if (PciIoDevice == NULL) {\r
     return NULL;\r
   }\r
 \r
     return NULL;\r
   }\r
 \r
@@ -564,8 +564,8 @@ GatherP2CInfo (
 /**\r
   Create device path for pci deivce\r
   \r
 /**\r
   Create device path for pci deivce\r
   \r
-  @param ParentDevicePath  Parent bridge's path\r
-  @param PciIoDevice       Pci device instance\r
+  @param ParentDevicePath  Parent bridge's path.\r
+  @param PciIoDevice       Pci device instance.\r
   \r
   @return device path protocol instance for specific pci device.\r
 **/\r
   \r
   @return device path protocol instance for specific pci device.\r
 **/\r
@@ -662,13 +662,13 @@ BarExisted (
 /**\r
   Test whether the device can support attributes \r
   \r
 /**\r
   Test whether the device can support attributes \r
   \r
-  @param PciIoDevice   Pci device instance\r
+  @param PciIoDevice   Pci device instance.\r
   @param Command       Command register value.\r
   @param BridgeControl Bridge control value for PPB or P2C.\r
   @param Command       Command register value.\r
   @param BridgeControl Bridge control value for PPB or P2C.\r
-  @param OldCommand    Old command register offset\r
+  @param OldCommand    Old command register offset.\r
   @param OldBridgeControl Old Bridge control value for PPB or P2C.\r
   \r
   @param OldBridgeControl Old Bridge control value for PPB or P2C.\r
   \r
-  @return EFI_SUCCESS\r
+  @return EFI_SUCCESS.\r
 **/\r
 EFI_STATUS\r
 PciTestSupportedAttribute (\r
 **/\r
 EFI_STATUS\r
 PciTestSupportedAttribute (\r
@@ -758,33 +758,33 @@ PciSetDeviceAttribute (
 \r
   Attributes = 0;\r
 \r
 \r
   Attributes = 0;\r
 \r
-  if (Command & EFI_PCI_COMMAND_IO_SPACE) {\r
+  if ((Command & EFI_PCI_COMMAND_IO_SPACE) != 0) {\r
     Attributes |= EFI_PCI_IO_ATTRIBUTE_IO;\r
   }\r
 \r
     Attributes |= EFI_PCI_IO_ATTRIBUTE_IO;\r
   }\r
 \r
-  if (Command & EFI_PCI_COMMAND_MEMORY_SPACE) {\r
+  if ((Command & EFI_PCI_COMMAND_MEMORY_SPACE) != 0) {\r
     Attributes |= EFI_PCI_IO_ATTRIBUTE_MEMORY;\r
   }\r
 \r
     Attributes |= EFI_PCI_IO_ATTRIBUTE_MEMORY;\r
   }\r
 \r
-  if (Command & EFI_PCI_COMMAND_BUS_MASTER) {\r
+  if ((Command & EFI_PCI_COMMAND_BUS_MASTER) != 0) {\r
     Attributes |= EFI_PCI_IO_ATTRIBUTE_BUS_MASTER;\r
   }\r
 \r
     Attributes |= EFI_PCI_IO_ATTRIBUTE_BUS_MASTER;\r
   }\r
 \r
-  if (Command & EFI_PCI_COMMAND_VGA_PALETTE_SNOOP) {\r
+  if ((Command & EFI_PCI_COMMAND_VGA_PALETTE_SNOOP) != 0) {\r
     Attributes |= EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO;\r
   }\r
 \r
     Attributes |= EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO;\r
   }\r
 \r
-  if (BridgeControl & EFI_PCI_BRIDGE_CONTROL_ISA) {\r
+  if ((BridgeControl & EFI_PCI_BRIDGE_CONTROL_ISA) != 0) {\r
     Attributes |= EFI_PCI_IO_ATTRIBUTE_ISA_IO;\r
   }\r
 \r
     Attributes |= EFI_PCI_IO_ATTRIBUTE_ISA_IO;\r
   }\r
 \r
-  if (BridgeControl & EFI_PCI_BRIDGE_CONTROL_VGA) {\r
+  if ((BridgeControl & EFI_PCI_BRIDGE_CONTROL_VGA) != 0) {\r
     Attributes |= EFI_PCI_IO_ATTRIBUTE_VGA_IO;\r
     Attributes |= EFI_PCI_IO_ATTRIBUTE_VGA_MEMORY;\r
     Attributes |= EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO;\r
   }\r
 \r
     Attributes |= EFI_PCI_IO_ATTRIBUTE_VGA_IO;\r
     Attributes |= EFI_PCI_IO_ATTRIBUTE_VGA_MEMORY;\r
     Attributes |= EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO;\r
   }\r
 \r
-  if (BridgeControl & EFI_PCI_BRIDGE_CONTROL_VGA_16) {\r
+  if ((BridgeControl & EFI_PCI_BRIDGE_CONTROL_VGA_16) != 0) {\r
     Attributes |= EFI_PCI_IO_ATTRIBUTE_VGA_IO_16;\r
     Attributes |= EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO_16;\r
   }\r
     Attributes |= EFI_PCI_IO_ATTRIBUTE_VGA_IO_16;\r
     Attributes |= EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO_16;\r
   }\r
@@ -798,7 +798,7 @@ PciSetDeviceAttribute (
                   EFI_PCI_IO_ATTRIBUTE_EMBEDDED_ROM         |\r
                   EFI_PCI_IO_ATTRIBUTE_DUAL_ADDRESS_CYCLE;\r
 \r
                   EFI_PCI_IO_ATTRIBUTE_EMBEDDED_ROM         |\r
                   EFI_PCI_IO_ATTRIBUTE_DUAL_ADDRESS_CYCLE;\r
 \r
-    if (Attributes & EFI_PCI_IO_ATTRIBUTE_IO) {\r
+    if ((Attributes & EFI_PCI_IO_ATTRIBUTE_IO) != 0) {\r
       Attributes |= EFI_PCI_IO_ATTRIBUTE_ISA_MOTHERBOARD_IO;\r
       Attributes |= EFI_PCI_IO_ATTRIBUTE_ISA_IO;\r
     }\r
       Attributes |= EFI_PCI_IO_ATTRIBUTE_ISA_MOTHERBOARD_IO;\r
       Attributes |= EFI_PCI_IO_ATTRIBUTE_ISA_IO;\r
     }\r
@@ -835,10 +835,10 @@ PciSetDeviceAttribute (
 }\r
 \r
 /**\r
 }\r
 \r
 /**\r
-  Determine if the device can support Fast Back to Back attribute\r
+  Determine if the device can support Fast Back to Back attribute.\r
   \r
   \r
-  @param PciIoDevice  Pci device instance\r
-  @param StatusIndex  Status register value\r
+  @param PciIoDevice  Pci device instance.\r
+  @param StatusIndex  Status register value.\r
 **/\r
 EFI_STATUS\r
 GetFastBackToBackSupport (\r
 **/\r
 EFI_STATUS\r
 GetFastBackToBackSupport (\r
@@ -862,7 +862,7 @@ GetFastBackToBackSupport (
   //\r
   // Check the Fast B2B bit\r
   //\r
   //\r
   // Check the Fast B2B bit\r
   //\r
-  if (StatusRegister & EFI_PCI_FAST_BACK_TO_BACK_CAPABLE) {\r
+  if ((StatusRegister & EFI_PCI_FAST_BACK_TO_BACK_CAPABLE) != 0) {\r
     return EFI_SUCCESS;\r
   } else {\r
     return EFI_UNSUPPORTED;\r
     return EFI_SUCCESS;\r
   } else {\r
     return EFI_UNSUPPORTED;\r
@@ -874,7 +874,7 @@ GetFastBackToBackSupport (
   Process the option ROM for all the children of the specified parent PCI device.\r
   It can only be used after the first full Option ROM process.\r
 \r
   Process the option ROM for all the children of the specified parent PCI device.\r
   It can only be used after the first full Option ROM process.\r
 \r
-  @param PciIoDevice Pci device instance\r
+  @param PciIoDevice Pci device instance.\r
   \r
   @retval EFI_SUCCESS Success Operation.\r
 **/\r
   \r
   @retval EFI_SUCCESS Success Operation.\r
 **/\r
@@ -890,7 +890,7 @@ ProcessOptionRomLight (
   // For RootBridge, PPB , P2C, go recursively to traverse all its children\r
   //\r
   CurrentLink = PciIoDevice->ChildList.ForwardLink;\r
   // For RootBridge, PPB , P2C, go recursively to traverse all its children\r
   //\r
   CurrentLink = PciIoDevice->ChildList.ForwardLink;\r
-  while (CurrentLink && CurrentLink != &PciIoDevice->ChildList) {\r
+  while (CurrentLink != NULL && CurrentLink != &PciIoDevice->ChildList) {\r
 \r
     Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
 \r
 \r
     Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
 \r
@@ -914,7 +914,7 @@ ProcessOptionRomLight (
 /**\r
  Determine the related attributes of all devices under a Root Bridge\r
  \r
 /**\r
  Determine the related attributes of all devices under a Root Bridge\r
  \r
- @param PciIoDevice   PCI device instance\r
+ @param PciIoDevice   PCI device instance.\r
  \r
 **/\r
 EFI_STATUS\r
  \r
 **/\r
 EFI_STATUS\r
@@ -940,7 +940,7 @@ DetermineDeviceAttribute (
   // For Root Bridge, just copy it by RootBridgeIo proctocol\r
   // so as to keep consistent with the actual attribute\r
   //\r
   // For Root Bridge, just copy it by RootBridgeIo proctocol\r
   // so as to keep consistent with the actual attribute\r
   //\r
-  if (!PciIoDevice->Parent) {\r
+  if (PciIoDevice->Parent == NULL) {\r
     Status = PciIoDevice->PciRootBridgeIo->GetAttributes (\r
                                             PciIoDevice->PciRootBridgeIo,\r
                                             &PciIoDevice->Supports,\r
     Status = PciIoDevice->PciRootBridgeIo->GetAttributes (\r
                                             PciIoDevice->PciRootBridgeIo,\r
                                             &PciIoDevice->Supports,\r
@@ -1029,7 +1029,7 @@ DetermineDeviceAttribute (
   // For RootBridge, PPB , P2C, go recursively to traverse all its children\r
   //\r
   CurrentLink = PciIoDevice->ChildList.ForwardLink;\r
   // For RootBridge, PPB , P2C, go recursively to traverse all its children\r
   //\r
   CurrentLink = PciIoDevice->ChildList.ForwardLink;\r
-  while (CurrentLink && CurrentLink != &PciIoDevice->ChildList) {\r
+  while (CurrentLink != NULL && CurrentLink != &PciIoDevice->ChildList) {\r
 \r
     Temp    = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
     Status  = DetermineDeviceAttribute (Temp);\r
 \r
     Temp    = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
     Status  = DetermineDeviceAttribute (Temp);\r
@@ -1064,7 +1064,7 @@ DetermineDeviceAttribute (
     }\r
 \r
     CurrentLink = PciIoDevice->ChildList.ForwardLink;\r
     }\r
 \r
     CurrentLink = PciIoDevice->ChildList.ForwardLink;\r
-    while (CurrentLink && CurrentLink != &PciIoDevice->ChildList) {\r
+    while (CurrentLink != NULL && CurrentLink != &PciIoDevice->ChildList) {\r
       Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
       if (FastB2BSupport) {\r
         PciEnableCommandRegister (Temp, EFI_PCI_COMMAND_FAST_BACK_TO_BACK);\r
       Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
       if (FastB2BSupport) {\r
         PciEnableCommandRegister (Temp, EFI_PCI_COMMAND_FAST_BACK_TO_BACK);\r
@@ -1084,8 +1084,8 @@ DetermineDeviceAttribute (
 /**\r
   This routine is used to update the bar information for those incompatible PCI device\r
   \r
 /**\r
   This routine is used to update the bar information for those incompatible PCI device\r
   \r
-  @param PciIoDevice      Pci device instance\r
-  @return EFI_UNSUPPORTED failed to update Pci Info\r
+  @param PciIoDevice      Pci device instance.\r
+  @return EFI_UNSUPPORTED failed to update Pci Info.\r
 **/\r
 EFI_STATUS\r
 UpdatePciInfo (\r
 **/\r
 EFI_STATUS\r
 UpdatePciInfo (\r
@@ -1232,8 +1232,8 @@ UpdatePciInfo (
 /**\r
   This routine will update the alignment with the new alignment\r
   \r
 /**\r
   This routine will update the alignment with the new alignment\r
   \r
-  @param Alignment old alignment\r
-  @param NewAlignment new alignment\r
+  @param Alignment old alignment.\r
+  @param NewAlignment new alignment.\r
   \r
 **/\r
 VOID\r
   \r
 **/\r
 VOID\r
@@ -1277,15 +1277,15 @@ SetNewAlign (
   // Adjust the alignment to even, quad or double quad boundary\r
   //\r
   if (NewAlignment == PCI_BAR_EVEN_ALIGN) {\r
   // Adjust the alignment to even, quad or double quad boundary\r
   //\r
   if (NewAlignment == PCI_BAR_EVEN_ALIGN) {\r
-    if (OldAlignment & 0x01) {\r
+    if ((OldAlignment & 0x01) != 0) {\r
       OldAlignment = OldAlignment + 2 - (OldAlignment & 0x01);\r
     }\r
   } else if (NewAlignment == PCI_BAR_SQUAD_ALIGN) {\r
       OldAlignment = OldAlignment + 2 - (OldAlignment & 0x01);\r
     }\r
   } else if (NewAlignment == PCI_BAR_SQUAD_ALIGN) {\r
-    if (OldAlignment & 0x03) {\r
+    if ((OldAlignment & 0x03) != 0) {\r
       OldAlignment = OldAlignment + 4 - (OldAlignment & 0x03);\r
     }\r
   } else if (NewAlignment == PCI_BAR_DQUAD_ALIGN) {\r
       OldAlignment = OldAlignment + 4 - (OldAlignment & 0x03);\r
     }\r
   } else if (NewAlignment == PCI_BAR_DQUAD_ALIGN) {\r
-    if (OldAlignment & 0x07) {\r
+    if ((OldAlignment & 0x07) != 0) {\r
       OldAlignment = OldAlignment + 8 - (OldAlignment & 0x07);\r
     }\r
   }\r
       OldAlignment = OldAlignment + 8 - (OldAlignment & 0x07);\r
     }\r
   }\r
@@ -1302,9 +1302,9 @@ SetNewAlign (
 /**\r
   Parse PCI bar bit.\r
   \r
 /**\r
   Parse PCI bar bit.\r
   \r
-  @param PciIoDevice  Pci device instance\r
-  @param Offset       bar offset\r
-  @param BarIndex     bar index\r
+  @param PciIoDevice  Pci device instance.\r
+  @param Offset       bar offset.\r
+  @param BarIndex     bar index.\r
   \r
   @return next bar offset.\r
 **/\r
   \r
   @return next bar offset.\r
 **/\r
@@ -1345,13 +1345,13 @@ PciParseBar (
   }\r
 \r
   PciIoDevice->PciBar[BarIndex].Offset = (UINT8) Offset;\r
   }\r
 \r
   PciIoDevice->PciBar[BarIndex].Offset = (UINT8) Offset;\r
-  if (Value & 0x01) {\r
+  if ((Value & 0x01) != 0) {\r
     //\r
     // Device I/Os\r
     //\r
     Mask = 0xfffffffc;\r
 \r
     //\r
     // Device I/Os\r
     //\r
     Mask = 0xfffffffc;\r
 \r
-    if (Value & 0xFFFF0000) {\r
+    if ((Value & 0xFFFF0000) != 0) {\r
       //\r
       // It is a IO32 bar\r
       //\r
       //\r
       // It is a IO32 bar\r
       //\r
@@ -1391,7 +1391,7 @@ PciParseBar (
     //memory space; anywhere in 32 bit address space\r
     //\r
     case 0x00:\r
     //memory space; anywhere in 32 bit address space\r
     //\r
     case 0x00:\r
-      if (Value & 0x08) {\r
+      if ((Value & 0x08) != 0) {\r
         PciIoDevice->PciBar[BarIndex].BarType = PciBarTypePMem32;\r
       } else {\r
         PciIoDevice->PciBar[BarIndex].BarType = PciBarTypeMem32;\r
         PciIoDevice->PciBar[BarIndex].BarType = PciBarTypePMem32;\r
       } else {\r
         PciIoDevice->PciBar[BarIndex].BarType = PciBarTypeMem32;\r
@@ -1406,7 +1406,7 @@ PciParseBar (
     // memory space; anywhere in 64 bit address space\r
     //\r
     case 0x04:\r
     // memory space; anywhere in 64 bit address space\r
     //\r
     case 0x04:\r
-      if (Value & 0x08) {\r
+      if ((Value & 0x08) != 0) {\r
         PciIoDevice->PciBar[BarIndex].BarType = PciBarTypePMem64;\r
       } else {\r
         PciIoDevice->PciBar[BarIndex].BarType = PciBarTypeMem64;\r
         PciIoDevice->PciBar[BarIndex].BarType = PciBarTypePMem64;\r
       } else {\r
         PciIoDevice->PciBar[BarIndex].BarType = PciBarTypeMem64;\r
@@ -1487,10 +1487,10 @@ PciParseBar (
 }\r
 \r
 /**\r
 }\r
 \r
 /**\r
-  This routine is used to initialize the bar of a PCI device\r
-  It can be called typically when a device is going to be rejected\r
+  This routine is used to initialize the bar of a PCI device.\r
+  It can be called typically when a device is going to be rejected.\r
 \r
 \r
-  @param PciIoDevice Pci device instance\r
+  @param PciIoDevice Pci device instance.\r
 **/\r
 EFI_STATUS\r
 InitializePciDevice (\r
 **/\r
 EFI_STATUS\r
 InitializePciDevice (\r
@@ -1517,7 +1517,7 @@ InitializePciDevice (
 /**\r
   Init PPB for bridge device\r
   \r
 /**\r
   Init PPB for bridge device\r
   \r
-  @param  PciIoDevice Pci device instance\r
+  @param  PciIoDevice Pci device instance.\r
 **/\r
 EFI_STATUS\r
 InitializePpb (\r
 **/\r
 EFI_STATUS\r
 InitializePpb (\r
@@ -1562,7 +1562,7 @@ InitializePpb (
 /**\r
   Init private data for Hotplug bridge device\r
   \r
 /**\r
   Init private data for Hotplug bridge device\r
   \r
-  @param PciIoDevice hotplug bridge device\r
+  @param PciIoDevice hotplug bridge device.\r
 **/\r
 EFI_STATUS\r
 InitializeP2C (\r
 **/\r
 EFI_STATUS\r
 InitializeP2C (\r
@@ -1601,13 +1601,13 @@ InitializeP2C (
   Create and initiliaze general PCI I/O device instance for\r
   PCI device/bridge device/hotplug bridge device.\r
   \r
   Create and initiliaze general PCI I/O device instance for\r
   PCI device/bridge device/hotplug bridge device.\r
   \r
-  @param PciRootBridgeIo   Pointer to instance of EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL\r
-  @param Pci               Pci bar block\r
+  @param PciRootBridgeIo   Pointer to instance of EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL.\r
+  @param Pci               Pci bar block.\r
   @param Bus               device Bus NO.\r
   @param Device            device device NO.\r
   @param Func              device func NO.\r
   \r
   @param Bus               device Bus NO.\r
   @param Device            device device NO.\r
   @param Func              device func NO.\r
   \r
-  @return instance of PCI device\r
+  @return instance of PCI device.\r
 **/\r
 PCI_IO_DEVICE *\r
 CreatePciIoDevice (\r
 **/\r
 PCI_IO_DEVICE *\r
 CreatePciIoDevice (\r
@@ -1695,7 +1695,7 @@ CreatePciIoDevice (
   in a given platform\r
   It is only called on the second start on the same Root Bridge.\r
 \r
   in a given platform\r
   It is only called on the second start on the same Root Bridge.\r
 \r
-  @param Controller  Parent bridge handler\r
+  @param Controller  Parent bridge handler.\r
   \r
   @return status of operation.\r
 **/\r
   \r
   @return status of operation.\r
 **/\r
@@ -1751,7 +1751,7 @@ PciEnumeratorLight (
     //\r
     RootBridgeDev = CreateRootBridge (Controller);\r
 \r
     //\r
     RootBridgeDev = CreateRootBridge (Controller);\r
 \r
-    if (!RootBridgeDev) {\r
+    if (RootBridgeDev == NULL) {\r
       Descriptors++;\r
       continue;\r
     }\r
       Descriptors++;\r
       continue;\r
     }\r
@@ -1887,10 +1887,10 @@ StartManagingRootBridge (
 /**\r
   This routine can be used to check whether a PCI device should be rejected when light enumeration\r
 \r
 /**\r
   This routine can be used to check whether a PCI device should be rejected when light enumeration\r
 \r
-  @param PciIoDevice  Pci device instance\r
+  @param PciIoDevice  Pci device instance.\r
 \r
 \r
-  @retval TRUE      This device should be rejected\r
-  @retval FALSE     This device shouldn't be rejected\r
+  @retval TRUE      This device should be rejected.\r
+  @retval FALSE     This device shouldn't be rejected.\r
   \r
 **/\r
 BOOLEAN\r
   \r
 **/\r
 BOOLEAN\r
@@ -1944,7 +1944,7 @@ IsPciDeviceRejected (
       continue;\r
     }\r
 \r
       continue;\r
     }\r
 \r
-    if (TestValue & 0x01) {\r
+    if ((TestValue & 0x01) != 0) {\r
 \r
       //\r
       // IO Bar\r
 \r
       //\r
       // IO Bar\r
@@ -2001,8 +2001,8 @@ IsPciDeviceRejected (
 /**\r
   Reset and all bus number from specific bridge.\r
   \r
 /**\r
   Reset and all bus number from specific bridge.\r
   \r
-  @param Bridge           Parent specific bridge\r
-  @param StartBusNumber   start bus number\r
+  @param Bridge           Parent specific bridge.\r
+  @param StartBusNumber   start bus number.\r
 **/\r
 EFI_STATUS\r
 ResetAllPpbBusNumber (\r
 **/\r
 EFI_STATUS\r
 ResetAllPpbBusNumber (\r
index ab46b5ac8a48f7a74d7714561e8938659547c4ca..8840998d94b6e8e7e6a9609470b71a86fc9c8a21 100644 (file)
@@ -1,4 +1,4 @@
-/**@file\r
+/**@ file\r
 \r
 Copyright (c) 2006, Intel Corporation                                                         \r
 All rights reserved. This program and the accompanying materials                          \r
 \r
 Copyright (c) 2006, Intel Corporation                                                         \r
 All rights reserved. This program and the accompanying materials                          \r
@@ -99,7 +99,7 @@ GatherDeviceInfo (
   @param Device     Bridge device's device NO.\r
   @param Func       Bridge device's func NO.\r
   \r
   @param Device     Bridge device's device NO.\r
   @param Func       Bridge device's func NO.\r
   \r
-  @return bridge device instance\r
+  @return bridge device instance.\r
 **/\r
 PCI_IO_DEVICE             *\r
 GatherPpbInfo (\r
 **/\r
 PCI_IO_DEVICE             *\r
 GatherPpbInfo (\r
@@ -133,8 +133,8 @@ GatherP2CInfo (
 /**\r
   Create device path for pci deivce\r
   \r
 /**\r
   Create device path for pci deivce\r
   \r
-  @param ParentDevicePath  Parent bridge's path\r
-  @param PciIoDevice       Pci device instance\r
+  @param ParentDevicePath  Parent bridge's path.\r
+  @param PciIoDevice       Pci device instance.\r
   \r
   @return device path protocol instance for specific pci device.\r
 **/\r
   \r
   @return device path protocol instance for specific pci device.\r
 **/\r
@@ -173,7 +173,7 @@ BarExisted (
   @param OldCommand    Old command register offset\r
   @param OldBridgeControl Old Bridge control value for PPB or P2C.\r
   \r
   @param OldCommand    Old command register offset\r
   @param OldBridgeControl Old Bridge control value for PPB or P2C.\r
   \r
-  @return EFI_SUCCESS\r
+  @return EFI_SUCCESS.\r
 **/\r
 EFI_STATUS\r
 PciTestSupportedAttribute (\r
 **/\r
 EFI_STATUS\r
 PciTestSupportedAttribute (\r
@@ -204,8 +204,8 @@ PciSetDeviceAttribute (
 /**\r
   Determine if the device can support Fast Back to Back attribute\r
   \r
 /**\r
   Determine if the device can support Fast Back to Back attribute\r
   \r
-  @param PciIoDevice  Pci device instance\r
-  @param StatusIndex  Status register value\r
+  @param PciIoDevice  Pci device instance.\r
+  @param StatusIndex  Status register value.\r
 **/\r
 EFI_STATUS\r
 GetFastBackToBackSupport (\r
 **/\r
 EFI_STATUS\r
 GetFastBackToBackSupport (\r
@@ -216,7 +216,7 @@ GetFastBackToBackSupport (
 /**\r
  Determine the related attributes of all devices under a Root Bridge\r
  \r
 /**\r
  Determine the related attributes of all devices under a Root Bridge\r
  \r
- @param PciIoDevice   PCI device instance\r
+ @param PciIoDevice   PCI device instance.\r
  \r
 **/\r
 EFI_STATUS\r
  \r
 **/\r
 EFI_STATUS\r
@@ -227,8 +227,8 @@ DetermineDeviceAttribute (
 /**\r
   This routine is used to update the bar information for those incompatible PCI device\r
   \r
 /**\r
   This routine is used to update the bar information for those incompatible PCI device\r
   \r
-  @param PciIoDevice      Pci device instance\r
-  @return EFI_UNSUPPORTED failed to update Pci Info\r
+  @param PciIoDevice      Pci device instance.\r
+  @return EFI_UNSUPPORTED failed to update Pci Info.\r
 **/\r
 EFI_STATUS\r
 UpdatePciInfo (\r
 **/\r
 EFI_STATUS\r
 UpdatePciInfo (\r
@@ -238,8 +238,8 @@ UpdatePciInfo (
 /**\r
   This routine will update the alignment with the new alignment\r
   \r
 /**\r
   This routine will update the alignment with the new alignment\r
   \r
-  @param Alignment old alignment\r
-  @param NewAlignment new alignment\r
+  @param Alignment old alignment.\r
+  @param NewAlignment new alignment.\r
   \r
 **/\r
 VOID\r
   \r
 **/\r
 VOID\r
@@ -251,9 +251,9 @@ SetNewAlign (
 /**\r
   Parse PCI bar bit.\r
   \r
 /**\r
   Parse PCI bar bit.\r
   \r
-  @param PciIoDevice  Pci device instance\r
-  @param Offset       bar offset\r
-  @param BarIndex     bar index\r
+  @param PciIoDevice  Pci device instance.\r
+  @param Offset       bar offset.\r
+  @param BarIndex     bar index.\r
   \r
   @return next bar offset.\r
 **/\r
   \r
   @return next bar offset.\r
 **/\r
@@ -266,9 +266,9 @@ PciParseBar (
 \r
 /**\r
   This routine is used to initialize the bar of a PCI device\r
 \r
 /**\r
   This routine is used to initialize the bar of a PCI device\r
-  It can be called typically when a device is going to be rejected\r
+  It can be called typically when a device is going to be rejected.\r
 \r
 \r
-  @param PciIoDevice Pci device instance\r
+  @param PciIoDevice Pci device instance.\r
 **/\r
 EFI_STATUS\r
 InitializePciDevice (\r
 **/\r
 EFI_STATUS\r
 InitializePciDevice (\r
@@ -278,7 +278,7 @@ InitializePciDevice (
 /**\r
   Init PPB for bridge device\r
   \r
 /**\r
   Init PPB for bridge device\r
   \r
-  @param  PciIoDevice Pci device instance\r
+  @param  PciIoDevice Pci device instance.\r
 **/\r
 EFI_STATUS\r
 InitializePpb (\r
 **/\r
 EFI_STATUS\r
 InitializePpb (\r
@@ -288,7 +288,7 @@ InitializePpb (
 /**\r
   Init private data for Hotplug bridge device\r
   \r
 /**\r
   Init private data for Hotplug bridge device\r
   \r
-  @param PciIoDevice hotplug bridge device\r
+  @param PciIoDevice hotplug bridge device.\r
 **/\r
 EFI_STATUS\r
 InitializeP2C (\r
 **/\r
 EFI_STATUS\r
 InitializeP2C (\r
@@ -299,13 +299,13 @@ InitializeP2C (
   Create and initiliaze general PCI I/O device instance for\r
   PCI device/bridge device/hotplug bridge device.\r
   \r
   Create and initiliaze general PCI I/O device instance for\r
   PCI device/bridge device/hotplug bridge device.\r
   \r
-  @param PciRootBridgeIo   Pointer to instance of EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL\r
+  @param PciRootBridgeIo   Pointer to instance of EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL.\r
   @param Pci               Pci bar block\r
   @param Bus               device Bus NO.\r
   @param Device            device device NO.\r
   @param Func              device func NO.\r
   \r
   @param Pci               Pci bar block\r
   @param Bus               device Bus NO.\r
   @param Device            device device NO.\r
   @param Func              device func NO.\r
   \r
-  @return instance of PCI device\r
+  @return instance of PCI device.\r
 **/\r
 PCI_IO_DEVICE             *\r
 CreatePciIoDevice (\r
 **/\r
 PCI_IO_DEVICE             *\r
 CreatePciIoDevice (\r
@@ -321,7 +321,7 @@ CreatePciIoDevice (
   in a given platform\r
   It is only called on the second start on the same Root Bridge.\r
 \r
   in a given platform\r
   It is only called on the second start on the same Root Bridge.\r
 \r
-  @param Controller  Parent bridge handler\r
+  @param Controller  Parent bridge handler.\r
   \r
   @return status of operation.\r
 **/\r
   \r
   @return status of operation.\r
 **/\r
@@ -357,10 +357,10 @@ StartManagingRootBridge (
 /**\r
   This routine can be used to check whether a PCI device should be rejected when light enumeration\r
 \r
 /**\r
   This routine can be used to check whether a PCI device should be rejected when light enumeration\r
 \r
-  @param PciIoDevice  Pci device instance\r
+  @param PciIoDevice  Pci device instance.\r
 \r
 \r
-  @retval TRUE      This device should be rejected\r
-  @retval FALSE     This device shouldn't be rejected\r
+  @retval TRUE      This device should be rejected.\r
+  @retval FALSE     This device shouldn't be rejected.\r
   \r
 **/\r
 BOOLEAN\r
   \r
 **/\r
 BOOLEAN\r
index dbf3a749d378cc0fbf2b7d3ec8d140bff68a28c4..dcc6d72058c70a3bbafaa0561a3489725264b8d2 100644 (file)
@@ -1,4 +1,4 @@
-/**@file\r
+/**@ file\r
   This module provide support function for hot plug device.\r
   \r
 Copyright (c) 2006, Intel Corporation                                                         \r
   This module provide support function for hot plug device.\r
   \r
 Copyright (c) 2006, Intel Corporation                                                         \r
@@ -44,11 +44,11 @@ PciHPCInitialized (
 /**\r
   Compare two device path\r
   \r
 /**\r
   Compare two device path\r
   \r
-  @param DevicePath1    the first device path want to be compared\r
-  @param DevicePath2    the first device path want to be compared\r
+  @param DevicePath1    the first device path want to be compared.\r
+  @param DevicePath2    the first device path want to be compared.\r
   \r
   \r
-  @retval TRUE    equal\r
-  @retval FALSE   different\r
+  @retval TRUE    equal.\r
+  @retval FALSE   different.\r
 **/\r
 BOOLEAN\r
 EfiCompareDevicePath (\r
 **/\r
 BOOLEAN\r
 EfiCompareDevicePath (\r
@@ -131,11 +131,11 @@ InitializeHotPlugSupport (
 /**\r
   Test whether device path is for root pci hot plug bus\r
   \r
 /**\r
   Test whether device path is for root pci hot plug bus\r
   \r
-  @param HpbdevicePath  tested device path\r
+  @param HpbdevicePath  tested device path.\r
   @param HpIndex        Return the index of root hot plug in global array.\r
   \r
   @param HpIndex        Return the index of root hot plug in global array.\r
   \r
-  @retval TRUE  device path is for root pci hot plug\r
-  @retval FALSE device path is not for root pci hot plug\r
+  @retval TRUE  device path is for root pci hot plug.\r
+  @retval FALSE device path is not for root pci hot plug.\r
 **/\r
 BOOLEAN\r
 IsRootPciHotPlugBus (\r
 **/\r
 BOOLEAN\r
 IsRootPciHotPlugBus (\r
@@ -163,11 +163,11 @@ IsRootPciHotPlugBus (
 /**\r
   Test whether device path is for root pci hot plug controller\r
   \r
 /**\r
   Test whether device path is for root pci hot plug controller\r
   \r
-  @param HpbdevicePath  tested device path\r
+  @param HpbdevicePath  tested device path.\r
   @param HpIndex        Return the index of root hot plug in global array.\r
   \r
   @param HpIndex        Return the index of root hot plug in global array.\r
   \r
-  @retval TRUE  device path is for root pci hot plug controller\r
-  @retval FALSE device path is not for root pci hot plug controller\r
+  @retval TRUE  device path is for root pci hot plug controller.\r
+  @retval FALSE device path is not for root pci hot plug controller.\r
 **/\r
 BOOLEAN\r
 IsRootPciHotPlugController (\r
 **/\r
 BOOLEAN\r
 IsRootPciHotPlugController (\r
@@ -195,10 +195,10 @@ IsRootPciHotPlugController (
 /**\r
   Wrapper for creating event object for HPC \r
   \r
 /**\r
   Wrapper for creating event object for HPC \r
   \r
-  @param  HpIndex   index of hot plug device in global array\r
-  @param  Event     event object\r
+  @param  HpIndex   index of hot plug device in global array.\r
+  @param  Event     event object.\r
   \r
   \r
-  @return status of create event invoken\r
+  @return status of create event invoken.\r
 **/\r
 EFI_STATUS\r
 CreateEventForHpc (\r
 **/\r
 EFI_STATUS\r
 CreateEventForHpc (\r
@@ -226,7 +226,7 @@ CreateEventForHpc (
 /**\r
   Wait for all root HPC initialized.\r
   \r
 /**\r
   Wait for all root HPC initialized.\r
   \r
-  @param TimeoutInMicroSeconds  microseconds to wait for all root hpc's initialization\r
+  @param TimeoutInMicroSeconds  microseconds to wait for all root hpc's initialization.\r
 **/\r
 EFI_STATUS\r
 AllRootHPCInitialized (\r
 **/\r
 EFI_STATUS\r
 AllRootHPCInitialized (\r
@@ -257,7 +257,7 @@ AllRootHPCInitialized (
 \r
     Delay--;\r
 \r
 \r
     Delay--;\r
 \r
-  } while (Delay);\r
+  } while (Delay > 0);\r
 \r
   return EFI_TIMEOUT;\r
 }\r
 \r
   return EFI_TIMEOUT;\r
 }\r
@@ -265,10 +265,10 @@ AllRootHPCInitialized (
 /**\r
   Check HPC capability register block\r
   \r
 /**\r
   Check HPC capability register block\r
   \r
-  @param PciIoDevice PCI device instance\r
+  @param PciIoDevice PCI device instance.\r
   \r
   \r
-  @retval EFI_SUCCESS   PCI device is HPC\r
-  @retval EFI_NOT_FOUND PCI device is not HPC\r
+  @retval EFI_SUCCESS   PCI device is HPC.\r
+  @retval EFI_NOT_FOUND PCI device is not HPC.\r
 **/\r
 EFI_STATUS\r
 IsSHPC (\r
 **/\r
 EFI_STATUS\r
 IsSHPC (\r
@@ -279,7 +279,7 @@ IsSHPC (
   EFI_STATUS  Status;\r
   UINT8       Offset;\r
 \r
   EFI_STATUS  Status;\r
   UINT8       Offset;\r
 \r
-  if (!PciIoDevice) {\r
+  if (PciIoDevice == NULL) {\r
     return EFI_NOT_FOUND;\r
   }\r
 \r
     return EFI_NOT_FOUND;\r
   }\r
 \r
@@ -352,7 +352,7 @@ Returns:
       return Status;\r
     }\r
 \r
       return Status;\r
     }\r
 \r
-    if ((State & EFI_HPC_STATE_ENABLED) && (State & EFI_HPC_STATE_INITIALIZED)) {\r
+    if ((State & EFI_HPC_STATE_ENABLED) != 0 && (State & EFI_HPC_STATE_INITIALIZED) != 0) {\r
       PciIoDevice->ResourcePaddingDescriptors = Descriptors;\r
       PciIoDevice->PaddingAttributes          = Attributes;\r
     }\r
       PciIoDevice->ResourcePaddingDescriptors = Descriptors;\r
       PciIoDevice->PaddingAttributes          = Attributes;\r
     }\r
@@ -366,10 +366,10 @@ Returns:
 /**\r
   Test whether PCI device is hot plug bus.\r
   \r
 /**\r
   Test whether PCI device is hot plug bus.\r
   \r
-  @param PciIoDevice  PCI device instance\r
+  @param PciIoDevice  PCI device instance.\r
   \r
   \r
-  @retval EFI_SUCCESS   PCI device is hot plug bus\r
-  @retval EFI_NOT_FOUND PCI device is not hot plug bus\r
+  @retval EFI_SUCCESS   PCI device is hot plug bus.\r
+  @retval EFI_NOT_FOUND PCI device is not hot plug bus.\r
 **/\r
 EFI_STATUS\r
 IsPciHotPlugBus (\r
 **/\r
 EFI_STATUS\r
 IsPciHotPlugBus (\r
index bc1253d7a13817b271a04a603695ffdafd6e23ab..50836657ea9c663ec447f8cf0a6112ce40ebb19d 100644 (file)
@@ -1,4 +1,4 @@
-/**@file\r
+/**@ file\r
 \r
 Copyright (c) 2006, Intel Corporation                                                         \r
 All rights reserved. This program and the accompanying materials                          \r
 \r
 Copyright (c) 2006, Intel Corporation                                                         \r
 All rights reserved. This program and the accompanying materials                          \r
@@ -48,11 +48,11 @@ PciHPCInitialized (
 /**\r
   Compare two device path\r
   \r
 /**\r
   Compare two device path\r
   \r
-  @param DevicePath1    the first device path want to be compared\r
-  @param DevicePath2    the first device path want to be compared\r
+  @param DevicePath1    the first device path want to be compared.\r
+  @param DevicePath2    the first device path want to be compared.\r
   \r
   \r
-  @retval TRUE    equal\r
-  @retval FALSE   different\r
+  @retval TRUE    equal.\r
+  @retval FALSE   different.\r
 **/\r
 BOOLEAN\r
 EfiCompareDevicePath (\r
 **/\r
 BOOLEAN\r
 EfiCompareDevicePath (\r
@@ -72,10 +72,10 @@ InitializeHotPlugSupport (
 /**\r
   Test whether PCI device is hot plug bus.\r
   \r
 /**\r
   Test whether PCI device is hot plug bus.\r
   \r
-  @param PciIoDevice  PCI device instance\r
+  @param PciIoDevice  PCI device instance.\r
   \r
   \r
-  @retval EFI_SUCCESS   PCI device is hot plug bus\r
-  @retval EFI_NOT_FOUND PCI device is not hot plug bus\r
+  @retval EFI_SUCCESS   PCI device is hot plug bus.\r
+  @retval EFI_NOT_FOUND PCI device is not hot plug bus.\r
 **/\r
 EFI_STATUS\r
 IsPciHotPlugBus (\r
 **/\r
 EFI_STATUS\r
 IsPciHotPlugBus (\r
@@ -85,7 +85,7 @@ IsPciHotPlugBus (
 /**\r
   Test whether device path is for root pci hot plug bus\r
   \r
 /**\r
   Test whether device path is for root pci hot plug bus\r
   \r
-  @param HpbdevicePath  tested device path\r
+  @param HpbDevicePath  tested device path\r
   @param HpIndex        Return the index of root hot plug in global array.\r
   \r
   @retval TRUE  device path is for root pci hot plug\r
   @param HpIndex        Return the index of root hot plug in global array.\r
   \r
   @retval TRUE  device path is for root pci hot plug\r
@@ -100,11 +100,11 @@ IsRootPciHotPlugBus (
 /**\r
   Test whether device path is for root pci hot plug controller\r
   \r
 /**\r
   Test whether device path is for root pci hot plug controller\r
   \r
-  @param HpbdevicePath  tested device path\r
+  @param HpcDevicePath  tested device path.\r
   @param HpIndex        Return the index of root hot plug in global array.\r
   \r
   @param HpIndex        Return the index of root hot plug in global array.\r
   \r
-  @retval TRUE  device path is for root pci hot plug controller\r
-  @retval FALSE device path is not for root pci hot plug controller\r
+  @retval TRUE  device path is for root pci hot plug controller.\r
+  @retval FALSE device path is not for root pci hot plug controller.\r
 **/\r
 BOOLEAN\r
 IsRootPciHotPlugController (\r
 **/\r
 BOOLEAN\r
 IsRootPciHotPlugController (\r
@@ -115,10 +115,10 @@ IsRootPciHotPlugController (
 /**\r
   Wrapper for creating event object for HPC \r
   \r
 /**\r
   Wrapper for creating event object for HPC \r
   \r
-  @param  HpIndex   index of hot plug device in global array\r
-  @param  Event     event object\r
+  @param  HpIndex   index of hot plug device in global array.\r
+  @param  Event     event object.\r
   \r
   \r
-  @return status of create event invoken\r
+  @return status of create event invoken.\r
 **/\r
 EFI_STATUS\r
 CreateEventForHpc (\r
 **/\r
 EFI_STATUS\r
 CreateEventForHpc (\r
@@ -129,7 +129,7 @@ CreateEventForHpc (
 /**\r
   Wait for all root HPC initialized.\r
   \r
 /**\r
   Wait for all root HPC initialized.\r
   \r
-  @param TimeoutInMicroSeconds  microseconds to wait for all root hpc's initialization\r
+  @param TimeoutInMicroSeconds  microseconds to wait for all root hpc's initialization.\r
 **/\r
 EFI_STATUS\r
 AllRootHPCInitialized (\r
 **/\r
 EFI_STATUS\r
 AllRootHPCInitialized (\r
@@ -139,10 +139,10 @@ AllRootHPCInitialized (
 /**\r
   Check HPC capability register block\r
   \r
 /**\r
   Check HPC capability register block\r
   \r
-  @param PciIoDevice PCI device instance\r
+  @param PciIoDevice PCI device instance.\r
   \r
   \r
-  @retval EFI_SUCCESS   PCI device is HPC\r
-  @retval EFI_NOT_FOUND PCI device is not HPC\r
+  @retval EFI_SUCCESS   PCI device is HPC.\r
+  @retval EFI_NOT_FOUND PCI device is not HPC.\r
 **/\r
 EFI_STATUS\r
 IsSHPC (\r
 **/\r
 EFI_STATUS\r
 IsSHPC (\r
@@ -152,9 +152,9 @@ IsSHPC (
 /**\r
   Get resource padding for hot plug bus\r
   \r
 /**\r
   Get resource padding for hot plug bus\r
   \r
-  @param PciIoDevice PCI device instance\r
+  @param PciIoDevice PCI device instance.\r
   \r
   \r
-  @retval EFI_SUCCESS   success get padding and set it into PCI device instance\r
+  @retval EFI_SUCCESS   success get padding and set it into PCI device instance.\r
   @retval EFI_NOT_FOUND PCI device is not a hot plug bus.\r
 **/\r
 EFI_STATUS\r
   @retval EFI_NOT_FOUND PCI device is not a hot plug bus.\r
 **/\r
 EFI_STATUS\r
index 6530899c8db3a3249d3a06c50eae8b8c1f7230bc..68e507aceb7c84428100cb52f1ec59d277a23357 100644 (file)
@@ -831,7 +831,7 @@ PciIoMap (
     return EFI_INVALID_PARAMETER;\r
   }\r
 \r
     return EFI_INVALID_PARAMETER;\r
   }\r
 \r
-  if (PciIoDevice->Attributes & EFI_PCI_IO_ATTRIBUTE_DUAL_ADDRESS_CYCLE) {\r
+  if ((PciIoDevice->Attributes & EFI_PCI_IO_ATTRIBUTE_DUAL_ADDRESS_CYCLE) != 0) {\r
     Operation = (EFI_PCI_IO_PROTOCOL_OPERATION) (Operation + EfiPciOperationBusMasterRead64);\r
   }\r
 \r
     Operation = (EFI_PCI_IO_PROTOCOL_OPERATION) (Operation + EfiPciOperationBusMasterRead64);\r
   }\r
 \r
@@ -919,14 +919,14 @@ PciIoAllocateBuffer (
   EFI_STATUS    Status;\r
   PCI_IO_DEVICE *PciIoDevice;\r
 \r
   EFI_STATUS    Status;\r
   PCI_IO_DEVICE *PciIoDevice;\r
 \r
-  if (Attributes &\r
-      (~(EFI_PCI_ATTRIBUTE_MEMORY_WRITE_COMBINE | EFI_PCI_ATTRIBUTE_MEMORY_CACHED))) {\r
+  if ((Attributes &\r
+      (~(EFI_PCI_ATTRIBUTE_MEMORY_WRITE_COMBINE | EFI_PCI_ATTRIBUTE_MEMORY_CACHED))) != 0){\r
     return EFI_UNSUPPORTED;\r
   }\r
 \r
   PciIoDevice = PCI_IO_DEVICE_FROM_PCI_IO_THIS (This);\r
 \r
     return EFI_UNSUPPORTED;\r
   }\r
 \r
   PciIoDevice = PCI_IO_DEVICE_FROM_PCI_IO_THIS (This);\r
 \r
-  if (PciIoDevice->Attributes & EFI_PCI_IO_ATTRIBUTE_DUAL_ADDRESS_CYCLE) {\r
+  if ((PciIoDevice->Attributes & EFI_PCI_IO_ATTRIBUTE_DUAL_ADDRESS_CYCLE) != 0) {\r
     Attributes |= EFI_PCI_ATTRIBUTE_DUAL_ADDRESS_CYCLE;\r
   }\r
 \r
     Attributes |= EFI_PCI_ATTRIBUTE_DUAL_ADDRESS_CYCLE;\r
   }\r
 \r
@@ -1146,7 +1146,7 @@ ModifyRootBridgeAttributes (
   //\r
   // Call the PCI Root Bridge to attempt to modify the attributes\r
   //\r
   //\r
   // Call the PCI Root Bridge to attempt to modify the attributes\r
   //\r
-  if (NewPciRootBridgeAttributes ^ PciRootBridgeAttributes) {\r
+  if ((NewPciRootBridgeAttributes ^ PciRootBridgeAttributes) != 0) {\r
 \r
     Status = PciIoDevice->PciRootBridgeIo->SetAttributes (\r
                                             PciIoDevice->PciRootBridgeIo,\r
 \r
     Status = PciIoDevice->PciRootBridgeIo->SetAttributes (\r
                                             PciIoDevice->PciRootBridgeIo,\r
@@ -1200,7 +1200,7 @@ SupportPaletteSnoopAttributes (
   //\r
   Temp = ActiveVGADeviceOnTheSameSegment (PciIoDevice);\r
 \r
   //\r
   Temp = ActiveVGADeviceOnTheSameSegment (PciIoDevice);\r
 \r
-  if (!Temp) {\r
+  if (Temp == NULL) {\r
     //\r
     // If there is no VGA device on the segement, set\r
     // this graphics card to decode the palette range\r
     //\r
     // If there is no VGA device on the segement, set\r
     // this graphics card to decode the palette range\r
@@ -1228,7 +1228,7 @@ SupportPaletteSnoopAttributes (
     // If they are on the same bus, either one can\r
     // be set to snoop, the other set to decode\r
     //\r
     // If they are on the same bus, either one can\r
     // be set to snoop, the other set to decode\r
     //\r
-    if (VGACommand & EFI_PCI_COMMAND_VGA_PALETTE_SNOOP) {\r
+    if ((VGACommand & EFI_PCI_COMMAND_VGA_PALETTE_SNOOP) != 0) {\r
       //\r
       // VGA has set to snoop, so GFX can be only set to disable snoop\r
       //\r
       //\r
       // VGA has set to snoop, so GFX can be only set to disable snoop\r
       //\r
@@ -1399,7 +1399,7 @@ PciIoAttributes (
   //\r
   // For Root Bridge, just call RootBridgeIo to set attributes;\r
   //\r
   //\r
   // For Root Bridge, just call RootBridgeIo to set attributes;\r
   //\r
-  if (!PciIoDevice->Parent) {\r
+  if (PciIoDevice->Parent == NULL) {\r
     Status = ModifyRootBridgeAttributes (PciIoDevice, Attributes, Operation);\r
     return Status;\r
   }\r
     Status = ModifyRootBridgeAttributes (PciIoDevice, Attributes, Operation);\r
     return Status;\r
   }\r
@@ -1410,14 +1410,14 @@ PciIoAttributes (
   //\r
   // Check VGA and VGA16, they can not be set at the same time\r
   //\r
   //\r
   // Check VGA and VGA16, they can not be set at the same time\r
   //\r
-  if (((Attributes & EFI_PCI_IO_ATTRIBUTE_VGA_IO)         &&\r
-       (Attributes & EFI_PCI_IO_ATTRIBUTE_VGA_IO_16))         ||\r
-      ((Attributes & EFI_PCI_IO_ATTRIBUTE_VGA_IO)         &&\r
-       (Attributes & EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO_16)) ||\r
-      ((Attributes & EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO) &&\r
-       (Attributes & EFI_PCI_IO_ATTRIBUTE_VGA_IO_16))         ||\r
-      ((Attributes & EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO) &&\r
-       (Attributes & EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO_16)) ) {\r
+  if (((Attributes & EFI_PCI_IO_ATTRIBUTE_VGA_IO) != 0         &&\r
+       (Attributes & EFI_PCI_IO_ATTRIBUTE_VGA_IO_16) != 0)         ||\r
+      ((Attributes & EFI_PCI_IO_ATTRIBUTE_VGA_IO) != 0         &&\r
+       (Attributes & EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO_16) != 0) ||\r
+      ((Attributes & EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO) != 0 &&\r
+       (Attributes & EFI_PCI_IO_ATTRIBUTE_VGA_IO_16) != 0)         ||\r
+      ((Attributes & EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO) != 0 &&\r
+       (Attributes & EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO_16) != 0) ) {\r
     return EFI_UNSUPPORTED;\r
   }\r
 \r
     return EFI_UNSUPPORTED;\r
   }\r
 \r
@@ -1426,19 +1426,19 @@ PciIoAttributes (
   //\r
   if (IS_PCI_BRIDGE (&PciIoDevice->Pci) || IS_CARDBUS_BRIDGE (&PciIoDevice->Pci)) {\r
 \r
   //\r
   if (IS_PCI_BRIDGE (&PciIoDevice->Pci) || IS_CARDBUS_BRIDGE (&PciIoDevice->Pci)) {\r
 \r
-    if (Attributes & (EFI_PCI_IO_ATTRIBUTE_VGA_IO | EFI_PCI_IO_ATTRIBUTE_VGA_IO_16)) {\r
+    if ((Attributes & (EFI_PCI_IO_ATTRIBUTE_VGA_IO | EFI_PCI_IO_ATTRIBUTE_VGA_IO_16)) != 0) {\r
       BridgeControl |= EFI_PCI_BRIDGE_CONTROL_VGA;\r
     }\r
 \r
       BridgeControl |= EFI_PCI_BRIDGE_CONTROL_VGA;\r
     }\r
 \r
-    if (Attributes & EFI_PCI_IO_ATTRIBUTE_ISA_IO) {\r
+    if ((Attributes & EFI_PCI_IO_ATTRIBUTE_ISA_IO) != 0) {\r
       BridgeControl |= EFI_PCI_BRIDGE_CONTROL_ISA;\r
     }\r
 \r
       BridgeControl |= EFI_PCI_BRIDGE_CONTROL_ISA;\r
     }\r
 \r
-    if (Attributes & (EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO | EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO_16)) {\r
+    if ((Attributes & (EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO | EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO_16)) != 0) {\r
       Command |= EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO;\r
     }\r
 \r
       Command |= EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO;\r
     }\r
 \r
-    if (Attributes & (EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO_16 | EFI_PCI_IO_ATTRIBUTE_VGA_IO_16)) {\r
+    if ((Attributes & (EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO_16 | EFI_PCI_IO_ATTRIBUTE_VGA_IO_16)) != 0) {\r
       BridgeControl |= EFI_PCI_BRIDGE_CONTROL_VGA_16;\r
     }\r
 \r
       BridgeControl |= EFI_PCI_BRIDGE_CONTROL_VGA_16;\r
     }\r
 \r
@@ -1447,10 +1447,10 @@ PciIoAttributes (
     // Do with the attributes on VGA\r
     // Only for VGA's legacy resource, we just can enable once.\r
     //\r
     // Do with the attributes on VGA\r
     // Only for VGA's legacy resource, we just can enable once.\r
     //\r
-    if (Attributes &\r
+    if ((Attributes &\r
         (EFI_PCI_IO_ATTRIBUTE_VGA_IO    |\r
          EFI_PCI_IO_ATTRIBUTE_VGA_IO_16 |\r
         (EFI_PCI_IO_ATTRIBUTE_VGA_IO    |\r
          EFI_PCI_IO_ATTRIBUTE_VGA_IO_16 |\r
-         EFI_PCI_IO_ATTRIBUTE_VGA_MEMORY)) {\r
+         EFI_PCI_IO_ATTRIBUTE_VGA_MEMORY)) != 0) {\r
       //\r
       // Check if a VGA has been enabled before enabling a new one\r
       //\r
       //\r
       // Check if a VGA has been enabled before enabling a new one\r
       //\r
@@ -1471,7 +1471,7 @@ PciIoAttributes (
     //\r
     // Do with the attributes on GFX\r
     //\r
     //\r
     // Do with the attributes on GFX\r
     //\r
-    if (Attributes & (EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO | EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO_16)) {\r
+    if ((Attributes & (EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO | EFI_PCI_IO_ATTRIBUTE_VGA_PALETTE_IO_16)) != 0) {\r
 \r
       if (Operation == EfiPciIoAttributeOperationEnable) {\r
         //\r
 \r
       if (Operation == EfiPciIoAttributeOperationEnable) {\r
         //\r
@@ -1501,15 +1501,15 @@ PciIoAttributes (
     }\r
   }\r
 \r
     }\r
   }\r
 \r
-  if (Attributes & EFI_PCI_IO_ATTRIBUTE_IO) {\r
+  if ((Attributes & EFI_PCI_IO_ATTRIBUTE_IO) != 0) {\r
     Command |= EFI_PCI_COMMAND_IO_SPACE;\r
   }\r
 \r
     Command |= EFI_PCI_COMMAND_IO_SPACE;\r
   }\r
 \r
-  if (Attributes & EFI_PCI_IO_ATTRIBUTE_MEMORY) {\r
+  if ((Attributes & EFI_PCI_IO_ATTRIBUTE_MEMORY) != 0) {\r
     Command |= EFI_PCI_COMMAND_MEMORY_SPACE;\r
   }\r
 \r
     Command |= EFI_PCI_COMMAND_MEMORY_SPACE;\r
   }\r
 \r
-  if (Attributes & EFI_PCI_IO_ATTRIBUTE_BUS_MASTER) {\r
+  if ((Attributes & EFI_PCI_IO_ATTRIBUTE_BUS_MASTER) != 0) {\r
     Command |= EFI_PCI_COMMAND_BUS_MASTER;\r
   }\r
   //\r
     Command |= EFI_PCI_COMMAND_BUS_MASTER;\r
   }\r
   //\r
index f1ac6ed58c8e2b295a3addf7451b96a55e3c3809..18a27e69336668cb72f150677736178a71cc35e0 100644 (file)
@@ -1,4 +1,4 @@
-/**@file\r
+/** @file\r
 \r
 Copyright (c) 2006, Intel Corporation                                                         \r
 All rights reserved. This program and the accompanying materials                          \r
 \r
 Copyright (c) 2006, Intel Corporation                                                         \r
 All rights reserved. This program and the accompanying materials                          \r
@@ -59,9 +59,9 @@ PciIoVerifyBarAccess (
   @param Count        The number of memory or I/O operations to perform.\r
   @param Offset       The offset within the PCI configuration space for the PCI controller.\r
 \r
   @param Count        The number of memory or I/O operations to perform.\r
   @param Offset       The offset within the PCI configuration space for the PCI controller.\r
 \r
-  @retval EFI_INVALID_PARAMETER  Invalid Width\r
-  @retval EFI_UNSUPPORTED        Offset overflow\r
-  @retval EFI_SUCCESS            Success operation\r
+  @retval EFI_INVALID_PARAMETER  Invalid Width.\r
+  @retval EFI_UNSUPPORTED        Offset overflow.\r
+  @retval EFI_SUCCESS            Success operation.\r
 **/\r
 EFI_STATUS\r
 PciIoVerifyConfigAccess (\r
 **/\r
 EFI_STATUS\r
 PciIoVerifyConfigAccess (\r
index 0a6b0d07e5f1876f789bc816e7cdbe60737079ba..d7f7cc77eaac98ac492dfa66c982ef269d0e6509 100644 (file)
@@ -1,4 +1,4 @@
-/**@file\r
+/** @file\r
 \r
   PCI Bus Driver Lib file\r
   It abstracts some functions that can be different\r
 \r
   PCI Bus Driver Lib file\r
   It abstracts some functions that can be different\r
@@ -217,7 +217,7 @@ RemoveRejectedPciDevices (
 \r
   CurrentLink = Bridge->ChildList.ForwardLink;\r
 \r
 \r
   CurrentLink = Bridge->ChildList.ForwardLink;\r
 \r
-  while (CurrentLink && CurrentLink != &Bridge->ChildList) {\r
+  while (CurrentLink != NULL && CurrentLink != &Bridge->ChildList) {\r
 \r
     Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
 \r
 \r
     Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
 \r
@@ -650,7 +650,6 @@ PciHostBridgeResourceAllocator_WithoutHotPlugDeviceSupport (
 \r
   @retval EFI_SUCCESS           Success\r
 **/\r
 \r
   @retval EFI_SUCCESS           Success\r
 **/\r
-\r
 EFI_STATUS\r
 PciHostBridgeResourceAllocator_WithHotPlugDeviceSupport (\r
   IN EFI_PCI_HOST_BRIDGE_RESOURCE_ALLOCATION_PROTOCOL *PciResAlloc\r
 EFI_STATUS\r
 PciHostBridgeResourceAllocator_WithHotPlugDeviceSupport (\r
   IN EFI_PCI_HOST_BRIDGE_RESOURCE_ALLOCATION_PROTOCOL *PciResAlloc\r
@@ -1605,8 +1604,8 @@ PciScanBus_WithHotPlugDeviceSupport (
           // Ensure the device is enabled and initialized\r
           //\r
           if ((Attributes == EfiPaddingPciRootBridge) &&\r
           // Ensure the device is enabled and initialized\r
           //\r
           if ((Attributes == EfiPaddingPciRootBridge) &&\r
-              (State & EFI_HPC_STATE_ENABLED)         &&\r
-              (State & EFI_HPC_STATE_INITIALIZED)     ) {\r
+              (State & EFI_HPC_STATE_ENABLED) != 0    &&\r
+              (State & EFI_HPC_STATE_INITIALIZED) != 0) {\r
             *PaddedBusRange = (UINT8) ((UINT8) (BusRange) +*PaddedBusRange);\r
           } else {\r
             *SubBusNumber = (UINT8) ((UINT8) (BusRange) +*SubBusNumber);\r
             *PaddedBusRange = (UINT8) ((UINT8) (BusRange) +*PaddedBusRange);\r
           } else {\r
             *SubBusNumber = (UINT8) ((UINT8) (BusRange) +*SubBusNumber);\r
@@ -1662,13 +1661,13 @@ PciRootBridgeP2CProcess (
 \r
   CurrentLink = Bridge->ChildList.ForwardLink;\r
 \r
 \r
   CurrentLink = Bridge->ChildList.ForwardLink;\r
 \r
-  while (CurrentLink && CurrentLink != &Bridge->ChildList) {\r
+  while (CurrentLink != NULL && CurrentLink != &Bridge->ChildList) {\r
 \r
     Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
 \r
     if (IS_CARDBUS_BRIDGE (&Temp->Pci)) {\r
 \r
 \r
     Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
 \r
     if (IS_CARDBUS_BRIDGE (&Temp->Pci)) {\r
 \r
-      if (gPciHotPlugInit && Temp->Allocated) {\r
+      if (gPciHotPlugInit != NULL && Temp->Allocated) {\r
 \r
         //\r
         // Raise the EFI_IOB_PCI_HPC_INIT status code\r
 \r
         //\r
         // Raise the EFI_IOB_PCI_HPC_INIT status code\r
index 80c3af6c6cf94abd7c4b3e4fa22e00f7f0a4e1d4..4a79ad115868dfe0a4cd137df4c604dd04ee2631 100644 (file)
@@ -53,7 +53,7 @@ typedef struct {
   Install protocol gEfiPciHotPlugRequestProtocolGuid\r
   @param Status    return status of protocol installation.\r
 **/\r
   Install protocol gEfiPciHotPlugRequestProtocolGuid\r
   @param Status    return status of protocol installation.\r
 **/\r
-void\r
+VOID\r
 InstallHotPlugRequestProtocol (\r
   IN  EFI_STATUS                    *Status\r
   );\r
 InstallHotPlugRequestProtocol (\r
   IN  EFI_STATUS                    *Status\r
   );\r
index d8ebadf64b0ab28ee45528ebcad3c32da1e0744b..ab641e6691785aca00150f938d3572897a1ee01c 100644 (file)
@@ -215,7 +215,7 @@ CalculateApertureIo16 (
 \r
   Aperture = 0;\r
 \r
 \r
   Aperture = 0;\r
 \r
-  if (!Bridge) {\r
+  if (Bridge == NULL) {\r
     return EFI_SUCCESS;\r
   }\r
 \r
     return EFI_SUCCESS;\r
   }\r
 \r
@@ -233,7 +233,7 @@ CalculateApertureIo16 (
     //\r
     offset = Aperture & (Node->Alignment);\r
 \r
     //\r
     offset = Aperture & (Node->Alignment);\r
 \r
-    if (offset) {\r
+    if (offset != 0) {\r
 \r
       Aperture = Aperture + (Node->Alignment + 1) - offset;\r
 \r
 \r
       Aperture = Aperture + (Node->Alignment + 1) - offset;\r
 \r
@@ -257,7 +257,7 @@ CalculateApertureIo16 (
             Node->Length               \r
             );\r
           offset = Aperture & (Node->Alignment);\r
             Node->Length               \r
             );\r
           offset = Aperture & (Node->Alignment);\r
-          if (offset) {\r
+          if (offset != 0) {\r
             Aperture = Aperture + (Node->Alignment + 1) - offset;\r
           }\r
         } else if (VGAEnable) {\r
             Aperture = Aperture + (Node->Alignment + 1) - offset;\r
           }\r
         } else if (VGAEnable) {\r
@@ -266,7 +266,7 @@ CalculateApertureIo16 (
             Node->Length\r
             );\r
           offset = Aperture & (Node->Alignment);\r
             Node->Length\r
             );\r
           offset = Aperture & (Node->Alignment);\r
-          if (offset) {\r
+          if (offset != 0) {\r
             Aperture = Aperture + (Node->Alignment + 1) - offset;\r
           }\r
         }\r
             Aperture = Aperture + (Node->Alignment + 1) - offset;\r
           }\r
         }\r
@@ -289,7 +289,7 @@ CalculateApertureIo16 (
   //\r
   offset = Aperture & (Bridge->Alignment);\r
 \r
   //\r
   offset = Aperture & (Bridge->Alignment);\r
 \r
-  if (offset) {\r
+  if (offset != 0) {\r
     Aperture = Aperture + (Bridge->Alignment + 1) - offset;\r
   }\r
 \r
     Aperture = Aperture + (Bridge->Alignment + 1) - offset;\r
   }\r
 \r
@@ -330,7 +330,7 @@ CalculateResourceAperture (
 \r
   Aperture = 0;\r
 \r
 \r
   Aperture = 0;\r
 \r
-  if (!Bridge) {\r
+  if (Bridge == NULL) {\r
     return EFI_SUCCESS;\r
   }\r
 \r
     return EFI_SUCCESS;\r
   }\r
 \r
@@ -353,7 +353,7 @@ CalculateResourceAperture (
         \r
     offset = Aperture & (Node->Alignment);\r
 \r
         \r
     offset = Aperture & (Node->Alignment);\r
 \r
-    if (offset) {\r
+    if (offset != 0) {\r
 \r
       Aperture = Aperture + (Node->Alignment + 1) - offset;\r
 \r
 \r
       Aperture = Aperture + (Node->Alignment + 1) - offset;\r
 \r
@@ -382,7 +382,7 @@ CalculateResourceAperture (
   // alignment\r
   //\r
   offset = Aperture & (Bridge->Alignment);\r
   // alignment\r
   //\r
   offset = Aperture & (Bridge->Alignment);\r
-  if (offset) {\r
+  if (offset != 0) {\r
     Aperture = Aperture + (Bridge->Alignment + 1) - offset;\r
   }\r
 \r
     Aperture = Aperture + (Bridge->Alignment + 1) - offset;\r
   }\r
 \r
@@ -634,7 +634,7 @@ CreateResourceMap (
 \r
   CurrentLink = Bridge->ChildList.ForwardLink;\r
 \r
 \r
   CurrentLink = Bridge->ChildList.ForwardLink;\r
 \r
-  while (CurrentLink && CurrentLink != &Bridge->ChildList) {\r
+  while (CurrentLink != NULL && CurrentLink != &Bridge->ChildList) {\r
 \r
     Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
 \r
 \r
     Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
 \r
@@ -923,7 +923,7 @@ DegradeResource (
   // \r
   HasOprom = FALSE;\r
   CurrentLink = Bridge->ChildList.ForwardLink;\r
   // \r
   HasOprom = FALSE;\r
   CurrentLink = Bridge->ChildList.ForwardLink;\r
-  while (CurrentLink && CurrentLink != &Bridge->ChildList) {\r
+  while (CurrentLink != NULL && CurrentLink != &Bridge->ChildList) {\r
 \r
     Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
     if (Temp->RomSize != 0) {\r
 \r
     Temp = PCI_IO_DEVICE_FROM_LINK (CurrentLink);\r
     if (Temp->RomSize != 0) {\r
@@ -1021,7 +1021,7 @@ BridgeSupportResourceDecode (
   )\r
 {\r
 \r
   )\r
 {\r
 \r
-  if ((Bridge->Decodes) & Decode) {\r
+  if (((Bridge->Decodes) & Decode) != 0) {\r
     return TRUE;\r
   }\r
 \r
     return TRUE;\r
   }\r
 \r
@@ -1362,7 +1362,7 @@ ProgrameUpstreamBridgeForRom (
   //\r
   Parent = PciDevice->Parent;\r
   ZeroMem (&Node, sizeof (Node));\r
   //\r
   Parent = PciDevice->Parent;\r
   ZeroMem (&Node, sizeof (Node));\r
-  while (Parent) {\r
+  while (Parent != NULL) {\r
     if (!IS_PCI_BRIDGE (&Parent->Pci)) {\r
       break;\r
     }\r
     if (!IS_PCI_BRIDGE (&Parent->Pci)) {\r
       break;\r
     }\r
@@ -2128,7 +2128,7 @@ GetResourcePaddingPpb (
   IN  PCI_IO_DEVICE                  *PciIoDevice\r
   )\r
 {\r
   IN  PCI_IO_DEVICE                  *PciIoDevice\r
   )\r
 {\r
-  if (gPciHotPlugInit) {\r
+  if (gPciHotPlugInit != NULL) {\r
     if (PciIoDevice->ResourcePaddingDescriptors == NULL) {\r
       GetResourcePaddingForHpb (PciIoDevice);\r
     }\r
     if (PciIoDevice->ResourcePaddingDescriptors == NULL) {\r
       GetResourcePaddingForHpb (PciIoDevice);\r
     }\r