Acidanthera UEFI Development Kit based on EDK II edk2-stable202311
Go to file
Laszlo Ersek 8aba40b792 OvmfPkg: add PciHotPlugInitDxe
After IncompatiblePciDeviceSupportDxe, this is another small driver /
protocol implementation that tweaks the behavior of the PCI bus driver in
edk2.

The protocol is specified in the Platform Init Spec v1.4a, Volume 5,
Chapter 12.6 "PCI Hot Plug PCI Initialization Protocol". This
implementation steers the PCI bus driver to reserve the following
resources ("padding") for each PCI bus, in addition to the BARs of the
devices on that PCI bus:
- 2MB of 64-bit non-prefetchable MMIO aperture,
- 512B of IO port space.

The goal is to reserve room for devices hot-plugged at runtime even if the
bridge receiving the device is empty at boot time.

The 2MB MMIO size is inspired by SeaBIOS. The 512B IO port size is
actually only 1/8th of the PCI spec mandated reservation, but the
specified size of 4096 has proved wasteful (given the limited size of our
IO port space -- see commit bba734ab4c). Especially on Q35, where every
PCIe root port and downstream port qualifies as a separate bridge (capable
of accepting a single device).

Test results for this patch:
- regardless of our request for 64-bit MMIO reservation, it is downgraded
  to 32-bit,
- although we request 512B alignment for the IO port space reservation,
  the next upstream bridge rounds it up to 4096B.

