BootloaderCorePkg/Library/PciEnumerationLib/PciEnumerationLib.c
VOID
DumpPciRootBridgeInfoHob (
  VOID
  )
{
  PCI_ROOT_BRIDGE_INFO_HOB    *RootBridgeInfoHob;
  UINT8                        Count;
  UINT8                        Index;

  RootBridgeInfoHob = (PCI_ROOT_BRIDGE_INFO_HOB *) GetGuidHobData (NULL, NULL,
    &gLoaderPciRootBridgeInfoGuid);

  if (RootBridgeInfoHob != NULL) {
    DEBUG ((DEBUG_INFO, "PciRootBridgeInfoHob: Rev 0x%X, Count 0x%X\n",
      RootBridgeInfoHob->Revision, RootBridgeInfoHob->Count));

    for (Count = 0; Count < RootBridgeInfoHob->Count; Count++) {
      DEBUG ((DEBUG_INFO, "Bus(0x%02X-%02X)\n",
        RootBridgeInfoHob->Entry[Count].BusBase,
        RootBridgeInfoHob->Entry[Count].BusLimit));

      for (Index = 0; Index < PCI_MAX_BAR; Index++) {
        if (RootBridgeInfoHob->Entry[Count].Resource[Index].ResLength > 0) {
          DEBUG ((DEBUG_INFO, "  BarType-%d: Base 0x%016lX Length 0x%016lX\n",
            Index + 1,
            RootBridgeInfoHob->Entry[Count].Resource[Index].ResBase,
            RootBridgeInfoHob->Entry[Count].Resource[Index].ResLength));
        }
      }
    }
  }
}
/**
  Dump PCI Root Bridge Info Hob

**/
Dump PCI Root Bridge Info Hob
Dump PCI Root Bridge Info Hob
VOID
DumpPciRootBridgeInfoHob (
  VOID
  )
{
  PCI_ROOT_BRIDGE_INFO_HOB    *RootBridgeInfoHob;
  UINT8                        Count;
  UINT8                        Index;
  RootBridgeInfoHob = (PCI_ROOT_BRIDGE_INFO_HOB *) GetGuidHobData (NULL, NULL,
    &gLoaderPciRootBridgeInfoGuid);
  if (RootBridgeInfoHob != NULL) {
    DEBUG ((DEBUG_INFO, "PciRootBridgeInfoHob: Rev 0x%X, Count 0x%X\n",
      RootBridgeInfoHob->Revision, RootBridgeInfoHob->Count));
    for (Count = 0; Count < RootBridgeInfoHob->Count; Count++) {
      DEBUG ((DEBUG_INFO, "Bus(0x%02X-%02X)\n",
        RootBridgeInfoHob->Entry[Count].BusBase,
        RootBridgeInfoHob->Entry[Count].BusLimit));
      for (Index = 0; Index < PCI_MAX_BAR; Index++) {
        if (RootBridgeInfoHob->Entry[Count].Resource[Index].ResLength > 0) {
          DEBUG ((DEBUG_INFO, "  BarType-%d: Base 0x%016lX Length 0x%016lX\n",
            Index + 1,
            RootBridgeInfoHob->Entry[Count].Resource[Index].ResBase,
            RootBridgeInfoHob->Entry[Count].Resource[Index].ResLength));
        }
      }
    }
  }
}
VOID DumpPciRootBridgeInfoHob ( VOID ) { PCI_ROOT_BRIDGE_INFO_HOB * RootBridgeInfoHob ; UINT8 Count ; UINT8 Index ; RootBridgeInfoHob = ( PCI_ROOT_BRIDGE_INFO_HOB * ) GetGuidHobData ( NULL , NULL , & gLoaderPciRootBridgeInfoGuid ) ; if ( RootBridgeInfoHob != NULL ) { DEBUG ( ( DEBUG_INFO , " \n " , RootBridgeInfoHob -> Revision , RootBridgeInfoHob -> Count ) ) ; for ( Count = 0 ; Count < RootBridgeInfoHob -> Count ; Count ++ ) { DEBUG ( ( DEBUG_INFO , " \n " , RootBridgeInfoHob -> Entry [ Count ] . BusBase , RootBridgeInfoHob -> Entry [ Count ] . BusLimit ) ) ; for ( Index = 0 ; Index < PCI_MAX_BAR ; Index ++ ) { if ( RootBridgeInfoHob -> Entry [ Count ] . Resource [ Index ] . ResLength > 0 ) { DEBUG ( ( DEBUG_INFO , " \n " , Index + 1 , RootBridgeInfoHob -> Entry [ Count ] . Resource [ Index ] . ResBase , RootBridgeInfoHob -> Entry [ Count ] . Resource [ Index ] . ResLength ) ) ; } } } } }
Dump PCI Root Bridge Info Hob
Dump PCI Root Bridge Info Hob