]> git.proxmox.com Git - mirror_edk2.git/commit - MdeModulePkg/Bus/Pci/PciBusDxe/PciResourceSupport.c
MdeModulePkg/PciBus: Count multiple hotplug resource paddings
authorRuiyu Ni <ruiyu.ni@intel.com>
Sat, 30 Sep 2017 05:10:08 +0000 (13:10 +0800)
committerRuiyu Ni <ruiyu.ni@intel.com>
Mon, 9 Oct 2017 02:41:29 +0000 (10:41 +0800)
commit728d74973c9262b6c7b7ef4be213223d55affec3
tree96d6d092efa654570fc749cd8a81815249e4cf54
parentf8f0e454e1f9e0be354cfab2b70d4faa14982f6f
MdeModulePkg/PciBus: Count multiple hotplug resource paddings

REF: https://bugzilla.tianocore.org/show_bug.cgi?id=720

The current implementation assumes there is only one hotplug resource
padding for each resource type. It's not true considering
DegradeResource(): MEM64 resource could be degraded to MEM32
resource.

The patch treat the resource paddings using the same logic as
treating typical/actual resources and the total resource of a bridge
is set to the MAX of typical/actual resources and resource paddings.

Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Tested-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Star Zeng <star.zeng@intel.com>
MdeModulePkg/Bus/Pci/PciBusDxe/PciResourceSupport.c