mirror of
https://github.com/acidanthera/audk.git
synced 2025-07-29 00:24:07 +02:00
The PCI host bridge can signal failures in its initialization to
the PCI Bus driver through the function call NotifyPhase(). Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Olivier Martin <olivier.martin@arm.com> Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@14483 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
591fb3781a
commit
ea8d98fa9f
@ -82,7 +82,11 @@ PciEnumerator (
|
|||||||
//
|
//
|
||||||
// Notify the pci bus enumeration is about to begin
|
// Notify the pci bus enumeration is about to begin
|
||||||
//
|
//
|
||||||
NotifyPhase (PciResAlloc, EfiPciHostBridgeBeginEnumeration);
|
Status = NotifyPhase (PciResAlloc, EfiPciHostBridgeBeginEnumeration);
|
||||||
|
|
||||||
|
if (EFI_ERROR (Status)) {
|
||||||
|
return Status;
|
||||||
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
// Start the bus allocation phase
|
// Start the bus allocation phase
|
||||||
@ -105,7 +109,11 @@ PciEnumerator (
|
|||||||
//
|
//
|
||||||
// Notify the pci bus enumeration is about to complete
|
// Notify the pci bus enumeration is about to complete
|
||||||
//
|
//
|
||||||
NotifyPhase (PciResAlloc, EfiPciHostBridgeEndEnumeration);
|
Status = NotifyPhase (PciResAlloc, EfiPciHostBridgeEndEnumeration);
|
||||||
|
|
||||||
|
if (EFI_ERROR (Status)) {
|
||||||
|
return Status;
|
||||||
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
// Process P2C
|
// Process P2C
|
||||||
|
@ -759,7 +759,11 @@ PciHostBridgeResourceAllocator (
|
|||||||
//
|
//
|
||||||
// Notify pci bus driver starts to program the resource
|
// Notify pci bus driver starts to program the resource
|
||||||
//
|
//
|
||||||
NotifyPhase (PciResAlloc, EfiPciHostBridgeSetResources);
|
Status = NotifyPhase (PciResAlloc, EfiPciHostBridgeSetResources);
|
||||||
|
|
||||||
|
if (EFI_ERROR (Status)) {
|
||||||
|
return Status;
|
||||||
|
}
|
||||||
|
|
||||||
RootBridgeDev = NULL;
|
RootBridgeDev = NULL;
|
||||||
|
|
||||||
@ -898,9 +902,9 @@ PciHostBridgeResourceAllocator (
|
|||||||
//
|
//
|
||||||
// Notify the resource allocation phase is to end
|
// Notify the resource allocation phase is to end
|
||||||
//
|
//
|
||||||
NotifyPhase (PciResAlloc, EfiPciHostBridgeEndResourceAllocation);
|
Status = NotifyPhase (PciResAlloc, EfiPciHostBridgeEndResourceAllocation);
|
||||||
|
|
||||||
return EFI_SUCCESS;
|
return Status;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -1443,7 +1447,11 @@ PciHostBridgeEnumerator (
|
|||||||
//
|
//
|
||||||
// Notify the bus allocation phase is about to start
|
// Notify the bus allocation phase is about to start
|
||||||
//
|
//
|
||||||
NotifyPhase (PciResAlloc, EfiPciHostBridgeBeginBusAllocation);
|
Status = NotifyPhase (PciResAlloc, EfiPciHostBridgeBeginBusAllocation);
|
||||||
|
|
||||||
|
if (EFI_ERROR (Status)) {
|
||||||
|
return Status;
|
||||||
|
}
|
||||||
|
|
||||||
DEBUG((EFI_D_INFO, "PCI Bus First Scanning\n"));
|
DEBUG((EFI_D_INFO, "PCI Bus First Scanning\n"));
|
||||||
RootBridgeHandle = NULL;
|
RootBridgeHandle = NULL;
|
||||||
@ -1531,7 +1539,11 @@ PciHostBridgeEnumerator (
|
|||||||
//
|
//
|
||||||
// Notify the bus allocation phase is about to start for the 2nd time
|
// Notify the bus allocation phase is about to start for the 2nd time
|
||||||
//
|
//
|
||||||
NotifyPhase (PciResAlloc, EfiPciHostBridgeBeginBusAllocation);
|
Status = NotifyPhase (PciResAlloc, EfiPciHostBridgeBeginBusAllocation);
|
||||||
|
|
||||||
|
if (EFI_ERROR (Status)) {
|
||||||
|
return Status;
|
||||||
|
}
|
||||||
|
|
||||||
DEBUG((EFI_D_INFO, "PCI Bus Second Scanning\n"));
|
DEBUG((EFI_D_INFO, "PCI Bus Second Scanning\n"));
|
||||||
RootBridgeHandle = NULL;
|
RootBridgeHandle = NULL;
|
||||||
@ -1569,7 +1581,11 @@ PciHostBridgeEnumerator (
|
|||||||
//
|
//
|
||||||
// Notify the resource allocation phase is to start
|
// Notify the resource allocation phase is to start
|
||||||
//
|
//
|
||||||
NotifyPhase (PciResAlloc, EfiPciHostBridgeBeginResourceAllocation);
|
Status = NotifyPhase (PciResAlloc, EfiPciHostBridgeBeginResourceAllocation);
|
||||||
|
|
||||||
|
if (EFI_ERROR (Status)) {
|
||||||
|
return Status;
|
||||||
|
}
|
||||||
|
|
||||||
RootBridgeHandle = NULL;
|
RootBridgeHandle = NULL;
|
||||||
while (PciResAlloc->GetNextRootBridge (PciResAlloc, &RootBridgeHandle) == EFI_SUCCESS) {
|
while (PciResAlloc->GetNextRootBridge (PciResAlloc, &RootBridgeHandle) == EFI_SUCCESS) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user