Cc: "Johnson, Brian J." <bjohnson@sgi.com>
Cc: Alex Williamson <alex.williamson@redhat.com>
Cc: Andrew Fish <afish@apple.com>
Cc: Feng Tian <feng.tian@intel.com>
Cc: Jordan Justen <jordan.l.justen@intel.com>
Cc: Marcel Apfelbaum <marcel@redhat.com>
Cc: Michael Kinney <michael.d.kinney@intel.com>
Cc: Ruiyu Ni <ruiyu.ni@intel.com>
Cc: Star Zeng <star.zeng@intel.com>
Suggested-by: Andrew Fish <afish@apple.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Acked-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Ruiyu Ni <Ruiyu.ni@intel.com>
2016-07-13 08:39:50 +02:00
AppPkg AppPkg/.../Python: Clean up and document how to escape the -# option. 2016-01-06 01:00:19 +00:00
ArmPkg ArmPkg: Fix typos in comments 2016-07-11 10:29:44 +08:00
ArmPlatformPkg ArmPlatformPkg: Set Juno debug serial port defaults 2016-07-07 17:55:34 +01:00
ArmVirtPkg ArmVirtPkg: add name GUIDs to FvMain instances 2016-07-12 15:19:42 +02:00
BaseTools BaseTools/GenFds: unbreak Region.PadBuffer 2016-07-12 16:22:28 +02:00
BeagleBoardPkg BeagleBoardPkg: Convert to build FatPkg from source 2016-04-07 20:45:39 +02:00
Conf
CorebootModulePkg CorebootModulePkg: Remove unused PCI non-enumeration drivers 2016-05-27 14:26:16 -07:00
CorebootPayloadPkg CorebootModulePkg/PciHostBridgeLib: Fix PCI 64bit memory BAR size issue 2016-05-27 14:28:37 -07:00
CryptoPkg CryptoPkg BaseCryptLib: Init the content of struct 'CertCtx' before use 2016-07-12 08:53:19 +08:00
DuetPkg DuetPkg FSVariable: return error for empty str VariableName to GetVariable 2016-05-15 17:48:53 +08:00
EdkCompatibilityPkg EdkCompatibilityPkg: Fix typos in comments 2016-07-11 10:29:45 +08:00
EdkShellBinPkg
EdkShellPkg
EmbeddedPkg EmbeddedPkg/AcpiLib: add GICC table init macro for ACPI 6.0 2016-07-06 10:51:38 +02:00
EmulatorPkg EmulatorPkg/EmuGopDxe: Use correct FROM_THIS macro for TextInEx 2016-05-16 18:25:17 -07:00
FatBinPkg FatBinPkg: Change to 2-clause BSD license 2016-04-22 00:55:21 -07:00
FatPkg FatPkg: Add Contributions.txt 2016-04-22 00:55:21 -07:00
IntelFrameworkModulePkg IntelFrameworkModulePkg: Fix typos in comments 2016-07-11 10:29:48 +08:00
IntelFrameworkPkg IntelFrameworkPkg/FrameworkUefiLib: implement EfiEventGroupSignal 2016-03-23 12:05:45 +01:00
IntelFsp2Pkg IntelFsp2Pkg SecFspSecPlatformLibNull: Remove MASM/GAS files 2016-07-11 13:53:57 +08:00
IntelFsp2WrapperPkg IntelFsp2WrapperPkg SecFspWrapperPlatformSecLibSample: Remove MASM/GAS files 2016-07-11 13:53:48 +08:00
IntelFspPkg IntelFspPkg: Add NOOPT target in IntelFspPkg.dsc 2016-01-21 02:14:43 +00:00
IntelFspWrapperPkg IntelFspWrapperPkg: PeiFspHobProcessLibSample: remove set but unused variables 2016-03-25 10:52:21 +01:00
IntelSiliconPkg IntelSiliconPkg/IgdOpRegion: Add definition for Intel IGD 2016-06-16 08:42:44 +08:00
MdeModulePkg MdeModulePkg/PciBusDxe: recognize hotplug-capable PCIe ports 2016-07-13 08:39:29 +02:00
MdePkg MdePkg/IndustryStandard: introduce EFI_PCI_CAPABILITY_ID_SHPC 2016-07-13 08:38:41 +02:00
NetworkPkg NetworkPkg: Update PXE driver to follow edk2 coding standards. 2016-07-12 08:50:36 +08:00
Nt32Pkg Nt32Pkg: Fix typos in comments 2016-07-11 10:29:45 +08:00
Omap35xxPkg Omap35xxPkg: drop CpuExceptionHandlerLib library class resolution 2016-03-17 09:15:11 +01:00
OptionRomPkg OptionRomPkg: Fix typos in comments 2016-07-11 10:29:47 +08:00
OvmfPkg OvmfPkg: add PciHotPlugInitDxe 2016-07-13 08:39:50 +02:00
PcAtChipsetPkg PcAtChipsetPkg: Fix typos in comments 2016-07-11 10:29:47 +08:00
PerformancePkg PerformancePkg: Replace UnicodeStrToAsciiStr/AsciiStrToUnicodeStr 2016-06-21 12:46:25 +08:00
QuarkPlatformPkg QuarkPlatformPkg: fix ASSERT_EFI_ERROR() typos 2016-06-30 13:08:14 +02:00
QuarkSocPkg QuarkSocPkg/SmmCpuFeaturesLib: Add SMRR PhysBase/PhysMask fields check 2016-05-19 10:04:34 -07:00
SecurityPkg SecurityPkg OpalPasswordSmm: Remove useless code. 2016-07-11 10:38:20 +08:00
ShellBinPkg ShellBinPkg: Ia32/X64 Shell binary update. 2016-07-12 15:10:09 +08:00
ShellPkg Revert "ShellPkg: Make the USB mouse behavior in 'edit' consistent with 'hexedit'." 2016-07-08 14:54:30 +08:00
SourceLevelDebugPkg SourceLevelDebugPkg DebugAgentLib: Add nasm source file into LIB INF files. 2016-06-28 09:52:25 +08:00
StdLib StdLib: Series of patches to fix typos - availabe to available 2016-07-07 15:23:19 -07:00
StdLibPrivateInternalFiles StdLib: Clarify and improve comments. 2016-01-06 00:31:42 +00:00
UefiCpuPkg UefiCpuPkg CpuMpPei: Update INF to refer to NASM source file 2016-07-11 13:20:22 +08:00
UnixPkg
Vlv2DeviceRefCodePkg Vlv2DeviceRefCodePkg&Vlv2TbltDevicePkg:Add setup option of LPE Audio. 2016-06-21 11:20:54 +08:00
Vlv2TbltDevicePkg Vlv2TbltDevicePkg: fix ASSERT_EFI_ERROR() typos 2016-06-30 17:27:38 +02:00
.gitignore
BuildNotes2.txt BaseTools: Updated BuildNotes URLs 2016-03-25 09:46:44 +08:00
Edk2Setup.bat
Maintainers.txt Change ShellPkg&ShellBinPkg maintainer 2016-07-06 08:05:21 -07:00
edksetup.bat Update edksetup.bat to check EDK_TOOLS_PATH before set it. 2016-04-11 16:20:28 +08:00
edksetup.sh BaseTools: Update edksetup.sh to support multiple workspaces 2015-10-08 09:29:56 +00:00