]> git.proxmox.com Git - mirror_edk2.git/blobdiff - IntelFrameworkModulePkg/Bus/Pci/PciBusDxe/PciDeviceSupport.h
fixed ECC and Klocwork issues.
[mirror_edk2.git] / IntelFrameworkModulePkg / Bus / Pci / PciBusDxe / PciDeviceSupport.h
index 41251ef3aba11e4b6eea02a2c3cb5c6459606928..af162dc198c3423323545af182abb70c03a0b4ae 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
@@ -11,17 +11,16 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
 \r
 **/\r
 \r
-#ifndef _EFI_PCI_DEVICE_SUPPORT_H\r
-#define _EFI_PCI_DEVICE_SUPPORT_H\r
+#ifndef _EFI_PCI_DEVICE_SUPPORT_H_\r
+#define _EFI_PCI_DEVICE_SUPPORT_H_\r
 \r
 /**\r
-  Initialize the gPciDevicePool\r
+  Initialize the gPciDevicePool.\r
 **/\r
 EFI_STATUS\r
 InitializePciDevicePool (\r
   VOID\r
-  )\r
-;\r
+  );\r
 \r
 /**\r
   Insert a root bridge into PCI device pool\r
@@ -32,8 +31,7 @@ InitializePciDevicePool (
 EFI_STATUS\r
 InsertRootBridge (\r
   PCI_IO_DEVICE *RootBridge\r
-  )\r
-;\r
+  );\r
 \r
 /**\r
   This function is used to insert a PCI device node under\r
@@ -47,8 +45,7 @@ EFI_STATUS
 InsertPciDevice (\r
   PCI_IO_DEVICE *Bridge,\r
   PCI_IO_DEVICE *PciDeviceNode\r
-  )\r
-;\r
+  );\r
 \r
 /**\r
   Destroy root bridge and remove it from deivce tree.\r
@@ -59,8 +56,7 @@ InsertPciDevice (
 EFI_STATUS\r
 DestroyRootBridge (\r
   IN PCI_IO_DEVICE *RootBridge\r
-  )\r
-;\r
+  );\r
 \r
 /**\r
   Destroy all the pci device node under the bridge.\r
@@ -72,8 +68,7 @@ DestroyRootBridge (
 EFI_STATUS\r
 DestroyPciDeviceTree (\r
   IN PCI_IO_DEVICE *Bridge\r
-  )\r
-;\r
+  );\r
 \r
 /**\r
   Destroy all device nodes under the root bridge\r
@@ -86,8 +81,7 @@ DestroyPciDeviceTree (
 EFI_STATUS\r
 DestroyRootBridgeByHandle (\r
   EFI_HANDLE Controller\r
-  )\r
-;\r
+  );\r
 \r
 /**\r
   This function registers the PCI IO device. It creates a handle for this PCI IO device\r
@@ -107,8 +101,7 @@ RegisterPciDevice (
   IN  EFI_HANDLE                     Controller,\r
   IN  PCI_IO_DEVICE                  *PciIoDevice,\r
   OUT EFI_HANDLE                     *Handle OPTIONAL\r
-  )\r
-;\r
+  );\r
 \r
 /**\r
   This function is used to remove the whole PCI devices from the bridge.\r
@@ -122,8 +115,7 @@ EFI_STATUS
 RemoveAllPciDeviceOnBridge (\r
   EFI_HANDLE               RootBridgeHandle,\r
   PCI_IO_DEVICE            *Bridge\r
-  )\r
-;\r
+  );\r
 \r
 /**\r
 \r
@@ -140,8 +132,7 @@ EFI_STATUS
 DeRegisterPciDevice (\r
   IN  EFI_HANDLE                     Controller,\r
   IN  EFI_HANDLE                     Handle\r
-  )\r
-;\r
+  );\r
 \r
 /**\r
   Start to manage the PCI device on specified the root bridge or PCI-PCI Bridge\r
@@ -165,8 +156,7 @@ StartPciDevicesOnBridge (
   IN EFI_DEVICE_PATH_PROTOCOL            *RemainingDevicePath,\r
   IN OUT UINT8                           *NumberOfChildren,\r
   IN OUT EFI_HANDLE                      *ChildHandleBuffer\r
-  )\r
-;\r
+  );\r
 \r
 /**\r
   Start to manage all the PCI devices it found previously under \r
@@ -178,8 +168,7 @@ StartPciDevicesOnBridge (
 EFI_STATUS\r
 StartPciDevices (\r
   IN EFI_HANDLE                         Controller\r
-  )\r
-;\r
+  );\r
 \r
 /**\r
   Create root bridge device\r
@@ -191,91 +180,91 @@ StartPciDevices (
 PCI_IO_DEVICE *\r
 CreateRootBridge (\r
   IN EFI_HANDLE RootBridgeHandle\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
-  @param RootBridgeHandle    Given root bridge handle\r
+  @param RootBridgeHandle    Given root bridge handle.\r
 \r
-  @return root bridge device instance\r
+  @return root bridge device instance.\r
 **/\r
 PCI_IO_DEVICE *\r
 GetRootBridgeByHandle (\r
   EFI_HANDLE RootBridgeHandle\r
-  )\r
-;\r
+  );\r
 \r
+/**\r
+  Check root bridge device is existed or not.\r
+\r
+  @param RootBridgeHandle    Given root bridge handle.\r
+\r
+  @return root bridge device is existed or not.\r
+**/\r
 BOOLEAN\r
 RootBridgeExisted (\r
   IN EFI_HANDLE RootBridgeHandle\r
-  )\r
-;\r
+  );\r
 \r
 /**\r
-  Judege whether Pci device existed\r
+  Judege whether Pci device existed.\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
-  @return whether Pci device existed\r
+  @return whether Pci device existed.\r
 **/\r
 BOOLEAN\r
 PciDeviceExisted (\r
   IN PCI_IO_DEVICE    *Bridge,\r
   IN PCI_IO_DEVICE    *PciIoDevice\r
-  )\r
-;\r
+  );\r
 \r
 /**\r
-  Active VGA device\r
+  Active VGA device.\r
   \r
-  @param VgaDevice device instance for VGA\r
+  @param VgaDevice device instance for VGA.\r
   \r
-  @return device instance\r
+  @return device instance.\r
 **/\r
 PCI_IO_DEVICE *\r
 ActiveVGADeviceOnTheSameSegment (\r
   IN PCI_IO_DEVICE        *VgaDevice\r
-  )\r
-;\r
+  );\r
 \r
 /**\r
-  Active VGA device on root bridge\r
+  Active VGA device on root bridge.\r
   \r
-  @param RootBridge  Root bridge device instance\r
+  @param RootBridge  Root bridge device instance.\r
   \r
-  @return VGA device instance\r
+  @return VGA device instance.\r
 **/\r
 PCI_IO_DEVICE *\r
 ActiveVGADeviceOnTheRootBridge (\r
   IN PCI_IO_DEVICE        *RootBridge\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
-  @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
   IN  EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL  *PciRootBridgeIo,\r
   IN  EFI_DEVICE_PATH_PROTOCOL         *HpcDevicePath,\r
   OUT UINT64                           *PciAddress\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
@@ -284,8 +273,7 @@ GetHpcPciAddressFromRootBridge (
   IN  PCI_IO_DEVICE                    *RootBridge,\r
   IN  EFI_DEVICE_PATH_PROTOCOL         *RemainingDevicePath,\r
   OUT UINT64                           *PciAddress\r
-  )\r
-;\r
+  );\r
 \r
 /**\r
   Destroy a pci device node.\r
@@ -297,7 +285,6 @@ GetHpcPciAddressFromRootBridge (
 EFI_STATUS\r
 FreePciDevice (\r
   IN PCI_IO_DEVICE *PciIoDevice\r
-  )\r
-;\r
+  );\r
 \r
 #endif\r