audk/OvmfPkg/PciHostBridgeDxe
Laszlo Ersek 7ee9dc2321 OvmfPkg: PciHostBridgeDxe: release resources on driver entry failure
The entry point of the driver, InitializePciHostBridge(), leaks resources
(and installed protocols) in the following cases:

- The first root bridge protocol installation fails. In this case, the
  host bridge protocol is left installed, but the driver exits with an
  error.

- The second or a later root bridge protocol installation fails. In this
  case, the host bridge protocol, and all prior root bridge protocols, are
  left installed, even though the driver exits with an error.

Handle errors correctly: roll back / release / uninstall resources when
aborting the driver.

Cc: Jordan Justen <jordan.l.justen@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Regression-tested-by: Gabriel Somlo <somlo@cmu.edu>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@17959 6f19259b-4bc3-4df7-8a09-765794883524
2015-07-14 12:02:15 +00:00
..
Ia32 OvmfPkg: clone PciHostBridgeDxe from PcAtChipsetPkg 2015-07-14 12:01:36 +00:00
X64 OvmfPkg: clone PciHostBridgeDxe from PcAtChipsetPkg 2015-07-14 12:01:36 +00:00
IoFifo.h OvmfPkg: clone PciHostBridgeDxe from PcAtChipsetPkg 2015-07-14 12:01:36 +00:00
PciHostBridge.c OvmfPkg: PciHostBridgeDxe: release resources on driver entry failure 2015-07-14 12:02:15 +00:00
PciHostBridge.h OvmfPkg: PciHostBridgeDxe: embed device path in private root bridge struct 2015-07-14 12:02:06 +00:00
PciHostBridgeDxe.inf OvmfPkg: clone PciHostBridgeDxe from PcAtChipsetPkg 2015-07-14 12:01:36 +00:00
PciRootBridgeIo.c OvmfPkg: clone PciHostBridgeDxe from PcAtChipsetPkg 2015-07-14 12:01:36 +00:00