RedfishPkg: Create RestEx child on selected interface

When a MAC address matching interface is found, a RestEx child will be
created to provide the Redfish communication on that interface.
Currently, It will try to locate all RestEx binding services and choose
the first satisfied instance without taking care about current selected
interface. This might raise an issue on the system with multiple network
devices that the RestEx child was installed on wrong interface.

Signed-off-by: Minh Nguyen <minhnguyen1@os.amperecomputing.com>
Cc: Abner Chang <abner.chang@amd.com>
Cc: Igor Kulchytskyy <igork@ami.com>
Cc: Nick Ramirez <nramirez@nvidia.com>
Reviewed-by: Abner Chang <Abner.Chang@amd.com>
This commit is contained in:
Vu Nguyen
2021-06-28 17:26:55 +07:00
committed by mergify[bot]
parent 05762bd2e0
commit a1f6485a9b
3 changed files with 77 additions and 104 deletions

View File

@@ -87,6 +87,7 @@ CreateRestExInstance (
EFI_STATUS Status;
Status = RestExLibCreateChild (
Instance->NetworkInterface->OpenDriverControllerHandle,
Instance->Owner,
FixedPcdGetBool (PcdRedfishDiscoverAccessModeInBand) ? EfiRestExServiceInBandAccess : EfiRestExServiceOutOfBandAccess,
EfiRestExConfigHttp,