From: "Chang, Abner via groups.io" <abner.chang=amd.com@groups.io>
To: Mike Maslenkin <mike.maslenkin@gmail.com>
Cc: "devel@edk2.groups.io" <devel@edk2.groups.io>,
Nickle Wang <nicklew@nvidia.com>,
Igor Kulchytskyy <igork@ami.com>
Subject: Re: [edk2-devel] [PATCH V2 2/8] RedfishPkg/RedfishHostInterfaceDxe: Add Redfish HI readiness notification
Date: Mon, 27 Nov 2023 04:33:30 +0000 [thread overview]
Message-ID: <MN2PR12MB396658557BCCAFC280B89D7DEABDA@MN2PR12MB3966.namprd12.prod.outlook.com> (raw)
In-Reply-To: <CAL77WPBeZRd9U-+QHLrGUrR=QLUH2VDG0Xx6d+Mhu5so=iqr=g@mail.gmail.com>
[AMD Official Use Only - General]
> -----Original Message-----
> From: Mike Maslenkin <mike.maslenkin@gmail.com>
> Sent: Monday, November 27, 2023 3:36 AM
> To: Chang, Abner <Abner.Chang@amd.com>
> Cc: devel@edk2.groups.io; Nickle Wang <nicklew@nvidia.com>; Igor
> Kulchytskyy <igork@ami.com>
> Subject: Re: [PATCH V2 2/8] RedfishPkg/RedfishHostInterfaceDxe: Add
> Redfish HI readiness notification
>
> Caution: This message originated from an External Source. Use proper caution
> when opening attachments, clicking links, or responding.
>
>
> On Thu, Nov 23, 2023 at 9:48 AM <abner.chang@amd.com> wrote:
> >
> > From: Abner Chang <abner.chang@amd.com>
> >
> > Introduce gEdkIIRedfishHostInterfaceReadyProtocolGuid
> > and produce it when Redfish Host Interface is installed
> > on system.
> >
> > Signed-off-by: Abner Chang <abner.chang@amd.com>
> > Cc: Nickle Wang <nicklew@nvidia.com>
> > Cc: Igor Kulchytskyy <igork@ami.com>
> > Cc: Mike Maslenkin <mike.maslenkin@gmail.com>
> > ---
> > RedfishPkg/RedfishPkg.dec | 3 +++
> > .../RedfishHostInterfaceDxe.inf | 3 ++-
> > .../RedfishHostInterfaceDxe.c | 16 ++++++++++++++++
> > 3 files changed, 21 insertions(+), 1 deletion(-)
> >
> > diff --git a/RedfishPkg/RedfishPkg.dec b/RedfishPkg/RedfishPkg.dec
> > index 0f18865cea0..e40538247c2 100644
> > --- a/RedfishPkg/RedfishPkg.dec
> > +++ b/RedfishPkg/RedfishPkg.dec
> > @@ -90,6 +90,9 @@
> > ## Include/Protocol/EdkIIRedfishPlatformConfig.h
> > gEdkIIRedfishPlatformConfigProtocolGuid = { 0X4D94A7C7, 0X4CE4,
> 0X4A84, { 0X88, 0XC1, 0X33, 0X0C, 0XD4, 0XA3, 0X47, 0X67 } }
> >
> > + # Redfish Host Interface ready notification protocol
> > + gEdkIIRedfishHostInterfaceReadyProtocolGuid = { 0xC3F6D062, 0x3D38,
> 0x4EA4, { 0x92, 0xB1, 0xE8, 0xF8, 0x02, 0x27, 0x63, 0xDF } }
> > +
> > [Guids]
> > gEfiRedfishPkgTokenSpaceGuid = { 0x4fdbccb7, 0xe829, 0x4b4c, { 0x88,
> 0x87, 0xb2, 0x3f, 0xd7, 0x25, 0x4b, 0x85 }}
> >
> > diff --git a/RedfishPkg/RedfishHostInterfaceDxe/RedfishHostInterfaceDxe.inf
> b/RedfishPkg/RedfishHostInterfaceDxe/RedfishHostInterfaceDxe.inf
> > index 1cdae149aad..f969e75463f 100644
> > --- a/RedfishPkg/RedfishHostInterfaceDxe/RedfishHostInterfaceDxe.inf
> > +++ b/RedfishPkg/RedfishHostInterfaceDxe/RedfishHostInterfaceDxe.inf
> > @@ -43,7 +43,8 @@
> > UefiLib
> >
> > [Protocols]
> > - gEfiSmbiosProtocolGuid ## TO_START
> > + gEfiSmbiosProtocolGuid ## TO_START
> > + gEdkIIRedfishHostInterfaceReadyProtocolGuid ## PRODUCED
> >
> > [Depex]
> > gEfiSmbiosProtocolGuid
> > diff --git a/RedfishPkg/RedfishHostInterfaceDxe/RedfishHostInterfaceDxe.c
> b/RedfishPkg/RedfishHostInterfaceDxe/RedfishHostInterfaceDxe.c
> > index 55a66decfc8..94c0f9b6a92 100644
> > --- a/RedfishPkg/RedfishHostInterfaceDxe/RedfishHostInterfaceDxe.c
> > +++ b/RedfishPkg/RedfishHostInterfaceDxe/RedfishHostInterfaceDxe.c
> > @@ -53,7 +53,9 @@ RedfishCreateSmbiosTable42 (
> > SMBIOS_TABLE_TYPE42 *Type42Record;
> > EFI_SMBIOS_PROTOCOL *Smbios;
> > EFI_SMBIOS_HANDLE MemArrayMappedAddrSmbiosHandle;
> > + EFI_HANDLE Handle;
> >
> > + Handle = NULL;
> > //
> > // Get platform Redfish host interface device type descriptor data.
> > //
> > @@ -228,6 +230,20 @@ RedfishCreateSmbiosTable42 (
> >
> > Status = EFI_SUCCESS;
> >
> > + //
> > + // Install Redfish Host Interface ready protocol.
> > + //
> > + Status = gBS->InstallProtocolInterface (
> > + &Handle,
> > + &gEdkIIRedfishHostInterfaceReadyProtocolGuid,
> > + EFI_NATIVE_INTERFACE,
> > + (VOID *)NULL
> > + );
> > + if (EFI_ERROR (Status)) {
> > + DEBUG ((DEBUG_ERROR, "Failed to install
> gEdkIIRedfishHostInterfaceReadyProtocolGuid.\n"));
> > + DEBUG ((DEBUG_ERROR, "PlatformConfigHandler driver may not be
> triggered to acquire Redfish service.\n"));
> > + }
> > +
> > ON_EXIT:
> > if (DeviceDescriptor != NULL) {
> > FreePool (DeviceDescriptor);
> > --
> > 2.37.1.windows.1
> >
>
> You have clobbered explicit Status = EFI_SUCCESS;
> is it intended? Overall result of this function does not depend from
> this InstallProtocolInterface() call, SMBIOS table has been installed
> successfully.
> Looks like InstallProtocolInterface() should be added before Status
> return value set.
No, I didn’t aware this 😊. Move it to below the new change as SMBIOS 42 is installed successfully.
Thanks
Abner
-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#111714): https://edk2.groups.io/g/devel/message/111714
Mute This Topic: https://groups.io/mt/102763119/7686176
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io]
-=-=-=-=-=-=-=-=-=-=-=-
next prev parent reply other threads:[~2023-11-27 4:33 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-11-23 6:47 [edk2-devel] [PATCH V2 0/8] Refine BMC USB NIC discovery and Redfish service enablement Chang, Abner via groups.io
2023-11-23 6:47 ` [edk2-devel] [PATCH V2 1/8] RedfishPkg/BmcUsbNicLib: Update BMC USB NIC searching algorithm Chang, Abner via groups.io
2023-11-26 19:38 ` Mike Maslenkin
2023-11-27 4:32 ` Chang, Abner via groups.io
2023-11-23 6:47 ` [edk2-devel] [PATCH V2 2/8] RedfishPkg/RedfishHostInterfaceDxe: Add Redfish HI readiness notification Chang, Abner via groups.io
2023-11-26 19:35 ` Mike Maslenkin
2023-11-27 4:33 ` Chang, Abner via groups.io [this message]
2023-11-23 6:47 ` [edk2-devel] [PATCH V2 3/8] RedfishPkg/RedfishConfigHandler: Use " Chang, Abner via groups.io
2023-11-23 6:47 ` [edk2-devel] [PATCH V2 4/8] RedfishPkg/RedfishConfigHandler: Correct the prototype of callback function Chang, Abner via groups.io
2023-11-23 6:47 ` [edk2-devel] [PATCH V2 5/8] RedfishPkg/RedfishDiscovery: Add more debug message Chang, Abner via groups.io
2023-11-23 6:47 ` [edk2-devel] [PATCH V2 6/8] RedfishPkg/RedfishDiscovery: Refine SMBIOS 42h code Chang, Abner via groups.io
2023-11-23 6:47 ` [edk2-devel] [PATCH V2 7/8] RedfishPkg/HostInterfaceBmcUsbNic: Fix incorrect reference of MAC address pointer Chang, Abner via groups.io
2023-11-23 6:47 ` [edk2-devel] [PATCH V2 8/8] RedfishPkg/HostInterfaceBmcUsbNic: Fix incorrect HI protocol record size Chang, Abner via groups.io
2023-11-26 19:30 ` Mike Maslenkin
2023-11-27 4:38 ` Chang, Abner via groups.io
2023-11-26 19:46 ` [edk2-devel] [PATCH V2 0/8] Refine BMC USB NIC discovery and Redfish service enablement Mike Maslenkin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-list from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=MN2PR12MB396658557BCCAFC280B89D7DEABDA@MN2PR12MB3966.namprd12.prod.outlook.com \
--to=devel@edk2.groups.io \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox