[edk2-devel] [PATCH v2 1/2] MdeModulePkg: Check legal BarIndex/NumberofBars

2024-10-23 Thread Foster Nong
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=4868 In current PCIE Resizable BAR feature, add below check: 1. Check Register Number of Resizable BARs is legal. 2. Check Register Register BAR Index is legal. Signed-off-by: Foster Nong Cc: Michael D Kinney Cc: Liming Gao Cc: Ray Ni

[edk2-devel] [PATCH V1 2/2] MdeModulePkg:New Pcd to platform constrain BarSize

2024-10-23 Thread Foster Nong
Signed-off-by: Foster Nong Cc: Michael D Kinney Cc: Liming Gao Cc: Ray Ni --- MdeModulePkg/Bus/Pci/PciBusDxe/PciBusDxe.inf | 1 + MdeModulePkg/Bus/Pci/PciBusDxe/PciLib.c | 19 --- MdeModulePkg/MdeModulePkg.dec| 5 + 3 files changed, 22 insertions(+), 3

[edk2-devel] [PATCH v2 2/2] MdeModulePkg:New Pcd to platform constrain BarSize

2024-10-23 Thread Foster Nong
Signed-off-by: Foster Nong Cc: Michael D Kinney Cc: Liming Gao Cc: Ray Ni --- MdeModulePkg/Bus/Pci/PciBusDxe/PciBusDxe.inf | 1 + MdeModulePkg/Bus/Pci/PciBusDxe/PciLib.c | 25 +--- MdeModulePkg/MdeModulePkg.dec| 5 3 files changed, 28 insertions(+), 3

[edk2-devel] [PATCH V1 1/2] MdeModulePkg: Check legal BarIndex/NumberofBars

2024-10-23 Thread Foster Nong
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=4868 In current PCIE Resizable BAR feature, add below check: 1. Check Register Number of Resizable BARs is legal. 2. Check Register Register BAR Index is legal. Signed-off-by: Foster Nong Cc: Michael D Kinney Cc: Liming Gao Cc: Ray Ni

[edk2-devel] [PATCH v2] MdePkg: Add Cxl30.h into IndustryStandard

2024-04-29 Thread Foster Nong
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=4516 1) Add CXL 3.0 header file to comply with CXL 3.0 specification 2) CXL 3.0 header will embed Cxl20.h 3) Updated Cxl.h to point to 3.0 header file Signed-off-by: Foster Nong Cc: Michael D Kinney Cc: Liming Gao Cc: Ray Ni Cc: Chris Li

[edk2-devel] [PATCH v1] MdePkg: Add Cxl30.h into IndustryStandard

2023-11-29 Thread Foster Nong
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=4516 1) Add CXL 3.0 header file to comply with CXL 3.0 specification 2) CXL 3.0 header will embed Cxl20.h 3) Updated Cxl.h to point to 3.0 header file Signed-off-by: Foster Nong Cc: Michael D Kinney Cc: Liming Gao Cc: Ray Ni Cc: Chris Li

[edk2-devel] [PATCH v2] MedPkg/Include: Add PCI_EXPRESS_EXTENDED_CAPABILITY_DVSEC_ID

2023-08-04 Thread Foster Nong
REF:https://bugzilla.tianocore.org/show_bug.cgi?id=4515 Add PCI_EXPRESS_EXTENDED_CAPABILITY_DESIGNATED_VENDOR_SPECIFIC_ID 0x0023 in PciExpress40.h Signed-off-by: Foster Nong Cc: Michael D Kinney Cc: Liming Gao Cc: Ray Ni --- MdePkg/Include/IndustryStandard/PciExpress40.h | 2 ++ 1 file

[edk2-devel] [PATCH] Add PCI_EXPRESS_EXTENDED_CAPABILITY_DVSEC_ID

2023-08-01 Thread Foster Nong
Package/Module: MdePkg/Include REF:https://bugzilla.tianocore.org/show_bug.cgi?id=4515 Add PCI_EXPRESS_EXTENDED_CAPABILITY_DESIGNATED_VENDOR_SPECIFIC_ID 0x0023 in PciExpress40.h Signed-off-by: Foster Nong --- MdePkg/Include/IndustryStandard/PciExpress40.h | 2 ++ 1 file changed, 2 insertions

[edk2-devel] [PATCH v2 1/2] MdeModulePkg: Fixed extra 1 SR-IOV reserved bus

2022-10-12 Thread Foster Nong
ber usage to avoid wasting Bus Numbers So the issue can be fixed with below code change. PciIoDevice->ReservedBusNum = (UINT16)(EFI_PCI_BUS_OF_RID (LastVF) - Bus); https://bugzilla.tianocore.org/show_bug.cgi?id=4069 Signed-off-by: Foster Nong --- MdeModulePkg/Bus/Pci/PciBusDxe/PciEnume

[edk2-devel] [PATCH v2 2/2] Fix bug on SRIOV ReservedBusNum when ARI enable.

2022-10-12 Thread Foster Nong
>ReservedBusNum - TempReservedBusNum), SubBusNumber); The solution is add a new flag IsAriEnabled to help handle this case. if ARI is enabled, then TempReservedBusNum will not be reset again during all functions(1-255) scan with checking flag IsAriEnabled. Signed-off-by: Foster Nong --- MdeModulePkg

[edk2-devel] [PATCH 1/1] MdeModulePkg: Handle InitialVFs=0 case for SR-IOV

2022-09-29 Thread Foster Nong
Bus + 1); } https://bugzilla.tianocore.org/show_bug.cgi?id=4069 Signed-off-by: Foster Nong --- .../Bus/Pci/PciBusDxe/PciEnumeratorSupport.c | 16 ++-- 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/MdeModulePkg/Bus/Pci/PciBusDxe/PciEnumeratorSupport.c b/MdeModulePkg

[edk2-devel] [PATCH 1/1] MdeModulePkg: Enhance bus scan for all root bridge instances

2022-07-22 Thread Foster Nong
to handle this case. Signed-off-by: Foster Nong --- MdeModulePkg/Bus/Pci/PciBusDxe/PciLib.c | 14 -- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/MdeModulePkg/Bus/Pci/PciBusDxe/PciLib.c b/MdeModulePkg/Bus/Pci/PciBusDxe/PciLib.c index 63d149b3b8c0..a89f912de85b 10