[edk2] [PATCH 0/3] MdeModulePkg/PciBus: Fix bug that doesn't produce BusOverride

Ruiyu Ni posted 3 patches 6 years, 5 months ago
Failed in applying to current master (apply log)
MdeModulePkg/Bus/Pci/PciBusDxe/PciBus.h            |   7 +-
MdeModulePkg/Bus/Pci/PciBusDxe/PciBusDxe.inf       |   3 +-
MdeModulePkg/Bus/Pci/PciBusDxe/PciDeviceSupport.c  |   4 +-
MdeModulePkg/Bus/Pci/PciBusDxe/PciDriverOverride.c | 147 ++++++++++++++-------
MdeModulePkg/Bus/Pci/PciBusDxe/PciDriverOverride.h |  17 ++-
.../Bus/Pci/PciBusDxe/PciOptionRomSupport.c        |  21 ++-
MdeModulePkg/Bus/Pci/PciBusDxe/PciRomTable.c       |  99 ++++++++------
MdeModulePkg/Bus/Pci/PciBusDxe/PciRomTable.h       |  10 +-
8 files changed, 190 insertions(+), 118 deletions(-)
[edk2] [PATCH 0/3] MdeModulePkg/PciBus: Fix bug that doesn't produce BusOverride
Posted by Ruiyu Ni 6 years, 5 months ago
It's a regression of below commit:
SHA-1: 8be37a5cee700777ca8e8e8a34cc2225b21931a7
* MdeModulePkg/SecurityStubDxe: Defer 3rd party image before EndOfDxe

When PciBus driver fails to load the Option ROM, it doesn't produce
BusOverride protocol. It was a correct behavior before the above
commit. But due to the above commit, BusOverride protocol never is
produced by PciBus driver.

The patch fixes this issue using the following solution:
1. PciBus records the image device path when LoadImage fails.
2. Override.GetDriver() tries to look for the image handle using
   the stored image device path.

Ruiyu Ni (3):
  MdeModulePkg/PciBus: Refine EFI_PCI_ROM_IMAGE_MAPPING
  MdeModulePkg/PciBus: Don't create entry when recording ImageHandle
  MdeModulePkg/PciBus: Fix bug that doesn't produce BusOverride

 MdeModulePkg/Bus/Pci/PciBusDxe/PciBus.h            |   7 +-
 MdeModulePkg/Bus/Pci/PciBusDxe/PciBusDxe.inf       |   3 +-
 MdeModulePkg/Bus/Pci/PciBusDxe/PciDeviceSupport.c  |   4 +-
 MdeModulePkg/Bus/Pci/PciBusDxe/PciDriverOverride.c | 147 ++++++++++++++-------
 MdeModulePkg/Bus/Pci/PciBusDxe/PciDriverOverride.h |  17 ++-
 .../Bus/Pci/PciBusDxe/PciOptionRomSupport.c        |  21 ++-
 MdeModulePkg/Bus/Pci/PciBusDxe/PciRomTable.c       |  99 ++++++++------
 MdeModulePkg/Bus/Pci/PciBusDxe/PciRomTable.h       |  10 +-
 8 files changed, 190 insertions(+), 118 deletions(-)

-- 
2.12.2.windows.2

_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel
Re: [edk2] [PATCH 0/3] MdeModulePkg/PciBus: Fix bug that doesn't produce BusOverride
Posted by Zeng, Star 6 years, 5 months ago
Reviewed-by: Star Zeng <star.zeng@intel.com>

-----Original Message-----
From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of Ruiyu Ni
Sent: Friday, October 27, 2017 2:55 PM
To: edk2-devel@lists.01.org
Subject: [edk2] [PATCH 0/3] MdeModulePkg/PciBus: Fix bug that doesn't produce BusOverride

It's a regression of below commit:
SHA-1: 8be37a5cee700777ca8e8e8a34cc2225b21931a7
* MdeModulePkg/SecurityStubDxe: Defer 3rd party image before EndOfDxe

When PciBus driver fails to load the Option ROM, it doesn't produce BusOverride protocol. It was a correct behavior before the above commit. But due to the above commit, BusOverride protocol never is produced by PciBus driver.

The patch fixes this issue using the following solution:
1. PciBus records the image device path when LoadImage fails.
2. Override.GetDriver() tries to look for the image handle using
   the stored image device path.

Ruiyu Ni (3):
  MdeModulePkg/PciBus: Refine EFI_PCI_ROM_IMAGE_MAPPING
  MdeModulePkg/PciBus: Don't create entry when recording ImageHandle
  MdeModulePkg/PciBus: Fix bug that doesn't produce BusOverride

 MdeModulePkg/Bus/Pci/PciBusDxe/PciBus.h            |   7 +-
 MdeModulePkg/Bus/Pci/PciBusDxe/PciBusDxe.inf       |   3 +-
 MdeModulePkg/Bus/Pci/PciBusDxe/PciDeviceSupport.c  |   4 +-
 MdeModulePkg/Bus/Pci/PciBusDxe/PciDriverOverride.c | 147 ++++++++++++++-------  MdeModulePkg/Bus/Pci/PciBusDxe/PciDriverOverride.h |  17 ++-
 .../Bus/Pci/PciBusDxe/PciOptionRomSupport.c        |  21 ++-
 MdeModulePkg/Bus/Pci/PciBusDxe/PciRomTable.c       |  99 ++++++++------
 MdeModulePkg/Bus/Pci/PciBusDxe/PciRomTable.h       |  10 +-
 8 files changed, 190 insertions(+), 118 deletions(-)

--
2.12.2.windows.2

_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel
_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel