public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* [edk2-platforms][PATCH 0/7] Implementation of IPMI Protocol
@ 2023-02-07 16:22 Chang, Abner
  2023-02-07 16:22 ` [edk2-platforms][PATCH 1/7] IpmiFeaturePkg: Rename IpmiSubmitCommand function Chang, Abner
                   ` (8 more replies)
  0 siblings, 9 replies; 22+ messages in thread
From: Chang, Abner @ 2023-02-07 16:22 UTC (permalink / raw)
  To: devel
  Cc: Liming Gao, Isaac Oram, Nate DeSimone, Nickle Wang,
	Igor Kulchytskyy, Abdul Lateef Attar, Leif Lindholm,
	Michael D Kinney

From: Abner Chang <abner.chang@amd.com>

This change implementes IPMI Protocol and PPI in the
new introduced ManageabilityPkg (described in below email)
https://edk2.groups.io/g/devel/message/95579?p=%2C%2C%2C20%2C0%2C0%2C0%3A%3ACreated%2C%2CManageability%2C20%2C2%2C0%2C94572748

BZ #4336:
The change also fixes the confusion (Patch 1/7) of IpmiSubmitCommand()
deinfed in IPMI Transport protocol.

You can skip reviewing on patch 2/7 as it is an image file.

Signed-off-by: Abner Chang <abner.chang@amd.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Isaac Oram <isaac.w.oram@intel.com>
Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
Cc: Nickle Wang <nicklew@nvidia.com>
Cc: Igor Kulchytskyy <igork@ami.com>
Cc: Abdul Lateef Attar <abdattar@amd.com>
Cc: Leif Lindholm <quic_llindhol@quicinc.com>
Cc: Michael D Kinney <michael.d.kinney@intel.com>

Abner Chang (7):
  IpmiFeaturePkg: Rename IpmiSubmitCommand function
  ManageabilityPkg: Add diagrams
  ManageabilityPkg: Add Readme file
  ManageabilityPkg: Initial package
  ManageabilityPkg: Implement Ipmi Protocol/Ppi
  IpmiProtocol: Add to Manageability Package
  edk2-platforms: Maintainers.txt

 .../ManageabilityPkg/ManageabilityPkg.dec     |  18 ++++
 .../Include/CommonLibs.dsc.inc                |  52 +++++++++
 .../ManageabilityPkg/ManageabilityPkg.dsc     |  27 +++++
 .../IpmiProtocol/Dxe/IpmiProtocolDxe.inf      |  37 +++++++
 .../Universal/IpmiProtocol/Pei/IpmiPpiPei.inf |  38 +++++++
 .../IpmiProtocol/Smm/IpmiProtocolSmm.inf      |  40 +++++++
 .../Include/Library/IpmiBaseLib.h             |   2 +-
 .../Include/Ppi/IpmiTransportPpi.h            |   2 +-
 .../Include/Protocol/IpmiTransportProtocol.h  |   2 +-
 .../IpmiFeaturePkg/GenericIpmi/Dxe/IpmiInit.c |   2 +-
 .../GenericIpmi/Pei/PeiGenericIpmi.c          |   2 +-
 .../GenericIpmi/Smm/SmmGenericIpmi.c          |   2 +-
 .../Library/IpmiBaseLib/IpmiBaseLib.c         |   4 +-
 .../Library/IpmiBaseLibNull/IpmiBaseLibNull.c |   2 +-
 .../IpmiCommandLib/IpmiCommandLibNetFnApp.c   |  26 ++---
 .../IpmiCommandLibNetFnChassis.c              |  12 +--
 .../IpmiCommandLibNetFnStorage.c              |  24 ++---
 .../IpmiCommandLibNetFnTransport.c            |   8 +-
 .../Library/PeiIpmiBaseLib/PeiIpmiBaseLib.c   |   4 +-
 .../Library/SmmIpmiBaseLib/SmmIpmiBaseLib.c   |   4 +-
 .../Universal/IpmiProtocol/Dxe/IpmiProtocol.c |  97 +++++++++++++++++
 .../Universal/IpmiProtocol/Pei/IpmiPpi.c      | 102 ++++++++++++++++++
 .../Universal/IpmiProtocol/Smm/IpmiProtocol.c |  98 +++++++++++++++++
 .../Ipmi/Library/IpmiLibKcs/IpmiLibKcs.c      |  12 +--
 Features/ManageabilityPkg/Readme.md           |  37 +++++++
 .../Media/ManageabilityDriverStack.svg        |   1 +
 Maintainers.txt                               |   9 +-
 27 files changed, 608 insertions(+), 56 deletions(-)
 create mode 100644 Features/ManageabilityPkg/ManageabilityPkg.dec
 create mode 100644 Features/ManageabilityPkg/Include/CommonLibs.dsc.inc
 create mode 100644 Features/ManageabilityPkg/ManageabilityPkg.dsc
 create mode 100644 Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocolDxe.inf
 create mode 100644 Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpiPei.inf
 create mode 100644 Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocolSmm.inf
 create mode 100644 Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocol.c
 create mode 100644 Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpi.c
 create mode 100644 Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocol.c
 create mode 100644 Features/ManageabilityPkg/Readme.md
 create mode 100644 Features/ManageabilityPkg/Documents/Media/ManageabilityDriverStack.svg

-- 
2.37.1.windows.1


^ permalink raw reply	[flat|nested] 22+ messages in thread

* [edk2-platforms][PATCH 1/7] IpmiFeaturePkg: Rename IpmiSubmitCommand function
  2023-02-07 16:22 [edk2-platforms][PATCH 0/7] Implementation of IPMI Protocol Chang, Abner
@ 2023-02-07 16:22 ` Chang, Abner
  2023-02-16  1:43   ` Isaac Oram
  2023-02-07 16:22 ` [edk2-platforms][PATCH 2/7] ManageabilityPkg: Add diagrams Chang, Abner
                   ` (7 subsequent siblings)
  8 siblings, 1 reply; 22+ messages in thread
From: Chang, Abner @ 2023-02-07 16:22 UTC (permalink / raw)
  To: devel
  Cc: Liming Gao, Isaac Oram, Nate DeSimone, Nickle Wang,
	Igor Kulchytskyy, Abdul Lateef Attar

From: Abner Chang <abner.chang@amd.com>

Rename IpmiSubmitCommand to IpmiSendCommand because
the naming of this function is confusing with
IpmiSubmitCommand defined in IPMI Protocol.

Signed-off-by: Abner Chang <abner.chang@amd.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Isaac Oram <isaac.w.oram@intel.com>
Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
Cc: Nickle Wang <nicklew@nvidia.com>
Cc: Igor Kulchytskyy <igork@ami.com>
Cc: Abdul Lateef Attar <abdattar@amd.com>
---
 .../Include/Library/IpmiBaseLib.h             |  2 +-
 .../Include/Ppi/IpmiTransportPpi.h            |  2 +-
 .../Include/Protocol/IpmiTransportProtocol.h  |  2 +-
 .../IpmiFeaturePkg/GenericIpmi/Dxe/IpmiInit.c |  2 +-
 .../GenericIpmi/Pei/PeiGenericIpmi.c          |  2 +-
 .../GenericIpmi/Smm/SmmGenericIpmi.c          |  2 +-
 .../Library/IpmiBaseLib/IpmiBaseLib.c         |  4 +--
 .../Library/IpmiBaseLibNull/IpmiBaseLibNull.c |  2 +-
 .../IpmiCommandLib/IpmiCommandLibNetFnApp.c   | 26 +++++++++----------
 .../IpmiCommandLibNetFnChassis.c              | 12 ++++-----
 .../IpmiCommandLibNetFnStorage.c              | 24 ++++++++---------
 .../IpmiCommandLibNetFnTransport.c            |  8 +++---
 .../Library/PeiIpmiBaseLib/PeiIpmiBaseLib.c   |  4 +--
 .../Library/SmmIpmiBaseLib/SmmIpmiBaseLib.c   |  4 +--
 .../Ipmi/Library/IpmiLibKcs/IpmiLibKcs.c      | 12 ++++-----
 15 files changed, 54 insertions(+), 54 deletions(-)

diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Library/IpmiBaseLib.h b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Library/IpmiBaseLib.h
index 8487ace5ba..9e77bdad8d 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Library/IpmiBaseLib.h
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Library/IpmiBaseLib.h
@@ -37,7 +37,7 @@ InitializeIpmiBase (
 
 **/
 EFI_STATUS
-IpmiSubmitCommand (
+IpmiSendCommand (
   IN UINT8     NetFunction,
   IN UINT8     Command,
   IN UINT8     *CommandData,
diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Ppi/IpmiTransportPpi.h b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Ppi/IpmiTransportPpi.h
index 9ecb20f9bf..4bdb5db00b 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Ppi/IpmiTransportPpi.h
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Ppi/IpmiTransportPpi.h
@@ -59,7 +59,7 @@ EFI_STATUS
 //
 struct _PEI_IPMI_TRANSPORT_PPI {
   UINT64                      Revision;
-  PEI_IPMI_SEND_COMMAND       IpmiSubmitCommand;
+  PEI_IPMI_SEND_COMMAND       IpmiSendCommand;
   PEI_IPMI_GET_CHANNEL_STATUS GetBmcStatus;
 };
 
diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Protocol/IpmiTransportProtocol.h b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Protocol/IpmiTransportProtocol.h
index 2ee6f98e07..bb17073f06 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Protocol/IpmiTransportProtocol.h
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Protocol/IpmiTransportProtocol.h
@@ -63,7 +63,7 @@ EFI_STATUS
 //
 struct _IPMI_TRANSPORT {
   UINT64                      Revision;
-  IPMI_SEND_COMMAND           IpmiSubmitCommand;
+  IPMI_SEND_COMMAND           IpmiSendCommand;
   IPMI_GET_CHANNEL_STATUS     GetBmcStatus;
   EFI_HANDLE                  IpmiHandle;
   UINT8                       CompletionCode;
diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Dxe/IpmiInit.c b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Dxe/IpmiInit.c
index d788b48867..f1f089b575 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Dxe/IpmiInit.c
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Dxe/IpmiInit.c
@@ -396,7 +396,7 @@ InitializeIpmiKcsPhysicalLayer (
     mIpmiInstance->Signature                        = SM_IPMI_BMC_SIGNATURE;
     mIpmiInstance->SlaveAddress                     = BMC_SLAVE_ADDRESS;
     mIpmiInstance->BmcStatus                        = BMC_NOTREADY;
-    mIpmiInstance->IpmiTransport.IpmiSubmitCommand  = IpmiSendCommand;
+    mIpmiInstance->IpmiTransport.IpmiSendCommand    = IpmiSendCommand;
     mIpmiInstance->IpmiTransport.GetBmcStatus       = IpmiGetBmcStatus;
 
     //
diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Pei/PeiGenericIpmi.c b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Pei/PeiGenericIpmi.c
index 3efb772b68..e9018ca8df 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Pei/PeiGenericIpmi.c
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Pei/PeiGenericIpmi.c
@@ -76,7 +76,7 @@ PeiInitializeIpmiKcsPhysicalLayer (
   mIpmiInstance->Signature                          = SM_IPMI_BMC_SIGNATURE;
   mIpmiInstance->SlaveAddress                       = BMC_SLAVE_ADDRESS;
   mIpmiInstance->BmcStatus                          = BMC_NOTREADY;
-  mIpmiInstance->IpmiTransportPpi.IpmiSubmitCommand = PeiIpmiSendCommand;
+  mIpmiInstance->IpmiTransportPpi.IpmiSendCommand   = PeiIpmiSendCommand;
   mIpmiInstance->IpmiTransportPpi.GetBmcStatus      = PeiGetIpmiBmcStatus;
 
   mIpmiInstance->PeiIpmiBmcDataDesc.Flags         = EFI_PEI_PPI_DESCRIPTOR_PPI | EFI_PEI_PPI_DESCRIPTOR_TERMINATE_LIST;
diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Smm/SmmGenericIpmi.c b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Smm/SmmGenericIpmi.c
index fda215baaa..c1892f5ab8 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Smm/SmmGenericIpmi.c
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Smm/SmmGenericIpmi.c
@@ -166,7 +166,7 @@ Returns:
     mIpmiInstance->Signature                        = SM_IPMI_BMC_SIGNATURE;
     mIpmiInstance->SlaveAddress                     = BMC_SLAVE_ADDRESS;
     mIpmiInstance->BmcStatus                        = BMC_NOTREADY;
-    mIpmiInstance->IpmiTransport.IpmiSubmitCommand  = IpmiSendCommand;
+    mIpmiInstance->IpmiTransport.IpmiSendCommand    = IpmiSendCommand;
     mIpmiInstance->IpmiTransport.GetBmcStatus       = IpmiGetBmcStatus;
 
     DEBUG ((DEBUG_INFO,"IPMI: Waiting for Getting BMC DID in SMM \n"));
diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiBaseLib/IpmiBaseLib.c b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiBaseLib/IpmiBaseLib.c
index 5df9d861c6..01ff322d27 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiBaseLib/IpmiBaseLib.c
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiBaseLib/IpmiBaseLib.c
@@ -91,7 +91,7 @@ InitializeIpmiBase (
 
 **/
 EFI_STATUS
-IpmiSubmitCommand (
+IpmiSendCommand (
   IN UINT8        NetFunction,
   IN UINT8        Command,
   IN UINT8        *CommandData,
@@ -108,7 +108,7 @@ IpmiSubmitCommand (
     return Status;
   }
 
-  Status = mIpmiTransport->IpmiSubmitCommand (
+  Status = mIpmiTransport->IpmiSendCommand (
                              mIpmiTransport,
                              NetFunction,
                              0,
diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiBaseLibNull/IpmiBaseLibNull.c b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiBaseLibNull/IpmiBaseLibNull.c
index 7c4c67f6ac..7af21bbaf1 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiBaseLibNull/IpmiBaseLibNull.c
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiBaseLibNull/IpmiBaseLibNull.c
@@ -43,7 +43,7 @@ InitializeIpmiBase (
 
 **/
 EFI_STATUS
-IpmiSubmitCommand (
+IpmiSendCommand (
   IN UINT8     NetFunction,
   IN UINT8     Command,
   IN UINT8     *CommandData,
diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnApp.c b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnApp.c
index 2e34909f3e..dbd154e2a6 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnApp.c
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnApp.c
@@ -24,7 +24,7 @@ IpmiGetDeviceId (
   UINT32                       DataSize;
 
   DataSize = sizeof(*DeviceId);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_APP,
              IPMI_APP_GET_DEVICE_ID,
              NULL,
@@ -45,7 +45,7 @@ IpmiGetSelfTestResult (
   UINT32                       DataSize;
 
   DataSize = sizeof(*SelfTestResult);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_APP,
              IPMI_APP_GET_SELFTEST_RESULTS,
              NULL,
@@ -66,7 +66,7 @@ IpmiResetWatchdogTimer (
   UINT32                       DataSize;
 
   DataSize = sizeof(*CompletionCode);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_APP,
              IPMI_APP_RESET_WATCHDOG_TIMER,
              NULL,
@@ -88,7 +88,7 @@ IpmiSetWatchdogTimer (
   UINT32                       DataSize;
 
   DataSize = sizeof(*CompletionCode);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_APP,
              IPMI_APP_SET_WATCHDOG_TIMER,
              (VOID *)SetWatchdogTimer,
@@ -109,7 +109,7 @@ IpmiGetWatchdogTimer (
   UINT32                       DataSize;
 
   DataSize = sizeof(*GetWatchdogTimer);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_APP,
              IPMI_APP_GET_WATCHDOG_TIMER,
              NULL,
@@ -131,7 +131,7 @@ IpmiSetBmcGlobalEnables (
   UINT32                       DataSize;
 
   DataSize = sizeof(*CompletionCode);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_APP,
              IPMI_APP_SET_BMC_GLOBAL_ENABLES,
              (VOID *)SetBmcGlobalEnables,
@@ -152,7 +152,7 @@ IpmiGetBmcGlobalEnables (
   UINT32                       DataSize;
 
   DataSize = sizeof(*GetBmcGlobalEnables);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_APP,
              IPMI_APP_GET_BMC_GLOBAL_ENABLES,
              NULL,
@@ -174,7 +174,7 @@ IpmiClearMessageFlags (
   UINT32                       DataSize;
 
   DataSize = sizeof(*CompletionCode);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_APP,
              IPMI_APP_CLEAR_MESSAGE_FLAGS,
              (VOID *)ClearMessageFlagsRequest,
@@ -195,7 +195,7 @@ IpmiGetMessageFlags (
   UINT32                       DataSize;
 
   DataSize = sizeof(*GetMessageFlagsResponse);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_APP,
              IPMI_APP_GET_MESSAGE_FLAGS,
              NULL,
@@ -215,7 +215,7 @@ IpmiGetMessage (
 {
   EFI_STATUS                   Status;
 
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_APP,
              IPMI_APP_GET_MESSAGE,
              NULL,
@@ -237,7 +237,7 @@ IpmiSendMessage (
 {
   EFI_STATUS                   Status;
 
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_APP,
              IPMI_APP_SEND_MESSAGE,
              (VOID *)SendMessageRequest,
@@ -274,7 +274,7 @@ IpmiGetSystemUuid (
   }
   RequestSize = 0;
   ResponseSize = sizeof (IPMI_GET_SYSTEM_UUID_RESPONSE);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_APP,
              IPMI_APP_GET_SYSTEM_GUID,
              (VOID *)NULL,
@@ -323,7 +323,7 @@ IpmiGetChannelInfo (
   }
 
   *GetChannelInfoResponseSize = sizeof (IPMI_GET_CHANNEL_INFO_RESPONSE);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_APP,
              IPMI_APP_GET_CHANNEL_INFO,
              (UINT8 *)GetChannelInfoRequest,
diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnChassis.c b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnChassis.c
index 9c19f52ce4..c8c0e90a79 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnChassis.c
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnChassis.c
@@ -23,7 +23,7 @@ IpmiGetChassisCapabilities (
   UINT32                       DataSize;
 
   DataSize = sizeof(*GetChassisCapabilitiesResponse);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_CHASSIS,
              IPMI_CHASSIS_GET_CAPABILITIES,
              NULL,
@@ -44,7 +44,7 @@ IpmiGetChassisStatus (
   UINT32                       DataSize;
 
   DataSize = sizeof(*GetChassisStatusResponse);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_CHASSIS,
              IPMI_CHASSIS_GET_STATUS,
              NULL,
@@ -66,7 +66,7 @@ IpmiChassisControl (
   UINT32                       DataSize;
 
   DataSize = sizeof(*CompletionCode);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_CHASSIS,
              IPMI_CHASSIS_CONTROL,
              (VOID *)ChassisControlRequest,
@@ -88,7 +88,7 @@ IpmiSetPowerRestorePolicy (
   UINT32                       DataSize;
 
   DataSize = sizeof(*ChassisControlResponse);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_CHASSIS,
              IPMI_CHASSIS_SET_POWER_RESTORE_POLICY,
              (VOID *)ChassisControlRequest,
@@ -110,7 +110,7 @@ IpmiSetSystemBootOptions (
   UINT32                       DataSize;
 
   DataSize = sizeof(*BootOptionsResponse);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_CHASSIS,
              IPMI_CHASSIS_SET_SYSTEM_BOOT_OPTIONS,
              (VOID *)BootOptionsRequest,
@@ -132,7 +132,7 @@ IpmiGetSystemBootOptions (
   UINT32                       DataSize;
 
   DataSize = sizeof(*BootOptionsResponse);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_CHASSIS,
              IPMI_CHASSIS_GET_SYSTEM_BOOT_OPTIONS,
              (VOID *)BootOptionsRequest,
diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnStorage.c b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnStorage.c
index 2215028089..4e84084605 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnStorage.c
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnStorage.c
@@ -24,7 +24,7 @@ IpmiGetFruInventoryAreaInfo (
   UINT32                       DataSize;
 
   DataSize = sizeof(*GetFruInventoryAreaInfoResponse);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_STORAGE,
              IPMI_STORAGE_GET_FRU_INVENTORY_AREAINFO,
              (VOID *)GetFruInventoryAreaInfoRequest,
@@ -45,7 +45,7 @@ IpmiReadFruData (
 {
   EFI_STATUS                   Status;
 
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_STORAGE,
              IPMI_STORAGE_READ_FRU_DATA,
              (VOID *)ReadFruDataRequest,
@@ -68,7 +68,7 @@ IpmiWriteFruData (
   UINT32                       DataSize;
 
   DataSize = sizeof(*WriteFruDataResponse);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_STORAGE,
              IPMI_STORAGE_WRITE_FRU_DATA,
              (VOID *)WriteFruDataRequest,
@@ -89,7 +89,7 @@ IpmiGetSelInfo (
   UINT32                       DataSize;
 
   DataSize = sizeof(*GetSelInfoResponse);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_STORAGE,
              IPMI_STORAGE_GET_SEL_INFO,
              NULL,
@@ -110,7 +110,7 @@ IpmiGetSelEntry (
 {
   EFI_STATUS                   Status;
 
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_STORAGE,
              IPMI_STORAGE_GET_SEL_ENTRY,
              (VOID *)GetSelEntryRequest,
@@ -132,7 +132,7 @@ IpmiAddSelEntry (
   UINT32                       DataSize;
 
   DataSize = sizeof(*AddSelEntryResponse);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_STORAGE,
              IPMI_STORAGE_ADD_SEL_ENTRY,
              (VOID *)AddSelEntryRequest,
@@ -155,7 +155,7 @@ IpmiPartialAddSelEntry (
   UINT32                       DataSize;
 
   DataSize = sizeof(*PartialAddSelEntryResponse);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_STORAGE,
              IPMI_STORAGE_PARTIAL_ADD_SEL_ENTRY,
              (VOID *)PartialAddSelEntryRequest,
@@ -177,7 +177,7 @@ IpmiClearSel (
   UINT32                       DataSize;
 
   DataSize = sizeof(*ClearSelResponse);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_STORAGE,
              IPMI_STORAGE_CLEAR_SEL,
              (VOID *)ClearSelRequest,
@@ -198,7 +198,7 @@ IpmiGetSelTime (
   UINT32                       DataSize;
 
   DataSize = sizeof(*GetSelTimeResponse);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_STORAGE,
              IPMI_STORAGE_GET_SEL_TIME,
              NULL,
@@ -220,7 +220,7 @@ IpmiSetSelTime (
   UINT32                       DataSize;
 
   DataSize = sizeof(*CompletionCode);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_STORAGE,
              IPMI_STORAGE_SET_SEL_TIME,
              (VOID *)SetSelTimeRequest,
@@ -241,7 +241,7 @@ IpmiGetSdrRepositoryInfo (
   UINT32                       DataSize;
 
   DataSize = sizeof(*GetSdrRepositoryInfoResp);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_STORAGE,
              IPMI_STORAGE_GET_SDR_REPOSITORY_INFO,
              NULL,
@@ -262,7 +262,7 @@ IpmiGetSdr (
 {
   EFI_STATUS                   Status;
 
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_STORAGE,
              IPMI_STORAGE_GET_SDR,
              (VOID *)GetSdrRequest,
diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnTransport.c b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnTransport.c
index 30ea84c04b..eec281c5bd 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnTransport.c
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnTransport.c
@@ -26,7 +26,7 @@ IpmiSolActivating (
   UINT32                       DataSize;
 
   DataSize = sizeof(*CompletionCode);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_TRANSPORT,
              IPMI_TRANSPORT_SOL_ACTIVATING,
              (VOID *)SolActivatingRequest,
@@ -49,7 +49,7 @@ IpmiSetSolConfigurationParameters (
   UINT32                       DataSize;
 
   DataSize = sizeof(*CompletionCode);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_TRANSPORT,
              IPMI_TRANSPORT_SET_SOL_CONFIG_PARAM,
              (VOID *)SetConfigurationParametersRequest,
@@ -70,7 +70,7 @@ IpmiGetSolConfigurationParameters (
 {
   EFI_STATUS                   Status;
 
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_TRANSPORT,
              IPMI_TRANSPORT_GET_SOL_CONFIG_PARAM,
              (VOID *)GetConfigurationParametersRequest,
@@ -111,7 +111,7 @@ IpmiGetLanConfigurationParameters (
     return EFI_INVALID_PARAMETER;
   }
 
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_TRANSPORT,
              IPMI_TRANSPORT_GET_LAN_CONFIG_PARAMETERS,
              (UINT8 *)GetLanConfigurationParametersRequest,
diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/PeiIpmiBaseLib/PeiIpmiBaseLib.c b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/PeiIpmiBaseLib/PeiIpmiBaseLib.c
index 8679cd95db..b97152208a 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/PeiIpmiBaseLib/PeiIpmiBaseLib.c
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/PeiIpmiBaseLib/PeiIpmiBaseLib.c
@@ -48,7 +48,7 @@ InitializeIpmiBase (
 
 **/
 EFI_STATUS
-IpmiSubmitCommand (
+IpmiSendCommand (
   IN UINT8        NetFunction,
   IN UINT8        Command,
   IN UINT8        *CommandData,
@@ -65,7 +65,7 @@ IpmiSubmitCommand (
     ASSERT_EFI_ERROR (Status);
     return Status;
   }
-  Status = IpmiTransport->IpmiSubmitCommand (
+  Status = IpmiTransport->IpmiSendCommand (
                             IpmiTransport,
                             NetFunction,
                             0,
diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/SmmIpmiBaseLib/SmmIpmiBaseLib.c b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/SmmIpmiBaseLib/SmmIpmiBaseLib.c
index 6282adc269..ee1d3d5bed 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/SmmIpmiBaseLib/SmmIpmiBaseLib.c
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/SmmIpmiBaseLib/SmmIpmiBaseLib.c
@@ -96,7 +96,7 @@ InitializeIpmiBase (
 
 **/
 EFI_STATUS
-IpmiSubmitCommand (
+IpmiSendCommand (
   IN UINT8        NetFunction,
   IN UINT8        Command,
   IN UINT8        *CommandData,
@@ -133,7 +133,7 @@ Returns:
     return Status;
   }
 
-  Status = mIpmiTransport->IpmiSubmitCommand (
+  Status = mIpmiTransport->IpmiSendCommand (
                              mIpmiTransport,
                              NetFunction,
                              0,
diff --git a/Platform/Intel/PurleyOpenBoardPkg/Features/Ipmi/Library/IpmiLibKcs/IpmiLibKcs.c b/Platform/Intel/PurleyOpenBoardPkg/Features/Ipmi/Library/IpmiLibKcs/IpmiLibKcs.c
index 700e413aa6..2b02ba6a20 100644
--- a/Platform/Intel/PurleyOpenBoardPkg/Features/Ipmi/Library/IpmiLibKcs/IpmiLibKcs.c
+++ b/Platform/Intel/PurleyOpenBoardPkg/Features/Ipmi/Library/IpmiLibKcs/IpmiLibKcs.c
@@ -193,7 +193,7 @@ UpdateBmcStatusOnResponse (
 **/
 EFI_STATUS
 EFIAPI
-IpmiSubmitCommand (
+IpmiSendCommand (
   IN     UINT8     NetFunction,
   IN     UINT8     Command,
   IN     UINT8     *RequestData,
@@ -222,7 +222,7 @@ IpmiSubmitCommand (
     }
 
     IpmiInstance->Signature                      = SM_IPMI_BMC_SIGNATURE;
-    IpmiInstance->KcsTimeoutPeriod               = PcdGet64(PcdIpmiKcsTimeoutPeriod); 
+    IpmiInstance->KcsTimeoutPeriod               = PcdGet64(PcdIpmiKcsTimeoutPeriod);
     IpmiInstance->SlaveAddress                   = PcdGet8(PcdIpmiBmcSlaveAddress);
     IpmiInstance->IpmiIoBase                     = PcdGet16(PcdIpmiIoBaseAddress);
     DEBUG((DEBUG_INFO,"IPMI KcsTimeoutPeriod=0x%x\n", IpmiInstance->KcsTimeoutPeriod));
@@ -269,7 +269,7 @@ IpmiSubmitCommand (
   }
 
   Status = SendDataToBmcPort (
-  	IpmiInstance->KcsTimeoutPeriod,
+    IpmiInstance->KcsTimeoutPeriod,
     IpmiInstance->IpmiIoBase,
     (UINT8 *)IpmiCommand,
     (UINT8)(RequestDataSize + EFI_IPMI_COMMAND_HEADER_SIZE)
@@ -287,7 +287,7 @@ IpmiSubmitCommand (
   //
   DataSize = MAX_TEMP_DATA;
   Status = ReceiveBmcDataFromPort (
-  	IpmiInstance->KcsTimeoutPeriod,
+    IpmiInstance->KcsTimeoutPeriod,
     IpmiInstance->IpmiIoBase,
     (UINT8 *)IpmiResponse,
     &DataSize
@@ -301,8 +301,8 @@ IpmiSubmitCommand (
   }
 
   //
-  // If we got this far without any error codes, but the DataSize is 0 then the 
-  // command response failed, so do not continue.  
+  // If we got this far without any error codes, but the DataSize is 0 then the
+  // command response failed, so do not continue.
   //
   if (DataSize < 3) {
     Status = EFI_DEVICE_ERROR;
-- 
2.37.1.windows.1


^ permalink raw reply related	[flat|nested] 22+ messages in thread

* [edk2-platforms][PATCH 2/7] ManageabilityPkg: Add diagrams
  2023-02-07 16:22 [edk2-platforms][PATCH 0/7] Implementation of IPMI Protocol Chang, Abner
  2023-02-07 16:22 ` [edk2-platforms][PATCH 1/7] IpmiFeaturePkg: Rename IpmiSubmitCommand function Chang, Abner
@ 2023-02-07 16:22 ` Chang, Abner
  2023-02-07 16:22 ` [edk2-platforms][PATCH 3/7] ManageabilityPkg: Add Readme file Chang, Abner
                   ` (6 subsequent siblings)
  8 siblings, 0 replies; 22+ messages in thread
From: Chang, Abner @ 2023-02-07 16:22 UTC (permalink / raw)
  To: devel
  Cc: Liming Gao, Isaac Oram, Nate DeSimone, Nickle Wang,
	Igor Kulchytskyy, Abdul Lateef Attar

From: Abner Chang <abner.chang@amd.com>

Add diagram of ManageabilityPkg.

Signed-off-by: Abner Chang <abner.chang@amd.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Isaac Oram <isaac.w.oram@intel.com>
Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
Cc: Nickle Wang <nicklew@nvidia.com>
Cc: Igor Kulchytskyy <igork@ami.com>
Cc: Abdul Lateef Attar <abdattar@amd.com>
---
 .../Documents/Media/ManageabilityDriverStack.svg                 | 1 +
 1 file changed, 1 insertion(+)
 create mode 100644 Features/ManageabilityPkg/Documents/Media/ManageabilityDriverStack.svg

diff --git a/Features/ManageabilityPkg/Documents/Media/ManageabilityDriverStack.svg b/Features/ManageabilityPkg/Documents/Media/ManageabilityDriverStack.svg
new file mode 100644
index 0000000000..987de40874
--- /dev/null
+++ b/Features/ManageabilityPkg/Documents/Media/ManageabilityDriverStack.svg
@@ -0,0 +1 @@
+<svg width="1280" height="720" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" overflow="hidden"><defs><clipPath id="clip0"><rect x="0" y="0" width="1280" height="720"/></clipPath><image width="213" height="84" xlink:href="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAANUAAABUCAMAAAAicoLMAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAEpUExURQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFQnk6sAAABidFJOUwABAggJChAREhgZGiAiKCowMTI3ODk6P0BBQkdISk9RUllaX2BhZ2hpb3Bxd3l/gIGGiI6QlZaYnZ6foKWmqK2ur7C1tre4vb6/wMXGx8jNzs/V1tfd3t/l5uft7/X29/3+82qPCgAAAAlwSFlzAAAOwwAADsMBx2+oZAAABPJJREFUeF7tmXtb1EYUhye7rGVVKNJWbpYWtlooW6TFaimKFqrrpUWptaDALpnv/yE6yfzmzCUDO8nGx/I88/4155wkm5dkz9kEFolEIpFIJBKJRCKRSCQSKUcSCDa/HLTn5oO4ie0vB829lIdwiO3Lg2udgYwJKufdCnYVkQkqLoFa1a2WNhRLyJjcRm0csc00qtdliIhYnp+/1mh4zcK0KluNDXAEzk/GkDN4gdozT41NnKA6K2NEFoPdtc99YkFala1WcICMNeQMlBXfKZ7Z+CFqF1llHCx7vEK0Klsd4AAZh8XPJiv+s1ts/YXKUCtx5OVKWlWtbmB/yTfIarQVX7FPLNlFXjDUivMHLbmNwXCtqlYPsL9kH1mNYcW/NbWSe8hmBFjx/WLDGapV0eoz3StybiBPmFYDYygm5vexYHWmMM96v/zVqmi1ht0Vu8gTphU/mUCWsa+RkjhWOJnJmcX7fxtinoYjtApg64xqVonqFepQg6uoKCwrfngN6Wn7GvutcmZ6+jRXkDNo/tpzeYOtBdWsvsLefEt99D1UFLYVP5B30cQHxOACK8a6pPXBN/QKzGJrQTWrbezdb/+JlTuJHSv+rCGS4/8gUlxoxe6QlmcgFu/KUa2oVzxhHazcD3at+HbCxl5iTVxsxbaQ91ys1hwWmlGtqFcssuZ7LJ1JXLDiGw11hTVDrNp9FLjr0Hp6FyvNiFbUK96LYBNrZxKTlf7O6+lLuSFW7BEK7te29ZTXbkW94icRXFenaE9isvrhFAvN0V0shlp9jwI/QEIipOq3UndSOplFfyCyJzFZzS7oqyU5nfoOq6FWdKIDJHIyqdqtqFc8z8NFRPYk1lZs1dZKF1mwVRsFzpvICHKp2q2oV3RkrPqFNYkNK7ZpaqWrLNyK0dDG86VAStVtlaih08ffr4vY+kqbVuwx1oJ0U8ThVurxUltBqm6rOezJ7yNB/decxJZV8zUCzveyYrDVFRQ4v4KMkqrbagd78i+Q0P3XmMSWFWu/Q/Q6v77BVl+iwDkSJFWz1VV1q7/F26AkocMZk9i2YpPHefCunUfBVksoqMoYSdVsRb1iG28UBfSbVU9ix4otZLfp8ZQMgq3o2fSJjH9DKKjVinqFFz2JXSvWSdP+AtahVvo91h2ZoKPWbEW9wg9N4oIV6/YwCYKtkg3kqQV+LCvqFX5oEhetDAKtbtKleoPMR7KiXnEONIlHt0qmaVilt5AzrDYaNuLpWQ/7klbUK/CugECaJvGoVkljmaRUr7CsHEQjMl7RlLPSveIVXhaAV0jTJK5mJSeF+MuP3zaeMI/zX9EZ51rl3VVrlbOiXvEvEgS9CsEkrmR1Iv95sPNyH4mcvrr/zrfCyCCtclb04NdFgqAnfUziSlZezqh1nmul5iBplbKiXtGXvxEM6Ekfk7guq/TIPIDfiqRIq5TVj/lBBPT11ayjhElcj1V69lD9rM3xWhlSSquMVUL/oZlBxkC/OckncQ1WaXq6RX1C4rOypKBVxuoWunj6FgmLRyimv2fRCwSp1wo1VURkcXb0eLVwn3usHCmpVcaqizauf/qYTKHY28ueNjYR9NwPzVhATRURKR6ur693nKskKVoVpHKtUt+rT07ByiOVaRUGz/+a57g9FV4pofULFpeDjrg3TfxSkUgkEolEIpFIJBKJRCKRTw9j/wEy9fOTWOvuAwAAAABJRU5ErkJggg==" preserveAspectRatio="none" id="img1"></image></defs><g clip-path="url(#clip0)"><rect x="0" y="0" width="1280" height="719.812"/><use width="100%" height="100%" xlink:href="#img1" fill="none" transform="translate(1014 35)"></use><rect x="303.5" y="180.453" width="117" height="78.9794" stroke="#ED1C24" stroke-width="2.66736" stroke-linejoin="round" stroke-miterlimit="10"/><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 314.579 214)">PLDM MCTP</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 316.673 237)">Lib Instance</text><rect x="147.5" y="121.468" width="98" height="108.972" stroke="#BDFBFF" stroke-width="2.66736" stroke-linejoin="round" stroke-miterlimit="10" fill="#00AAB5"/><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 173.183 161)">PLDM</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 159.28 184)">Transport</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 163.914 206)">Protocol</text><rect x="147" y="229.94" width="116" height="35.9906" fill="#ED1C24"/><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="15" transform="matrix(1 0 0 0.99974 156.537 244)">PLDM Transport</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="15" transform="matrix(1 0 0 0.99974 184.211 261)">Library</text><rect x="303" y="259.932" width="117" height="42.9888" fill="#00AAB5"/><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="15" transform="matrix(1 0 0 0.99974 322.628 280)">Invoke MCTP</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="15" transform="matrix(1 0 0 0.99974 336.631 297)">Protocol</text><rect x="469.5" y="121.468" width="98" height="108.972" stroke="#BDFBFF" stroke-width="2.66736" stroke-linecap="square" stroke-linejoin="round" stroke-miterlimit="10" stroke-dasharray="8.00208 2.66736" fill="#00AAB5"/><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 495.364 161)">MCTP</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 481.427 184)">Transport</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 486.061 206)">Protocol</text><rect x="469" y="229.94" width="118" height="35.9906" fill="#ED1C24"/><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="15" transform="matrix(1 0 0 0.99974 479.787 244)">MCTP Transport</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="15" transform="matrix(1 0 0 0.99974 507.381 261)">Library</text><rect x="787.5" y="120.469" width="98" height="108.972" stroke="#BDFBFF" stroke-width="2.66736" stroke-linejoin="round" stroke-miterlimit="10" fill="#00AAB5"/><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 818.493 160)">IPMI</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 799.588 183)">Transport</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 804.223 205)">Protocol</text><rect x="785" y="219.943" width="119" height="34.9909" fill="#ED1C24"/><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="15" transform="matrix(1 0 0 0.99974 800.432 234)">IPMI Transport</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="15" transform="matrix(1 0 0 0.99974 824.184 251)">Library</text><rect x="934.5" y="179.453" width="117" height="78.9794" stroke="#ED1C24" stroke-width="2.66736" stroke-linejoin="round" stroke-miterlimit="10"/><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 946.198 213)">IPMI KCS Lib</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 960.728 236)">Instance</text><path d="M0-0.5 20.0536-0.5C20.3298-0.5 20.5536-0.276142 20.5536 0L20.5536 28.2331 20.0536 27.7331 33.4406 27.7331 33.4406 28.7331 20.0536 28.7331C19.7775 28.7331 19.5536 28.5092 19.5536 28.2331L19.5536 0 20.0536 0.5 0 0.5ZM32.1073 24.2331 40.1073 28.2331 32.1073 32.2331Z" fill="#ED161E" transform="matrix(1.00026 0 0 -1 263.5 248.676)"/><path d="M0-0.5 24.2879-0.5C24.564-0.5 24.7879-0.276142 24.7879 0L24.7879 106.129 24.2879 105.629 41.9091 105.629 41.9091 106.629 24.2879 106.629C24.0117 106.629 23.7879 106.405 23.7879 106.129L23.7879 0 24.2879 0.5 0 0.5ZM40.5757 102.129 48.5757 106.129 40.5757 110.129Z" fill="#00AAB5" transform="matrix(1.00026 0 0 -1 420.5 282.583)"/><path d="M0-0.5 18.1056-0.5C18.3817-0.5 18.6056-0.276142 18.6056 0L18.6056 27.2119 18.1056 26.7119 29.5445 26.7119 29.5445 27.7119 18.1056 27.7119C17.8294 27.7119 17.6056 27.488 17.6056 27.2119L17.6056 0 18.1056 0.5 0 0.5ZM28.2111 23.2119 36.2111 27.2119 28.2111 31.2119Z" fill="#ED161E" transform="matrix(1.00026 0 0 -1 587.5 248.654)"/><path d="M0-0.5 14.8276-0.5C15.1038-0.5 15.3276-0.276142 15.3276 0L15.3276 18.5851 14.8276 18.0851 22.9886 18.0851 22.9886 19.0851 14.8276 19.0851C14.5515 19.0851 14.3276 18.8612 14.3276 18.5851L14.3276 0 14.8276 0.5 0 0.5ZM21.6552 14.5851 29.6552 18.5851 21.6552 22.5851Z" fill="#ED1C24" transform="matrix(1.00026 0 0 -1 904.5 238.028)"/><rect x="303.5" y="365.405" width="117" height="88.9768" stroke="#ED1C24" stroke-width="2.66736" stroke-linejoin="round" stroke-miterlimit="10"/><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 339.469 393)">Other</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 325.232 415)">Transport</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 326.098 436)">Instances</text><rect x="623.5" y="324.416" width="117" height="78.9794" stroke="#ED1C24" stroke-width="2.66736" stroke-linejoin="round" stroke-miterlimit="10"/><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 659.057 346)">MCTP</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 633.598 370)">PCI/VDM Lib</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 649.655 394)">Instance</text><rect x="935.5" y="325.415" width="117" height="78.9794" stroke="#ED1C24" stroke-width="2.66736" stroke-linejoin="round" stroke-miterlimit="10"/><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 948.652 359)">IPMI I2C Lib</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 961.542 382)">Instance</text><path d="M263.5 247.935 267.501 247.935 267.501 248.935 263.5 248.935ZM270.502 247.935 274.503 247.935 274.503 248.935 270.502 248.935ZM277.504 247.935 281.505 247.935 281.505 248.935 277.504 248.935ZM284.059 249.382 284.059 253.382 283.059 253.382 283.059 249.382ZM284.059 256.382 284.059 260.382 283.059 260.382 283.059 256.382ZM284.059 263.382 284.059 267.382 283.059 267.382 283.059 263.382ZM284.059 270.382 284.059 274.382 283.059 274.382 283.059 270.382ZM284.059 277.382 284.059 281.382 283.059 281.382 283.059 277.382ZM284.059 284.382 284.059 288.382 283.059 288.382 283.059 284.382ZM284.059 291.382 284.059 295.382 283.059 295.382 283.059 291.382ZM284.059 298.382 284.059 302.382 283.059 302.382 283.059 298.382ZM284.059 305.382 284.059 309.382 283.059 309.382 283.059 305.382ZM284.059 312.382 284.059 316.382 283.059 316.382 283.059 312.382ZM284.059 319.382 284.059 323.382 283.059 323.382 283.059 319.382ZM284.059 326.382 284.059 330.382 283.059 330.382 283.059 326.382ZM284.059 333.382 284.059 337.382 283.059 337.382 283.059 333.382ZM284.059 340.382 284.059 344.382 283.059 344.382 283.059 340.382ZM284.059 347.382 284.059 351.382 283.059 351.382 283.059 347.382ZM284.059 354.382 284.059 358.382 283.059 358.382 283.059 354.382ZM284.059 361.382 284.059 365.382 283.059 365.382 283.059 361.382ZM284.059 368.382 284.059 372.382 283.059 372.382 283.059 368.382ZM284.059 375.382 284.059 379.382 283.059 379.382 283.059 375.382ZM284.059 382.382 284.059 386.382 283.059 386.382 283.059 382.382ZM284.059 389.382 284.059 393.382 283.059 393.382 283.059 389.382ZM284.059 396.382 284.059 400.382 283.059 400.382 283.059 396.382ZM284.059 403.382 284.059 407.382 283.059 407.382 283.059 403.382ZM284.014 409.427 288.015 409.427 288.015 410.427 284.014 410.427ZM291.016 409.427 295.017 409.427 295.017 410.427 291.016 410.427ZM295.616 405.927 303.618 409.927 295.616 413.927Z" fill="#ED161E"/><path d="M587.5 247.935 591.501 247.935 591.501 248.935 587.5 248.935ZM594.502 247.935 598.503 247.935 598.503 248.935 594.502 248.935ZM601.504 247.935 605.505 247.935 605.505 248.935 601.504 248.935ZM606.11 251.33 606.11 255.33 605.11 255.33 605.11 251.33ZM606.11 258.33 606.11 262.33 605.11 262.33 605.11 258.33ZM606.11 265.33 606.11 269.33 605.11 269.33 605.11 265.33ZM606.11 272.33 606.11 276.33 605.11 276.33 605.11 272.33ZM606.11 279.33 606.11 283.33 605.11 283.33 605.11 279.33ZM606.11 286.33 606.11 290.33 605.11 290.33 605.11 286.33ZM606.11 293.33 606.11 297.33 605.11 297.33 605.11 293.33ZM606.11 300.33 606.11 304.33 605.11 304.33 605.11 300.33ZM606.11 307.33 606.11 311.33 605.11 311.33 605.11 307.33ZM606.11 314.33 606.11 318.33 605.11 318.33 605.11 314.33ZM606.11 321.33 606.11 325.33 605.11 325.33 605.11 321.33ZM606.11 328.33 606.11 332.33 605.11 332.33 605.11 328.33ZM606.11 335.33 606.11 339.33 605.11 339.33 605.11 335.33ZM606.11 342.33 606.11 346.33 605.11 346.33 605.11 342.33ZM606.11 349.33 606.11 353.33 605.11 353.33 605.11 349.33ZM606.11 356.33 606.11 360.33 605.11 360.33 605.11 356.33ZM606.11 363.33 606.11 363.701 605.61 363.201 609.24 363.201 609.24 364.201 605.61 364.201C605.334 364.201 605.11 363.977 605.11 363.701L605.11 363.33ZM612.241 363.201 616.242 363.201 616.242 364.201 612.241 364.201ZM615.719 359.701 623.721 363.701 615.719 367.701Z" fill="#ED161E"/><path d="M908.5 235.938 912.501 235.938 912.501 236.938 908.5 236.938ZM915.502 235.938 919.503 235.938 919.503 236.938 915.502 236.938ZM922.504 235.938 923.271 235.938C923.547 235.938 923.771 236.162 923.771 236.438L923.771 239.672 922.77 239.672 922.77 236.438 923.271 236.938 922.504 236.938ZM923.771 242.672 923.771 246.672 922.77 246.672 922.77 242.672ZM923.771 249.672 923.771 253.672 922.77 253.672 922.77 249.672ZM923.771 256.672 923.771 260.672 922.77 260.672 922.77 256.672ZM923.771 263.672 923.771 267.672 922.77 267.672 922.77 263.672ZM923.771 270.672 923.771 274.672 922.77 274.672 922.77 270.672ZM923.771 277.672 923.771 281.672 922.77 281.672 922.77 277.672ZM923.771 284.672 923.771 288.672 922.77 288.672 922.77 284.672ZM923.771 291.672 923.771 295.672 922.77 295.672 922.77 291.672ZM923.771 298.672 923.771 302.672 922.77 302.672 922.77 298.672ZM923.771 305.672 923.771 309.672 922.77 309.672 922.77 305.672ZM923.771 312.672 923.771 316.672 922.77 316.672 922.77 312.672ZM923.771 319.672 923.771 323.672 922.77 323.672 922.77 319.672ZM923.771 326.672 923.771 330.672 922.77 330.672 922.77 326.672ZM923.771 333.672 923.771 337.672 922.77 337.672 922.77 333.672ZM923.771 340.672 923.771 344.672 922.77 344.672 922.77 340.672ZM923.771 347.672 923.771 351.672 922.77 351.672 922.77 347.672ZM924.037 353.406 928.038 353.406 928.038 354.406 924.037 354.406ZM931.039 353.406 931.372 353.406 931.372 354.406 931.039 354.406ZM930.039 349.906 938.041 353.906 930.039 357.906Z" fill="#ED161E"/><rect x="932" y="259.932" width="120" height="39.9896" fill="#00AAB5"/><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="15" transform="matrix(1 0 0 0.99974 959.422 279)">Invoke KCS</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="15" transform="matrix(1 0 0 0.99974 967.004 296)">Protocol</text><rect x="1084.5" y="119.469" width="96" height="108.972" stroke="#BDFBFF" stroke-width="2.66736" stroke-linejoin="round" stroke-miterlimit="10" fill="#00AAB5"/><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 1118.16 159)">KCS</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 1095.48 182)">Transport</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 1100.12 204)">Protocol</text><path d="M0-0.5 15.9054-0.5C16.1816-0.5 16.4054-0.276142 16.4054 0L16.4054 106.402 15.9054 105.902 25.144 105.902 25.144 106.902 15.9054 106.902C15.6293 106.902 15.4054 106.678 15.4054 106.402L15.4054 0 15.9054 0.5 0 0.5ZM23.8107 102.402 31.8107 106.402 23.8107 110.402Z" fill="#00AAB5" transform="matrix(1.00026 0 0 -1 1052.5 280.857)"/><rect x="623.5" y="181.453" width="117" height="78.9794" stroke="#ED1C24" stroke-width="2.66736" stroke-linejoin="round" stroke-miterlimit="10"/><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 639.472 215)">MCTP IPMI</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 636.565 239)">Lib Instance</text><rect x="621" y="261.932" width="120" height="40.9893" fill="#00AAB5"/><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="15" transform="matrix(1 0 0 0.99974 645.761 282)">Invoke IPMI</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="15" transform="matrix(1 0 0 0.99974 655.93 298)">Protocol</text><path d="M0-0.5 23.0193-0.5C23.2955-0.5 23.5193-0.276142 23.5193 0L23.5193 108.111 23.0193 107.611 39.3719 107.611 39.3719 108.611 23.0193 108.611C22.7432 108.611 22.5193 108.387 22.5193 108.111L22.5193 0 23.0193 0.5 0 0.5ZM38.0385 104.111 46.0385 108.111 38.0385 112.111Z" fill="#00AAB5" transform="matrix(1.00026 0 0 -1 741.5 283.566)"/><rect x="1086.5" y="308.42" width="93.0001" height="103.973" stroke="#BDFBFF" stroke-width="2.66736" stroke-linejoin="round" stroke-miterlimit="10" fill="#00AAB5"/><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 1120.26 355)">I2C</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 1100.58 378)">Protocol</text><path d="M0-0.5 4-0.5 4 0.5 0 0.5ZM7-0.5 11-0.5 11 0.5 7 0.5ZM14-0.5 17.0536-0.5C17.3298-0.5 17.5536-0.276142 17.5536 0L17.5536 0.946352 16.5536 0.946352 16.5536 0 17.0536 0.5 14 0.5ZM17.5536 3.94635 17.5536 4.29795 17.0536 3.79795 20.702 3.79795 20.702 4.79795 17.0536 4.79795C16.7775 4.79795 16.5536 4.5741 16.5536 4.29795L16.5536 3.94635ZM23.702 3.79795 27.4406 3.79795 27.4406 4.79795 23.702 4.79795ZM26.1073 0.297953 34.1073 4.29795 26.1073 8.29795Z" fill="#00AAB5" transform="matrix(1.00026 0 0 -1 1052.5 364.704)"/><rect x="623.5" y="428.388" width="117" height="78.9794" stroke="#ED1C24" stroke-width="2.66736" stroke-linejoin="round" stroke-miterlimit="10"/><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 659.054 450)">MCTP</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 656.354 474)">I2C</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 684.694 474)">Lib</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 649.652 498)">Instance</text><path d="M587.5 247.935 591.501 247.935 591.501 248.935 587.5 248.935ZM594.502 247.935 598.503 247.935 598.503 248.935 594.502 248.935ZM601.504 247.935 605.505 247.935 605.505 248.935 601.504 248.935ZM606.111 251.33 606.111 255.33 605.11 255.33 605.11 251.33ZM606.111 258.33 606.111 262.33 605.11 262.33 605.11 258.33ZM606.111 265.33 606.111 269.33 605.11 269.33 605.11 265.33ZM606.111 272.33 606.111 276.33 605.11 276.33 605.11 272.33ZM606.111 279.33 606.111 283.33 605.11 283.33 605.11 279.33ZM606.111 286.33 606.111 290.33 605.11 290.33 605.11 286.33ZM606.111 293.33 606.111 297.33 605.11 297.33 605.11 293.33ZM606.111 300.33 606.111 304.33 605.11 304.33 605.11 300.33ZM606.111 307.33 606.111 311.33 605.11 311.33 605.11 307.33ZM606.111 314.33 606.111 318.33 605.11 318.33 605.11 314.33ZM606.111 321.33 606.111 325.33 605.11 325.33 605.11 321.33ZM606.111 328.33 606.111 332.33 605.11 332.33 605.11 328.33ZM606.111 335.33 606.111 339.33 605.11 339.33 605.11 335.33ZM606.111 342.33 606.111 346.33 605.11 346.33 605.11 342.33ZM606.111 349.33 606.111 353.33 605.11 353.33 605.11 349.33ZM606.111 356.33 606.111 360.33 605.11 360.33 605.11 356.33ZM606.111 363.33 606.111 367.33 605.11 367.33 605.11 363.33ZM606.111 370.33 606.111 374.33 605.11 374.33 605.11 370.33ZM606.111 377.33 606.111 381.33 605.11 381.33 605.11 377.33ZM606.111 384.33 606.111 388.33 605.11 388.33 605.11 384.33ZM606.111 391.33 606.111 395.33 605.11 395.33 605.11 391.33ZM606.111 398.33 606.111 402.33 605.11 402.33 605.11 398.33ZM606.111 405.33 606.111 409.33 605.11 409.33 605.11 405.33ZM606.111 412.33 606.111 416.33 605.11 416.33 605.11 412.33ZM606.111 419.33 606.111 423.33 605.11 423.33 605.11 419.33ZM606.111 426.33 606.111 430.33 605.11 430.33 605.11 426.33ZM606.111 433.33 606.111 437.33 605.11 437.33 605.11 433.33ZM606.111 440.33 606.111 444.33 605.11 444.33 605.11 440.33ZM606.111 447.33 606.111 451.33 605.11 451.33 605.11 447.33ZM606.111 454.33 606.111 458.33 605.11 458.33 605.11 454.33ZM606.111 461.33 606.111 465.33 605.11 465.33 605.11 461.33ZM605.996 467.444 609.997 467.444 609.997 468.444 605.996 468.444ZM612.998 467.444 616.999 467.444 616.999 468.444 612.998 468.444ZM615.719 463.944 623.721 467.944 615.719 471.944Z" fill="#ED161E"/><path d="M740.5 467.378 896.443 467.378 896.443 544.926 1052.39 544.926" stroke="#00AAB5" stroke-width="1.00026" stroke-linejoin="round" stroke-miterlimit="10" fill="none" fill-rule="evenodd"/><path d="M60.5 78.4797C60.5 75.1668 63.1863 72.4812 66.5 72.4812L141.5 72.4812C144.814 72.4812 147.5 75.1668 147.5 78.4797L147.5 102.473C147.5 105.786 144.814 108.472 141.5 108.472L66.5 108.472C63.1863 108.472 60.5 105.786 60.5 102.473Z" stroke="#BDFBFF" stroke-width="2.66736" stroke-linejoin="round" stroke-miterlimit="10" fill="#FFC000" fill-rule="evenodd"/><text font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="13" transform="matrix(1 0 0 0.99974 74.8648 94)">PLDM BCC</text><path d="M95.5 35.4908C95.5 32.1779 98.1864 29.4923 101.5 29.4923L176.5 29.4923C179.814 29.4923 182.5 32.1779 182.5 35.4908L182.5 59.4843C182.5 62.7972 179.814 65.4828 176.5 65.4828L101.5 65.4828C98.1864 65.4828 95.5 62.7972 95.5 59.4843Z" stroke="#BDFBFF" stroke-width="2.66736" stroke-linejoin="round" stroke-miterlimit="10" fill="#FFC000" fill-rule="evenodd"/><text font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="13" transform="matrix(1 0 0 0.99974 122.774 43)">PLDM</text><text font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="13" transform="matrix(1 0 0 0.99974 117.193 59)">SMBIOS</text><path d="M35.5 184.285C35.5 181.065 38.1117 178.454 41.3334 178.454L116.667 178.454C119.888 178.454 122.5 181.065 122.5 184.285L122.5 207.613C122.5 210.833 119.888 213.444 116.667 213.444L41.3334 213.444C38.1117 213.444 35.5 210.833 35.5 207.613Z" stroke="#BDFBFF" stroke-width="2.66736" stroke-linejoin="round" stroke-miterlimit="10" fill="#FFC000" fill-rule="evenodd"/><text font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="13" transform="matrix(1 0 0 0.99974 49.991 200)">PLDM FRU</text><path d="M35.5 129.466C35.5 126.153 38.1863 123.468 41.5 123.468L116.5 123.468C119.814 123.468 122.5 126.153 122.5 129.466L122.5 153.46C122.5 156.773 119.814 159.458 116.5 159.458L41.5 159.458C38.1863 159.458 35.5 156.773 35.5 153.46Z" stroke="#BDFBFF" stroke-width="2.66736" stroke-linejoin="round" stroke-miterlimit="10" fill="#FFC000" fill-rule="evenodd"/><text font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="13" transform="matrix(1 0 0 0.99974 48.0052 145)">PLDM PMC</text><path d="M0.312923-0.389973 19.8973 15.325 19.2715 16.1049-0.312923 0.389973ZM21.0478 11.7607 24.784 19.8872 16.0411 18.0003Z" fill="#FFC000" transform="matrix(1.00026 0 0 -1 122.5 196.341)"/><path d="M122.907 141.172 144.055 170.748 143.241 171.329 122.093 141.754ZM146.127 167.628 147.526 176.462 139.617 172.28Z" fill="#FFC000"/><path d="M147.771 90.0559 191.131 117.943 190.59 118.784 147.229 90.8969ZM191.904 114.278 196.469 121.971 187.574 121.006Z" fill="#FFC000"/><path d="M182.992 47.3992 195.205 115.36 194.221 115.536 182.008 47.5761ZM198.415 113.428 195.892 122.01 190.539 114.843Z" fill="#FFC000"/><path d="M360.5 89.4768C360.5 86.1639 363.186 83.4782 366.5 83.4782L441.5 83.4782C444.814 83.4782 447.5 86.1639 447.5 89.4768L447.5 113.47C447.5 116.783 444.814 119.469 441.5 119.469L366.5 119.469C363.186 119.469 360.5 116.783 360.5 113.47Z" stroke="#BDFBFF" stroke-width="2.66736" stroke-linejoin="round" stroke-miterlimit="10" fill="#FFC000" fill-rule="evenodd"/><text font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="13" transform="matrix(1 0 0 0.99974 387.885 105)">PLDM</text><path d="M399.5 37.3237C399.5 34.1028 402.112 31.4918 405.334 31.4918L489.667 31.4918C492.888 31.4918 495.5 34.1028 495.5 37.3237L495.5 60.6508C495.5 63.8717 492.888 66.4827 489.667 66.4827L405.334 66.4827C402.112 66.4827 399.5 63.8717 399.5 60.6508Z" stroke="#BDFBFF" stroke-width="2.66736" stroke-linejoin="round" stroke-miterlimit="10" fill="#FFC000" fill-rule="evenodd"/><text font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="13" transform="matrix(1 0 0 0.99974 430.312 44)">NVMe</text><text font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="13" transform="matrix(1 0 0 0.99974 410.974 60)">Management</text><path d="M447.808 66.0886 512.984 116.955 512.369 117.743 447.192 66.8769ZM514.087 113.376 517.933 121.452 509.163 119.682Z" fill="#FFC000"/><path d="M447.638 100.993 511.661 119.354 511.385 120.315 447.362 101.954ZM511.344 115.622 517.933 121.673 509.138 123.312Z" fill="#FFC000"/><path d="M779.5 39.4898C779.5 36.1769 782.186 33.4912 785.5 33.4912L868.5 33.4912C871.814 33.4912 874.5 36.1769 874.5 39.4898L874.5 63.4833C874.5 66.7962 871.814 69.4819 868.5 69.4819L785.5 69.4819C782.186 69.4819 779.5 66.7962 779.5 63.4833Z" stroke="#BDFBFF" stroke-width="2.66736" stroke-linejoin="round" stroke-miterlimit="10" fill="#FFC000" fill-rule="evenodd"/><text font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="13" transform="matrix(1 0 0 0.99974 795.999 55)">IPMI NetFn</text><path d="M826.992 69.3907 835.346 114.408 834.363 114.591 826.008 69.5731ZM838.545 112.459 836.071 121.054 830.678 113.918Z" fill="#FFC000"/><path d="M666.5 74.4808C666.5 71.1678 669.186 68.4822 672.5 68.4822L756.5 68.4822C759.814 68.4822 762.5 71.1678 762.5 74.4808L762.5 98.4742C762.5 101.787 759.814 104.473 756.5 104.473L672.5 104.473C669.186 104.473 666.5 101.787 666.5 98.4742Z" stroke="#BDFBFF" stroke-width="2.66736" stroke-linejoin="round" stroke-miterlimit="10" fill="#FFC000" fill-rule="evenodd"/><text font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="13" transform="matrix(1 0 0 0.99974 686.967 82)">Redfish HI</text><text font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="13" transform="matrix(1 0 0 0.99974 697.803 98)">NetFn</text><path d="M762.71 86.0235 830.434 117.262 830.015 118.17 762.29 86.9315ZM830.69 113.525 836.28 120.509 827.337 120.789Z" fill="#FFC000"/><path d="M125.5 344.91C125.5 322.548 144.752 304.421 168.5 304.421 192.248 304.421 211.5 322.548 211.5 344.91 211.5 367.272 192.248 385.4 168.5 385.4 144.752 385.4 125.5 367.272 125.5 344.91Z" stroke="#FFFFFF" stroke-width="1.00026" stroke-linejoin="round" stroke-miterlimit="10" fill="none" fill-rule="evenodd"/><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="700" font-size="12" transform="matrix(1 0 0 0.99974 146.217 341)">Platform</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="700" font-size="12" transform="matrix(1 0 0 0.99974 137.802 356)">Replaceable</text><path d="M0 0 36.5634 38.5578" stroke="#FFFFFF" stroke-linejoin="round" stroke-miterlimit="10" fill="none" fill-rule="evenodd" transform="matrix(1.00026 0 0 -1 168.5 304.988)"/><path d="M0 0 28.2012 34.1434" stroke="#FFFFFF" stroke-linejoin="round" stroke-miterlimit="10" fill="none" fill-rule="evenodd" transform="matrix(1.00026 0 0 -1 500.5 300.574)"/><path d="M0 0 25.9776 25.5151" stroke="#FFFFFF" stroke-linejoin="round" stroke-miterlimit="10" fill="none" fill-rule="evenodd" transform="matrix(1.00026 0 0 -1 819.5 280.949)"/><path d="M452.5 345.41C452.5 320.564 473.99 300.422 500.5 300.422 527.01 300.422 548.5 320.564 548.5 345.41 548.5 370.256 527.01 390.398 500.5 390.398 473.99 390.398 452.5 370.256 452.5 345.41Z" stroke="#FFFFFF" stroke-width="1.00026" stroke-linejoin="round" stroke-miterlimit="10" fill="none" fill-rule="evenodd"/><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="700" font-size="13" transform="matrix(1 0 0 0.99974 475.504 341)">Platform</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="700" font-size="13" transform="matrix(1 0 0 0.99974 466.249 357)">Replaceable</text><path d="M769.5 328.414C769.5 302.464 791.886 281.427 819.5 281.427 847.114 281.427 869.5 302.464 869.5 328.414 869.5 354.365 847.114 375.402 819.5 375.402 791.886 375.402 769.5 354.365 769.5 328.414Z" stroke="#FFFFFF" stroke-width="1.00026" stroke-linejoin="round" stroke-miterlimit="10" fill="none" fill-rule="evenodd"/><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="700" font-size="14" transform="matrix(1 0 0 0.99974 793.285 324)">Platform</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="700" font-size="14" transform="matrix(1 0 0 0.99974 783.616 341)">Replaceable</text><rect x="936.5" y="429.388" width="118" height="78.9794" stroke="#ED1C24" stroke-width="2.66736" stroke-linejoin="round" stroke-miterlimit="10"/><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 972.728 451)">Other</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 958.491 474)">T</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 966.5 474)">ransport</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 959.358 496)">Instances</text><rect x="624.5" y="530.362" width="117" height="78.9794" stroke="#ED1C24" stroke-width="2.66736" stroke-linejoin="round" stroke-miterlimit="10"/><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 659.865 552)">MCTP</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 653.91 576)">USB</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 688.752 576)">Lib</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 650.462 600)">Instance</text><path d="M587.5 247.935 591.501 247.935 591.501 248.935 587.5 248.935ZM594.502 247.935 598.503 247.935 598.503 248.935 594.502 248.935ZM601.504 247.935 605.505 247.935 605.505 248.935 601.504 248.935ZM606.516 250.924 606.516 254.924 605.515 254.924 605.515 250.924ZM606.516 257.924 606.516 261.924 605.515 261.924 605.515 257.924ZM606.516 264.924 606.516 268.924 605.515 268.924 605.515 264.924ZM606.516 271.924 606.516 275.924 605.515 275.924 605.515 271.924ZM606.516 278.924 606.516 282.924 605.515 282.924 605.515 278.924ZM606.516 285.924 606.516 289.924 605.515 289.924 605.515 285.924ZM606.516 292.924 606.516 296.924 605.515 296.924 605.515 292.924ZM606.516 299.924 606.516 303.924 605.515 303.924 605.515 299.924ZM606.516 306.924 606.516 310.924 605.515 310.924 605.515 306.924ZM606.516 313.924 606.516 317.924 605.515 317.924 605.515 313.924ZM606.516 320.924 606.516 324.924 605.515 324.924 605.515 320.924ZM606.516 327.924 606.516 331.924 605.515 331.924 605.515 327.924ZM606.516 334.924 606.516 338.924 605.515 338.924 605.515 334.924ZM606.516 341.924 606.516 345.924 605.515 345.924 605.515 341.924ZM606.516 348.924 606.516 352.924 605.515 352.924 605.515 348.924ZM606.516 355.924 606.516 359.924 605.515 359.924 605.515 355.924ZM606.516 362.924 606.516 366.924 605.515 366.924 605.515 362.924ZM606.516 369.924 606.516 373.924 605.515 373.924 605.515 369.924ZM606.516 376.924 606.516 380.924 605.515 380.924 605.515 376.924ZM606.516 383.924 606.516 387.924 605.515 387.924 605.515 383.924ZM606.516 390.924 606.516 394.924 605.515 394.924 605.515 390.924ZM606.516 397.924 606.516 401.924 605.515 401.924 605.515 397.924ZM606.516 404.924 606.516 408.924 605.515 408.924 605.515 404.924ZM606.516 411.924 606.516 415.924 605.515 415.924 605.515 411.924ZM606.516 418.924 606.516 422.924 605.515 422.924 605.515 418.924ZM606.516 425.924 606.516 429.924 605.515 429.924 605.515 425.924ZM606.516 432.924 606.516 436.924 605.515 436.924 605.515 432.924ZM606.516 439.924 606.516 443.924 605.515 443.924 605.515 439.924ZM606.516 446.924 606.516 450.924 605.515 450.924 605.515 446.924ZM606.516 453.924 606.516 457.924 605.515 457.924 605.515 453.924ZM606.516 460.924 606.516 464.924 605.515 464.924 605.515 460.924ZM606.516 467.924 606.516 471.924 605.515 471.924 605.515 467.924ZM606.516 474.924 606.516 478.924 605.515 478.924 605.515 474.924ZM606.516 481.924 606.516 485.924 605.515 485.924 605.515 481.924ZM606.516 488.924 606.516 492.924 605.515 492.924 605.515 488.924ZM606.516 495.924 606.516 499.924 605.515 499.924 605.515 495.924ZM606.516 502.924 606.516 506.924 605.515 506.924 605.515 502.924ZM606.516 509.924 606.516 513.924 605.515 513.924 605.515 509.924ZM606.516 516.924 606.516 520.924 605.515 520.924 605.515 516.924ZM606.516 523.924 606.516 527.924 605.515 527.924 605.515 523.924ZM606.516 530.924 606.516 534.924 605.515 534.924 605.515 530.924ZM606.516 537.924 606.516 541.924 605.515 541.924 605.515 537.924ZM606.516 544.924 606.516 548.924 605.515 548.924 605.515 544.924ZM606.516 551.924 606.516 555.924 605.515 555.924 605.515 551.924ZM606.516 558.924 606.516 562.924 605.515 562.924 605.515 558.924ZM606.516 565.924 606.516 569.701 606.016 569.201 606.239 569.201 606.239 570.201 606.016 570.201C605.739 570.201 605.515 569.977 605.515 569.701L605.515 565.924ZM609.24 569.201 613.241 569.201 613.241 570.201 609.24 570.201ZM616.242 569.201 617.862 569.201 617.862 570.201 616.242 570.201ZM616.529 565.701 624.531 569.701 616.529 573.701Z" fill="#ED161E"/><path d="M904.5 237.938 908.501 237.938 908.501 238.938 904.5 238.938ZM911.502 237.938 915.503 237.938 915.503 238.938 911.502 238.938ZM918.504 237.938 922.079 237.938C922.355 237.938 922.579 238.162 922.579 238.438L922.579 238.863 921.579 238.863 921.579 238.438 922.079 238.938 918.504 238.938ZM922.579 241.863 922.579 245.863 921.579 245.863 921.579 241.863ZM922.579 248.863 922.579 252.863 921.579 252.863 921.579 248.863ZM922.579 255.863 922.579 259.863 921.579 259.863 921.579 255.863ZM922.579 262.863 922.579 266.863 921.579 266.863 921.579 262.863ZM922.579 269.863 922.579 273.863 921.579 273.863 921.579 269.863ZM922.579 276.863 922.579 280.863 921.579 280.863 921.579 276.863ZM922.579 283.863 922.579 287.863 921.579 287.863 921.579 283.863ZM922.579 290.863 922.579 294.863 921.579 294.863 921.579 290.863ZM922.579 297.863 922.579 301.863 921.579 301.863 921.579 297.863ZM922.579 304.863 922.579 308.863 921.579 308.863 921.579 304.863ZM922.579 311.863 922.579 315.863 921.579 315.863 921.579 311.863ZM922.579 318.863 922.579 322.863 921.579 322.863 921.579 318.863ZM922.579 325.863 922.579 329.863 921.579 329.863 921.579 325.863ZM922.579 332.863 922.579 336.863 921.579 336.863 921.579 332.863ZM922.579 339.863 922.579 343.863 921.579 343.863 921.579 339.863ZM922.579 346.863 922.579 350.863 921.579 350.863 921.579 346.863ZM922.579 353.863 922.579 357.863 921.579 357.863 921.579 353.863ZM922.579 360.863 922.579 364.863 921.579 364.863 921.579 360.863ZM922.579 367.863 922.579 371.863 921.579 371.863 921.579 367.863ZM922.579 374.863 922.579 378.863 921.579 378.863 921.579 374.863ZM922.579 381.863 922.579 385.863 921.579 385.863 921.579 381.863ZM922.579 388.863 922.579 392.863 921.579 392.863 921.579 388.863ZM922.579 395.863 922.579 399.863 921.579 399.863 921.579 395.863ZM922.579 402.863 922.579 406.863 921.579 406.863 921.579 402.863ZM922.579 409.863 922.579 413.863 921.579 413.863 921.579 409.863ZM922.579 416.863 922.579 420.863 921.579 420.863 921.579 416.863ZM922.579 423.863 922.579 427.863 921.579 427.863 921.579 423.863ZM922.579 430.863 922.579 434.863 921.579 434.863 921.579 430.863ZM922.579 437.863 922.579 441.863 921.579 441.863 921.579 437.863ZM922.579 444.863 922.579 448.863 921.579 448.863 921.579 444.863ZM922.579 451.863 922.579 455.863 921.579 455.863 921.579 451.863ZM922.579 458.863 922.579 462.863 921.579 462.863 921.579 458.863ZM922.579 465.863 922.579 469.004 922.079 468.504 922.939 468.504 922.939 469.504 922.079 469.504C921.803 469.504 921.579 469.28 921.579 469.004L921.579 465.863ZM925.94 468.504 929.789 468.504 929.789 469.504 925.94 469.504ZM928.455 465.004 936.457 469.004 928.455 473.004Z" fill="#ED161E"/><rect x="623.5" y="629.336" width="117" height="78.9794" stroke="#ED1C24" stroke-width="2.66736" stroke-linejoin="round" stroke-miterlimit="10"/><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 659.358 651)">Other</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 645.121 675)">Transport</text><text fill="#FFFFFF" font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="19" transform="matrix(1 0 0 0.99974 645.987 699)">Instances</text><path d="M587.5 247.935 591.501 247.935 591.501 248.935 587.5 248.935ZM594.502 247.935 598.503 247.935 598.503 248.935 594.502 248.935ZM601.504 247.935 605.505 247.935 605.505 248.935 601.504 248.935ZM606.11 251.33 606.11 255.33 605.11 255.33 605.11 251.33ZM606.11 258.33 606.11 262.33 605.11 262.33 605.11 258.33ZM606.11 265.33 606.11 269.33 605.11 269.33 605.11 265.33ZM606.11 272.33 606.11 276.33 605.11 276.33 605.11 272.33ZM606.11 279.33 606.11 283.33 605.11 283.33 605.11 279.33ZM606.11 286.33 606.11 290.33 605.11 290.33 605.11 286.33ZM606.11 293.33 606.11 297.33 605.11 297.33 605.11 293.33ZM606.11 300.33 606.11 304.33 605.11 304.33 605.11 300.33ZM606.11 307.33 606.11 311.33 605.11 311.33 605.11 307.33ZM606.11 314.33 606.11 318.33 605.11 318.33 605.11 314.33ZM606.11 321.33 606.11 325.33 605.11 325.33 605.11 321.33ZM606.11 328.33 606.11 332.33 605.11 332.33 605.11 328.33ZM606.11 335.33 606.11 339.33 605.11 339.33 605.11 335.33ZM606.11 342.33 606.11 346.33 605.11 346.33 605.11 342.33ZM606.11 349.33 606.11 353.33 605.11 353.33 605.11 349.33ZM606.11 356.33 606.11 360.33 605.11 360.33 605.11 356.33ZM606.11 363.33 606.11 367.33 605.11 367.33 605.11 363.33ZM606.11 370.33 606.11 374.33 605.11 374.33 605.11 370.33ZM606.11 377.33 606.11 381.33 605.11 381.33 605.11 377.33ZM606.11 384.33 606.11 388.33 605.11 388.33 605.11 384.33ZM606.11 391.33 606.11 395.33 605.11 395.33 605.11 391.33ZM606.11 398.33 606.11 402.33 605.11 402.33 605.11 398.33ZM606.11 405.33 606.11 409.33 605.11 409.33 605.11 405.33ZM606.11 412.33 606.11 416.33 605.11 416.33 605.11 412.33ZM606.11 419.33 606.11 423.33 605.11 423.33 605.11 419.33ZM606.11 426.33 606.11 430.33 605.11 430.33 605.11 426.33ZM606.11 433.33 606.11 437.33 605.11 437.33 605.11 433.33ZM606.11 440.33 606.11 444.33 605.11 444.33 605.11 440.33ZM606.11 447.33 606.11 451.33 605.11 451.33 605.11 447.33ZM606.11 454.33 606.11 458.33 605.11 458.33 605.11 454.33ZM606.11 461.33 606.11 465.33 605.11 465.33 605.11 461.33ZM606.11 468.33 606.11 472.33 605.11 472.33 605.11 468.33ZM606.11 475.33 606.11 479.33 605.11 479.33 605.11 475.33ZM606.11 482.33 606.11 486.33 605.11 486.33 605.11 482.33ZM606.11 489.33 606.11 493.33 605.11 493.33 605.11 489.33ZM606.11 496.33 606.11 500.33 605.11 500.33 605.11 496.33ZM606.11 503.33 606.11 507.33 605.11 507.33 605.11 503.33ZM606.11 510.33 606.11 514.33 605.11 514.33 605.11 510.33ZM606.11 517.33 606.11 521.33 605.11 521.33 605.11 517.33ZM606.11 524.33 606.11 528.33 605.11 528.33 605.11 524.33ZM606.11 531.33 606.11 535.33 605.11 535.33 605.11 531.33ZM606.11 538.33 606.11 542.33 605.11 542.33 605.11 538.33ZM606.11 545.33 606.11 549.33 605.11 549.33 605.11 545.33ZM606.11 552.33 606.11 556.33 605.11 556.33 605.11 552.33ZM606.11 559.33 606.11 563.33 605.11 563.33 605.11 559.33ZM606.11 566.33 606.11 570.33 605.11 570.33 605.11 566.33ZM606.11 573.33 606.11 577.33 605.11 577.33 605.11 573.33ZM606.11 580.33 606.11 584.33 605.11 584.33 605.11 580.33ZM606.11 587.33 606.11 591.33 605.11 591.33 605.11 587.33ZM606.11 594.33 606.11 598.33 605.11 598.33 605.11 594.33ZM606.11 601.33 606.11 605.33 605.11 605.33 605.11 601.33ZM606.11 608.33 606.11 612.33 605.11 612.33 605.11 608.33ZM606.11 615.33 606.11 619.33 605.11 619.33 605.11 615.33ZM606.11 622.33 606.11 626.33 605.11 626.33 605.11 622.33ZM606.11 629.33 606.11 633.33 605.11 633.33 605.11 629.33ZM606.11 636.33 606.11 640.33 605.11 640.33 605.11 636.33ZM606.11 643.33 606.11 647.33 605.11 647.33 605.11 643.33ZM606.11 650.33 606.11 654.33 605.11 654.33 605.11 650.33ZM606.11 657.33 606.11 661.33 605.11 661.33 605.11 657.33ZM606.11 664.33 606.11 668.33 605.11 668.33 605.11 664.33ZM608.141 668.299 612.142 668.299 612.142 669.299 608.141 669.299ZM615.143 668.299 617.052 668.299 617.052 669.299 615.143 669.299ZM615.719 664.799 623.721 668.799 615.719 672.799Z" fill="#ED161E"/><path d="M1049 547.738 1049 546.386C1049 546.11 1049.22 545.886 1049.5 545.886L1132.9 545.886 1132.4 546.386 1132.4 419.059 1133.4 419.059 1133.4 546.386C1133.4 546.662 1133.18 546.886 1132.9 546.886L1049.5 546.886 1050 546.386 1050 547.738ZM1128.9 420.393 1132.9 412.393 1136.9 420.393Z" fill="#00AAB5"/><path d="M509.5 52.3199C509.5 49.0989 512.112 46.4879 515.333 46.4879L599.667 46.4879C602.888 46.4879 605.5 49.0989 605.5 52.3199L605.5 75.647C605.5 78.8679 602.888 81.479 599.667 81.479L515.333 81.479C512.112 81.479 509.5 78.8679 509.5 75.647Z" stroke="#BDFBFF" stroke-width="2.66736" stroke-linejoin="round" stroke-miterlimit="10" fill="#FFC000" fill-rule="evenodd"/><text font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="13" transform="matrix(1 0 0 0.99974 527.107 59)">CXL Device</text><text font-family="Calibri,Calibri_MSFontService,sans-serif" font-weight="400" font-size="13" transform="matrix(1 0 0 0.99974 547.779 75)">CCI</text><path d="M0.358708-0.348323 34.4862 34.7966 33.7687 35.4932-0.358708 0.348323ZM36.0682 31.4018 38.7718 39.9277 30.3289 36.9749Z" fill="#FFC000" transform="matrix(-1.00026 0 0 1 557.282 81.4787)"/></g></svg>
\ No newline at end of file
-- 
2.37.1.windows.1


^ permalink raw reply related	[flat|nested] 22+ messages in thread

* [edk2-platforms][PATCH 3/7] ManageabilityPkg: Add Readme file
  2023-02-07 16:22 [edk2-platforms][PATCH 0/7] Implementation of IPMI Protocol Chang, Abner
  2023-02-07 16:22 ` [edk2-platforms][PATCH 1/7] IpmiFeaturePkg: Rename IpmiSubmitCommand function Chang, Abner
  2023-02-07 16:22 ` [edk2-platforms][PATCH 2/7] ManageabilityPkg: Add diagrams Chang, Abner
@ 2023-02-07 16:22 ` Chang, Abner
  2023-02-16  1:44   ` Isaac Oram
  2023-02-07 16:22 ` [edk2-platforms][PATCH 4/7] ManageabilityPkg: Initial package Chang, Abner
                   ` (5 subsequent siblings)
  8 siblings, 1 reply; 22+ messages in thread
From: Chang, Abner @ 2023-02-07 16:22 UTC (permalink / raw)
  To: devel
  Cc: Liming Gao, Isaac Oram, Nate DeSimone, Nickle Wang,
	Igor Kulchytskyy, Abdul Lateef Attar

From: Abner Chang <abner.chang@amd.com>

Add Readme file of edk2 platform ManageabilityPkg.

Signed-off-by: Abner Chang <abner.chang@amd.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Isaac Oram <isaac.w.oram@intel.com>
Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
Cc: Nickle Wang <nicklew@nvidia.com>
Cc: Igor Kulchytskyy <igork@ami.com>
Cc: Abdul Lateef Attar <abdattar@amd.com>
---
 Features/ManageabilityPkg/Readme.md | 37 +++++++++++++++++++++++++++++
 1 file changed, 37 insertions(+)
 create mode 100644 Features/ManageabilityPkg/Readme.md

diff --git a/Features/ManageabilityPkg/Readme.md b/Features/ManageabilityPkg/Readme.md
new file mode 100644
index 0000000000..880aa4aa48
--- /dev/null
+++ b/Features/ManageabilityPkg/Readme.md
@@ -0,0 +1,37 @@
+# EDK2 Manageability Package
+
+The edk2 Manageability package is introduced to provide edk2 drivers and
+libraries for the industry platform management standards, such as PLDM (Platform
+Level Data Model), MCTP (Management Component Transfer Protocol) and IPMI
+(Intelligent Platform Management Interface). The framework of edk2 Manageability
+package is designed to flexibly support transports for the above industry standards, the transports such as KCS or I2C for IPMI, PCI VDM (Vendor Defined
+Message), I2C or KCS for MCTP, or the OEM proprietary transports.
+
+## EDK2 Manageability Package Driver Stack
+
+Below figure shows the driver stacks which are abstracted to support disparate
+transports for the platform management.
+![Manageability Package Driver Stack](https://github.com/tianocore/edk2-platforms/blob/master/Features/ManageabilityPkg/Documents/Media/ManageabilityDriverStack.svg?raw=true)
+
+## Build the Manageability Package
+In order to use the modules provided by ManageabilityPkg, **PACKAGES_PATH** must
+contains the path to point to [edk2-platform Features](https://github.com/tianocore/edk2-platforms/tree/master/Features):
+
+```
+$ export PACKAGES_PATH=$PWD/edk2:$PWD/edk2-platforms:$PWD/edk2-platforms/Features
+```
+
+Due to the [IPMI Migration Work](#migration-of-ipmi-driver-stack-from-outofbandmanagement) is in progress, an
+additional package path is required to add to **PACKAGES_PATH** for the reference
+of IPMI modules those are currently located under
+[OutOfBandManagement](https://github.com/tianocore/edk2-platforms/tree/master/Features/Intel/OutOfBandManagement) folder.
+
+```
+$PWD/edk2-platforms/Features/Intel/OutOfBandManagement
+```
+
+## Migration of IPMI Driver Stack from OutOfBandManagement
+
+This is the ongoing task that relocates IPMI modules from OutOfBandManagement to
+under ManageabilityPkg. This task also requires to abstract the transport layer
+from IPMI driver in order to flexibly support different transports adopted on the platform.
-- 
2.37.1.windows.1


^ permalink raw reply related	[flat|nested] 22+ messages in thread

* [edk2-platforms][PATCH 4/7] ManageabilityPkg: Initial package
  2023-02-07 16:22 [edk2-platforms][PATCH 0/7] Implementation of IPMI Protocol Chang, Abner
                   ` (2 preceding siblings ...)
  2023-02-07 16:22 ` [edk2-platforms][PATCH 3/7] ManageabilityPkg: Add Readme file Chang, Abner
@ 2023-02-07 16:22 ` Chang, Abner
  2023-02-16  1:49   ` Isaac Oram
  2023-02-07 16:22 ` [edk2-platforms][PATCH 5/7] ManageabilityPkg: Implement Ipmi Protocol/Ppi Chang, Abner
                   ` (4 subsequent siblings)
  8 siblings, 1 reply; 22+ messages in thread
From: Chang, Abner @ 2023-02-07 16:22 UTC (permalink / raw)
  To: devel
  Cc: Liming Gao, Isaac Oram, Nate DeSimone, Abdul Lateef Attar,
	Nickle Wang, Igor Kulchytskyy

From: Abner Chang <abner.chang@amd.com>

Initial commit of ManageabilityPkg

Signed-off-by: Abner Chang <abner.chang@amd.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Isaac Oram <isaac.w.oram@intel.com>
Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
Cc: Abdul Lateef Attar <abdattar@amd.com>
Cc: Nickle Wang <nicklew@nvidia.com>
Cc: Igor Kulchytskyy <igork@ami.com>
---
 .../ManageabilityPkg/ManageabilityPkg.dec     | 18 +++++++++
 .../Include/CommonLibs.dsc.inc                | 40 +++++++++++++++++++
 .../ManageabilityPkg/ManageabilityPkg.dsc     | 23 +++++++++++
 3 files changed, 81 insertions(+)
 create mode 100644 Features/ManageabilityPkg/ManageabilityPkg.dec
 create mode 100644 Features/ManageabilityPkg/Include/CommonLibs.dsc.inc
 create mode 100644 Features/ManageabilityPkg/ManageabilityPkg.dsc

diff --git a/Features/ManageabilityPkg/ManageabilityPkg.dec b/Features/ManageabilityPkg/ManageabilityPkg.dec
new file mode 100644
index 0000000000..8a0e28f50b
--- /dev/null
+++ b/Features/ManageabilityPkg/ManageabilityPkg.dec
@@ -0,0 +1,18 @@
+## @file
+# Manageabilty Package
+# This is the package provides the edk2 drivers and libraries
+# those are related to the platform management.
+#
+# Copyright (C) 2023 Advanced Micro Devices, Inc. All rights reserved.<BR>
+# SPDX-License-Identifier: BSD-2-Clause-Patent
+#
+##
+
+[Defines]
+  DEC_SPECIFICATION = 0x0001001d
+  PACKAGE_NAME      = ManageabilityPkg
+  PACKAGE_GUID      = 36310119-4FB2-4BA3-959D-74C16B849F9E
+  PACKAGE_VERSION   = 1.0
+
+[Includes]
+  Include
diff --git a/Features/ManageabilityPkg/Include/CommonLibs.dsc.inc b/Features/ManageabilityPkg/Include/CommonLibs.dsc.inc
new file mode 100644
index 0000000000..2dc2d07f17
--- /dev/null
+++ b/Features/ManageabilityPkg/Include/CommonLibs.dsc.inc
@@ -0,0 +1,40 @@
+## @file
+# Common libraries for Manageabilty Package
+#
+# Copyright (C) 2023 Advanced Micro Devices, Inc. All rights reserved.<BR>
+# SPDX-License-Identifier: BSD-2-Clause-Patent
+#
+##
+
+[LibraryClasses]
+  UefiDriverEntryPoint|MdePkg/Library/UefiDriverEntryPoint/UefiDriverEntryPoint.inf
+  UefiBootServicesTableLib|MdePkg/Library/UefiBootServicesTableLib/UefiBootServicesTableLib.inf
+  UefiLib|MdePkg/Library/UefiLib/UefiLib.inf
+  BaseLib|MdePkg/Library/BaseLib/BaseLib.inf
+  BaseMemoryLib|MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf
+  PrintLib|MdePkg/Library/BasePrintLib/BasePrintLib.inf
+  DebugLib|MdePkg/Library/UefiDebugLibStdErr/UefiDebugLibStdErr.inf
+  PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf
+  DebugPrintErrorLevelLib|MdePkg/Library/BaseDebugPrintErrorLevelLib/BaseDebugPrintErrorLevelLib.inf
+  DebugLib|MdePkg/Library/BaseDebugLibNull/BaseDebugLibNull.inf
+  MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf
+
+[LibraryClasses.common.PEIM]
+  PeimEntryPoint|MdePkg/Library/PeimEntryPoint/PeimEntryPoint.inf
+  PeiServicesTablePointerLib|MdePkg/Library/PeiServicesTablePointerLibIdt/PeiServicesTablePointerLibIdt.inf
+  PeiServicesLib|MdePkg/Library/PeiServicesLib/PeiServicesLib.inf
+  MemoryAllocationLib|MdePkg/Library/PeiMemoryAllocationLib/PeiMemoryAllocationLib.inf
+  HobLib|MdePkg/Library/PeiHobLib/PeiHobLib.inf
+
+[LibraryClasses.common.DXE_SMM_DRIVER]
+  SmmServicesTableLib|MdePkg/Library/SmmServicesTableLib/SmmServicesTableLib.inf
+  MemoryAllocationLib|MdePkg/Library/SmmMemoryAllocationLib/SmmMemoryAllocationLib.inf
+
+[LibraryClasses.ARM, LibraryClasses.AARCH64]
+  #
+  # This library provides the instrinsic functions generated by a given compiler.
+  #
+  NULL|ArmPkg/Library/CompilerIntrinsicsLib/CompilerIntrinsicsLib.inf
+  NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf
+  ArmSoftFloatLib|ArmPkg/Library/ArmSoftFloatLib/ArmSoftFloatLib.inf
+
diff --git a/Features/ManageabilityPkg/ManageabilityPkg.dsc b/Features/ManageabilityPkg/ManageabilityPkg.dsc
new file mode 100644
index 0000000000..9ae398277f
--- /dev/null
+++ b/Features/ManageabilityPkg/ManageabilityPkg.dsc
@@ -0,0 +1,23 @@
+## @file
+# Manageabilty Package
+# This is the package provides edk2 drivers and libraries
+# those are related to the platform management.
+#
+# Copyright (C) 2023 Advanced Micro Devices, Inc. All rights reserved.<BR>
+# SPDX-License-Identifier: BSD-2-Clause-Patent
+#
+##
+
+[Defines]
+  PLATFORM_NAME                  = ManageabilityPkg
+  PLATFORM_GUID                  = 7A98123A-B194-40B6-A863-A52192F6D65D
+  PLATFORM_VERSION               = 1.0
+  DSC_SPECIFICATION              = 0x0001001e
+  OUTPUT_DIRECTORY               = Build/ManageabilityPkg
+  SUPPORTED_ARCHITECTURES        = IA32|X64|ARM|AARCH64|RISCV64
+  BUILD_TARGETS                  = DEBUG|RELEASE|NOOPT
+  SKUID_IDENTIFIER               = DEFAULT
+
+!include MdePkg/MdeLibs.dsc.inc
+!include ManageabilityPkg/Include/CommonLibs.dsc.inc
+
-- 
2.37.1.windows.1


^ permalink raw reply related	[flat|nested] 22+ messages in thread

* [edk2-platforms][PATCH 5/7] ManageabilityPkg: Implement Ipmi Protocol/Ppi
  2023-02-07 16:22 [edk2-platforms][PATCH 0/7] Implementation of IPMI Protocol Chang, Abner
                   ` (3 preceding siblings ...)
  2023-02-07 16:22 ` [edk2-platforms][PATCH 4/7] ManageabilityPkg: Initial package Chang, Abner
@ 2023-02-07 16:22 ` Chang, Abner
  2023-02-16  1:47   ` Isaac Oram
  2023-02-07 16:22 ` [edk2-platforms][PATCH 6/7] IpmiProtocol: Add to Manageability Package Chang, Abner
                   ` (3 subsequent siblings)
  8 siblings, 1 reply; 22+ messages in thread
From: Chang, Abner @ 2023-02-07 16:22 UTC (permalink / raw)
  To: devel
  Cc: Liming Gao, Isaac Oram, Nate DeSimone, Abdul Lateef Attar,
	Nickle Wang, Igor Kulchytskyy

From: Abner Chang <abner.chang@amd.com>

Add Ipmi Protocol/Ppi implementation. The underlying
implementation is provided by IpmiBaseLib.

Signed-off-by: Abner Chang <abner.chang@amd.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Isaac Oram <isaac.w.oram@intel.com>
Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
Cc: Abdul Lateef Attar <abdattar@amd.com>
Cc: Nickle Wang <nicklew@nvidia.com>
Cc: Igor Kulchytskyy <igork@ami.com>
---
 .../IpmiProtocol/Dxe/IpmiProtocolDxe.inf      |  37 +++++++
 .../Universal/IpmiProtocol/Pei/IpmiPpiPei.inf |  38 +++++++
 .../IpmiProtocol/Smm/IpmiProtocolSmm.inf      |  40 +++++++
 .../Universal/IpmiProtocol/Dxe/IpmiProtocol.c |  97 +++++++++++++++++
 .../Universal/IpmiProtocol/Pei/IpmiPpi.c      | 102 ++++++++++++++++++
 .../Universal/IpmiProtocol/Smm/IpmiProtocol.c |  98 +++++++++++++++++
 6 files changed, 412 insertions(+)
 create mode 100644 Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocolDxe.inf
 create mode 100644 Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpiPei.inf
 create mode 100644 Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocolSmm.inf
 create mode 100644 Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocol.c
 create mode 100644 Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpi.c
 create mode 100644 Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocol.c

diff --git a/Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocolDxe.inf b/Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocolDxe.inf
new file mode 100644
index 0000000000..0737a5ad8f
--- /dev/null
+++ b/Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocolDxe.inf
@@ -0,0 +1,37 @@
+## @file
+# IPMI Protocol DXE Driver.
+#
+# Copyright (C) 2023 Advanced Micro Devices, Inc. All rights reserved.<BR>
+# SPDX-License-Identifier: BSD-2-Clause-Patent
+##
+
+[Defines]
+  INF_VERSION                    = 0x0001001d
+  BASE_NAME                      = IpmiDxe
+  FILE_GUID                      = BC41B0C2-9D8A-42B5-A28F-02CE0D4A6C28
+  MODULE_TYPE                    = DXE_DRIVER
+  VERSION_STRING                 = 1.0
+  ENTRY_POINT                    = IpmiEntry
+
+#
+#  VALID_ARCHITECTURES           = IA32 X64 ARM AARCH64
+#
+
+[Sources]
+  IpmiProtocol.c
+
+[Packages]
+  MdePkg/MdePkg.dec
+  MdeModulePkg/MdeModulePkg.dec
+  IpmiFeaturePkg/IpmiFeaturePkg.dec
+
+[LibraryClasses]
+  IpmiBaseLib
+  UefiDriverEntryPoint
+  UefiBootServicesTableLib
+
+[Protocols]
+  gIpmiProtocolGuid               # PROTOCOL ALWAYS_PRODUCED
+
+[Depex]
+  TRUE
diff --git a/Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpiPei.inf b/Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpiPei.inf
new file mode 100644
index 0000000000..7ba8584f84
--- /dev/null
+++ b/Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpiPei.inf
@@ -0,0 +1,38 @@
+## @file
+# IPMI Protocol PEI Driver.
+#
+# Copyright (C) 2023 Advanced Micro Devices, Inc. All rights reserved.<BR>
+# SPDX-License-Identifier: BSD-2-Clause-Patent
+##
+
+[Defines]
+  INF_VERSION                    = 0x0001001d
+  BASE_NAME                      = IpmiPei
+  FILE_GUID                      = 7832F989-CB72-4715-ADCA-35C0B031856C
+  MODULE_TYPE                    = PEIM
+  VERSION_STRING                 = 1.0
+  ENTRY_POINT                    = IpmiEntry
+
+#
+# The following information is for reference only and not required by the build tools.
+#
+#  VALID_ARCHITECTURES           = IA32 X64 ARM AARCH64
+#
+
+[Sources]
+  IpmiPpi.c
+
+[Packages]
+  MdePkg/MdePkg.dec
+  MdeModulePkg/MdeModulePkg.dec
+  IpmiFeaturePkg/IpmiFeaturePkg.dec
+
+[LibraryClasses]
+  IpmiBaseLib
+  PeimEntryPoint
+
+[Ppis]
+  gPeiIpmiPpiGuid       # PPI ALWAYS PRODUCED
+
+[Depex]
+  TRUE
diff --git a/Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocolSmm.inf b/Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocolSmm.inf
new file mode 100644
index 0000000000..25a5771cb3
--- /dev/null
+++ b/Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocolSmm.inf
@@ -0,0 +1,40 @@
+## @file
+# IPMI Protocol SMM Driver.
+#
+# Copyright (C) 2023 Advanced Micro Devices, Inc. All rights reserved.<BR>
+# SPDX-License-Identifier: BSD-2-Clause-Patent
+##
+
+#
+# The following information is for reference only and not required by the build tools.
+#
+#  VALID_ARCHITECTURES           = IA32 X64 ARM AARCH64
+#
+[Defines]
+  INF_VERSION                         = 0x0001001d
+  BASE_NAME                           = IpmiSmm
+  FILE_GUID                           = CDD5D1DE-E3D3-4B1F-8689-DCC661561BB4
+  MODULE_TYPE                         = DXE_SMM_DRIVER
+  PI_SPECIFICATION_VERSION            = 0x0001000A
+  VERSION_STRING                      = 1.0
+  ENTRY_POINT                         = IpmiEntry
+
+[Sources]
+  IpmiProtocol.c
+
+[Packages]
+  MdePkg/MdePkg.dec
+  MdeModulePkg/MdeModulePkg.dec
+  IpmiFeaturePkg/IpmiFeaturePkg.dec
+
+[LibraryClasses]
+  IpmiBaseLib
+  UefiDriverEntryPoint
+  UefiBootServicesTableLib
+  SmmServicesTableLib
+
+[Protocols]
+  gSmmIpmiProtocolGuid               # PROTOCOL ALWAYS_PRODUCED
+
+[Depex]
+  TRUE
diff --git a/Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocol.c b/Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocol.c
new file mode 100644
index 0000000000..1f0b88052e
--- /dev/null
+++ b/Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocol.c
@@ -0,0 +1,97 @@
+/** @file
+  This file provides IPMI Protocol implementation.
+
+  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights reserved.<BR>
+  SPDX-License-Identifier: BSD-2-Clause-Patent
+**/
+
+#include <PiDxe.h>
+#include <Library/DebugLib.h>
+#include <Library/UefiBootServicesTableLib.h>
+#include <Library/IpmiBaseLib.h>
+#include <Protocol/IpmiProtocol.h>
+
+/**
+  This service enables submitting commands via Ipmi.
+
+  @param[in]         This              This point for IPMI_PROTOCOL structure.
+  @param[in]         NetFunction       Net function of the command.
+  @param[in]         Command           IPMI Command.
+  @param[in]         RequestData       Command Request Data.
+  @param[in]         RequestDataSize   Size of Command Request Data.
+  @param[out]        ResponseData      Command Response Data. The completion code is the first byte of response data.
+  @param[in, out]    ResponseDataSize  Size of Command Response Data.
+
+  @retval EFI_SUCCESS            The command byte stream was successfully submit to the device and a response was successfully received.
+  @retval EFI_NOT_FOUND          The command was not successfully sent to the device or a response was not successfully received from the device.
+  @retval EFI_NOT_READY          Ipmi Device is not ready for Ipmi command access.
+  @retval EFI_DEVICE_ERROR       Ipmi Device hardware error.
+  @retval EFI_TIMEOUT            The command time out.
+  @retval EFI_UNSUPPORTED        The command was not successfully sent to the device.
+  @retval EFI_OUT_OF_RESOURCES   The resource allcation is out of resource or data size error.
+**/
+EFI_STATUS
+EFIAPI
+IpmiSubmitCommand (
+  IN     IPMI_PROTOCOL  *This,
+  IN     UINT8          NetFunction,
+  IN     UINT8          Command,
+  IN     UINT8          *RequestData,
+  IN     UINT32         RequestDataSize,
+  OUT    UINT8          *ResponseData,
+  IN OUT UINT32         *ResponseDataSize
+  )
+{
+  EFI_STATUS  Status;
+
+  Status = IpmiSendCommand (
+             NetFunction,
+             Command,
+             RequestData,
+             RequestDataSize,
+             ResponseData,
+             ResponseDataSize
+             );
+  if (EFI_ERROR (Status)) {
+    DEBUG ((DEBUG_ERROR, "%a: Failed to send IPMI command in DXE - %r\n", __FUNCTION__, Status));
+  }
+
+  return Status;
+}
+
+static IPMI_PROTOCOL  mIpmiProtocol = {
+  IpmiSubmitCommand
+};
+
+/**
+  The entry point of the Ipmi DXE driver.
+
+  @param[in] ImageHandle - Handle of this driver image
+  @param[in] SystemTable - Table containing standard EFI services
+
+  @retval EFI_SUCCESS    - IPMI Protocol is installed successfully.
+  @retval Otherwise      - Other errors.
+**/
+EFI_STATUS
+EFIAPI
+IpmiEntry (
+  IN EFI_HANDLE        ImageHandle,
+  IN EFI_SYSTEM_TABLE  *SystemTable
+  )
+{
+  EFI_STATUS  Status;
+  EFI_HANDLE  Handle;
+
+  Handle = NULL;
+  Status = gBS->InstallProtocolInterface (
+                  &Handle,
+                  &gIpmiProtocolGuid,
+                  EFI_NATIVE_INTERFACE,
+                  (VOID **)&mIpmiProtocol
+                  );
+  if (EFI_ERROR (Status)) {
+    DEBUG ((DEBUG_ERROR, "%a: Failed to install IPMI protocol - %r\n", __FUNCTION__, Status));
+  }
+
+  return Status;
+}
diff --git a/Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpi.c b/Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpi.c
new file mode 100644
index 0000000000..913a9b0811
--- /dev/null
+++ b/Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpi.c
@@ -0,0 +1,102 @@
+/** @file
+  This file provides IPMI PPI implementation.
+
+  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights reserved.<BR>
+  SPDX-License-Identifier: BSD-2-Clause-Patent
+
+**/
+
+#include <PiPei.h>
+#include <Library/DebugLib.h>
+#include <Library/PeiServicesLib.h>
+#include <Library/IpmiBaseLib.h>
+#include <Ppi/IpmiPpi.h>
+
+/**
+  This service enables submitting commands via Ipmi.
+
+  @param[in]         This              This point for PEI_IPMI_PPI structure.
+  @param[in]         NetFunction       Net function of the command.
+  @param[in]         Command           IPMI Command.
+  @param[in]         RequestData       Command Request Data.
+  @param[in]         RequestDataSize   Size of Command Request Data.
+  @param[out]        ResponseData      Command Response Data. The completion code is the first byte of response data.
+  @param[in, out]    ResponseDataSize  Size of Command Response Data.
+
+  @retval EFI_SUCCESS            The command byte stream was successfully submit to the device and a response was successfully received.
+  @retval EFI_NOT_FOUND          The command was not successfully sent to the device or a response was not successfully received from the device.
+  @retval EFI_NOT_READY          Ipmi Device is not ready for Ipmi command access.
+  @retval EFI_DEVICE_ERROR       Ipmi Device hardware error.
+  @retval EFI_TIMEOUT            The command time out.
+  @retval EFI_UNSUPPORTED        The command was not successfully sent to the device.
+  @retval EFI_OUT_OF_RESOURCES   The resource allcation is out of resource or data size error.
+**/
+EFI_STATUS
+EFIAPI
+IpmiSubmitCommand (
+  IN     PEI_IPMI_PPI  *This,
+  IN     UINT8         NetFunction,
+  IN     UINT8         Command,
+  IN     UINT8         *RequestData,
+  IN     UINT32        RequestDataSize,
+  OUT    UINT8         *ResponseData,
+  IN OUT UINT32        *ResponseDataSize
+  )
+{
+  EFI_STATUS  Status;
+
+  Status = IpmiSendCommand (
+             NetFunction,
+             Command,
+             RequestData,
+             RequestDataSize,
+             ResponseData,
+             ResponseDataSize
+             );
+  if (EFI_ERROR (Status)) {
+    DEBUG ((DEBUG_ERROR, "%a: Failed to send IPMI command in PEI- %r\n", __FUNCTION__, Status));
+  }
+
+  return Status;
+}
+
+static PEI_IPMI_PPI  mPeiIpmiPpi = {
+  IpmiSubmitCommand
+};
+
+static EFI_PEI_PPI_DESCRIPTOR  mIpmiPpiList[] = {
+  {
+    (EFI_PEI_PPI_DESCRIPTOR_PPI | EFI_PEI_PPI_DESCRIPTOR_TERMINATE_LIST),
+    &gPeiIpmiPpiGuid,
+    &mPeiIpmiPpi
+  }
+};
+
+/**
+  The entry point of the Ipmi PPI PEIM.
+
+  @param  FileHandle  Handle of the file being invoked.
+  @param  PeiServices Describes the list of possible PEI Services.
+
+  @retval EFI_SUCCESS   Indicates that Ipmi initialization completed successfully.
+  @retval Others        Indicates that Ipmi initialization could not complete successfully.
+**/
+EFI_STATUS
+EFIAPI
+IpmiEntry (
+  IN       EFI_PEI_FILE_HANDLE  FileHandle,
+  IN CONST EFI_PEI_SERVICES     **PeiServices
+  )
+{
+  EFI_STATUS  Status;
+
+  //
+  // Install IPMI PPI.
+  //
+  Status = PeiServicesInstallPpi (&mIpmiPpiList[0]);
+  if (EFI_ERROR (Status)) {
+    DEBUG ((DEBUG_ERROR, "%a: Failed to install IPMI PPI - %r\n", __FUNCTION__, Status));
+  }
+
+  return Status;
+}
diff --git a/Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocol.c b/Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocol.c
new file mode 100644
index 0000000000..ed14f9fbd1
--- /dev/null
+++ b/Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocol.c
@@ -0,0 +1,98 @@
+/** @file
+  This file provides IPMI SMM Protocol implementation.
+
+  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights reserved.<BR>
+  SPDX-License-Identifier: BSD-2-Clause-Patent
+**/
+
+#include <PiDxe.h>
+#include <Library/DebugLib.h>
+#include <Library/UefiBootServicesTableLib.h>
+#include <Library/SmmServicesTableLib.h>
+#include <Library/IpmiBaseLib.h>
+#include <Protocol/IpmiProtocol.h>
+
+/**
+  This service enables submitting commands via Ipmi.
+
+  @param[in]         This              This point for IPMI_PROTOCOL structure.
+  @param[in]         NetFunction       Net function of the command.
+  @param[in]         Command           IPMI Command.
+  @param[in]         RequestData       Command Request Data.
+  @param[in]         RequestDataSize   Size of Command Request Data.
+  @param[out]        ResponseData      Command Response Data. The completion code is the first byte of response data.
+  @param[in, out]    ResponseDataSize  Size of Command Response Data.
+
+  @retval EFI_SUCCESS            The command byte stream was successfully submit to the device and a response was successfully received.
+  @retval EFI_NOT_FOUND          The command was not successfully sent to the device or a response was not successfully received from the device.
+  @retval EFI_NOT_READY          Ipmi Device is not ready for Ipmi command access.
+  @retval EFI_DEVICE_ERROR       Ipmi Device hardware error.
+  @retval EFI_TIMEOUT            The command time out.
+  @retval EFI_UNSUPPORTED        The command was not successfully sent to the device.
+  @retval EFI_OUT_OF_RESOURCES   The resource allcation is out of resource or data size error.
+**/
+EFI_STATUS
+EFIAPI
+IpmiSubmitCommand (
+  IN     IPMI_PROTOCOL  *This,
+  IN     UINT8          NetFunction,
+  IN     UINT8          Command,
+  IN     UINT8          *RequestData,
+  IN     UINT32         RequestDataSize,
+  OUT    UINT8          *ResponseData,
+  IN OUT UINT32         *ResponseDataSize
+  )
+{
+  EFI_STATUS  Status;
+
+  Status = IpmiSendCommand (
+             NetFunction,
+             Command,
+             RequestData,
+             RequestDataSize,
+             ResponseData,
+             ResponseDataSize
+             );
+  if (EFI_ERROR (Status)) {
+    DEBUG ((DEBUG_ERROR, "%a: Failed to send IPMI command in DXE - %r\n", __FUNCTION__, Status));
+  }
+
+  return Status;
+}
+
+static IPMI_PROTOCOL  mIpmiProtocol = {
+  IpmiSubmitCommand
+};
+
+/**
+  The entry point of the Ipmi DXE driver.
+
+  @param[in] ImageHandle - Handle of this driver image
+  @param[in] SystemTable - Table containing standard EFI services
+
+  @retval EFI_SUCCESS    - IPMI Protocol is installed successfully.
+  @retval Otherwise      - Other errors.
+**/
+EFI_STATUS
+EFIAPI
+IpmiEntry (
+  IN EFI_HANDLE        ImageHandle,
+  IN EFI_SYSTEM_TABLE  *SystemTable
+  )
+{
+  EFI_STATUS  Status;
+  EFI_HANDLE  Handle;
+
+  Handle = NULL;
+  Status = gSmst->SmmInstallProtocolInterface (
+                    &Handle,
+                    &gSmmIpmiProtocolGuid,
+                    EFI_NATIVE_INTERFACE,
+                    (VOID **)&mIpmiProtocol
+                    );
+  if (EFI_ERROR (Status)) {
+    DEBUG ((DEBUG_ERROR, "%a: Failed to install IPMI SMM protocol - %r\n", __FUNCTION__, Status));
+  }
+
+  return Status;
+}
-- 
2.37.1.windows.1


^ permalink raw reply related	[flat|nested] 22+ messages in thread

* [edk2-platforms][PATCH 6/7] IpmiProtocol: Add to Manageability Package
  2023-02-07 16:22 [edk2-platforms][PATCH 0/7] Implementation of IPMI Protocol Chang, Abner
                   ` (4 preceding siblings ...)
  2023-02-07 16:22 ` [edk2-platforms][PATCH 5/7] ManageabilityPkg: Implement Ipmi Protocol/Ppi Chang, Abner
@ 2023-02-07 16:22 ` Chang, Abner
  2023-02-07 16:22 ` [edk2-platforms][PATCH 7/7] edk2-platforms: Maintainers.txt Chang, Abner
                   ` (2 subsequent siblings)
  8 siblings, 0 replies; 22+ messages in thread
From: Chang, Abner @ 2023-02-07 16:22 UTC (permalink / raw)
  To: devel
  Cc: Liming Gao, Isaac Oram, Nate DeSimone, Abdul Lateef Attar,
	Nickle Wang, Igor Kulchytskyy

From: Abner Chang <abner.chang@amd.com>

Add Ipmi Protocol/Ppi module to ManageabilityPkg.

Signed-off-by: Abner Chang <abner.chang@amd.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Isaac Oram <isaac.w.oram@intel.com>
Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
Cc: Abdul Lateef Attar <abdattar@amd.com>
Cc: Nickle Wang <nicklew@nvidia.com>
Cc: Igor Kulchytskyy <igork@ami.com>
---
 Features/ManageabilityPkg/Include/CommonLibs.dsc.inc | 12 ++++++++++++
 Features/ManageabilityPkg/ManageabilityPkg.dsc       |  4 ++++
 2 files changed, 16 insertions(+)

diff --git a/Features/ManageabilityPkg/Include/CommonLibs.dsc.inc b/Features/ManageabilityPkg/Include/CommonLibs.dsc.inc
index 2dc2d07f17..40094dea7b 100644
--- a/Features/ManageabilityPkg/Include/CommonLibs.dsc.inc
+++ b/Features/ManageabilityPkg/Include/CommonLibs.dsc.inc
@@ -38,3 +38,15 @@
   NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf
   ArmSoftFloatLib|ArmPkg/Library/ArmSoftFloatLib/ArmSoftFloatLib.inf
 
+#
+# IPMI Libraries, will move these libraries to under ManageabilityPkg later.
+#
+[LibraryClasses.common.DXE_DRIVER]
+  IpmiBaseLib|IpmiFeaturePkg/Library/IpmiBaseLib/IpmiBaseLib.inf
+
+[LibraryClasses.common.PEIM]
+  IpmiBaseLib|IpmiFeaturePkg/Library/PeiIpmiBaseLib/PeiIpmiBaseLib.inf
+
+[LibraryClasses.common.DXE_SMM_DRIVER]
+  IpmiBaseLib|IpmiFeaturePkg/Library/SmmIpmiBaseLib/SmmIpmiBaseLib.inf
+
diff --git a/Features/ManageabilityPkg/ManageabilityPkg.dsc b/Features/ManageabilityPkg/ManageabilityPkg.dsc
index 9ae398277f..6b555502ff 100644
--- a/Features/ManageabilityPkg/ManageabilityPkg.dsc
+++ b/Features/ManageabilityPkg/ManageabilityPkg.dsc
@@ -21,3 +21,7 @@
 !include MdePkg/MdeLibs.dsc.inc
 !include ManageabilityPkg/Include/CommonLibs.dsc.inc
 
+[Components]
+  ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocolDxe.inf
+  ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocolSmm.inf
+  ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpiPei.inf
-- 
2.37.1.windows.1


^ permalink raw reply related	[flat|nested] 22+ messages in thread

* [edk2-platforms][PATCH 7/7] edk2-platforms: Maintainers.txt
  2023-02-07 16:22 [edk2-platforms][PATCH 0/7] Implementation of IPMI Protocol Chang, Abner
                   ` (5 preceding siblings ...)
  2023-02-07 16:22 ` [edk2-platforms][PATCH 6/7] IpmiProtocol: Add to Manageability Package Chang, Abner
@ 2023-02-07 16:22 ` Chang, Abner
  2023-02-08  7:34   ` Michael D Kinney
       [not found] ` <174197631C900AFE.27199@groups.io>
  2023-02-16  1:42 ` [edk2-platforms][PATCH 0/7] Implementation of IPMI Protocol Isaac Oram
  8 siblings, 1 reply; 22+ messages in thread
From: Chang, Abner @ 2023-02-07 16:22 UTC (permalink / raw)
  To: devel
  Cc: Abdul Lateef Attar, Leif Lindholm, Michael D Kinney, Liming Gao,
	Isaac Oram, Nate DeSimone

From: Abner Chang <abner.chang@amd.com>

Add maintainer and reviewer of ManageabilityPkg.

Signed-off-by: Abner Chang <abner.chang@amd.com>
Cc: Abdul Lateef Attar <abdattar@amd.com>
Cc: Leif Lindholm <quic_llindhol@quicinc.com>
Cc: Michael D Kinney <michael.d.kinney@intel.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Isaac Oram <isaac.w.oram@intel.com>
Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
---
 Maintainers.txt | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/Maintainers.txt b/Maintainers.txt
index da1c98638d..1bd7838d61 100644
--- a/Maintainers.txt
+++ b/Maintainers.txt
@@ -164,6 +164,11 @@ F: Features/Intel/UserInterface/
 M: Dandan Bi <dandan.bi@intel.com>
 R: Liming Gao <gaoliming@byosoft.com.cn>
 
+Features/ManageabilityPkg
+F: Features/ManageabilityPkg/
+M: Abner Chang <abner.chang@amd.com>
+R: Abdul Lateef Attar <AbdulLateef.Attar@amd.com>
+
 Platform/Intel
 F: Platform/Intel/
 M: Sai Chaganty <rangasai.v.chaganty@intel.com>
@@ -326,10 +331,10 @@ R: Yuwei Chen <yuwei.chen@intel.com>
 
 Loongson platforms
 F: Platform/Loongson/
-M: Bibo Mao <maobibo@loongson.cn> 
+M: Bibo Mao <maobibo@loongson.cn>
 M: Xianglai li <lixianglai@loongson.cn>
 M: Chao Li <lichao@loongson.cn>
- 
+
 Marvell platforms and silicon
 F: Platform/Marvell/
 F: Platform/SolidRun/Armada80x0McBin/
-- 
2.37.1.windows.1


^ permalink raw reply related	[flat|nested] 22+ messages in thread

* Re: [edk2-devel] [edk2-platforms][PATCH 7/7] edk2-platforms: Maintainers.txt
       [not found] ` <174197631C900AFE.27199@groups.io>
@ 2023-02-07 18:24   ` Chang, Abner
  2023-02-16  1:51     ` Isaac Oram
  0 siblings, 1 reply; 22+ messages in thread
From: Chang, Abner @ 2023-02-07 18:24 UTC (permalink / raw)
  To: devel@edk2.groups.io
  Cc: Attar, AbdulLateef (Abdul Lateef), Leif Lindholm,
	Michael D Kinney, Liming Gao, Isaac Oram, Nate DeSimone

[-- Attachment #1: Type: text/plain, Size: 2459 bytes --]

[AMD Official Use Only - General]

Hi Isaac, Nate and Liming,
Please let me know if you would like to be the reviewer for ManageabilityPkg or not. I will add you to the maintainer list in the next patch set if you want.
Thanks
Abner


Get Outlook for Android<https://aka.ms/AAb9ysg>
________________________________
From: devel@edk2.groups.io <devel@edk2.groups.io> on behalf of Chang, Abner via groups.io <abner.chang=amd.com@groups.io>
Sent: Tuesday, February 7, 2023 11:22:36 AM
To: devel@edk2.groups.io <devel@edk2.groups.io>
Cc: Attar, AbdulLateef (Abdul Lateef) <AbdulLateef.Attar@amd.com>; Leif Lindholm <quic_llindhol@quicinc.com>; Michael D Kinney <michael.d.kinney@intel.com>; Liming Gao <gaoliming@byosoft.com.cn>; Isaac Oram <isaac.w.oram@intel.com>; Nate DeSimone <nathaniel.l.desimone@intel.com>
Subject: [edk2-devel] [edk2-platforms][PATCH 7/7] edk2-platforms: Maintainers.txt

Caution: This message originated from an External Source. Use proper caution when opening attachments, clicking links, or responding.


From: Abner Chang <abner.chang@amd.com>

Add maintainer and reviewer of ManageabilityPkg.

Signed-off-by: Abner Chang <abner.chang@amd.com>
Cc: Abdul Lateef Attar <abdattar@amd.com>
Cc: Leif Lindholm <quic_llindhol@quicinc.com>
Cc: Michael D Kinney <michael.d.kinney@intel.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Isaac Oram <isaac.w.oram@intel.com>
Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
---
 Maintainers.txt | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/Maintainers.txt b/Maintainers.txt
index da1c98638d..1bd7838d61 100644
--- a/Maintainers.txt
+++ b/Maintainers.txt
@@ -164,6 +164,11 @@ F: Features/Intel/UserInterface/
 M: Dandan Bi <dandan.bi@intel.com>
 R: Liming Gao <gaoliming@byosoft.com.cn>

+Features/ManageabilityPkg
+F: Features/ManageabilityPkg/
+M: Abner Chang <abner.chang@amd.com>
+R: Abdul Lateef Attar <AbdulLateef.Attar@amd.com>
+
 Platform/Intel
 F: Platform/Intel/
 M: Sai Chaganty <rangasai.v.chaganty@intel.com>
@@ -326,10 +331,10 @@ R: Yuwei Chen <yuwei.chen@intel.com>

 Loongson platforms
 F: Platform/Loongson/
-M: Bibo Mao <maobibo@loongson.cn>
+M: Bibo Mao <maobibo@loongson.cn>
 M: Xianglai li <lixianglai@loongson.cn>
 M: Chao Li <lichao@loongson.cn>
-
+
 Marvell platforms and silicon
 F: Platform/Marvell/
 F: Platform/SolidRun/Armada80x0McBin/
--
2.37.1.windows.1







[-- Attachment #2: Type: text/html, Size: 4103 bytes --]

^ permalink raw reply related	[flat|nested] 22+ messages in thread

* Re: [edk2-platforms][PATCH 7/7] edk2-platforms: Maintainers.txt
  2023-02-07 16:22 ` [edk2-platforms][PATCH 7/7] edk2-platforms: Maintainers.txt Chang, Abner
@ 2023-02-08  7:34   ` Michael D Kinney
  0 siblings, 0 replies; 22+ messages in thread
From: Michael D Kinney @ 2023-02-08  7:34 UTC (permalink / raw)
  To: abner.chang@amd.com, devel@edk2.groups.io
  Cc: Abdul Lateef Attar, Leif Lindholm, Gao, Liming, Oram, Isaac W,
	Desimone, Nathaniel L, Kinney, Michael D

Reviewed-by: Michael D Kinney <michael.d.kinney@intel.com>


> -----Original Message-----
> From: abner.chang@amd.com <abner.chang@amd.com>
> Sent: Tuesday, February 7, 2023 8:23 AM
> To: devel@edk2.groups.io
> Cc: Abdul Lateef Attar <abdattar@amd.com>; Leif Lindholm <quic_llindhol@quicinc.com>; Kinney, Michael D
> <michael.d.kinney@intel.com>; Gao, Liming <gaoliming@byosoft.com.cn>; Oram, Isaac W <isaac.w.oram@intel.com>; Desimone, Nathaniel L
> <nathaniel.l.desimone@intel.com>
> Subject: [edk2-platforms][PATCH 7/7] edk2-platforms: Maintainers.txt
> 
> From: Abner Chang <abner.chang@amd.com>
> 
> Add maintainer and reviewer of ManageabilityPkg.
> 
> Signed-off-by: Abner Chang <abner.chang@amd.com>
> Cc: Abdul Lateef Attar <abdattar@amd.com>
> Cc: Leif Lindholm <quic_llindhol@quicinc.com>
> Cc: Michael D Kinney <michael.d.kinney@intel.com>
> Cc: Liming Gao <gaoliming@byosoft.com.cn>
> Cc: Isaac Oram <isaac.w.oram@intel.com>
> Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
> ---
>  Maintainers.txt | 9 +++++++--
>  1 file changed, 7 insertions(+), 2 deletions(-)
> 
> diff --git a/Maintainers.txt b/Maintainers.txt
> index da1c98638d..1bd7838d61 100644
> --- a/Maintainers.txt
> +++ b/Maintainers.txt
> @@ -164,6 +164,11 @@ F: Features/Intel/UserInterface/
>  M: Dandan Bi <dandan.bi@intel.com>
>  R: Liming Gao <gaoliming@byosoft.com.cn>
> 
> +Features/ManageabilityPkg
> +F: Features/ManageabilityPkg/
> +M: Abner Chang <abner.chang@amd.com>
> +R: Abdul Lateef Attar <AbdulLateef.Attar@amd.com>
> +
>  Platform/Intel
>  F: Platform/Intel/
>  M: Sai Chaganty <rangasai.v.chaganty@intel.com>
> @@ -326,10 +331,10 @@ R: Yuwei Chen <yuwei.chen@intel.com>
> 
>  Loongson platforms
>  F: Platform/Loongson/
> -M: Bibo Mao <maobibo@loongson.cn>
> +M: Bibo Mao <maobibo@loongson.cn>
>  M: Xianglai li <lixianglai@loongson.cn>
>  M: Chao Li <lichao@loongson.cn>
> -
> +
>  Marvell platforms and silicon
>  F: Platform/Marvell/
>  F: Platform/SolidRun/Armada80x0McBin/
> --
> 2.37.1.windows.1


^ permalink raw reply	[flat|nested] 22+ messages in thread

* Re: [edk2-platforms][PATCH 0/7] Implementation of IPMI Protocol
  2023-02-07 16:22 [edk2-platforms][PATCH 0/7] Implementation of IPMI Protocol Chang, Abner
                   ` (7 preceding siblings ...)
       [not found] ` <174197631C900AFE.27199@groups.io>
@ 2023-02-16  1:42 ` Isaac Oram
  2023-02-17  7:27   ` Chang, Abner
  8 siblings, 1 reply; 22+ messages in thread
From: Isaac Oram @ 2023-02-16  1:42 UTC (permalink / raw)
  To: abner.chang@amd.com, devel@edk2.groups.io
  Cc: Gao, Liming, Desimone, Nathaniel L, Nickle Wang, Igor Kulchytskyy,
	Abdul Lateef Attar, Leif Lindholm, Kinney, Michael D

In looking at the code, this is what I see:

edk2:
	There is an IpmiLib.h library class which abstracts the IpmiPpi.h/IpmiProtocol.h use
	There is an IpmiPpi.h/IpmiProtocol.h which provide an interface to send a command "via IPMI"
	Current IpmiPpi.h/IpmiProtocol.h implementations use IpmiBaseLib library class to send commands

edk2-platforms/Features/Intel/OutOfBandManagement/IpmiFeaturePkg:
	There is an IpmiBaseLib library class which abstracts IpmiTransportPpi.h/IpmiTransportProtocol.h use
	There is an IpmiTransportPpi.h/IpmiTransportProtocol.h that abstracts the transport protocol. 
	Currently IpmiTransportPpi.h/IpmiTransportProtocol.h are implemented in "GenericIpmi".

It appears to me that they are meant to be the same API.  The IpmiFeaturePkg transport version adds a function to GetBmcStatus, but it seems like IpmiSubmitCommand is meant to be the same function throughout.
I don't find any use of the GetBmcStatus function that is in the IpmiFeaturePkg but not the edk2 API.  I am not sure what to make of that.  I think we need more feedback from current consumers to resolve that.


When I look at our internal reference version which is an ancestor to the edk2-platforms/Feature/Intel.../IpmiFeaturePkg version, there is no use of the IpmiLib.h/IpmiPpi.h/IpmiProtocol.h.  There are additional fields in interfaces, like GetBmcStatus and data values, but they seem to have been redesigned out when open sourcing the interfaces.


My main questions:  
To your understanding, are the IpmiLib.h/IpmiPpi.h/IpmiProtocol.h and the IpmiBaseLib.h/IpmiTransportPpi.h/IpmiTransportProtocol.h simply two versions of basically the same with a library API abstracting a dynamic phase specific IPMI transport API?
Why does ManageabilityPkg use IpmiBaseLib and not IpmiLib?  Is it more than a temporary solution?


High level feedback:
0001 - I think we should not make this change.  It impacts any existing users for no reason I can justify.
0002 - Not sure - per my understanding of the stack, it doesn't quite fit the code in an obvious way.
0003 - More description of the design and duplication, the roles of the library class and the PPI/protocols, and the relationship to other IPMI code in the repos.
0004 - Minor feedback only
0005/0006 - I think that we should skip the step of using IpmiBaseLib and just implement the modified version of GenericIpmi to support the edk2 API stack design.

I will send more specific details in response to each commit shortly.

Regards,
Isaac

-----Original Message-----
From: abner.chang@amd.com <abner.chang@amd.com> 
Sent: Tuesday, February 7, 2023 8:22 AM
To: devel@edk2.groups.io
Cc: Gao, Liming <gaoliming@byosoft.com.cn>; Oram, Isaac W <isaac.w.oram@intel.com>; Desimone, Nathaniel L <nathaniel.l.desimone@intel.com>; Nickle Wang <nicklew@nvidia.com>; Igor Kulchytskyy <igork@ami.com>; Abdul Lateef Attar <abdattar@amd.com>; Leif Lindholm <quic_llindhol@quicinc.com>; Kinney, Michael D <michael.d.kinney@intel.com>
Subject: [edk2-platforms][PATCH 0/7] Implementation of IPMI Protocol

From: Abner Chang <abner.chang@amd.com>

This change implementes IPMI Protocol and PPI in the new introduced ManageabilityPkg (described in below email)
https://edk2.groups.io/g/devel/message/95579?p=%2C%2C%2C20%2C0%2C0%2C0%3A%3ACreated%2C%2CManageability%2C20%2C2%2C0%2C94572748

BZ #4336:
The change also fixes the confusion (Patch 1/7) of IpmiSubmitCommand() deinfed in IPMI Transport protocol.

You can skip reviewing on patch 2/7 as it is an image file.

Signed-off-by: Abner Chang <abner.chang@amd.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Isaac Oram <isaac.w.oram@intel.com>
Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
Cc: Nickle Wang <nicklew@nvidia.com>
Cc: Igor Kulchytskyy <igork@ami.com>
Cc: Abdul Lateef Attar <abdattar@amd.com>
Cc: Leif Lindholm <quic_llindhol@quicinc.com>
Cc: Michael D Kinney <michael.d.kinney@intel.com>

Abner Chang (7):
  IpmiFeaturePkg: Rename IpmiSubmitCommand function
  ManageabilityPkg: Add diagrams
  ManageabilityPkg: Add Readme file
  ManageabilityPkg: Initial package
  ManageabilityPkg: Implement Ipmi Protocol/Ppi
  IpmiProtocol: Add to Manageability Package
  edk2-platforms: Maintainers.txt

 .../ManageabilityPkg/ManageabilityPkg.dec     |  18 ++++
 .../Include/CommonLibs.dsc.inc                |  52 +++++++++
 .../ManageabilityPkg/ManageabilityPkg.dsc     |  27 +++++
 .../IpmiProtocol/Dxe/IpmiProtocolDxe.inf      |  37 +++++++
 .../Universal/IpmiProtocol/Pei/IpmiPpiPei.inf |  38 +++++++
 .../IpmiProtocol/Smm/IpmiProtocolSmm.inf      |  40 +++++++
 .../Include/Library/IpmiBaseLib.h             |   2 +-
 .../Include/Ppi/IpmiTransportPpi.h            |   2 +-
 .../Include/Protocol/IpmiTransportProtocol.h  |   2 +-
 .../IpmiFeaturePkg/GenericIpmi/Dxe/IpmiInit.c |   2 +-
 .../GenericIpmi/Pei/PeiGenericIpmi.c          |   2 +-
 .../GenericIpmi/Smm/SmmGenericIpmi.c          |   2 +-
 .../Library/IpmiBaseLib/IpmiBaseLib.c         |   4 +-
 .../Library/IpmiBaseLibNull/IpmiBaseLibNull.c |   2 +-
 .../IpmiCommandLib/IpmiCommandLibNetFnApp.c   |  26 ++---
 .../IpmiCommandLibNetFnChassis.c              |  12 +--
 .../IpmiCommandLibNetFnStorage.c              |  24 ++---
 .../IpmiCommandLibNetFnTransport.c            |   8 +-
 .../Library/PeiIpmiBaseLib/PeiIpmiBaseLib.c   |   4 +-
 .../Library/SmmIpmiBaseLib/SmmIpmiBaseLib.c   |   4 +-
 .../Universal/IpmiProtocol/Dxe/IpmiProtocol.c |  97 +++++++++++++++++
 .../Universal/IpmiProtocol/Pei/IpmiPpi.c      | 102 ++++++++++++++++++
 .../Universal/IpmiProtocol/Smm/IpmiProtocol.c |  98 +++++++++++++++++
 .../Ipmi/Library/IpmiLibKcs/IpmiLibKcs.c      |  12 +--
 Features/ManageabilityPkg/Readme.md           |  37 +++++++
 .../Media/ManageabilityDriverStack.svg        |   1 +
 Maintainers.txt                               |   9 +-
 27 files changed, 608 insertions(+), 56 deletions(-)  create mode 100644 Features/ManageabilityPkg/ManageabilityPkg.dec
 create mode 100644 Features/ManageabilityPkg/Include/CommonLibs.dsc.inc
 create mode 100644 Features/ManageabilityPkg/ManageabilityPkg.dsc
 create mode 100644 Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocolDxe.inf
 create mode 100644 Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpiPei.inf
 create mode 100644 Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocolSmm.inf
 create mode 100644 Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocol.c
 create mode 100644 Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpi.c
 create mode 100644 Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocol.c
 create mode 100644 Features/ManageabilityPkg/Readme.md
 create mode 100644 Features/ManageabilityPkg/Documents/Media/ManageabilityDriverStack.svg

--
2.37.1.windows.1


^ permalink raw reply	[flat|nested] 22+ messages in thread

* Re: [edk2-platforms][PATCH 1/7] IpmiFeaturePkg: Rename IpmiSubmitCommand function
  2023-02-07 16:22 ` [edk2-platforms][PATCH 1/7] IpmiFeaturePkg: Rename IpmiSubmitCommand function Chang, Abner
@ 2023-02-16  1:43   ` Isaac Oram
  2023-02-17  7:28     ` Chang, Abner
  0 siblings, 1 reply; 22+ messages in thread
From: Isaac Oram @ 2023-02-16  1:43 UTC (permalink / raw)
  To: abner.chang@amd.com, devel@edk2.groups.io
  Cc: Gao, Liming, Desimone, Nathaniel L, Nickle Wang, Igor Kulchytskyy,
	Abdul Lateef Attar

I see your point that it is confusing the sets of protocols and libraries that have the same function.  I think that the solution should be to decouple them so that we can clearly say something like "use edk2 interfaces, IpmiLib, and ManageabilityPkg or IpmiFeaturePkg, do not mix the two solutions".  And if at some point in the future both are consuming edk2 API and ManageabilityPkg shared content, we can remove that comment.

Specific feedback on this commit:
edk2-platforms/Platform/Intel/PurleyOpenBoardPkg/Features/Ipmi/Library/IpmiLibKcs/IpmiLibKcs.c (212) has another instance of "IpmiSubmitCommand" that should be changed to "IpmiSendCommand" to match the rest of the patch.

We should not make this change.  We should modify the series to not use IpmiBaseLib/IpmiTransportPpi/IpmiTransportProtocol.

Regards,
Isaac

-----Original Message-----
From: abner.chang@amd.com <abner.chang@amd.com> 
Sent: Tuesday, February 7, 2023 8:23 AM
To: devel@edk2.groups.io
Cc: Gao, Liming <gaoliming@byosoft.com.cn>; Oram, Isaac W <isaac.w.oram@intel.com>; Desimone, Nathaniel L <nathaniel.l.desimone@intel.com>; Nickle Wang <nicklew@nvidia.com>; Igor Kulchytskyy <igork@ami.com>; Abdul Lateef Attar <abdattar@amd.com>
Subject: [edk2-platforms][PATCH 1/7] IpmiFeaturePkg: Rename IpmiSubmitCommand function

From: Abner Chang <abner.chang@amd.com>

Rename IpmiSubmitCommand to IpmiSendCommand because the naming of this function is confusing with IpmiSubmitCommand defined in IPMI Protocol.

Signed-off-by: Abner Chang <abner.chang@amd.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Isaac Oram <isaac.w.oram@intel.com>
Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
Cc: Nickle Wang <nicklew@nvidia.com>
Cc: Igor Kulchytskyy <igork@ami.com>
Cc: Abdul Lateef Attar <abdattar@amd.com>
---
 .../Include/Library/IpmiBaseLib.h             |  2 +-
 .../Include/Ppi/IpmiTransportPpi.h            |  2 +-
 .../Include/Protocol/IpmiTransportProtocol.h  |  2 +-  .../IpmiFeaturePkg/GenericIpmi/Dxe/IpmiInit.c |  2 +-
 .../GenericIpmi/Pei/PeiGenericIpmi.c          |  2 +-
 .../GenericIpmi/Smm/SmmGenericIpmi.c          |  2 +-
 .../Library/IpmiBaseLib/IpmiBaseLib.c         |  4 +--
 .../Library/IpmiBaseLibNull/IpmiBaseLibNull.c |  2 +-
 .../IpmiCommandLib/IpmiCommandLibNetFnApp.c   | 26 +++++++++----------
 .../IpmiCommandLibNetFnChassis.c              | 12 ++++-----
 .../IpmiCommandLibNetFnStorage.c              | 24 ++++++++---------
 .../IpmiCommandLibNetFnTransport.c            |  8 +++---
 .../Library/PeiIpmiBaseLib/PeiIpmiBaseLib.c   |  4 +--
 .../Library/SmmIpmiBaseLib/SmmIpmiBaseLib.c   |  4 +--
 .../Ipmi/Library/IpmiLibKcs/IpmiLibKcs.c      | 12 ++++-----
 15 files changed, 54 insertions(+), 54 deletions(-)

diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Library/IpmiBaseLib.h b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Library/IpmiBaseLib.h
index 8487ace5ba..9e77bdad8d 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Library/IpmiBaseLib.h
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Library/
+++ IpmiBaseLib.h
@@ -37,7 +37,7 @@ InitializeIpmiBase (
 
 **/
 EFI_STATUS
-IpmiSubmitCommand (
+IpmiSendCommand (
   IN UINT8     NetFunction,
   IN UINT8     Command,
   IN UINT8     *CommandData,
diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Ppi/IpmiTransportPpi.h b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Ppi/IpmiTransportPpi.h
index 9ecb20f9bf..4bdb5db00b 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Ppi/IpmiTransportPpi.h
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Ppi/Ipmi
+++ TransportPpi.h
@@ -59,7 +59,7 @@ EFI_STATUS
 //
 struct _PEI_IPMI_TRANSPORT_PPI {
   UINT64                      Revision;
-  PEI_IPMI_SEND_COMMAND       IpmiSubmitCommand;
+  PEI_IPMI_SEND_COMMAND       IpmiSendCommand;
   PEI_IPMI_GET_CHANNEL_STATUS GetBmcStatus;  };
 
diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Protocol/IpmiTransportProtocol.h b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Protocol/IpmiTransportProtocol.h
index 2ee6f98e07..bb17073f06 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Protocol/IpmiTransportProtocol.h
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Protocol
+++ /IpmiTransportProtocol.h
@@ -63,7 +63,7 @@ EFI_STATUS
 //
 struct _IPMI_TRANSPORT {
   UINT64                      Revision;
-  IPMI_SEND_COMMAND           IpmiSubmitCommand;
+  IPMI_SEND_COMMAND           IpmiSendCommand;
   IPMI_GET_CHANNEL_STATUS     GetBmcStatus;
   EFI_HANDLE                  IpmiHandle;
   UINT8                       CompletionCode;
diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Dxe/IpmiInit.c b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Dxe/IpmiInit.c
index d788b48867..f1f089b575 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Dxe/IpmiInit.c
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Dxe/
+++ IpmiInit.c
@@ -396,7 +396,7 @@ InitializeIpmiKcsPhysicalLayer (
     mIpmiInstance->Signature                        = SM_IPMI_BMC_SIGNATURE;
     mIpmiInstance->SlaveAddress                     = BMC_SLAVE_ADDRESS;
     mIpmiInstance->BmcStatus                        = BMC_NOTREADY;
-    mIpmiInstance->IpmiTransport.IpmiSubmitCommand  = IpmiSendCommand;
+    mIpmiInstance->IpmiTransport.IpmiSendCommand    = IpmiSendCommand;
     mIpmiInstance->IpmiTransport.GetBmcStatus       = IpmiGetBmcStatus;
 
     //
diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Pei/PeiGenericIpmi.c b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Pei/PeiGenericIpmi.c
index 3efb772b68..e9018ca8df 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Pei/PeiGenericIpmi.c
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Pei/
+++ PeiGenericIpmi.c
@@ -76,7 +76,7 @@ PeiInitializeIpmiKcsPhysicalLayer (
   mIpmiInstance->Signature                          = SM_IPMI_BMC_SIGNATURE;
   mIpmiInstance->SlaveAddress                       = BMC_SLAVE_ADDRESS;
   mIpmiInstance->BmcStatus                          = BMC_NOTREADY;
-  mIpmiInstance->IpmiTransportPpi.IpmiSubmitCommand = PeiIpmiSendCommand;
+  mIpmiInstance->IpmiTransportPpi.IpmiSendCommand   = PeiIpmiSendCommand;
   mIpmiInstance->IpmiTransportPpi.GetBmcStatus      = PeiGetIpmiBmcStatus;
 
   mIpmiInstance->PeiIpmiBmcDataDesc.Flags         = EFI_PEI_PPI_DESCRIPTOR_PPI | EFI_PEI_PPI_DESCRIPTOR_TERMINATE_LIST;
diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Smm/SmmGenericIpmi.c b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Smm/SmmGenericIpmi.c
index fda215baaa..c1892f5ab8 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Smm/SmmGenericIpmi.c
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Smm/
+++ SmmGenericIpmi.c
@@ -166,7 +166,7 @@ Returns:
     mIpmiInstance->Signature                        = SM_IPMI_BMC_SIGNATURE;
     mIpmiInstance->SlaveAddress                     = BMC_SLAVE_ADDRESS;
     mIpmiInstance->BmcStatus                        = BMC_NOTREADY;
-    mIpmiInstance->IpmiTransport.IpmiSubmitCommand  = IpmiSendCommand;
+    mIpmiInstance->IpmiTransport.IpmiSendCommand    = IpmiSendCommand;
     mIpmiInstance->IpmiTransport.GetBmcStatus       = IpmiGetBmcStatus;
 
     DEBUG ((DEBUG_INFO,"IPMI: Waiting for Getting BMC DID in SMM \n")); diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiBaseLib/IpmiBaseLib.c b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiBaseLib/IpmiBaseLib.c
index 5df9d861c6..01ff322d27 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiBaseLib/IpmiBaseLib.c
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiBase
+++ Lib/IpmiBaseLib.c
@@ -91,7 +91,7 @@ InitializeIpmiBase (
 
 **/
 EFI_STATUS
-IpmiSubmitCommand (
+IpmiSendCommand (
   IN UINT8        NetFunction,
   IN UINT8        Command,
   IN UINT8        *CommandData,
@@ -108,7 +108,7 @@ IpmiSubmitCommand (
     return Status;
   }
 
-  Status = mIpmiTransport->IpmiSubmitCommand (
+  Status = mIpmiTransport->IpmiSendCommand (
                              mIpmiTransport,
                              NetFunction,
                              0,
diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiBaseLibNull/IpmiBaseLibNull.c b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiBaseLibNull/IpmiBaseLibNull.c
index 7c4c67f6ac..7af21bbaf1 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiBaseLibNull/IpmiBaseLibNull.c
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiBase
+++ LibNull/IpmiBaseLibNull.c
@@ -43,7 +43,7 @@ InitializeIpmiBase (
 
 **/
 EFI_STATUS
-IpmiSubmitCommand (
+IpmiSendCommand (
   IN UINT8     NetFunction,
   IN UINT8     Command,
   IN UINT8     *CommandData,
diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnApp.c b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnApp.c
index 2e34909f3e..dbd154e2a6 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnApp.c
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiComm
+++ andLib/IpmiCommandLibNetFnApp.c
@@ -24,7 +24,7 @@ IpmiGetDeviceId (
   UINT32                       DataSize;
 
   DataSize = sizeof(*DeviceId);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_APP,
              IPMI_APP_GET_DEVICE_ID,
              NULL,
@@ -45,7 +45,7 @@ IpmiGetSelfTestResult (
   UINT32                       DataSize;
 
   DataSize = sizeof(*SelfTestResult);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_APP,
              IPMI_APP_GET_SELFTEST_RESULTS,
              NULL,
@@ -66,7 +66,7 @@ IpmiResetWatchdogTimer (
   UINT32                       DataSize;
 
   DataSize = sizeof(*CompletionCode);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_APP,
              IPMI_APP_RESET_WATCHDOG_TIMER,
              NULL,
@@ -88,7 +88,7 @@ IpmiSetWatchdogTimer (
   UINT32                       DataSize;
 
   DataSize = sizeof(*CompletionCode);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_APP,
              IPMI_APP_SET_WATCHDOG_TIMER,
              (VOID *)SetWatchdogTimer,
@@ -109,7 +109,7 @@ IpmiGetWatchdogTimer (
   UINT32                       DataSize;
 
   DataSize = sizeof(*GetWatchdogTimer);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_APP,
              IPMI_APP_GET_WATCHDOG_TIMER,
              NULL,
@@ -131,7 +131,7 @@ IpmiSetBmcGlobalEnables (
   UINT32                       DataSize;
 
   DataSize = sizeof(*CompletionCode);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_APP,
              IPMI_APP_SET_BMC_GLOBAL_ENABLES,
              (VOID *)SetBmcGlobalEnables, @@ -152,7 +152,7 @@ IpmiGetBmcGlobalEnables (
   UINT32                       DataSize;
 
   DataSize = sizeof(*GetBmcGlobalEnables);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_APP,
              IPMI_APP_GET_BMC_GLOBAL_ENABLES,
              NULL,
@@ -174,7 +174,7 @@ IpmiClearMessageFlags (
   UINT32                       DataSize;
 
   DataSize = sizeof(*CompletionCode);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_APP,
              IPMI_APP_CLEAR_MESSAGE_FLAGS,
              (VOID *)ClearMessageFlagsRequest, @@ -195,7 +195,7 @@ IpmiGetMessageFlags (
   UINT32                       DataSize;
 
   DataSize = sizeof(*GetMessageFlagsResponse);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_APP,
              IPMI_APP_GET_MESSAGE_FLAGS,
              NULL,
@@ -215,7 +215,7 @@ IpmiGetMessage (
 {
   EFI_STATUS                   Status;
 
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_APP,
              IPMI_APP_GET_MESSAGE,
              NULL,
@@ -237,7 +237,7 @@ IpmiSendMessage (
 {
   EFI_STATUS                   Status;
 
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_APP,
              IPMI_APP_SEND_MESSAGE,
              (VOID *)SendMessageRequest, @@ -274,7 +274,7 @@ IpmiGetSystemUuid (
   }
   RequestSize = 0;
   ResponseSize = sizeof (IPMI_GET_SYSTEM_UUID_RESPONSE);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_APP,
              IPMI_APP_GET_SYSTEM_GUID,
              (VOID *)NULL,
@@ -323,7 +323,7 @@ IpmiGetChannelInfo (
   }
 
   *GetChannelInfoResponseSize = sizeof (IPMI_GET_CHANNEL_INFO_RESPONSE);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_APP,
              IPMI_APP_GET_CHANNEL_INFO,
              (UINT8 *)GetChannelInfoRequest, diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnChassis.c b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnChassis.c
index 9c19f52ce4..c8c0e90a79 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnChassis.c
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiComm
+++ andLib/IpmiCommandLibNetFnChassis.c
@@ -23,7 +23,7 @@ IpmiGetChassisCapabilities (
   UINT32                       DataSize;
 
   DataSize = sizeof(*GetChassisCapabilitiesResponse);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_CHASSIS,
              IPMI_CHASSIS_GET_CAPABILITIES,
              NULL,
@@ -44,7 +44,7 @@ IpmiGetChassisStatus (
   UINT32                       DataSize;
 
   DataSize = sizeof(*GetChassisStatusResponse);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_CHASSIS,
              IPMI_CHASSIS_GET_STATUS,
              NULL,
@@ -66,7 +66,7 @@ IpmiChassisControl (
   UINT32                       DataSize;
 
   DataSize = sizeof(*CompletionCode);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_CHASSIS,
              IPMI_CHASSIS_CONTROL,
              (VOID *)ChassisControlRequest, @@ -88,7 +88,7 @@ IpmiSetPowerRestorePolicy (
   UINT32                       DataSize;
 
   DataSize = sizeof(*ChassisControlResponse);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_CHASSIS,
              IPMI_CHASSIS_SET_POWER_RESTORE_POLICY,
              (VOID *)ChassisControlRequest, @@ -110,7 +110,7 @@ IpmiSetSystemBootOptions (
   UINT32                       DataSize;
 
   DataSize = sizeof(*BootOptionsResponse);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_CHASSIS,
              IPMI_CHASSIS_SET_SYSTEM_BOOT_OPTIONS,
              (VOID *)BootOptionsRequest, @@ -132,7 +132,7 @@ IpmiGetSystemBootOptions (
   UINT32                       DataSize;
 
   DataSize = sizeof(*BootOptionsResponse);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_CHASSIS,
              IPMI_CHASSIS_GET_SYSTEM_BOOT_OPTIONS,
              (VOID *)BootOptionsRequest, diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnStorage.c b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnStorage.c
index 2215028089..4e84084605 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnStorage.c
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiComm
+++ andLib/IpmiCommandLibNetFnStorage.c
@@ -24,7 +24,7 @@ IpmiGetFruInventoryAreaInfo (
   UINT32                       DataSize;
 
   DataSize = sizeof(*GetFruInventoryAreaInfoResponse);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_STORAGE,
              IPMI_STORAGE_GET_FRU_INVENTORY_AREAINFO,
              (VOID *)GetFruInventoryAreaInfoRequest, @@ -45,7 +45,7 @@ IpmiReadFruData (  {
   EFI_STATUS                   Status;
 
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_STORAGE,
              IPMI_STORAGE_READ_FRU_DATA,
              (VOID *)ReadFruDataRequest, @@ -68,7 +68,7 @@ IpmiWriteFruData (
   UINT32                       DataSize;
 
   DataSize = sizeof(*WriteFruDataResponse);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_STORAGE,
              IPMI_STORAGE_WRITE_FRU_DATA,
              (VOID *)WriteFruDataRequest, @@ -89,7 +89,7 @@ IpmiGetSelInfo (
   UINT32                       DataSize;
 
   DataSize = sizeof(*GetSelInfoResponse);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_STORAGE,
              IPMI_STORAGE_GET_SEL_INFO,
              NULL,
@@ -110,7 +110,7 @@ IpmiGetSelEntry (
 {
   EFI_STATUS                   Status;
 
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_STORAGE,
              IPMI_STORAGE_GET_SEL_ENTRY,
              (VOID *)GetSelEntryRequest, @@ -132,7 +132,7 @@ IpmiAddSelEntry (
   UINT32                       DataSize;
 
   DataSize = sizeof(*AddSelEntryResponse);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_STORAGE,
              IPMI_STORAGE_ADD_SEL_ENTRY,
              (VOID *)AddSelEntryRequest, @@ -155,7 +155,7 @@ IpmiPartialAddSelEntry (
   UINT32                       DataSize;
 
   DataSize = sizeof(*PartialAddSelEntryResponse);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_STORAGE,
              IPMI_STORAGE_PARTIAL_ADD_SEL_ENTRY,
              (VOID *)PartialAddSelEntryRequest, @@ -177,7 +177,7 @@ IpmiClearSel (
   UINT32                       DataSize;
 
   DataSize = sizeof(*ClearSelResponse);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_STORAGE,
              IPMI_STORAGE_CLEAR_SEL,
              (VOID *)ClearSelRequest,
@@ -198,7 +198,7 @@ IpmiGetSelTime (
   UINT32                       DataSize;
 
   DataSize = sizeof(*GetSelTimeResponse);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_STORAGE,
              IPMI_STORAGE_GET_SEL_TIME,
              NULL,
@@ -220,7 +220,7 @@ IpmiSetSelTime (
   UINT32                       DataSize;
 
   DataSize = sizeof(*CompletionCode);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_STORAGE,
              IPMI_STORAGE_SET_SEL_TIME,
              (VOID *)SetSelTimeRequest, @@ -241,7 +241,7 @@ IpmiGetSdrRepositoryInfo (
   UINT32                       DataSize;
 
   DataSize = sizeof(*GetSdrRepositoryInfoResp);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_STORAGE,
              IPMI_STORAGE_GET_SDR_REPOSITORY_INFO,
              NULL,
@@ -262,7 +262,7 @@ IpmiGetSdr (
 {
   EFI_STATUS                   Status;
 
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_STORAGE,
              IPMI_STORAGE_GET_SDR,
              (VOID *)GetSdrRequest,
diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnTransport.c b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnTransport.c
index 30ea84c04b..eec281c5bd 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCommandLib/IpmiCommandLibNetFnTransport.c
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiComm
+++ andLib/IpmiCommandLibNetFnTransport.c
@@ -26,7 +26,7 @@ IpmiSolActivating (
   UINT32                       DataSize;
 
   DataSize = sizeof(*CompletionCode);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_TRANSPORT,
              IPMI_TRANSPORT_SOL_ACTIVATING,
              (VOID *)SolActivatingRequest, @@ -49,7 +49,7 @@ IpmiSetSolConfigurationParameters (
   UINT32                       DataSize;
 
   DataSize = sizeof(*CompletionCode);
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_TRANSPORT,
              IPMI_TRANSPORT_SET_SOL_CONFIG_PARAM,
              (VOID *)SetConfigurationParametersRequest,
@@ -70,7 +70,7 @@ IpmiGetSolConfigurationParameters (  {
   EFI_STATUS                   Status;
 
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_TRANSPORT,
              IPMI_TRANSPORT_GET_SOL_CONFIG_PARAM,
              (VOID *)GetConfigurationParametersRequest,
@@ -111,7 +111,7 @@ IpmiGetLanConfigurationParameters (
     return EFI_INVALID_PARAMETER;
   }
 
-  Status = IpmiSubmitCommand (
+  Status = IpmiSendCommand (
              IPMI_NETFN_TRANSPORT,
              IPMI_TRANSPORT_GET_LAN_CONFIG_PARAMETERS,
              (UINT8 *)GetLanConfigurationParametersRequest,
diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/PeiIpmiBaseLib/PeiIpmiBaseLib.c b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/PeiIpmiBaseLib/PeiIpmiBaseLib.c
index 8679cd95db..b97152208a 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/PeiIpmiBaseLib/PeiIpmiBaseLib.c
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/PeiIpmiB
+++ aseLib/PeiIpmiBaseLib.c
@@ -48,7 +48,7 @@ InitializeIpmiBase (
 
 **/
 EFI_STATUS
-IpmiSubmitCommand (
+IpmiSendCommand (
   IN UINT8        NetFunction,
   IN UINT8        Command,
   IN UINT8        *CommandData,
@@ -65,7 +65,7 @@ IpmiSubmitCommand (
     ASSERT_EFI_ERROR (Status);
     return Status;
   }
-  Status = IpmiTransport->IpmiSubmitCommand (
+  Status = IpmiTransport->IpmiSendCommand (
                             IpmiTransport,
                             NetFunction,
                             0,
diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/SmmIpmiBaseLib/SmmIpmiBaseLib.c b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/SmmIpmiBaseLib/SmmIpmiBaseLib.c
index 6282adc269..ee1d3d5bed 100644
--- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/SmmIpmiBaseLib/SmmIpmiBaseLib.c
+++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/SmmIpmiB
+++ aseLib/SmmIpmiBaseLib.c
@@ -96,7 +96,7 @@ InitializeIpmiBase (
 
 **/
 EFI_STATUS
-IpmiSubmitCommand (
+IpmiSendCommand (
   IN UINT8        NetFunction,
   IN UINT8        Command,
   IN UINT8        *CommandData,
@@ -133,7 +133,7 @@ Returns:
     return Status;
   }
 
-  Status = mIpmiTransport->IpmiSubmitCommand (
+  Status = mIpmiTransport->IpmiSendCommand (
                              mIpmiTransport,
                              NetFunction,
                              0,
diff --git a/Platform/Intel/PurleyOpenBoardPkg/Features/Ipmi/Library/IpmiLibKcs/IpmiLibKcs.c b/Platform/Intel/PurleyOpenBoardPkg/Features/Ipmi/Library/IpmiLibKcs/IpmiLibKcs.c
index 700e413aa6..2b02ba6a20 100644
--- a/Platform/Intel/PurleyOpenBoardPkg/Features/Ipmi/Library/IpmiLibKcs/IpmiLibKcs.c
+++ b/Platform/Intel/PurleyOpenBoardPkg/Features/Ipmi/Library/IpmiLibKcs
+++ /IpmiLibKcs.c
@@ -193,7 +193,7 @@ UpdateBmcStatusOnResponse (  **/  EFI_STATUS  EFIAPI -IpmiSubmitCommand (
+IpmiSendCommand (
   IN     UINT8     NetFunction,
   IN     UINT8     Command,
   IN     UINT8     *RequestData,
@@ -222,7 +222,7 @@ IpmiSubmitCommand (
     }
 
     IpmiInstance->Signature                      = SM_IPMI_BMC_SIGNATURE;
-    IpmiInstance->KcsTimeoutPeriod               = PcdGet64(PcdIpmiKcsTimeoutPeriod); 
+    IpmiInstance->KcsTimeoutPeriod               = PcdGet64(PcdIpmiKcsTimeoutPeriod);
     IpmiInstance->SlaveAddress                   = PcdGet8(PcdIpmiBmcSlaveAddress);
     IpmiInstance->IpmiIoBase                     = PcdGet16(PcdIpmiIoBaseAddress);
     DEBUG((DEBUG_INFO,"IPMI KcsTimeoutPeriod=0x%x\n", IpmiInstance->KcsTimeoutPeriod)); @@ -269,7 +269,7 @@ IpmiSubmitCommand (
   }
 
   Status = SendDataToBmcPort (
-  	IpmiInstance->KcsTimeoutPeriod,
+    IpmiInstance->KcsTimeoutPeriod,
     IpmiInstance->IpmiIoBase,
     (UINT8 *)IpmiCommand,
     (UINT8)(RequestDataSize + EFI_IPMI_COMMAND_HEADER_SIZE) @@ -287,7 +287,7 @@ IpmiSubmitCommand (
   //
   DataSize = MAX_TEMP_DATA;
   Status = ReceiveBmcDataFromPort (
-  	IpmiInstance->KcsTimeoutPeriod,
+    IpmiInstance->KcsTimeoutPeriod,
     IpmiInstance->IpmiIoBase,
     (UINT8 *)IpmiResponse,
     &DataSize
@@ -301,8 +301,8 @@ IpmiSubmitCommand (
   }
 
   //
-  // If we got this far without any error codes, but the DataSize is 0 then the
-  // command response failed, so do not continue.  
+  // If we got this far without any error codes, but the DataSize is 0 
+ then the  // command response failed, so do not continue.
   //
   if (DataSize < 3) {
     Status = EFI_DEVICE_ERROR;
--
2.37.1.windows.1


^ permalink raw reply	[flat|nested] 22+ messages in thread

* Re: [edk2-platforms][PATCH 3/7] ManageabilityPkg: Add Readme file
  2023-02-07 16:22 ` [edk2-platforms][PATCH 3/7] ManageabilityPkg: Add Readme file Chang, Abner
@ 2023-02-16  1:44   ` Isaac Oram
  2023-02-17  7:28     ` Chang, Abner
  0 siblings, 1 reply; 22+ messages in thread
From: Isaac Oram @ 2023-02-16  1:44 UTC (permalink / raw)
  To: abner.chang@amd.com, devel@edk2.groups.io
  Cc: Gao, Liming, Desimone, Nathaniel L, Nickle Wang, Igor Kulchytskyy,
	Abdul Lateef Attar

Nits, not blocking (I don't know how pedantic the community is and if we care about these insignificant details, obviously lots of code doesn't):
- I don't find that saying it is the "EDK2" Manageability Package adds much value/clarity.  I would strip out "EDK2" from the discussion, except where it is clarifying.  My reasoning is that we may expand with content that isn't really edk2 content in some senses.  We might want to put more content in here and I wouldn't want people to thing it doesn't belong because of the name.
- "for the industry platform management standards".  I stumbled on this sentance, maybe removing "the" would be clearer.
- "PACKAGES_PATH must contains the path".  "contains" should probably be the singular "contain".

Regards,
Isaac

-----Original Message-----
From: abner.chang@amd.com <abner.chang@amd.com> 
Sent: Tuesday, February 7, 2023 8:23 AM
To: devel@edk2.groups.io
Cc: Gao, Liming <gaoliming@byosoft.com.cn>; Oram, Isaac W <isaac.w.oram@intel.com>; Desimone, Nathaniel L <nathaniel.l.desimone@intel.com>; Nickle Wang <nicklew@nvidia.com>; Igor Kulchytskyy <igork@ami.com>; Abdul Lateef Attar <abdattar@amd.com>
Subject: [edk2-platforms][PATCH 3/7] ManageabilityPkg: Add Readme file

From: Abner Chang <abner.chang@amd.com>

Add Readme file of edk2 platform ManageabilityPkg.

Signed-off-by: Abner Chang <abner.chang@amd.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Isaac Oram <isaac.w.oram@intel.com>
Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
Cc: Nickle Wang <nicklew@nvidia.com>
Cc: Igor Kulchytskyy <igork@ami.com>
Cc: Abdul Lateef Attar <abdattar@amd.com>
---
 Features/ManageabilityPkg/Readme.md | 37 +++++++++++++++++++++++++++++
 1 file changed, 37 insertions(+)
 create mode 100644 Features/ManageabilityPkg/Readme.md

diff --git a/Features/ManageabilityPkg/Readme.md b/Features/ManageabilityPkg/Readme.md
new file mode 100644
index 0000000000..880aa4aa48
--- /dev/null
+++ b/Features/ManageabilityPkg/Readme.md
@@ -0,0 +1,37 @@
+# EDK2 Manageability Package
+
+The edk2 Manageability package is introduced to provide edk2 drivers 
+and libraries for the industry platform management standards, such as 
+PLDM (Platform Level Data Model), MCTP (Management Component Transfer 
+Protocol) and IPMI (Intelligent Platform Management Interface). The 
+framework of edk2 Manageability package is designed to flexibly support 
+transports for the above industry standards, the transports such as KCS or I2C for IPMI, PCI VDM (Vendor Defined Message), I2C or KCS for MCTP, or the OEM proprietary transports.
+
+## EDK2 Manageability Package Driver Stack
+
+Below figure shows the driver stacks which are abstracted to support 
+disparate transports for the platform management.
+![Manageability Package Driver 
+Stack](https://github.com/tianocore/edk2-platforms/blob/master/Features
+/ManageabilityPkg/Documents/Media/ManageabilityDriverStack.svg?raw=true
+)
+
+## Build the Manageability Package
+In order to use the modules provided by ManageabilityPkg, 
+**PACKAGES_PATH** must contains the path to point to [edk2-platform Features](https://github.com/tianocore/edk2-platforms/tree/master/Features):
+
+```
+$ export 
+PACKAGES_PATH=$PWD/edk2:$PWD/edk2-platforms:$PWD/edk2-platforms/Feature
+s
+```
+
+Due to the [IPMI Migration 
+Work](#migration-of-ipmi-driver-stack-from-outofbandmanagement) is in 
+progress, an additional package path is required to add to 
+**PACKAGES_PATH** for the reference of IPMI modules those are currently 
+located under
+[OutOfBandManagement](https://github.com/tianocore/edk2-platforms/tree/master/Features/Intel/OutOfBandManagement) folder.
+
+```
+$PWD/edk2-platforms/Features/Intel/OutOfBandManagement
+```
+
+## Migration of IPMI Driver Stack from OutOfBandManagement
+
+This is the ongoing task that relocates IPMI modules from 
+OutOfBandManagement to under ManageabilityPkg. This task also requires 
+to abstract the transport layer from IPMI driver in order to flexibly support different transports adopted on the platform.
--
2.37.1.windows.1


^ permalink raw reply related	[flat|nested] 22+ messages in thread

* Re: [edk2-platforms][PATCH 5/7] ManageabilityPkg: Implement Ipmi Protocol/Ppi
  2023-02-07 16:22 ` [edk2-platforms][PATCH 5/7] ManageabilityPkg: Implement Ipmi Protocol/Ppi Chang, Abner
@ 2023-02-16  1:47   ` Isaac Oram
  2023-02-17  7:29     ` Chang, Abner
  0 siblings, 1 reply; 22+ messages in thread
From: Isaac Oram @ 2023-02-16  1:47 UTC (permalink / raw)
  To: abner.chang@amd.com, devel@edk2.groups.io
  Cc: Gao, Liming, Desimone, Nathaniel L, Abdul Lateef Attar,
	Nickle Wang, Igor Kulchytskyy

I find the code to be misleading because source code looks like it is using the edk2 API but it actually invokes the IpmiFeaturePkg implementations of the IpmiTransport* API.  we end up with things like a depex that says TRUE, but really includes a library that carries a dependency on a different protocol than the one in the INF.  It includes IpmiProtocol.h, but actually invokes a library that locates and uses IpmiTransportProtocol.h.

I think that we should have these implement IpmiPpi.h and IpmiProtocol.h instead of chaining them into the old implementation.  

If we don't want to implement them directly, I would prefer to obviously have the IpmiPpi and IpmiProtocol implementations look up and invoke IpmiTransportPpi and IpmiTransportProtocol directly so that the code is obvious about what it is doing.  It seems that IpmiBaseLib only abstracts the phase for calling code.  Is there any other value for phase specific code to obfuscate what is really happening by adding the library layer?  If the library is there to avoid source code collisions, then I guess detailed commenting at all the misleading places is probably the only answer besides implementing directly.

Regards,
Isaac

-----Original Message-----
From: abner.chang@amd.com <abner.chang@amd.com> 
Sent: Tuesday, February 7, 2023 8:23 AM
To: devel@edk2.groups.io
Cc: Gao, Liming <gaoliming@byosoft.com.cn>; Oram, Isaac W <isaac.w.oram@intel.com>; Desimone, Nathaniel L <nathaniel.l.desimone@intel.com>; Abdul Lateef Attar <abdattar@amd.com>; Nickle Wang <nicklew@nvidia.com>; Igor Kulchytskyy <igork@ami.com>
Subject: [edk2-platforms][PATCH 5/7] ManageabilityPkg: Implement Ipmi Protocol/Ppi

From: Abner Chang <abner.chang@amd.com>

Add Ipmi Protocol/Ppi implementation. The underlying implementation is provided by IpmiBaseLib.

Signed-off-by: Abner Chang <abner.chang@amd.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Isaac Oram <isaac.w.oram@intel.com>
Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
Cc: Abdul Lateef Attar <abdattar@amd.com>
Cc: Nickle Wang <nicklew@nvidia.com>
Cc: Igor Kulchytskyy <igork@ami.com>
---
 .../IpmiProtocol/Dxe/IpmiProtocolDxe.inf      |  37 +++++++
 .../Universal/IpmiProtocol/Pei/IpmiPpiPei.inf |  38 +++++++
 .../IpmiProtocol/Smm/IpmiProtocolSmm.inf      |  40 +++++++
 .../Universal/IpmiProtocol/Dxe/IpmiProtocol.c |  97 +++++++++++++++++
 .../Universal/IpmiProtocol/Pei/IpmiPpi.c      | 102 ++++++++++++++++++
 .../Universal/IpmiProtocol/Smm/IpmiProtocol.c |  98 +++++++++++++++++
 6 files changed, 412 insertions(+)
 create mode 100644 Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocolDxe.inf
 create mode 100644 Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpiPei.inf
 create mode 100644 Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocolSmm.inf
 create mode 100644 Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocol.c
 create mode 100644 Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpi.c
 create mode 100644 Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocol.c

diff --git a/Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocolDxe.inf b/Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocolDxe.inf
new file mode 100644
index 0000000000..0737a5ad8f
--- /dev/null
+++ b/Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocolD
+++ xe.inf
@@ -0,0 +1,37 @@
+## @file
+# IPMI Protocol DXE Driver.
+#
+# Copyright (C) 2023 Advanced Micro Devices, Inc. All rights 
+reserved.<BR> # SPDX-License-Identifier: BSD-2-Clause-Patent ##
+
+[Defines]
+  INF_VERSION                    = 0x0001001d
+  BASE_NAME                      = IpmiDxe
+  FILE_GUID                      = BC41B0C2-9D8A-42B5-A28F-02CE0D4A6C28
+  MODULE_TYPE                    = DXE_DRIVER
+  VERSION_STRING                 = 1.0
+  ENTRY_POINT                    = IpmiEntry
+
+#
+#  VALID_ARCHITECTURES           = IA32 X64 ARM AARCH64
+#
+
+[Sources]
+  IpmiProtocol.c
+
+[Packages]
+  MdePkg/MdePkg.dec
+  MdeModulePkg/MdeModulePkg.dec
+  IpmiFeaturePkg/IpmiFeaturePkg.dec
+
+[LibraryClasses]
+  IpmiBaseLib
+  UefiDriverEntryPoint
+  UefiBootServicesTableLib
+
+[Protocols]
+  gIpmiProtocolGuid               # PROTOCOL ALWAYS_PRODUCED
+
+[Depex]
+  TRUE
diff --git a/Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpiPei.inf b/Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpiPei.inf
new file mode 100644
index 0000000000..7ba8584f84
--- /dev/null
+++ b/Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpiPei.in
+++ f
@@ -0,0 +1,38 @@
+## @file
+# IPMI Protocol PEI Driver.
+#
+# Copyright (C) 2023 Advanced Micro Devices, Inc. All rights 
+reserved.<BR> # SPDX-License-Identifier: BSD-2-Clause-Patent ##
+
+[Defines]
+  INF_VERSION                    = 0x0001001d
+  BASE_NAME                      = IpmiPei
+  FILE_GUID                      = 7832F989-CB72-4715-ADCA-35C0B031856C
+  MODULE_TYPE                    = PEIM
+  VERSION_STRING                 = 1.0
+  ENTRY_POINT                    = IpmiEntry
+
+#
+# The following information is for reference only and not required by the build tools.
+#
+#  VALID_ARCHITECTURES           = IA32 X64 ARM AARCH64
+#
+
+[Sources]
+  IpmiPpi.c
+
+[Packages]
+  MdePkg/MdePkg.dec
+  MdeModulePkg/MdeModulePkg.dec
+  IpmiFeaturePkg/IpmiFeaturePkg.dec
+
+[LibraryClasses]
+  IpmiBaseLib
+  PeimEntryPoint
+
+[Ppis]
+  gPeiIpmiPpiGuid       # PPI ALWAYS PRODUCED
+
+[Depex]
+  TRUE
diff --git a/Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocolSmm.inf b/Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocolSmm.inf
new file mode 100644
index 0000000000..25a5771cb3
--- /dev/null
+++ b/Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocolS
+++ mm.inf
@@ -0,0 +1,40 @@
+## @file
+# IPMI Protocol SMM Driver.
+#
+# Copyright (C) 2023 Advanced Micro Devices, Inc. All rights 
+reserved.<BR> # SPDX-License-Identifier: BSD-2-Clause-Patent ##
+
+#
+# The following information is for reference only and not required by the build tools.
+#
+#  VALID_ARCHITECTURES           = IA32 X64 ARM AARCH64
+#
+[Defines]
+  INF_VERSION                         = 0x0001001d
+  BASE_NAME                           = IpmiSmm
+  FILE_GUID                           = CDD5D1DE-E3D3-4B1F-8689-DCC661561BB4
+  MODULE_TYPE                         = DXE_SMM_DRIVER
+  PI_SPECIFICATION_VERSION            = 0x0001000A
+  VERSION_STRING                      = 1.0
+  ENTRY_POINT                         = IpmiEntry
+
+[Sources]
+  IpmiProtocol.c
+
+[Packages]
+  MdePkg/MdePkg.dec
+  MdeModulePkg/MdeModulePkg.dec
+  IpmiFeaturePkg/IpmiFeaturePkg.dec
+
+[LibraryClasses]
+  IpmiBaseLib
+  UefiDriverEntryPoint
+  UefiBootServicesTableLib
+  SmmServicesTableLib
+
+[Protocols]
+  gSmmIpmiProtocolGuid               # PROTOCOL ALWAYS_PRODUCED
+
+[Depex]
+  TRUE
diff --git a/Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocol.c b/Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocol.c
new file mode 100644
index 0000000000..1f0b88052e
--- /dev/null
+++ b/Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocol.
+++ c
@@ -0,0 +1,97 @@
+/** @file
+  This file provides IPMI Protocol implementation.
+
+  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights 
+reserved.<BR>
+  SPDX-License-Identifier: BSD-2-Clause-Patent **/
+
+#include <PiDxe.h>
+#include <Library/DebugLib.h>
+#include <Library/UefiBootServicesTableLib.h>
+#include <Library/IpmiBaseLib.h>
+#include <Protocol/IpmiProtocol.h>
+
+/**
+  This service enables submitting commands via Ipmi.
+
+  @param[in]         This              This point for IPMI_PROTOCOL structure.
+  @param[in]         NetFunction       Net function of the command.
+  @param[in]         Command           IPMI Command.
+  @param[in]         RequestData       Command Request Data.
+  @param[in]         RequestDataSize   Size of Command Request Data.
+  @param[out]        ResponseData      Command Response Data. The completion code is the first byte of response data.
+  @param[in, out]    ResponseDataSize  Size of Command Response Data.
+
+  @retval EFI_SUCCESS            The command byte stream was successfully submit to the device and a response was successfully received.
+  @retval EFI_NOT_FOUND          The command was not successfully sent to the device or a response was not successfully received from the device.
+  @retval EFI_NOT_READY          Ipmi Device is not ready for Ipmi command access.
+  @retval EFI_DEVICE_ERROR       Ipmi Device hardware error.
+  @retval EFI_TIMEOUT            The command time out.
+  @retval EFI_UNSUPPORTED        The command was not successfully sent to the device.
+  @retval EFI_OUT_OF_RESOURCES   The resource allcation is out of resource or data size error.
+**/
+EFI_STATUS
+EFIAPI
+IpmiSubmitCommand (
+  IN     IPMI_PROTOCOL  *This,
+  IN     UINT8          NetFunction,
+  IN     UINT8          Command,
+  IN     UINT8          *RequestData,
+  IN     UINT32         RequestDataSize,
+  OUT    UINT8          *ResponseData,
+  IN OUT UINT32         *ResponseDataSize
+  )
+{
+  EFI_STATUS  Status;
+
+  Status = IpmiSendCommand (
+             NetFunction,
+             Command,
+             RequestData,
+             RequestDataSize,
+             ResponseData,
+             ResponseDataSize
+             );
+  if (EFI_ERROR (Status)) {
+    DEBUG ((DEBUG_ERROR, "%a: Failed to send IPMI command in DXE - 
+ %r\n", __FUNCTION__, Status));  }
+
+  return Status;
+}
+
+static IPMI_PROTOCOL  mIpmiProtocol = {
+  IpmiSubmitCommand
+};
+
+/**
+  The entry point of the Ipmi DXE driver.
+
+  @param[in] ImageHandle - Handle of this driver image  @param[in] 
+ SystemTable - Table containing standard EFI services
+
+  @retval EFI_SUCCESS    - IPMI Protocol is installed successfully.
+  @retval Otherwise      - Other errors.
+**/
+EFI_STATUS
+EFIAPI
+IpmiEntry (
+  IN EFI_HANDLE        ImageHandle,
+  IN EFI_SYSTEM_TABLE  *SystemTable
+  )
+{
+  EFI_STATUS  Status;
+  EFI_HANDLE  Handle;
+
+  Handle = NULL;
+  Status = gBS->InstallProtocolInterface (
+                  &Handle,
+                  &gIpmiProtocolGuid,
+                  EFI_NATIVE_INTERFACE,
+                  (VOID **)&mIpmiProtocol
+                  );
+  if (EFI_ERROR (Status)) {
+    DEBUG ((DEBUG_ERROR, "%a: Failed to install IPMI protocol - %r\n", 
+ __FUNCTION__, Status));  }
+
+  return Status;
+}
diff --git a/Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpi.c b/Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpi.c
new file mode 100644
index 0000000000..913a9b0811
--- /dev/null
+++ b/Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpi.c
@@ -0,0 +1,102 @@
+/** @file
+  This file provides IPMI PPI implementation.
+
+  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights 
+ reserved.<BR>
+  SPDX-License-Identifier: BSD-2-Clause-Patent
+
+**/
+
+#include <PiPei.h>
+#include <Library/DebugLib.h>
+#include <Library/PeiServicesLib.h>
+#include <Library/IpmiBaseLib.h>
+#include <Ppi/IpmiPpi.h>
+
+/**
+  This service enables submitting commands via Ipmi.
+
+  @param[in]         This              This point for PEI_IPMI_PPI structure.
+  @param[in]         NetFunction       Net function of the command.
+  @param[in]         Command           IPMI Command.
+  @param[in]         RequestData       Command Request Data.
+  @param[in]         RequestDataSize   Size of Command Request Data.
+  @param[out]        ResponseData      Command Response Data. The completion code is the first byte of response data.
+  @param[in, out]    ResponseDataSize  Size of Command Response Data.
+
+  @retval EFI_SUCCESS            The command byte stream was successfully submit to the device and a response was successfully received.
+  @retval EFI_NOT_FOUND          The command was not successfully sent to the device or a response was not successfully received from the device.
+  @retval EFI_NOT_READY          Ipmi Device is not ready for Ipmi command access.
+  @retval EFI_DEVICE_ERROR       Ipmi Device hardware error.
+  @retval EFI_TIMEOUT            The command time out.
+  @retval EFI_UNSUPPORTED        The command was not successfully sent to the device.
+  @retval EFI_OUT_OF_RESOURCES   The resource allcation is out of resource or data size error.
+**/
+EFI_STATUS
+EFIAPI
+IpmiSubmitCommand (
+  IN     PEI_IPMI_PPI  *This,
+  IN     UINT8         NetFunction,
+  IN     UINT8         Command,
+  IN     UINT8         *RequestData,
+  IN     UINT32        RequestDataSize,
+  OUT    UINT8         *ResponseData,
+  IN OUT UINT32        *ResponseDataSize
+  )
+{
+  EFI_STATUS  Status;
+
+  Status = IpmiSendCommand (
+             NetFunction,
+             Command,
+             RequestData,
+             RequestDataSize,
+             ResponseData,
+             ResponseDataSize
+             );
+  if (EFI_ERROR (Status)) {
+    DEBUG ((DEBUG_ERROR, "%a: Failed to send IPMI command in PEI- 
+ %r\n", __FUNCTION__, Status));  }
+
+  return Status;
+}
+
+static PEI_IPMI_PPI  mPeiIpmiPpi = {
+  IpmiSubmitCommand
+};
+
+static EFI_PEI_PPI_DESCRIPTOR  mIpmiPpiList[] = {
+  {
+    (EFI_PEI_PPI_DESCRIPTOR_PPI | EFI_PEI_PPI_DESCRIPTOR_TERMINATE_LIST),
+    &gPeiIpmiPpiGuid,
+    &mPeiIpmiPpi
+  }
+};
+
+/**
+  The entry point of the Ipmi PPI PEIM.
+
+  @param  FileHandle  Handle of the file being invoked.
+  @param  PeiServices Describes the list of possible PEI Services.
+
+  @retval EFI_SUCCESS   Indicates that Ipmi initialization completed successfully.
+  @retval Others        Indicates that Ipmi initialization could not complete successfully.
+**/
+EFI_STATUS
+EFIAPI
+IpmiEntry (
+  IN       EFI_PEI_FILE_HANDLE  FileHandle,
+  IN CONST EFI_PEI_SERVICES     **PeiServices
+  )
+{
+  EFI_STATUS  Status;
+
+  //
+  // Install IPMI PPI.
+  //
+  Status = PeiServicesInstallPpi (&mIpmiPpiList[0]);  if (EFI_ERROR 
+ (Status)) {
+    DEBUG ((DEBUG_ERROR, "%a: Failed to install IPMI PPI - %r\n", 
+ __FUNCTION__, Status));  }
+
+  return Status;
+}
diff --git a/Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocol.c b/Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocol.c
new file mode 100644
index 0000000000..ed14f9fbd1
--- /dev/null
+++ b/Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocol.
+++ c
@@ -0,0 +1,98 @@
+/** @file
+  This file provides IPMI SMM Protocol implementation.
+
+  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights 
+reserved.<BR>
+  SPDX-License-Identifier: BSD-2-Clause-Patent **/
+
+#include <PiDxe.h>
+#include <Library/DebugLib.h>
+#include <Library/UefiBootServicesTableLib.h>
+#include <Library/SmmServicesTableLib.h> #include 
+<Library/IpmiBaseLib.h> #include <Protocol/IpmiProtocol.h>
+
+/**
+  This service enables submitting commands via Ipmi.
+
+  @param[in]         This              This point for IPMI_PROTOCOL structure.
+  @param[in]         NetFunction       Net function of the command.
+  @param[in]         Command           IPMI Command.
+  @param[in]         RequestData       Command Request Data.
+  @param[in]         RequestDataSize   Size of Command Request Data.
+  @param[out]        ResponseData      Command Response Data. The completion code is the first byte of response data.
+  @param[in, out]    ResponseDataSize  Size of Command Response Data.
+
+  @retval EFI_SUCCESS            The command byte stream was successfully submit to the device and a response was successfully received.
+  @retval EFI_NOT_FOUND          The command was not successfully sent to the device or a response was not successfully received from the device.
+  @retval EFI_NOT_READY          Ipmi Device is not ready for Ipmi command access.
+  @retval EFI_DEVICE_ERROR       Ipmi Device hardware error.
+  @retval EFI_TIMEOUT            The command time out.
+  @retval EFI_UNSUPPORTED        The command was not successfully sent to the device.
+  @retval EFI_OUT_OF_RESOURCES   The resource allcation is out of resource or data size error.
+**/
+EFI_STATUS
+EFIAPI
+IpmiSubmitCommand (
+  IN     IPMI_PROTOCOL  *This,
+  IN     UINT8          NetFunction,
+  IN     UINT8          Command,
+  IN     UINT8          *RequestData,
+  IN     UINT32         RequestDataSize,
+  OUT    UINT8          *ResponseData,
+  IN OUT UINT32         *ResponseDataSize
+  )
+{
+  EFI_STATUS  Status;
+
+  Status = IpmiSendCommand (
+             NetFunction,
+             Command,
+             RequestData,
+             RequestDataSize,
+             ResponseData,
+             ResponseDataSize
+             );
+  if (EFI_ERROR (Status)) {
+    DEBUG ((DEBUG_ERROR, "%a: Failed to send IPMI command in DXE - 
+ %r\n", __FUNCTION__, Status));  }
+
+  return Status;
+}
+
+static IPMI_PROTOCOL  mIpmiProtocol = {
+  IpmiSubmitCommand
+};
+
+/**
+  The entry point of the Ipmi DXE driver.
+
+  @param[in] ImageHandle - Handle of this driver image  @param[in] 
+ SystemTable - Table containing standard EFI services
+
+  @retval EFI_SUCCESS    - IPMI Protocol is installed successfully.
+  @retval Otherwise      - Other errors.
+**/
+EFI_STATUS
+EFIAPI
+IpmiEntry (
+  IN EFI_HANDLE        ImageHandle,
+  IN EFI_SYSTEM_TABLE  *SystemTable
+  )
+{
+  EFI_STATUS  Status;
+  EFI_HANDLE  Handle;
+
+  Handle = NULL;
+  Status = gSmst->SmmInstallProtocolInterface (
+                    &Handle,
+                    &gSmmIpmiProtocolGuid,
+                    EFI_NATIVE_INTERFACE,
+                    (VOID **)&mIpmiProtocol
+                    );
+  if (EFI_ERROR (Status)) {
+    DEBUG ((DEBUG_ERROR, "%a: Failed to install IPMI SMM protocol - 
+ %r\n", __FUNCTION__, Status));  }
+
+  return Status;
+}
--
2.37.1.windows.1


^ permalink raw reply related	[flat|nested] 22+ messages in thread

* Re: [edk2-platforms][PATCH 4/7] ManageabilityPkg: Initial package
  2023-02-07 16:22 ` [edk2-platforms][PATCH 4/7] ManageabilityPkg: Initial package Chang, Abner
@ 2023-02-16  1:49   ` Isaac Oram
  2023-02-17  7:29     ` Chang, Abner
  0 siblings, 1 reply; 22+ messages in thread
From: Isaac Oram @ 2023-02-16  1:49 UTC (permalink / raw)
  To: abner.chang@amd.com, devel@edk2.groups.io
  Cc: Gao, Liming, Desimone, Nathaniel L, Abdul Lateef Attar,
	Nickle Wang, Igor Kulchytskyy

I think that the ManageabilityPkg shouldn't have a file like CommonLibs.dsc.inc that defines commonly used content.  It is the wrong scope.  I would prefer to use the MinPlatformPkg content on the theory that it will move MinPlatformPkg to a more general location once it is in wider use.

Put another way, either we want many packages to include it, which is weird since the content isn't scoped to this package, or it is just for this package and others shouldn't include it, in which case, separating it from ManageabilityPkg.dsc via an include doesn't add anything.

If you don't want to use MinPlatformPkg then I would suggest following the original buildable package convention and put this content in the ManageabilityPkg/ManageabilityPkg.dsc.

"Manageabilty" is misspelled in a number of places in these files.

Regards,
Isaac

-----Original Message-----
From: abner.chang@amd.com <abner.chang@amd.com> 
Sent: Tuesday, February 7, 2023 8:23 AM
To: devel@edk2.groups.io
Cc: Gao, Liming <gaoliming@byosoft.com.cn>; Oram, Isaac W <isaac.w.oram@intel.com>; Desimone, Nathaniel L <nathaniel.l.desimone@intel.com>; Abdul Lateef Attar <abdattar@amd.com>; Nickle Wang <nicklew@nvidia.com>; Igor Kulchytskyy <igork@ami.com>
Subject: [edk2-platforms][PATCH 4/7] ManageabilityPkg: Initial package

From: Abner Chang <abner.chang@amd.com>

Initial commit of ManageabilityPkg

Signed-off-by: Abner Chang <abner.chang@amd.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Isaac Oram <isaac.w.oram@intel.com>
Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
Cc: Abdul Lateef Attar <abdattar@amd.com>
Cc: Nickle Wang <nicklew@nvidia.com>
Cc: Igor Kulchytskyy <igork@ami.com>
---
 .../ManageabilityPkg/ManageabilityPkg.dec     | 18 +++++++++
 .../Include/CommonLibs.dsc.inc                | 40 +++++++++++++++++++
 .../ManageabilityPkg/ManageabilityPkg.dsc     | 23 +++++++++++
 3 files changed, 81 insertions(+)
 create mode 100644 Features/ManageabilityPkg/ManageabilityPkg.dec
 create mode 100644 Features/ManageabilityPkg/Include/CommonLibs.dsc.inc
 create mode 100644 Features/ManageabilityPkg/ManageabilityPkg.dsc

diff --git a/Features/ManageabilityPkg/ManageabilityPkg.dec b/Features/ManageabilityPkg/ManageabilityPkg.dec
new file mode 100644
index 0000000000..8a0e28f50b
--- /dev/null
+++ b/Features/ManageabilityPkg/ManageabilityPkg.dec
@@ -0,0 +1,18 @@
+## @file
+# Manageabilty Package
+# This is the package provides the edk2 drivers and libraries # those 
+are related to the platform management.
+#
+# Copyright (C) 2023 Advanced Micro Devices, Inc. All rights 
+reserved.<BR> # SPDX-License-Identifier: BSD-2-Clause-Patent # ##
+
+[Defines]
+  DEC_SPECIFICATION = 0x0001001d
+  PACKAGE_NAME      = ManageabilityPkg
+  PACKAGE_GUID      = 36310119-4FB2-4BA3-959D-74C16B849F9E
+  PACKAGE_VERSION   = 1.0
+
+[Includes]
+  Include
diff --git a/Features/ManageabilityPkg/Include/CommonLibs.dsc.inc b/Features/ManageabilityPkg/Include/CommonLibs.dsc.inc
new file mode 100644
index 0000000000..2dc2d07f17
--- /dev/null
+++ b/Features/ManageabilityPkg/Include/CommonLibs.dsc.inc
@@ -0,0 +1,40 @@
+## @file
+# Common libraries for Manageabilty Package # # Copyright (C) 2023 
+Advanced Micro Devices, Inc. All rights reserved.<BR> # 
+SPDX-License-Identifier: BSD-2-Clause-Patent # ##
+
+[LibraryClasses]
+  
+UefiDriverEntryPoint|MdePkg/Library/UefiDriverEntryPoint/UefiDriverEntr
+yPoint.inf
+  
+UefiBootServicesTableLib|MdePkg/Library/UefiBootServicesTableLib/UefiBo
+otServicesTableLib.inf
+  UefiLib|MdePkg/Library/UefiLib/UefiLib.inf
+  BaseLib|MdePkg/Library/BaseLib/BaseLib.inf
+  BaseMemoryLib|MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf
+  PrintLib|MdePkg/Library/BasePrintLib/BasePrintLib.inf
+  DebugLib|MdePkg/Library/UefiDebugLibStdErr/UefiDebugLibStdErr.inf
+  PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf
+  
+DebugPrintErrorLevelLib|MdePkg/Library/BaseDebugPrintErrorLevelLib/Base
+DebugPrintErrorLevelLib.inf
+  DebugLib|MdePkg/Library/BaseDebugLibNull/BaseDebugLibNull.inf
+  
+MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAl
+locationLib.inf
+
+[LibraryClasses.common.PEIM]
+  PeimEntryPoint|MdePkg/Library/PeimEntryPoint/PeimEntryPoint.inf
+  
+PeiServicesTablePointerLib|MdePkg/Library/PeiServicesTablePointerLibIdt
+/PeiServicesTablePointerLibIdt.inf
+  PeiServicesLib|MdePkg/Library/PeiServicesLib/PeiServicesLib.inf
+  
+MemoryAllocationLib|MdePkg/Library/PeiMemoryAllocationLib/PeiMemoryAllo
+cationLib.inf
+  HobLib|MdePkg/Library/PeiHobLib/PeiHobLib.inf
+
+[LibraryClasses.common.DXE_SMM_DRIVER]
+  
+SmmServicesTableLib|MdePkg/Library/SmmServicesTableLib/SmmServicesTable
+Lib.inf
+  
+MemoryAllocationLib|MdePkg/Library/SmmMemoryAllocationLib/SmmMemoryAllo
+cationLib.inf
+
+[LibraryClasses.ARM, LibraryClasses.AARCH64]
+  #
+  # This library provides the instrinsic functions generated by a given compiler.
+  #
+  NULL|ArmPkg/Library/CompilerIntrinsicsLib/CompilerIntrinsicsLib.inf
+  NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf
+  ArmSoftFloatLib|ArmPkg/Library/ArmSoftFloatLib/ArmSoftFloatLib.inf
+
diff --git a/Features/ManageabilityPkg/ManageabilityPkg.dsc b/Features/ManageabilityPkg/ManageabilityPkg.dsc
new file mode 100644
index 0000000000..9ae398277f
--- /dev/null
+++ b/Features/ManageabilityPkg/ManageabilityPkg.dsc
@@ -0,0 +1,23 @@
+## @file
+# Manageabilty Package
+# This is the package provides edk2 drivers and libraries # those are 
+related to the platform management.
+#
+# Copyright (C) 2023 Advanced Micro Devices, Inc. All rights 
+reserved.<BR> # SPDX-License-Identifier: BSD-2-Clause-Patent # ##
+
+[Defines]
+  PLATFORM_NAME                  = ManageabilityPkg
+  PLATFORM_GUID                  = 7A98123A-B194-40B6-A863-A52192F6D65D
+  PLATFORM_VERSION               = 1.0
+  DSC_SPECIFICATION              = 0x0001001e
+  OUTPUT_DIRECTORY               = Build/ManageabilityPkg
+  SUPPORTED_ARCHITECTURES        = IA32|X64|ARM|AARCH64|RISCV64
+  BUILD_TARGETS                  = DEBUG|RELEASE|NOOPT
+  SKUID_IDENTIFIER               = DEFAULT
+
+!include MdePkg/MdeLibs.dsc.inc
+!include ManageabilityPkg/Include/CommonLibs.dsc.inc
+
--
2.37.1.windows.1


^ permalink raw reply related	[flat|nested] 22+ messages in thread

* Re: [edk2-devel] [edk2-platforms][PATCH 7/7] edk2-platforms: Maintainers.txt
  2023-02-07 18:24   ` [edk2-devel] " Chang, Abner
@ 2023-02-16  1:51     ` Isaac Oram
  2023-02-17  7:30       ` Chang, Abner
  0 siblings, 1 reply; 22+ messages in thread
From: Isaac Oram @ 2023-02-16  1:51 UTC (permalink / raw)
  To: Chang, Abner, devel@edk2.groups.io
  Cc: Attar, AbdulLateef (Abdul Lateef), Leif Lindholm,
	Kinney, Michael D, Gao, Liming, Desimone, Nathaniel L

[-- Attachment #1: Type: text/plain, Size: 4072 bytes --]

Please add me as a maintainer.  That gives us redundancy in maintainers and will also incentivize me to provide feedback on proprietary implementations which could hamper adoption.

Regards,
Isaac

From: Chang, Abner <Abner.Chang@amd.com>
Sent: Tuesday, February 7, 2023 10:25 AM
To: devel@edk2.groups.io
Cc: Attar, AbdulLateef (Abdul Lateef) <AbdulLateef.Attar@amd.com>; Leif Lindholm <quic_llindhol@quicinc.com>; Kinney, Michael D <michael.d.kinney@intel.com>; Gao, Liming <gaoliming@byosoft.com.cn>; Oram, Isaac W <isaac.w.oram@intel.com>; Desimone, Nathaniel L <nathaniel.l.desimone@intel.com>
Subject: Re: [edk2-devel] [edk2-platforms][PATCH 7/7] edk2-platforms: Maintainers.txt


[AMD Official Use Only - General]

Hi Isaac, Nate and Liming,
Please let me know if you would like to be the reviewer for ManageabilityPkg or not. I will add you to the maintainer list in the next patch set if you want.
Thanks
Abner


Get Outlook for Android<https://aka.ms/AAb9ysg>
________________________________
From: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> on behalf of Chang, Abner via groups.io <abner.chang=amd.com@groups.io<mailto:abner.chang=amd.com@groups.io>>
Sent: Tuesday, February 7, 2023 11:22:36 AM
To: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>>
Cc: Attar, AbdulLateef (Abdul Lateef) <AbdulLateef.Attar@amd.com<mailto:AbdulLateef.Attar@amd.com>>; Leif Lindholm <quic_llindhol@quicinc.com<mailto:quic_llindhol@quicinc.com>>; Michael D Kinney <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Liming Gao <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>; Isaac Oram <isaac.w.oram@intel.com<mailto:isaac.w.oram@intel.com>>; Nate DeSimone <nathaniel.l.desimone@intel.com<mailto:nathaniel.l.desimone@intel.com>>
Subject: [edk2-devel] [edk2-platforms][PATCH 7/7] edk2-platforms: Maintainers.txt

Caution: This message originated from an External Source. Use proper caution when opening attachments, clicking links, or responding.


From: Abner Chang <abner.chang@amd.com<mailto:abner.chang@amd.com>>

Add maintainer and reviewer of ManageabilityPkg.

Signed-off-by: Abner Chang <abner.chang@amd.com<mailto:abner.chang@amd.com>>
Cc: Abdul Lateef Attar <abdattar@amd.com<mailto:abdattar@amd.com>>
Cc: Leif Lindholm <quic_llindhol@quicinc.com<mailto:quic_llindhol@quicinc.com>>
Cc: Michael D Kinney <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>
Cc: Liming Gao <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>
Cc: Isaac Oram <isaac.w.oram@intel.com<mailto:isaac.w.oram@intel.com>>
Cc: Nate DeSimone <nathaniel.l.desimone@intel.com<mailto:nathaniel.l.desimone@intel.com>>
---
 Maintainers.txt | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/Maintainers.txt b/Maintainers.txt
index da1c98638d..1bd7838d61 100644
--- a/Maintainers.txt
+++ b/Maintainers.txt
@@ -164,6 +164,11 @@ F: Features/Intel/UserInterface/
 M: Dandan Bi <dandan.bi@intel.com<mailto:dandan.bi@intel.com>>
 R: Liming Gao <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>

+Features/ManageabilityPkg
+F: Features/ManageabilityPkg/
+M: Abner Chang <abner.chang@amd.com<mailto:abner.chang@amd.com>>
+R: Abdul Lateef Attar <AbdulLateef.Attar@amd.com<mailto:AbdulLateef.Attar@amd.com>>
+
 Platform/Intel
 F: Platform/Intel/
 M: Sai Chaganty <rangasai.v.chaganty@intel.com<mailto:rangasai.v.chaganty@intel.com>>
@@ -326,10 +331,10 @@ R: Yuwei Chen <yuwei.chen@intel.com<mailto:yuwei.chen@intel.com>>

 Loongson platforms
 F: Platform/Loongson/
-M: Bibo Mao <maobibo@loongson.cn<mailto:maobibo@loongson.cn>>
+M: Bibo Mao <maobibo@loongson.cn<mailto:maobibo@loongson.cn>>
 M: Xianglai li <lixianglai@loongson.cn<mailto:lixianglai@loongson.cn>>
 M: Chao Li <lichao@loongson.cn<mailto:lichao@loongson.cn>>
-
+
 Marvell platforms and silicon
 F: Platform/Marvell/
 F: Platform/SolidRun/Armada80x0McBin/
--
2.37.1.windows.1






[-- Attachment #2: Type: text/html, Size: 8339 bytes --]

^ permalink raw reply related	[flat|nested] 22+ messages in thread

* Re: [edk2-platforms][PATCH 0/7] Implementation of IPMI Protocol
  2023-02-16  1:42 ` [edk2-platforms][PATCH 0/7] Implementation of IPMI Protocol Isaac Oram
@ 2023-02-17  7:27   ` Chang, Abner
  0 siblings, 0 replies; 22+ messages in thread
From: Chang, Abner @ 2023-02-17  7:27 UTC (permalink / raw)
  To: Oram, Isaac W, devel@edk2.groups.io
  Cc: Gao, Liming, Desimone, Nathaniel L, Nickle Wang, Igor Kulchytskyy,
	Attar, AbdulLateef (Abdul Lateef), Leif Lindholm,
	Kinney, Michael D

[AMD Official Use Only - General]

Hi Isaac,
Thanks for spending time on this. Please see my feedback below,

> -----Original Message-----
> From: Oram, Isaac W <isaac.w.oram@intel.com>
> Sent: Thursday, February 16, 2023 9:42 AM
> To: Chang, Abner <Abner.Chang@amd.com>; devel@edk2.groups.io
> Cc: Gao, Liming <gaoliming@byosoft.com.cn>; Desimone, Nathaniel L
> <nathaniel.l.desimone@intel.com>; Nickle Wang <nicklew@nvidia.com>;
> Igor Kulchytskyy <igork@ami.com>; Attar, AbdulLateef (Abdul Lateef)
> <AbdulLateef.Attar@amd.com>; Leif Lindholm <quic_llindhol@quicinc.com>;
> Kinney, Michael D <michael.d.kinney@intel.com>
> Subject: RE: [edk2-platforms][PATCH 0/7] Implementation of IPMI Protocol
> 
> Caution: This message originated from an External Source. Use proper
> caution when opening attachments, clicking links, or responding.
> 
> 
> In looking at the code, this is what I see:
> 
> edk2:
>         There is an IpmiLib.h library class which abstracts the
> IpmiPpi.h/IpmiProtocol.h use
>         There is an IpmiPpi.h/IpmiProtocol.h which provide an interface to send
> a command "via IPMI"
>         Current IpmiPpi.h/IpmiProtocol.h implementations use IpmiBaseLib
> library class to send commands
> 
> edk2-platforms/Features/Intel/OutOfBandManagement/IpmiFeaturePkg:
>         There is an IpmiBaseLib library class which abstracts
> IpmiTransportPpi.h/IpmiTransportProtocol.h use
>         There is an IpmiTransportPpi.h/IpmiTransportProtocol.h that abstracts
> the transport protocol.
>         Currently IpmiTransportPpi.h/IpmiTransportProtocol.h are implemented
> in "GenericIpmi".
> 
> It appears to me that they are meant to be the same API.  The
> IpmiFeaturePkg transport version adds a function to GetBmcStatus, but it
> seems like IpmiSubmitCommand is meant to be the same function
> throughout.
> I don't find any use of the GetBmcStatus function that is in the
> IpmiFeaturePkg but not the edk2 API.  I am not sure what to make of that.  I
> think we need more feedback from current consumers to resolve that.
>
> 
> When I look at our internal reference version which is an ancestor to the
> edk2-platforms/Feature/Intel.../IpmiFeaturePkg version, there is no use of
> the IpmiLib.h/IpmiPpi.h/IpmiProtocol.h.  There are additional fields in
> interfaces, like GetBmcStatus and data values, but they seem to have been
> redesigned out when open sourcing the interfaces.
I don't really know the history of IpmiFeaturePkg and no idea why the implementation is sort of duplicated with the Ipmi stuff defined in edk2.
> 
> My main questions:
> To your understanding, are the IpmiLib.h/IpmiPpi.h/IpmiProtocol.h and the
> IpmiBaseLib.h/IpmiTransportPpi.h/IpmiTransportProtocol.h simply two
> versions of basically the same with a library API abstracting a dynamic phase
> specific IPMI transport API?
> Why does ManageabilityPkg use IpmiBaseLib and not IpmiLib?  Is it more
> than a temporary solution?

So what I was done is to connect the implementation between edk2 and edk2-platforms to avoid the design changes on both side.
There are IpmiLib implementation under MdeModulePkg/Library, those are
DxeIpmiLibIpmiProtocol Library
PeiIpmiLibIpmiPpi Library
SmmIpmiLibSmmIpmiProtocol Library
These libraries provide the abstract library of IpmiProtocol and this implementation makes sense to me for the usage of IPMI high level driver.
The drivers under ManageabilityPkg is the implementation of IpmiProtocol, so it uses IpmiBaseLib as IpmiBaseLib is the abstract API of IpmiTransport protocol.
So that is,
IpmiLib->IpmiProtocol->IpmiBaseLib->IpmiTransport (GenericIpmi). Again, the implementation of IpmiProtocol under ManageabilityPkg is the connection between existing IpmiLib and IpmiBaseLib.
More feedbacks in the each patch.

Thanks
Abner
> 
> 
> High level feedback:
> 0001 - I think we should not make this change.  It impacts any existing users
> for no reason I can justify.
> 0002 - Not sure - per my understanding of the stack, it doesn't quite fit the
> code in an obvious way.
> 0003 - More description of the design and duplication, the roles of the library
> class and the PPI/protocols, and the relationship to other IPMI code in the
> repos.
> 0004 - Minor feedback only
> 0005/0006 - I think that we should skip the step of using IpmiBaseLib and just
> implement the modified version of GenericIpmi to support the edk2 API
> stack design.
> 
> I will send more specific details in response to each commit shortly.
> 
> Regards,
> Isaac
> 
> -----Original Message-----
> From: abner.chang@amd.com <abner.chang@amd.com>
> Sent: Tuesday, February 7, 2023 8:22 AM
> To: devel@edk2.groups.io
> Cc: Gao, Liming <gaoliming@byosoft.com.cn>; Oram, Isaac W
> <isaac.w.oram@intel.com>; Desimone, Nathaniel L
> <nathaniel.l.desimone@intel.com>; Nickle Wang <nicklew@nvidia.com>;
> Igor Kulchytskyy <igork@ami.com>; Abdul Lateef Attar
> <abdattar@amd.com>; Leif Lindholm <quic_llindhol@quicinc.com>; Kinney,
> Michael D <michael.d.kinney@intel.com>
> Subject: [edk2-platforms][PATCH 0/7] Implementation of IPMI Protocol
> 
> From: Abner Chang <abner.chang@amd.com>
> 
> This change implementes IPMI Protocol and PPI in the new introduced
> ManageabilityPkg (described in below email)
> https://edk2.groups.io/g/devel/message/95579?p=%2C%2C%2C20%2C0%2C
> 0%2C0%3A%3ACreated%2C%2CManageability%2C20%2C2%2C0%2C94572748
> 
> BZ #4336:
> The change also fixes the confusion (Patch 1/7) of IpmiSubmitCommand()
> deinfed in IPMI Transport protocol.
> 
> You can skip reviewing on patch 2/7 as it is an image file.
> 
> Signed-off-by: Abner Chang <abner.chang@amd.com>
> Cc: Liming Gao <gaoliming@byosoft.com.cn>
> Cc: Isaac Oram <isaac.w.oram@intel.com>
> Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
> Cc: Nickle Wang <nicklew@nvidia.com>
> Cc: Igor Kulchytskyy <igork@ami.com>
> Cc: Abdul Lateef Attar <abdattar@amd.com>
> Cc: Leif Lindholm <quic_llindhol@quicinc.com>
> Cc: Michael D Kinney <michael.d.kinney@intel.com>
> 
> Abner Chang (7):
>   IpmiFeaturePkg: Rename IpmiSubmitCommand function
>   ManageabilityPkg: Add diagrams
>   ManageabilityPkg: Add Readme file
>   ManageabilityPkg: Initial package
>   ManageabilityPkg: Implement Ipmi Protocol/Ppi
>   IpmiProtocol: Add to Manageability Package
>   edk2-platforms: Maintainers.txt
> 
>  .../ManageabilityPkg/ManageabilityPkg.dec     |  18 ++++
>  .../Include/CommonLibs.dsc.inc                |  52 +++++++++
>  .../ManageabilityPkg/ManageabilityPkg.dsc     |  27 +++++
>  .../IpmiProtocol/Dxe/IpmiProtocolDxe.inf      |  37 +++++++
>  .../Universal/IpmiProtocol/Pei/IpmiPpiPei.inf |  38 +++++++
>  .../IpmiProtocol/Smm/IpmiProtocolSmm.inf      |  40 +++++++
>  .../Include/Library/IpmiBaseLib.h             |   2 +-
>  .../Include/Ppi/IpmiTransportPpi.h            |   2 +-
>  .../Include/Protocol/IpmiTransportProtocol.h  |   2 +-
>  .../IpmiFeaturePkg/GenericIpmi/Dxe/IpmiInit.c |   2 +-
>  .../GenericIpmi/Pei/PeiGenericIpmi.c          |   2 +-
>  .../GenericIpmi/Smm/SmmGenericIpmi.c          |   2 +-
>  .../Library/IpmiBaseLib/IpmiBaseLib.c         |   4 +-
>  .../Library/IpmiBaseLibNull/IpmiBaseLibNull.c |   2 +-
>  .../IpmiCommandLib/IpmiCommandLibNetFnApp.c   |  26 ++---
>  .../IpmiCommandLibNetFnChassis.c              |  12 +--
>  .../IpmiCommandLibNetFnStorage.c              |  24 ++---
>  .../IpmiCommandLibNetFnTransport.c            |   8 +-
>  .../Library/PeiIpmiBaseLib/PeiIpmiBaseLib.c   |   4 +-
>  .../Library/SmmIpmiBaseLib/SmmIpmiBaseLib.c   |   4 +-
>  .../Universal/IpmiProtocol/Dxe/IpmiProtocol.c |  97 +++++++++++++++++
>  .../Universal/IpmiProtocol/Pei/IpmiPpi.c      | 102 ++++++++++++++++++
>  .../Universal/IpmiProtocol/Smm/IpmiProtocol.c |  98 +++++++++++++++++
>  .../Ipmi/Library/IpmiLibKcs/IpmiLibKcs.c      |  12 +--
>  Features/ManageabilityPkg/Readme.md           |  37 +++++++
>  .../Media/ManageabilityDriverStack.svg        |   1 +
>  Maintainers.txt                               |   9 +-
>  27 files changed, 608 insertions(+), 56 deletions(-)  create mode 100644
> Features/ManageabilityPkg/ManageabilityPkg.dec
>  create mode 100644
> Features/ManageabilityPkg/Include/CommonLibs.dsc.inc
>  create mode 100644 Features/ManageabilityPkg/ManageabilityPkg.dsc
>  create mode 100644
> Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocolDxe.in
> f
>  create mode 100644
> Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpiPei.inf
>  create mode 100644
> Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocolSmm
> .inf
>  create mode 100644
> Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocol.c
>  create mode 100644
> Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpi.c
>  create mode 100644
> Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocol.c
>  create mode 100644 Features/ManageabilityPkg/Readme.md
>  create mode 100644
> Features/ManageabilityPkg/Documents/Media/ManageabilityDriverStack.sv
> g
> 
> --
> 2.37.1.windows.1

^ permalink raw reply	[flat|nested] 22+ messages in thread

* Re: [edk2-platforms][PATCH 1/7] IpmiFeaturePkg: Rename IpmiSubmitCommand function
  2023-02-16  1:43   ` Isaac Oram
@ 2023-02-17  7:28     ` Chang, Abner
  0 siblings, 0 replies; 22+ messages in thread
From: Chang, Abner @ 2023-02-17  7:28 UTC (permalink / raw)
  To: Oram, Isaac W, devel@edk2.groups.io
  Cc: Gao, Liming, Desimone, Nathaniel L, Nickle Wang, Igor Kulchytskyy,
	Attar, AbdulLateef (Abdul Lateef)

[AMD Official Use Only - General]



> -----Original Message-----
> From: Oram, Isaac W <isaac.w.oram@intel.com>
> Sent: Thursday, February 16, 2023 9:43 AM
> To: Chang, Abner <Abner.Chang@amd.com>; devel@edk2.groups.io
> Cc: Gao, Liming <gaoliming@byosoft.com.cn>; Desimone, Nathaniel L
> <nathaniel.l.desimone@intel.com>; Nickle Wang <nicklew@nvidia.com>;
> Igor Kulchytskyy <igork@ami.com>; Attar, AbdulLateef (Abdul Lateef)
> <AbdulLateef.Attar@amd.com>
> Subject: RE: [edk2-platforms][PATCH 1/7] IpmiFeaturePkg: Rename
> IpmiSubmitCommand function
> 
> Caution: This message originated from an External Source. Use proper
> caution when opening attachments, clicking links, or responding.
> 
> 
> I see your point that it is confusing the sets of protocols and libraries that
> have the same function.  I think that the solution should be to decouple
> them so that we can clearly say something like "use edk2 interfaces, IpmiLib,
> and ManageabilityPkg or IpmiFeaturePkg, do not mix the two solutions".
> And if at some point in the future both are consuming edk2 API and
> ManageabilityPkg shared content, we can remove that comment.
> 
> Specific feedback on this commit:
> edk2-
> platforms/Platform/Intel/PurleyOpenBoardPkg/Features/Ipmi/Library/IpmiL
> ibKcs/IpmiLibKcs.c (212) has another instance of "IpmiSubmitCommand" that
> should be changed to "IpmiSendCommand" to match the rest of the patch.
> 
> We should not make this change.  We should modify the series to not use
> IpmiBaseLib/IpmiTransportPpi/IpmiTransportProtocol.

I am glad to see that you also think we should avoid the redundant stack. I agree with that we don't use IpmiBaseLib.h
I will revise the drivers under ManageabilityPkg and abstract the implementation of transport from those drivers to the library, not bind with KCS due to there are some other transports for IPMI. So platform can link the transport implementation as they need.
The implementation of IpmiProtocol can also cover (invoke) GetBmcStatus (can name it as GetTransportStatus), but that would be implemented in the library.
The transport initialization can be implemented in the construction, and etc. The concept is to provide the framework in the manageability driver but leave the implementation in library.
Any other comments?
Thanks
Abner

> 
> Regards,
> Isaac
> 
> -----Original Message-----
> From: abner.chang@amd.com <abner.chang@amd.com>
> Sent: Tuesday, February 7, 2023 8:23 AM
> To: devel@edk2.groups.io
> Cc: Gao, Liming <gaoliming@byosoft.com.cn>; Oram, Isaac W
> <isaac.w.oram@intel.com>; Desimone, Nathaniel L
> <nathaniel.l.desimone@intel.com>; Nickle Wang <nicklew@nvidia.com>;
> Igor Kulchytskyy <igork@ami.com>; Abdul Lateef Attar
> <abdattar@amd.com>
> Subject: [edk2-platforms][PATCH 1/7] IpmiFeaturePkg: Rename
> IpmiSubmitCommand function
> 
> From: Abner Chang <abner.chang@amd.com>
> 
> Rename IpmiSubmitCommand to IpmiSendCommand because the naming of
> this function is confusing with IpmiSubmitCommand defined in IPMI Protocol.
> 
> Signed-off-by: Abner Chang <abner.chang@amd.com>
> Cc: Liming Gao <gaoliming@byosoft.com.cn>
> Cc: Isaac Oram <isaac.w.oram@intel.com>
> Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
> Cc: Nickle Wang <nicklew@nvidia.com>
> Cc: Igor Kulchytskyy <igork@ami.com>
> Cc: Abdul Lateef Attar <abdattar@amd.com>
> ---
>  .../Include/Library/IpmiBaseLib.h             |  2 +-
>  .../Include/Ppi/IpmiTransportPpi.h            |  2 +-
>  .../Include/Protocol/IpmiTransportProtocol.h  |  2 +-
>   .../IpmiFeaturePkg/GenericIpmi/Dxe/IpmiInit.c |  2 +-
>  .../GenericIpmi/Pei/PeiGenericIpmi.c          |  2 +-
>  .../GenericIpmi/Smm/SmmGenericIpmi.c          |  2 +-
>  .../Library/IpmiBaseLib/IpmiBaseLib.c         |  4 +--
>  .../Library/IpmiBaseLibNull/IpmiBaseLibNull.c |  2 +-
>  .../IpmiCommandLib/IpmiCommandLibNetFnApp.c   | 26 +++++++++---------
> -
>  .../IpmiCommandLibNetFnChassis.c              | 12 ++++-----
>  .../IpmiCommandLibNetFnStorage.c              | 24 ++++++++---------
>  .../IpmiCommandLibNetFnTransport.c            |  8 +++---
>  .../Library/PeiIpmiBaseLib/PeiIpmiBaseLib.c   |  4 +--
>  .../Library/SmmIpmiBaseLib/SmmIpmiBaseLib.c   |  4 +--
>  .../Ipmi/Library/IpmiLibKcs/IpmiLibKcs.c      | 12 ++++-----
>  15 files changed, 54 insertions(+), 54 deletions(-)
> 
> diff --git
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Library/I
> pmiBaseLib.h
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Library/
> IpmiBaseLib.h
> index 8487ace5ba..9e77bdad8d 100644
> ---
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Library/I
> pmiBaseLib.h
> +++
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Library/
> +++ IpmiBaseLib.h
> @@ -37,7 +37,7 @@ InitializeIpmiBase (
> 
>  **/
>  EFI_STATUS
> -IpmiSubmitCommand (
> +IpmiSendCommand (
>    IN UINT8     NetFunction,
>    IN UINT8     Command,
>    IN UINT8     *CommandData,
> diff --git
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Ppi/Ipm
> iTransportPpi.h
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Ppi/Ipm
> iTransportPpi.h
> index 9ecb20f9bf..4bdb5db00b 100644
> ---
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Ppi/Ipm
> iTransportPpi.h
> +++
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Ppi/Ipm
> i
> +++ TransportPpi.h
> @@ -59,7 +59,7 @@ EFI_STATUS
>  //
>  struct _PEI_IPMI_TRANSPORT_PPI {
>    UINT64                      Revision;
> -  PEI_IPMI_SEND_COMMAND       IpmiSubmitCommand;
> +  PEI_IPMI_SEND_COMMAND       IpmiSendCommand;
>    PEI_IPMI_GET_CHANNEL_STATUS GetBmcStatus;  };
> 
> diff --git
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Protocol
> /IpmiTransportProtocol.h
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Protoco
> l/IpmiTransportProtocol.h
> index 2ee6f98e07..bb17073f06 100644
> ---
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Protocol
> /IpmiTransportProtocol.h
> +++
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Protoco
> l
> +++ /IpmiTransportProtocol.h
> @@ -63,7 +63,7 @@ EFI_STATUS
>  //
>  struct _IPMI_TRANSPORT {
>    UINT64                      Revision;
> -  IPMI_SEND_COMMAND           IpmiSubmitCommand;
> +  IPMI_SEND_COMMAND           IpmiSendCommand;
>    IPMI_GET_CHANNEL_STATUS     GetBmcStatus;
>    EFI_HANDLE                  IpmiHandle;
>    UINT8                       CompletionCode;
> diff --git
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Dx
> e/IpmiInit.c
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Dx
> e/IpmiInit.c
> index d788b48867..f1f089b575 100644
> ---
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Dx
> e/IpmiInit.c
> +++
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Dx
> e/
> +++ IpmiInit.c
> @@ -396,7 +396,7 @@ InitializeIpmiKcsPhysicalLayer (
>      mIpmiInstance->Signature                        = SM_IPMI_BMC_SIGNATURE;
>      mIpmiInstance->SlaveAddress                     = BMC_SLAVE_ADDRESS;
>      mIpmiInstance->BmcStatus                        = BMC_NOTREADY;
> -    mIpmiInstance->IpmiTransport.IpmiSubmitCommand  =
> IpmiSendCommand;
> +    mIpmiInstance->IpmiTransport.IpmiSendCommand    =
> IpmiSendCommand;
>      mIpmiInstance->IpmiTransport.GetBmcStatus       = IpmiGetBmcStatus;
> 
>      //
> diff --git
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Pei
> /PeiGenericIpmi.c
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Pei
> /PeiGenericIpmi.c
> index 3efb772b68..e9018ca8df 100644
> ---
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Pei
> /PeiGenericIpmi.c
> +++
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Pei
> /
> +++ PeiGenericIpmi.c
> @@ -76,7 +76,7 @@ PeiInitializeIpmiKcsPhysicalLayer (
>    mIpmiInstance->Signature                          = SM_IPMI_BMC_SIGNATURE;
>    mIpmiInstance->SlaveAddress                       = BMC_SLAVE_ADDRESS;
>    mIpmiInstance->BmcStatus                          = BMC_NOTREADY;
> -  mIpmiInstance->IpmiTransportPpi.IpmiSubmitCommand =
> PeiIpmiSendCommand;
> +  mIpmiInstance->IpmiTransportPpi.IpmiSendCommand   =
> PeiIpmiSendCommand;
>    mIpmiInstance->IpmiTransportPpi.GetBmcStatus      =
> PeiGetIpmiBmcStatus;
> 
>    mIpmiInstance->PeiIpmiBmcDataDesc.Flags         =
> EFI_PEI_PPI_DESCRIPTOR_PPI | EFI_PEI_PPI_DESCRIPTOR_TERMINATE_LIST;
> diff --git
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Sm
> m/SmmGenericIpmi.c
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Sm
> m/SmmGenericIpmi.c
> index fda215baaa..c1892f5ab8 100644
> ---
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Sm
> m/SmmGenericIpmi.c
> +++
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Sm
> m/
> +++ SmmGenericIpmi.c
> @@ -166,7 +166,7 @@ Returns:
>      mIpmiInstance->Signature                        = SM_IPMI_BMC_SIGNATURE;
>      mIpmiInstance->SlaveAddress                     = BMC_SLAVE_ADDRESS;
>      mIpmiInstance->BmcStatus                        = BMC_NOTREADY;
> -    mIpmiInstance->IpmiTransport.IpmiSubmitCommand  =
> IpmiSendCommand;
> +    mIpmiInstance->IpmiTransport.IpmiSendCommand    =
> IpmiSendCommand;
>      mIpmiInstance->IpmiTransport.GetBmcStatus       = IpmiGetBmcStatus;
> 
>      DEBUG ((DEBUG_INFO,"IPMI: Waiting for Getting BMC DID in SMM \n"));
> diff --git
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiBas
> eLib/IpmiBaseLib.c
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiBas
> eLib/IpmiBaseLib.c
> index 5df9d861c6..01ff322d27 100644
> ---
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiBas
> eLib/IpmiBaseLib.c
> +++
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiBas
> e
> +++ Lib/IpmiBaseLib.c
> @@ -91,7 +91,7 @@ InitializeIpmiBase (
> 
>  **/
>  EFI_STATUS
> -IpmiSubmitCommand (
> +IpmiSendCommand (
>    IN UINT8        NetFunction,
>    IN UINT8        Command,
>    IN UINT8        *CommandData,
> @@ -108,7 +108,7 @@ IpmiSubmitCommand (
>      return Status;
>    }
> 
> -  Status = mIpmiTransport->IpmiSubmitCommand (
> +  Status = mIpmiTransport->IpmiSendCommand (
>                               mIpmiTransport,
>                               NetFunction,
>                               0,
> diff --git
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiBas
> eLibNull/IpmiBaseLibNull.c
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiBas
> eLibNull/IpmiBaseLibNull.c
> index 7c4c67f6ac..7af21bbaf1 100644
> ---
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiBas
> eLibNull/IpmiBaseLibNull.c
> +++
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiBas
> e
> +++ LibNull/IpmiBaseLibNull.c
> @@ -43,7 +43,7 @@ InitializeIpmiBase (
> 
>  **/
>  EFI_STATUS
> -IpmiSubmitCommand (
> +IpmiSendCommand (
>    IN UINT8     NetFunction,
>    IN UINT8     Command,
>    IN UINT8     *CommandData,
> diff --git
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCom
> mandLib/IpmiCommandLibNetFnApp.c
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCo
> mmandLib/IpmiCommandLibNetFnApp.c
> index 2e34909f3e..dbd154e2a6 100644
> ---
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCom
> mandLib/IpmiCommandLibNetFnApp.c
> +++
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCo
> mm
> +++ andLib/IpmiCommandLibNetFnApp.c
> @@ -24,7 +24,7 @@ IpmiGetDeviceId (
>    UINT32                       DataSize;
> 
>    DataSize = sizeof(*DeviceId);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_APP,
>               IPMI_APP_GET_DEVICE_ID,
>               NULL,
> @@ -45,7 +45,7 @@ IpmiGetSelfTestResult (
>    UINT32                       DataSize;
> 
>    DataSize = sizeof(*SelfTestResult);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_APP,
>               IPMI_APP_GET_SELFTEST_RESULTS,
>               NULL,
> @@ -66,7 +66,7 @@ IpmiResetWatchdogTimer (
>    UINT32                       DataSize;
> 
>    DataSize = sizeof(*CompletionCode);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_APP,
>               IPMI_APP_RESET_WATCHDOG_TIMER,
>               NULL,
> @@ -88,7 +88,7 @@ IpmiSetWatchdogTimer (
>    UINT32                       DataSize;
> 
>    DataSize = sizeof(*CompletionCode);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_APP,
>               IPMI_APP_SET_WATCHDOG_TIMER,
>               (VOID *)SetWatchdogTimer,
> @@ -109,7 +109,7 @@ IpmiGetWatchdogTimer (
>    UINT32                       DataSize;
> 
>    DataSize = sizeof(*GetWatchdogTimer);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_APP,
>               IPMI_APP_GET_WATCHDOG_TIMER,
>               NULL,
> @@ -131,7 +131,7 @@ IpmiSetBmcGlobalEnables (
>    UINT32                       DataSize;
> 
>    DataSize = sizeof(*CompletionCode);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_APP,
>               IPMI_APP_SET_BMC_GLOBAL_ENABLES,
>               (VOID *)SetBmcGlobalEnables, @@ -152,7 +152,7 @@
> IpmiGetBmcGlobalEnables (
>    UINT32                       DataSize;
> 
>    DataSize = sizeof(*GetBmcGlobalEnables);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_APP,
>               IPMI_APP_GET_BMC_GLOBAL_ENABLES,
>               NULL,
> @@ -174,7 +174,7 @@ IpmiClearMessageFlags (
>    UINT32                       DataSize;
> 
>    DataSize = sizeof(*CompletionCode);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_APP,
>               IPMI_APP_CLEAR_MESSAGE_FLAGS,
>               (VOID *)ClearMessageFlagsRequest, @@ -195,7 +195,7 @@
> IpmiGetMessageFlags (
>    UINT32                       DataSize;
> 
>    DataSize = sizeof(*GetMessageFlagsResponse);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_APP,
>               IPMI_APP_GET_MESSAGE_FLAGS,
>               NULL,
> @@ -215,7 +215,7 @@ IpmiGetMessage (
>  {
>    EFI_STATUS                   Status;
> 
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_APP,
>               IPMI_APP_GET_MESSAGE,
>               NULL,
> @@ -237,7 +237,7 @@ IpmiSendMessage (
>  {
>    EFI_STATUS                   Status;
> 
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_APP,
>               IPMI_APP_SEND_MESSAGE,
>               (VOID *)SendMessageRequest, @@ -274,7 +274,7 @@
> IpmiGetSystemUuid (
>    }
>    RequestSize = 0;
>    ResponseSize = sizeof (IPMI_GET_SYSTEM_UUID_RESPONSE);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_APP,
>               IPMI_APP_GET_SYSTEM_GUID,
>               (VOID *)NULL,
> @@ -323,7 +323,7 @@ IpmiGetChannelInfo (
>    }
> 
>    *GetChannelInfoResponseSize = sizeof
> (IPMI_GET_CHANNEL_INFO_RESPONSE);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_APP,
>               IPMI_APP_GET_CHANNEL_INFO,
>               (UINT8 *)GetChannelInfoRequest, diff --git
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCom
> mandLib/IpmiCommandLibNetFnChassis.c
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCo
> mmandLib/IpmiCommandLibNetFnChassis.c
> index 9c19f52ce4..c8c0e90a79 100644
> ---
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCom
> mandLib/IpmiCommandLibNetFnChassis.c
> +++
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCo
> mm
> +++ andLib/IpmiCommandLibNetFnChassis.c
> @@ -23,7 +23,7 @@ IpmiGetChassisCapabilities (
>    UINT32                       DataSize;
> 
>    DataSize = sizeof(*GetChassisCapabilitiesResponse);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_CHASSIS,
>               IPMI_CHASSIS_GET_CAPABILITIES,
>               NULL,
> @@ -44,7 +44,7 @@ IpmiGetChassisStatus (
>    UINT32                       DataSize;
> 
>    DataSize = sizeof(*GetChassisStatusResponse);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_CHASSIS,
>               IPMI_CHASSIS_GET_STATUS,
>               NULL,
> @@ -66,7 +66,7 @@ IpmiChassisControl (
>    UINT32                       DataSize;
> 
>    DataSize = sizeof(*CompletionCode);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_CHASSIS,
>               IPMI_CHASSIS_CONTROL,
>               (VOID *)ChassisControlRequest, @@ -88,7 +88,7 @@
> IpmiSetPowerRestorePolicy (
>    UINT32                       DataSize;
> 
>    DataSize = sizeof(*ChassisControlResponse);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_CHASSIS,
>               IPMI_CHASSIS_SET_POWER_RESTORE_POLICY,
>               (VOID *)ChassisControlRequest, @@ -110,7 +110,7 @@
> IpmiSetSystemBootOptions (
>    UINT32                       DataSize;
> 
>    DataSize = sizeof(*BootOptionsResponse);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_CHASSIS,
>               IPMI_CHASSIS_SET_SYSTEM_BOOT_OPTIONS,
>               (VOID *)BootOptionsRequest, @@ -132,7 +132,7 @@
> IpmiGetSystemBootOptions (
>    UINT32                       DataSize;
> 
>    DataSize = sizeof(*BootOptionsResponse);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_CHASSIS,
>               IPMI_CHASSIS_GET_SYSTEM_BOOT_OPTIONS,
>               (VOID *)BootOptionsRequest, diff --git
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCom
> mandLib/IpmiCommandLibNetFnStorage.c
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCo
> mmandLib/IpmiCommandLibNetFnStorage.c
> index 2215028089..4e84084605 100644
> ---
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCom
> mandLib/IpmiCommandLibNetFnStorage.c
> +++
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCo
> mm
> +++ andLib/IpmiCommandLibNetFnStorage.c
> @@ -24,7 +24,7 @@ IpmiGetFruInventoryAreaInfo (
>    UINT32                       DataSize;
> 
>    DataSize = sizeof(*GetFruInventoryAreaInfoResponse);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_STORAGE,
>               IPMI_STORAGE_GET_FRU_INVENTORY_AREAINFO,
>               (VOID *)GetFruInventoryAreaInfoRequest, @@ -45,7 +45,7 @@
> IpmiReadFruData (  {
>    EFI_STATUS                   Status;
> 
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_STORAGE,
>               IPMI_STORAGE_READ_FRU_DATA,
>               (VOID *)ReadFruDataRequest, @@ -68,7 +68,7 @@ IpmiWriteFruData
> (
>    UINT32                       DataSize;
> 
>    DataSize = sizeof(*WriteFruDataResponse);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_STORAGE,
>               IPMI_STORAGE_WRITE_FRU_DATA,
>               (VOID *)WriteFruDataRequest, @@ -89,7 +89,7 @@ IpmiGetSelInfo (
>    UINT32                       DataSize;
> 
>    DataSize = sizeof(*GetSelInfoResponse);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_STORAGE,
>               IPMI_STORAGE_GET_SEL_INFO,
>               NULL,
> @@ -110,7 +110,7 @@ IpmiGetSelEntry (
>  {
>    EFI_STATUS                   Status;
> 
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_STORAGE,
>               IPMI_STORAGE_GET_SEL_ENTRY,
>               (VOID *)GetSelEntryRequest, @@ -132,7 +132,7 @@ IpmiAddSelEntry
> (
>    UINT32                       DataSize;
> 
>    DataSize = sizeof(*AddSelEntryResponse);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_STORAGE,
>               IPMI_STORAGE_ADD_SEL_ENTRY,
>               (VOID *)AddSelEntryRequest, @@ -155,7 +155,7 @@
> IpmiPartialAddSelEntry (
>    UINT32                       DataSize;
> 
>    DataSize = sizeof(*PartialAddSelEntryResponse);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_STORAGE,
>               IPMI_STORAGE_PARTIAL_ADD_SEL_ENTRY,
>               (VOID *)PartialAddSelEntryRequest, @@ -177,7 +177,7 @@
> IpmiClearSel (
>    UINT32                       DataSize;
> 
>    DataSize = sizeof(*ClearSelResponse);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_STORAGE,
>               IPMI_STORAGE_CLEAR_SEL,
>               (VOID *)ClearSelRequest,
> @@ -198,7 +198,7 @@ IpmiGetSelTime (
>    UINT32                       DataSize;
> 
>    DataSize = sizeof(*GetSelTimeResponse);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_STORAGE,
>               IPMI_STORAGE_GET_SEL_TIME,
>               NULL,
> @@ -220,7 +220,7 @@ IpmiSetSelTime (
>    UINT32                       DataSize;
> 
>    DataSize = sizeof(*CompletionCode);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_STORAGE,
>               IPMI_STORAGE_SET_SEL_TIME,
>               (VOID *)SetSelTimeRequest, @@ -241,7 +241,7 @@
> IpmiGetSdrRepositoryInfo (
>    UINT32                       DataSize;
> 
>    DataSize = sizeof(*GetSdrRepositoryInfoResp);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_STORAGE,
>               IPMI_STORAGE_GET_SDR_REPOSITORY_INFO,
>               NULL,
> @@ -262,7 +262,7 @@ IpmiGetSdr (
>  {
>    EFI_STATUS                   Status;
> 
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_STORAGE,
>               IPMI_STORAGE_GET_SDR,
>               (VOID *)GetSdrRequest,
> diff --git
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCom
> mandLib/IpmiCommandLibNetFnTransport.c
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCo
> mmandLib/IpmiCommandLibNetFnTransport.c
> index 30ea84c04b..eec281c5bd 100644
> ---
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCom
> mandLib/IpmiCommandLibNetFnTransport.c
> +++
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/IpmiCo
> mm
> +++ andLib/IpmiCommandLibNetFnTransport.c
> @@ -26,7 +26,7 @@ IpmiSolActivating (
>    UINT32                       DataSize;
> 
>    DataSize = sizeof(*CompletionCode);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_TRANSPORT,
>               IPMI_TRANSPORT_SOL_ACTIVATING,
>               (VOID *)SolActivatingRequest, @@ -49,7 +49,7 @@
> IpmiSetSolConfigurationParameters (
>    UINT32                       DataSize;
> 
>    DataSize = sizeof(*CompletionCode);
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_TRANSPORT,
>               IPMI_TRANSPORT_SET_SOL_CONFIG_PARAM,
>               (VOID *)SetConfigurationParametersRequest,
> @@ -70,7 +70,7 @@ IpmiGetSolConfigurationParameters (  {
>    EFI_STATUS                   Status;
> 
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_TRANSPORT,
>               IPMI_TRANSPORT_GET_SOL_CONFIG_PARAM,
>               (VOID *)GetConfigurationParametersRequest,
> @@ -111,7 +111,7 @@ IpmiGetLanConfigurationParameters (
>      return EFI_INVALID_PARAMETER;
>    }
> 
> -  Status = IpmiSubmitCommand (
> +  Status = IpmiSendCommand (
>               IPMI_NETFN_TRANSPORT,
>               IPMI_TRANSPORT_GET_LAN_CONFIG_PARAMETERS,
>               (UINT8 *)GetLanConfigurationParametersRequest,
> diff --git
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/PeiIpmiB
> aseLib/PeiIpmiBaseLib.c
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/PeiIpmiB
> aseLib/PeiIpmiBaseLib.c
> index 8679cd95db..b97152208a 100644
> ---
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/PeiIpmiB
> aseLib/PeiIpmiBaseLib.c
> +++
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/PeiIpmiB
> +++ aseLib/PeiIpmiBaseLib.c
> @@ -48,7 +48,7 @@ InitializeIpmiBase (
> 
>  **/
>  EFI_STATUS
> -IpmiSubmitCommand (
> +IpmiSendCommand (
>    IN UINT8        NetFunction,
>    IN UINT8        Command,
>    IN UINT8        *CommandData,
> @@ -65,7 +65,7 @@ IpmiSubmitCommand (
>      ASSERT_EFI_ERROR (Status);
>      return Status;
>    }
> -  Status = IpmiTransport->IpmiSubmitCommand (
> +  Status = IpmiTransport->IpmiSendCommand (
>                              IpmiTransport,
>                              NetFunction,
>                              0,
> diff --git
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/SmmIpm
> iBaseLib/SmmIpmiBaseLib.c
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/SmmIp
> miBaseLib/SmmIpmiBaseLib.c
> index 6282adc269..ee1d3d5bed 100644
> ---
> a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/SmmIpm
> iBaseLib/SmmIpmiBaseLib.c
> +++
> b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Library/SmmIp
> miB
> +++ aseLib/SmmIpmiBaseLib.c
> @@ -96,7 +96,7 @@ InitializeIpmiBase (
> 
>  **/
>  EFI_STATUS
> -IpmiSubmitCommand (
> +IpmiSendCommand (
>    IN UINT8        NetFunction,
>    IN UINT8        Command,
>    IN UINT8        *CommandData,
> @@ -133,7 +133,7 @@ Returns:
>      return Status;
>    }
> 
> -  Status = mIpmiTransport->IpmiSubmitCommand (
> +  Status = mIpmiTransport->IpmiSendCommand (
>                               mIpmiTransport,
>                               NetFunction,
>                               0,
> diff --git
> a/Platform/Intel/PurleyOpenBoardPkg/Features/Ipmi/Library/IpmiLibKcs/Ip
> miLibKcs.c
> b/Platform/Intel/PurleyOpenBoardPkg/Features/Ipmi/Library/IpmiLibKcs/Ip
> miLibKcs.c
> index 700e413aa6..2b02ba6a20 100644
> ---
> a/Platform/Intel/PurleyOpenBoardPkg/Features/Ipmi/Library/IpmiLibKcs/Ip
> miLibKcs.c
> +++
> b/Platform/Intel/PurleyOpenBoardPkg/Features/Ipmi/Library/IpmiLibKcs
> +++ /IpmiLibKcs.c
> @@ -193,7 +193,7 @@ UpdateBmcStatusOnResponse (  **/  EFI_STATUS
> EFIAPI -IpmiSubmitCommand (
> +IpmiSendCommand (
>    IN     UINT8     NetFunction,
>    IN     UINT8     Command,
>    IN     UINT8     *RequestData,
> @@ -222,7 +222,7 @@ IpmiSubmitCommand (
>      }
> 
>      IpmiInstance->Signature                      = SM_IPMI_BMC_SIGNATURE;
> -    IpmiInstance->KcsTimeoutPeriod               =
> PcdGet64(PcdIpmiKcsTimeoutPeriod);
> +    IpmiInstance->KcsTimeoutPeriod               =
> PcdGet64(PcdIpmiKcsTimeoutPeriod);
>      IpmiInstance->SlaveAddress                   =
> PcdGet8(PcdIpmiBmcSlaveAddress);
>      IpmiInstance->IpmiIoBase                     = PcdGet16(PcdIpmiIoBaseAddress);
>      DEBUG((DEBUG_INFO,"IPMI KcsTimeoutPeriod=0x%x\n", IpmiInstance-
> >KcsTimeoutPeriod)); @@ -269,7 +269,7 @@ IpmiSubmitCommand (
>    }
> 
>    Status = SendDataToBmcPort (
> -       IpmiInstance->KcsTimeoutPeriod,
> +    IpmiInstance->KcsTimeoutPeriod,
>      IpmiInstance->IpmiIoBase,
>      (UINT8 *)IpmiCommand,
>      (UINT8)(RequestDataSize + EFI_IPMI_COMMAND_HEADER_SIZE) @@ -
> 287,7 +287,7 @@ IpmiSubmitCommand (
>    //
>    DataSize = MAX_TEMP_DATA;
>    Status = ReceiveBmcDataFromPort (
> -       IpmiInstance->KcsTimeoutPeriod,
> +    IpmiInstance->KcsTimeoutPeriod,
>      IpmiInstance->IpmiIoBase,
>      (UINT8 *)IpmiResponse,
>      &DataSize
> @@ -301,8 +301,8 @@ IpmiSubmitCommand (
>    }
> 
>    //
> -  // If we got this far without any error codes, but the DataSize is 0 then the
> -  // command response failed, so do not continue.
> +  // If we got this far without any error codes, but the DataSize is 0
> + then the  // command response failed, so do not continue.
>    //
>    if (DataSize < 3) {
>      Status = EFI_DEVICE_ERROR;
> --
> 2.37.1.windows.1

^ permalink raw reply	[flat|nested] 22+ messages in thread

* Re: [edk2-platforms][PATCH 3/7] ManageabilityPkg: Add Readme file
  2023-02-16  1:44   ` Isaac Oram
@ 2023-02-17  7:28     ` Chang, Abner
  0 siblings, 0 replies; 22+ messages in thread
From: Chang, Abner @ 2023-02-17  7:28 UTC (permalink / raw)
  To: Oram, Isaac W, devel@edk2.groups.io
  Cc: Gao, Liming, Desimone, Nathaniel L, Nickle Wang, Igor Kulchytskyy,
	Attar, AbdulLateef (Abdul Lateef)

[AMD Official Use Only - General]



> -----Original Message-----
> From: Oram, Isaac W <isaac.w.oram@intel.com>
> Sent: Thursday, February 16, 2023 9:44 AM
> To: Chang, Abner <Abner.Chang@amd.com>; devel@edk2.groups.io
> Cc: Gao, Liming <gaoliming@byosoft.com.cn>; Desimone, Nathaniel L
> <nathaniel.l.desimone@intel.com>; Nickle Wang <nicklew@nvidia.com>;
> Igor Kulchytskyy <igork@ami.com>; Attar, AbdulLateef (Abdul Lateef)
> <AbdulLateef.Attar@amd.com>
> Subject: RE: [edk2-platforms][PATCH 3/7] ManageabilityPkg: Add Readme
> file
> 
> Caution: This message originated from an External Source. Use proper
> caution when opening attachments, clicking links, or responding.
> 
> 
> Nits, not blocking (I don't know how pedantic the community is and if we
> care about these insignificant details, obviously lots of code doesn't):
So what do you mean here as I am not the English native person and not quite understand the meaning of this sentence.
Do you think we don't need the readme?

> - I don't find that saying it is the "EDK2" Manageability Package adds much
> value/clarity. 
Not sure what do you mean here.

> I would strip out "EDK2" from the discussion, except where it is
> clarifying.  My reasoning is that we may expand with content that isn't really
> edk2 content in some senses. We might want to put more content in here
> and I wouldn't want people to thing it doesn't belong because of the name.
This is the initial version and we will add more content to describe the edk2 protocols for the manageability drivers such as protocol for PLDM and MCTP. The design of library API and etc.

Thanks
Abner

> - "for the industry platform management standards".  I stumbled on this
> sentance, maybe removing "the" would be clearer.
> - "PACKAGES_PATH must contains the path".  "contains" should probably be
> the singular "contain".
> 
> Regards,
> Isaac
> 
> -----Original Message-----
> From: abner.chang@amd.com <abner.chang@amd.com>
> Sent: Tuesday, February 7, 2023 8:23 AM
> To: devel@edk2.groups.io
> Cc: Gao, Liming <gaoliming@byosoft.com.cn>; Oram, Isaac W
> <isaac.w.oram@intel.com>; Desimone, Nathaniel L
> <nathaniel.l.desimone@intel.com>; Nickle Wang <nicklew@nvidia.com>;
> Igor Kulchytskyy <igork@ami.com>; Abdul Lateef Attar
> <abdattar@amd.com>
> Subject: [edk2-platforms][PATCH 3/7] ManageabilityPkg: Add Readme file
> 
> From: Abner Chang <abner.chang@amd.com>
> 
> Add Readme file of edk2 platform ManageabilityPkg.
> 
> Signed-off-by: Abner Chang <abner.chang@amd.com>
> Cc: Liming Gao <gaoliming@byosoft.com.cn>
> Cc: Isaac Oram <isaac.w.oram@intel.com>
> Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
> Cc: Nickle Wang <nicklew@nvidia.com>
> Cc: Igor Kulchytskyy <igork@ami.com>
> Cc: Abdul Lateef Attar <abdattar@amd.com>
> ---
>  Features/ManageabilityPkg/Readme.md | 37
> +++++++++++++++++++++++++++++
>  1 file changed, 37 insertions(+)
>  create mode 100644 Features/ManageabilityPkg/Readme.md
> 
> diff --git a/Features/ManageabilityPkg/Readme.md
> b/Features/ManageabilityPkg/Readme.md
> new file mode 100644
> index 0000000000..880aa4aa48
> --- /dev/null
> +++ b/Features/ManageabilityPkg/Readme.md
> @@ -0,0 +1,37 @@
> +# EDK2 Manageability Package
> +
> +The edk2 Manageability package is introduced to provide edk2 drivers
> +and libraries for the industry platform management standards, such as
> +PLDM (Platform Level Data Model), MCTP (Management Component
> Transfer
> +Protocol) and IPMI (Intelligent Platform Management Interface). The
> +framework of edk2 Manageability package is designed to flexibly support
> +transports for the above industry standards, the transports such as KCS or
> I2C for IPMI, PCI VDM (Vendor Defined Message), I2C or KCS for MCTP, or
> the OEM proprietary transports.
> +
> +## EDK2 Manageability Package Driver Stack
> +
> +Below figure shows the driver stacks which are abstracted to support
> +disparate transports for the platform management.
> +![Manageability Package Driver
> +Stack](https://github.com/tianocore/edk2-
> platforms/blob/master/Features
> +/ManageabilityPkg/Documents/Media/ManageabilityDriverStack.svg?raw=
> true
> +)
> +
> +## Build the Manageability Package
> +In order to use the modules provided by ManageabilityPkg,
> +**PACKAGES_PATH** must contains the path to point to [edk2-platform
> Features](https://github.com/tianocore/edk2-
> platforms/tree/master/Features):
> +
> +```
> +$ export
> +PACKAGES_PATH=$PWD/edk2:$PWD/edk2-platforms:$PWD/edk2-
> platforms/Feature
> +s
> +```
> +
> +Due to the [IPMI Migration
> +Work](#migration-of-ipmi-driver-stack-from-outofbandmanagement) is in
> +progress, an additional package path is required to add to
> +**PACKAGES_PATH** for the reference of IPMI modules those are
> currently
> +located under
> +[OutOfBandManagement](https://github.com/tianocore/edk2-
> platforms/tree/master/Features/Intel/OutOfBandManagement) folder.
> +
> +```
> +$PWD/edk2-platforms/Features/Intel/OutOfBandManagement
> +```
> +
> +## Migration of IPMI Driver Stack from OutOfBandManagement
> +
> +This is the ongoing task that relocates IPMI modules from
> +OutOfBandManagement to under ManageabilityPkg. This task also requires
> +to abstract the transport layer from IPMI driver in order to flexibly support
> different transports adopted on the platform.
> --
> 2.37.1.windows.1

^ permalink raw reply	[flat|nested] 22+ messages in thread

* Re: [edk2-platforms][PATCH 4/7] ManageabilityPkg: Initial package
  2023-02-16  1:49   ` Isaac Oram
@ 2023-02-17  7:29     ` Chang, Abner
  0 siblings, 0 replies; 22+ messages in thread
From: Chang, Abner @ 2023-02-17  7:29 UTC (permalink / raw)
  To: Oram, Isaac W, devel@edk2.groups.io
  Cc: Gao, Liming, Desimone, Nathaniel L,
	Attar, AbdulLateef (Abdul Lateef), Nickle Wang, Igor Kulchytskyy

[AMD Official Use Only - General]

The Manageability package could be included by the AdvancedFeaturePkg.  The reason I didn't use common MinPlatform include metafiles is because there are many driver (plus the pull in libraries) which are no need to be built for ManageabilityPkg.
But to keep the consistent implementation is also important to Tianocore, so I may follow the package implementation under AdvancedFeaturePkg.

Thanks
Abner

> -----Original Message-----
> From: Oram, Isaac W <isaac.w.oram@intel.com>
> Sent: Thursday, February 16, 2023 9:50 AM
> To: Chang, Abner <Abner.Chang@amd.com>; devel@edk2.groups.io
> Cc: Gao, Liming <gaoliming@byosoft.com.cn>; Desimone, Nathaniel L
> <nathaniel.l.desimone@intel.com>; Attar, AbdulLateef (Abdul Lateef)
> <AbdulLateef.Attar@amd.com>; Nickle Wang <nicklew@nvidia.com>; Igor
> Kulchytskyy <igork@ami.com>
> Subject: RE: [edk2-platforms][PATCH 4/7] ManageabilityPkg: Initial package
> 
> Caution: This message originated from an External Source. Use proper
> caution when opening attachments, clicking links, or responding.
> 
> 
> I think that the ManageabilityPkg shouldn't have a file like
> CommonLibs.dsc.inc that defines commonly used content.  It is the wrong
> scope.  I would prefer to use the MinPlatformPkg content on the theory that
> it will move MinPlatformPkg to a more general location once it is in wider use.
> 
> Put another way, either we want many packages to include it, which is weird
> since the content isn't scoped to this package, or it is just for this package and
> others shouldn't include it, in which case, separating it from
> ManageabilityPkg.dsc via an include doesn't add anything.
> 
> If you don't want to use MinPlatformPkg then I would suggest following the
> original buildable package convention and put this content in the
> ManageabilityPkg/ManageabilityPkg.dsc.
> 
> "Manageabilty" is misspelled in a number of places in these files.
> 
> Regards,
> Isaac
> 
> -----Original Message-----
> From: abner.chang@amd.com <abner.chang@amd.com>
> Sent: Tuesday, February 7, 2023 8:23 AM
> To: devel@edk2.groups.io
> Cc: Gao, Liming <gaoliming@byosoft.com.cn>; Oram, Isaac W
> <isaac.w.oram@intel.com>; Desimone, Nathaniel L
> <nathaniel.l.desimone@intel.com>; Abdul Lateef Attar
> <abdattar@amd.com>; Nickle Wang <nicklew@nvidia.com>; Igor Kulchytskyy
> <igork@ami.com>
> Subject: [edk2-platforms][PATCH 4/7] ManageabilityPkg: Initial package
> 
> From: Abner Chang <abner.chang@amd.com>
> 
> Initial commit of ManageabilityPkg
> 
> Signed-off-by: Abner Chang <abner.chang@amd.com>
> Cc: Liming Gao <gaoliming@byosoft.com.cn>
> Cc: Isaac Oram <isaac.w.oram@intel.com>
> Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
> Cc: Abdul Lateef Attar <abdattar@amd.com>
> Cc: Nickle Wang <nicklew@nvidia.com>
> Cc: Igor Kulchytskyy <igork@ami.com>
> ---
>  .../ManageabilityPkg/ManageabilityPkg.dec     | 18 +++++++++
>  .../Include/CommonLibs.dsc.inc                | 40 +++++++++++++++++++
>  .../ManageabilityPkg/ManageabilityPkg.dsc     | 23 +++++++++++
>  3 files changed, 81 insertions(+)
>  create mode 100644 Features/ManageabilityPkg/ManageabilityPkg.dec
>  create mode 100644
> Features/ManageabilityPkg/Include/CommonLibs.dsc.inc
>  create mode 100644 Features/ManageabilityPkg/ManageabilityPkg.dsc
> 
> diff --git a/Features/ManageabilityPkg/ManageabilityPkg.dec
> b/Features/ManageabilityPkg/ManageabilityPkg.dec
> new file mode 100644
> index 0000000000..8a0e28f50b
> --- /dev/null
> +++ b/Features/ManageabilityPkg/ManageabilityPkg.dec
> @@ -0,0 +1,18 @@
> +## @file
> +# Manageabilty Package
> +# This is the package provides the edk2 drivers and libraries # those
> +are related to the platform management.
> +#
> +# Copyright (C) 2023 Advanced Micro Devices, Inc. All rights
> +reserved.<BR> # SPDX-License-Identifier: BSD-2-Clause-Patent # ##
> +
> +[Defines]
> +  DEC_SPECIFICATION = 0x0001001d
> +  PACKAGE_NAME      = ManageabilityPkg
> +  PACKAGE_GUID      = 36310119-4FB2-4BA3-959D-74C16B849F9E
> +  PACKAGE_VERSION   = 1.0
> +
> +[Includes]
> +  Include
> diff --git a/Features/ManageabilityPkg/Include/CommonLibs.dsc.inc
> b/Features/ManageabilityPkg/Include/CommonLibs.dsc.inc
> new file mode 100644
> index 0000000000..2dc2d07f17
> --- /dev/null
> +++ b/Features/ManageabilityPkg/Include/CommonLibs.dsc.inc
> @@ -0,0 +1,40 @@
> +## @file
> +# Common libraries for Manageabilty Package # # Copyright (C) 2023
> +Advanced Micro Devices, Inc. All rights reserved.<BR> #
> +SPDX-License-Identifier: BSD-2-Clause-Patent # ##
> +
> +[LibraryClasses]
> +
> +UefiDriverEntryPoint|MdePkg/Library/UefiDriverEntryPoint/UefiDriverEntr
> +yPoint.inf
> +
> +UefiBootServicesTableLib|MdePkg/Library/UefiBootServicesTableLib/UefiB
> o
> +otServicesTableLib.inf
> +  UefiLib|MdePkg/Library/UefiLib/UefiLib.inf
> +  BaseLib|MdePkg/Library/BaseLib/BaseLib.inf
> +  BaseMemoryLib|MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf
> +  PrintLib|MdePkg/Library/BasePrintLib/BasePrintLib.inf
> +  DebugLib|MdePkg/Library/UefiDebugLibStdErr/UefiDebugLibStdErr.inf
> +  PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf
> +
> +DebugPrintErrorLevelLib|MdePkg/Library/BaseDebugPrintErrorLevelLib/Ba
> se
> +DebugPrintErrorLevelLib.inf
> +  DebugLib|MdePkg/Library/BaseDebugLibNull/BaseDebugLibNull.inf
> +
> +MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMem
> oryAl
> +locationLib.inf
> +
> +[LibraryClasses.common.PEIM]
> +  PeimEntryPoint|MdePkg/Library/PeimEntryPoint/PeimEntryPoint.inf
> +
> +PeiServicesTablePointerLib|MdePkg/Library/PeiServicesTablePointerLibIdt
> +/PeiServicesTablePointerLibIdt.inf
> +  PeiServicesLib|MdePkg/Library/PeiServicesLib/PeiServicesLib.inf
> +
> +MemoryAllocationLib|MdePkg/Library/PeiMemoryAllocationLib/PeiMemor
> yAllo
> +cationLib.inf
> +  HobLib|MdePkg/Library/PeiHobLib/PeiHobLib.inf
> +
> +[LibraryClasses.common.DXE_SMM_DRIVER]
> +
> +SmmServicesTableLib|MdePkg/Library/SmmServicesTableLib/SmmServices
> Table
> +Lib.inf
> +
> +MemoryAllocationLib|MdePkg/Library/SmmMemoryAllocationLib/SmmMe
> moryAllo
> +cationLib.inf
> +
> +[LibraryClasses.ARM, LibraryClasses.AARCH64]
> +  #
> +  # This library provides the instrinsic functions generated by a given
> compiler.
> +  #
> +  NULL|ArmPkg/Library/CompilerIntrinsicsLib/CompilerIntrinsicsLib.inf
> +  NULL|MdePkg/Library/BaseStackCheckLib/BaseStackCheckLib.inf
> +  ArmSoftFloatLib|ArmPkg/Library/ArmSoftFloatLib/ArmSoftFloatLib.inf
> +
> diff --git a/Features/ManageabilityPkg/ManageabilityPkg.dsc
> b/Features/ManageabilityPkg/ManageabilityPkg.dsc
> new file mode 100644
> index 0000000000..9ae398277f
> --- /dev/null
> +++ b/Features/ManageabilityPkg/ManageabilityPkg.dsc
> @@ -0,0 +1,23 @@
> +## @file
> +# Manageabilty Package
> +# This is the package provides edk2 drivers and libraries # those are
> +related to the platform management.
> +#
> +# Copyright (C) 2023 Advanced Micro Devices, Inc. All rights
> +reserved.<BR> # SPDX-License-Identifier: BSD-2-Clause-Patent # ##
> +
> +[Defines]
> +  PLATFORM_NAME                  = ManageabilityPkg
> +  PLATFORM_GUID                  = 7A98123A-B194-40B6-A863-A52192F6D65D
> +  PLATFORM_VERSION               = 1.0
> +  DSC_SPECIFICATION              = 0x0001001e
> +  OUTPUT_DIRECTORY               = Build/ManageabilityPkg
> +  SUPPORTED_ARCHITECTURES        = IA32|X64|ARM|AARCH64|RISCV64
> +  BUILD_TARGETS                  = DEBUG|RELEASE|NOOPT
> +  SKUID_IDENTIFIER               = DEFAULT
> +
> +!include MdePkg/MdeLibs.dsc.inc
> +!include ManageabilityPkg/Include/CommonLibs.dsc.inc
> +
> --
> 2.37.1.windows.1

^ permalink raw reply	[flat|nested] 22+ messages in thread

* Re: [edk2-platforms][PATCH 5/7] ManageabilityPkg: Implement Ipmi Protocol/Ppi
  2023-02-16  1:47   ` Isaac Oram
@ 2023-02-17  7:29     ` Chang, Abner
  0 siblings, 0 replies; 22+ messages in thread
From: Chang, Abner @ 2023-02-17  7:29 UTC (permalink / raw)
  To: Oram, Isaac W, devel@edk2.groups.io
  Cc: Gao, Liming, Desimone, Nathaniel L,
	Attar, AbdulLateef (Abdul Lateef), Nickle Wang, Igor Kulchytskyy

[AMD Official Use Only - General]



> -----Original Message-----
> From: Oram, Isaac W <isaac.w.oram@intel.com>
> Sent: Thursday, February 16, 2023 9:48 AM
> To: Chang, Abner <Abner.Chang@amd.com>; devel@edk2.groups.io
> Cc: Gao, Liming <gaoliming@byosoft.com.cn>; Desimone, Nathaniel L
> <nathaniel.l.desimone@intel.com>; Attar, AbdulLateef (Abdul Lateef)
> <AbdulLateef.Attar@amd.com>; Nickle Wang <nicklew@nvidia.com>; Igor
> Kulchytskyy <igork@ami.com>
> Subject: RE: [edk2-platforms][PATCH 5/7] ManageabilityPkg: Implement Ipmi
> Protocol/Ppi
> 
> Caution: This message originated from an External Source. Use proper
> caution when opening attachments, clicking links, or responding.
> 
> 
> I find the code to be misleading because source code looks like it is using the
> edk2 API but it actually invokes the IpmiFeaturePkg implementations of the
> IpmiTransport* API.  we end up with things like a depex that says TRUE, but
> really includes a library that carries a dependency on a different protocol than
> the one in the INF.  It includes IpmiProtocol.h, but actually invokes a library
> that locates and uses IpmiTransportProtocol.h.
> 
> I think that we should have these implement IpmiPpi.h and IpmiProtocol.h
> instead of chaining them into the old implementation.
Agree as my feedback given to patch 1/7.
Abner

> 
> If we don't want to implement them directly, I would prefer to obviously
> have the IpmiPpi and IpmiProtocol implementations look up and invoke
> IpmiTransportPpi and IpmiTransportProtocol directly so that the code is
> obvious about what it is doing.  It seems that IpmiBaseLib only abstracts the
> phase for calling code.  Is there any other value for phase specific code to
> obfuscate what is really happening by adding the library layer?  If the library is
> there to avoid source code collisions, then I guess detailed commenting at all
> the misleading places is probably the only answer besides implementing
> directly.
> 
> Regards,
> Isaac
> 
> -----Original Message-----
> From: abner.chang@amd.com <abner.chang@amd.com>
> Sent: Tuesday, February 7, 2023 8:23 AM
> To: devel@edk2.groups.io
> Cc: Gao, Liming <gaoliming@byosoft.com.cn>; Oram, Isaac W
> <isaac.w.oram@intel.com>; Desimone, Nathaniel L
> <nathaniel.l.desimone@intel.com>; Abdul Lateef Attar
> <abdattar@amd.com>; Nickle Wang <nicklew@nvidia.com>; Igor Kulchytskyy
> <igork@ami.com>
> Subject: [edk2-platforms][PATCH 5/7] ManageabilityPkg: Implement Ipmi
> Protocol/Ppi
> 
> From: Abner Chang <abner.chang@amd.com>
> 
> Add Ipmi Protocol/Ppi implementation. The underlying implementation is
> provided by IpmiBaseLib.
> 
> Signed-off-by: Abner Chang <abner.chang@amd.com>
> Cc: Liming Gao <gaoliming@byosoft.com.cn>
> Cc: Isaac Oram <isaac.w.oram@intel.com>
> Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
> Cc: Abdul Lateef Attar <abdattar@amd.com>
> Cc: Nickle Wang <nicklew@nvidia.com>
> Cc: Igor Kulchytskyy <igork@ami.com>
> ---
>  .../IpmiProtocol/Dxe/IpmiProtocolDxe.inf      |  37 +++++++
>  .../Universal/IpmiProtocol/Pei/IpmiPpiPei.inf |  38 +++++++
>  .../IpmiProtocol/Smm/IpmiProtocolSmm.inf      |  40 +++++++
>  .../Universal/IpmiProtocol/Dxe/IpmiProtocol.c |  97 +++++++++++++++++
>  .../Universal/IpmiProtocol/Pei/IpmiPpi.c      | 102 ++++++++++++++++++
>  .../Universal/IpmiProtocol/Smm/IpmiProtocol.c |  98 +++++++++++++++++
>  6 files changed, 412 insertions(+)
>  create mode 100644
> Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocolDxe.in
> f
>  create mode 100644
> Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpiPei.inf
>  create mode 100644
> Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocolSmm
> .inf
>  create mode 100644
> Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocol.c
>  create mode 100644
> Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpi.c
>  create mode 100644
> Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocol.c
> 
> diff --git
> a/Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocolDxe.
> inf
> b/Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocolDxe
> .inf
> new file mode 100644
> index 0000000000..0737a5ad8f
> --- /dev/null
> +++
> b/Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocolD
> +++ xe.inf
> @@ -0,0 +1,37 @@
> +## @file
> +# IPMI Protocol DXE Driver.
> +#
> +# Copyright (C) 2023 Advanced Micro Devices, Inc. All rights
> +reserved.<BR> # SPDX-License-Identifier: BSD-2-Clause-Patent ##
> +
> +[Defines]
> +  INF_VERSION                    = 0x0001001d
> +  BASE_NAME                      = IpmiDxe
> +  FILE_GUID                      = BC41B0C2-9D8A-42B5-A28F-02CE0D4A6C28
> +  MODULE_TYPE                    = DXE_DRIVER
> +  VERSION_STRING                 = 1.0
> +  ENTRY_POINT                    = IpmiEntry
> +
> +#
> +#  VALID_ARCHITECTURES           = IA32 X64 ARM AARCH64
> +#
> +
> +[Sources]
> +  IpmiProtocol.c
> +
> +[Packages]
> +  MdePkg/MdePkg.dec
> +  MdeModulePkg/MdeModulePkg.dec
> +  IpmiFeaturePkg/IpmiFeaturePkg.dec
> +
> +[LibraryClasses]
> +  IpmiBaseLib
> +  UefiDriverEntryPoint
> +  UefiBootServicesTableLib
> +
> +[Protocols]
> +  gIpmiProtocolGuid               # PROTOCOL ALWAYS_PRODUCED
> +
> +[Depex]
> +  TRUE
> diff --git
> a/Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpiPei.inf
> b/Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpiPei.inf
> new file mode 100644
> index 0000000000..7ba8584f84
> --- /dev/null
> +++ b/Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpiPei.in
> +++ f
> @@ -0,0 +1,38 @@
> +## @file
> +# IPMI Protocol PEI Driver.
> +#
> +# Copyright (C) 2023 Advanced Micro Devices, Inc. All rights
> +reserved.<BR> # SPDX-License-Identifier: BSD-2-Clause-Patent ##
> +
> +[Defines]
> +  INF_VERSION                    = 0x0001001d
> +  BASE_NAME                      = IpmiPei
> +  FILE_GUID                      = 7832F989-CB72-4715-ADCA-35C0B031856C
> +  MODULE_TYPE                    = PEIM
> +  VERSION_STRING                 = 1.0
> +  ENTRY_POINT                    = IpmiEntry
> +
> +#
> +# The following information is for reference only and not required by the
> build tools.
> +#
> +#  VALID_ARCHITECTURES           = IA32 X64 ARM AARCH64
> +#
> +
> +[Sources]
> +  IpmiPpi.c
> +
> +[Packages]
> +  MdePkg/MdePkg.dec
> +  MdeModulePkg/MdeModulePkg.dec
> +  IpmiFeaturePkg/IpmiFeaturePkg.dec
> +
> +[LibraryClasses]
> +  IpmiBaseLib
> +  PeimEntryPoint
> +
> +[Ppis]
> +  gPeiIpmiPpiGuid       # PPI ALWAYS PRODUCED
> +
> +[Depex]
> +  TRUE
> diff --git
> a/Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocolSm
> m.inf
> b/Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocolSm
> m.inf
> new file mode 100644
> index 0000000000..25a5771cb3
> --- /dev/null
> +++
> b/Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocolS
> +++ mm.inf
> @@ -0,0 +1,40 @@
> +## @file
> +# IPMI Protocol SMM Driver.
> +#
> +# Copyright (C) 2023 Advanced Micro Devices, Inc. All rights
> +reserved.<BR> # SPDX-License-Identifier: BSD-2-Clause-Patent ##
> +
> +#
> +# The following information is for reference only and not required by the
> build tools.
> +#
> +#  VALID_ARCHITECTURES           = IA32 X64 ARM AARCH64
> +#
> +[Defines]
> +  INF_VERSION                         = 0x0001001d
> +  BASE_NAME                           = IpmiSmm
> +  FILE_GUID                           = CDD5D1DE-E3D3-4B1F-8689-DCC661561BB4
> +  MODULE_TYPE                         = DXE_SMM_DRIVER
> +  PI_SPECIFICATION_VERSION            = 0x0001000A
> +  VERSION_STRING                      = 1.0
> +  ENTRY_POINT                         = IpmiEntry
> +
> +[Sources]
> +  IpmiProtocol.c
> +
> +[Packages]
> +  MdePkg/MdePkg.dec
> +  MdeModulePkg/MdeModulePkg.dec
> +  IpmiFeaturePkg/IpmiFeaturePkg.dec
> +
> +[LibraryClasses]
> +  IpmiBaseLib
> +  UefiDriverEntryPoint
> +  UefiBootServicesTableLib
> +  SmmServicesTableLib
> +
> +[Protocols]
> +  gSmmIpmiProtocolGuid               # PROTOCOL ALWAYS_PRODUCED
> +
> +[Depex]
> +  TRUE
> diff --git
> a/Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocol.c
> b/Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocol.c
> new file mode 100644
> index 0000000000..1f0b88052e
> --- /dev/null
> +++ b/Features/ManageabilityPkg/Universal/IpmiProtocol/Dxe/IpmiProtocol.
> +++ c
> @@ -0,0 +1,97 @@
> +/** @file
> +  This file provides IPMI Protocol implementation.
> +
> +  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights
> +reserved.<BR>
> +  SPDX-License-Identifier: BSD-2-Clause-Patent **/
> +
> +#include <PiDxe.h>
> +#include <Library/DebugLib.h>
> +#include <Library/UefiBootServicesTableLib.h>
> +#include <Library/IpmiBaseLib.h>
> +#include <Protocol/IpmiProtocol.h>
> +
> +/**
> +  This service enables submitting commands via Ipmi.
> +
> +  @param[in]         This              This point for IPMI_PROTOCOL structure.
> +  @param[in]         NetFunction       Net function of the command.
> +  @param[in]         Command           IPMI Command.
> +  @param[in]         RequestData       Command Request Data.
> +  @param[in]         RequestDataSize   Size of Command Request Data.
> +  @param[out]        ResponseData      Command Response Data. The
> completion code is the first byte of response data.
> +  @param[in, out]    ResponseDataSize  Size of Command Response Data.
> +
> +  @retval EFI_SUCCESS            The command byte stream was successfully
> submit to the device and a response was successfully received.
> +  @retval EFI_NOT_FOUND          The command was not successfully sent to
> the device or a response was not successfully received from the device.
> +  @retval EFI_NOT_READY          Ipmi Device is not ready for Ipmi command
> access.
> +  @retval EFI_DEVICE_ERROR       Ipmi Device hardware error.
> +  @retval EFI_TIMEOUT            The command time out.
> +  @retval EFI_UNSUPPORTED        The command was not successfully sent to
> the device.
> +  @retval EFI_OUT_OF_RESOURCES   The resource allcation is out of
> resource or data size error.
> +**/
> +EFI_STATUS
> +EFIAPI
> +IpmiSubmitCommand (
> +  IN     IPMI_PROTOCOL  *This,
> +  IN     UINT8          NetFunction,
> +  IN     UINT8          Command,
> +  IN     UINT8          *RequestData,
> +  IN     UINT32         RequestDataSize,
> +  OUT    UINT8          *ResponseData,
> +  IN OUT UINT32         *ResponseDataSize
> +  )
> +{
> +  EFI_STATUS  Status;
> +
> +  Status = IpmiSendCommand (
> +             NetFunction,
> +             Command,
> +             RequestData,
> +             RequestDataSize,
> +             ResponseData,
> +             ResponseDataSize
> +             );
> +  if (EFI_ERROR (Status)) {
> +    DEBUG ((DEBUG_ERROR, "%a: Failed to send IPMI command in DXE -
> + %r\n", __FUNCTION__, Status));  }
> +
> +  return Status;
> +}
> +
> +static IPMI_PROTOCOL  mIpmiProtocol = {
> +  IpmiSubmitCommand
> +};
> +
> +/**
> +  The entry point of the Ipmi DXE driver.
> +
> +  @param[in] ImageHandle - Handle of this driver image  @param[in]
> + SystemTable - Table containing standard EFI services
> +
> +  @retval EFI_SUCCESS    - IPMI Protocol is installed successfully.
> +  @retval Otherwise      - Other errors.
> +**/
> +EFI_STATUS
> +EFIAPI
> +IpmiEntry (
> +  IN EFI_HANDLE        ImageHandle,
> +  IN EFI_SYSTEM_TABLE  *SystemTable
> +  )
> +{
> +  EFI_STATUS  Status;
> +  EFI_HANDLE  Handle;
> +
> +  Handle = NULL;
> +  Status = gBS->InstallProtocolInterface (
> +                  &Handle,
> +                  &gIpmiProtocolGuid,
> +                  EFI_NATIVE_INTERFACE,
> +                  (VOID **)&mIpmiProtocol
> +                  );
> +  if (EFI_ERROR (Status)) {
> +    DEBUG ((DEBUG_ERROR, "%a: Failed to install IPMI protocol - %r\n",
> + __FUNCTION__, Status));  }
> +
> +  return Status;
> +}
> diff --git a/Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpi.c
> b/Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpi.c
> new file mode 100644
> index 0000000000..913a9b0811
> --- /dev/null
> +++ b/Features/ManageabilityPkg/Universal/IpmiProtocol/Pei/IpmiPpi.c
> @@ -0,0 +1,102 @@
> +/** @file
> +  This file provides IPMI PPI implementation.
> +
> +  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights
> + reserved.<BR>
> +  SPDX-License-Identifier: BSD-2-Clause-Patent
> +
> +**/
> +
> +#include <PiPei.h>
> +#include <Library/DebugLib.h>
> +#include <Library/PeiServicesLib.h>
> +#include <Library/IpmiBaseLib.h>
> +#include <Ppi/IpmiPpi.h>
> +
> +/**
> +  This service enables submitting commands via Ipmi.
> +
> +  @param[in]         This              This point for PEI_IPMI_PPI structure.
> +  @param[in]         NetFunction       Net function of the command.
> +  @param[in]         Command           IPMI Command.
> +  @param[in]         RequestData       Command Request Data.
> +  @param[in]         RequestDataSize   Size of Command Request Data.
> +  @param[out]        ResponseData      Command Response Data. The
> completion code is the first byte of response data.
> +  @param[in, out]    ResponseDataSize  Size of Command Response Data.
> +
> +  @retval EFI_SUCCESS            The command byte stream was successfully
> submit to the device and a response was successfully received.
> +  @retval EFI_NOT_FOUND          The command was not successfully sent to
> the device or a response was not successfully received from the device.
> +  @retval EFI_NOT_READY          Ipmi Device is not ready for Ipmi command
> access.
> +  @retval EFI_DEVICE_ERROR       Ipmi Device hardware error.
> +  @retval EFI_TIMEOUT            The command time out.
> +  @retval EFI_UNSUPPORTED        The command was not successfully sent to
> the device.
> +  @retval EFI_OUT_OF_RESOURCES   The resource allcation is out of
> resource or data size error.
> +**/
> +EFI_STATUS
> +EFIAPI
> +IpmiSubmitCommand (
> +  IN     PEI_IPMI_PPI  *This,
> +  IN     UINT8         NetFunction,
> +  IN     UINT8         Command,
> +  IN     UINT8         *RequestData,
> +  IN     UINT32        RequestDataSize,
> +  OUT    UINT8         *ResponseData,
> +  IN OUT UINT32        *ResponseDataSize
> +  )
> +{
> +  EFI_STATUS  Status;
> +
> +  Status = IpmiSendCommand (
> +             NetFunction,
> +             Command,
> +             RequestData,
> +             RequestDataSize,
> +             ResponseData,
> +             ResponseDataSize
> +             );
> +  if (EFI_ERROR (Status)) {
> +    DEBUG ((DEBUG_ERROR, "%a: Failed to send IPMI command in PEI-
> + %r\n", __FUNCTION__, Status));  }
> +
> +  return Status;
> +}
> +
> +static PEI_IPMI_PPI  mPeiIpmiPpi = {
> +  IpmiSubmitCommand
> +};
> +
> +static EFI_PEI_PPI_DESCRIPTOR  mIpmiPpiList[] = {
> +  {
> +    (EFI_PEI_PPI_DESCRIPTOR_PPI |
> EFI_PEI_PPI_DESCRIPTOR_TERMINATE_LIST),
> +    &gPeiIpmiPpiGuid,
> +    &mPeiIpmiPpi
> +  }
> +};
> +
> +/**
> +  The entry point of the Ipmi PPI PEIM.
> +
> +  @param  FileHandle  Handle of the file being invoked.
> +  @param  PeiServices Describes the list of possible PEI Services.
> +
> +  @retval EFI_SUCCESS   Indicates that Ipmi initialization completed
> successfully.
> +  @retval Others        Indicates that Ipmi initialization could not complete
> successfully.
> +**/
> +EFI_STATUS
> +EFIAPI
> +IpmiEntry (
> +  IN       EFI_PEI_FILE_HANDLE  FileHandle,
> +  IN CONST EFI_PEI_SERVICES     **PeiServices
> +  )
> +{
> +  EFI_STATUS  Status;
> +
> +  //
> +  // Install IPMI PPI.
> +  //
> +  Status = PeiServicesInstallPpi (&mIpmiPpiList[0]);  if (EFI_ERROR
> + (Status)) {
> +    DEBUG ((DEBUG_ERROR, "%a: Failed to install IPMI PPI - %r\n",
> + __FUNCTION__, Status));  }
> +
> +  return Status;
> +}
> diff --git
> a/Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocol.c
> b/Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocol.c
> new file mode 100644
> index 0000000000..ed14f9fbd1
> --- /dev/null
> +++
> b/Features/ManageabilityPkg/Universal/IpmiProtocol/Smm/IpmiProtocol.
> +++ c
> @@ -0,0 +1,98 @@
> +/** @file
> +  This file provides IPMI SMM Protocol implementation.
> +
> +  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights
> +reserved.<BR>
> +  SPDX-License-Identifier: BSD-2-Clause-Patent **/
> +
> +#include <PiDxe.h>
> +#include <Library/DebugLib.h>
> +#include <Library/UefiBootServicesTableLib.h>
> +#include <Library/SmmServicesTableLib.h> #include
> +<Library/IpmiBaseLib.h> #include <Protocol/IpmiProtocol.h>
> +
> +/**
> +  This service enables submitting commands via Ipmi.
> +
> +  @param[in]         This              This point for IPMI_PROTOCOL structure.
> +  @param[in]         NetFunction       Net function of the command.
> +  @param[in]         Command           IPMI Command.
> +  @param[in]         RequestData       Command Request Data.
> +  @param[in]         RequestDataSize   Size of Command Request Data.
> +  @param[out]        ResponseData      Command Response Data. The
> completion code is the first byte of response data.
> +  @param[in, out]    ResponseDataSize  Size of Command Response Data.
> +
> +  @retval EFI_SUCCESS            The command byte stream was successfully
> submit to the device and a response was successfully received.
> +  @retval EFI_NOT_FOUND          The command was not successfully sent to
> the device or a response was not successfully received from the device.
> +  @retval EFI_NOT_READY          Ipmi Device is not ready for Ipmi command
> access.
> +  @retval EFI_DEVICE_ERROR       Ipmi Device hardware error.
> +  @retval EFI_TIMEOUT            The command time out.
> +  @retval EFI_UNSUPPORTED        The command was not successfully sent to
> the device.
> +  @retval EFI_OUT_OF_RESOURCES   The resource allcation is out of
> resource or data size error.
> +**/
> +EFI_STATUS
> +EFIAPI
> +IpmiSubmitCommand (
> +  IN     IPMI_PROTOCOL  *This,
> +  IN     UINT8          NetFunction,
> +  IN     UINT8          Command,
> +  IN     UINT8          *RequestData,
> +  IN     UINT32         RequestDataSize,
> +  OUT    UINT8          *ResponseData,
> +  IN OUT UINT32         *ResponseDataSize
> +  )
> +{
> +  EFI_STATUS  Status;
> +
> +  Status = IpmiSendCommand (
> +             NetFunction,
> +             Command,
> +             RequestData,
> +             RequestDataSize,
> +             ResponseData,
> +             ResponseDataSize
> +             );
> +  if (EFI_ERROR (Status)) {
> +    DEBUG ((DEBUG_ERROR, "%a: Failed to send IPMI command in DXE -
> + %r\n", __FUNCTION__, Status));  }
> +
> +  return Status;
> +}
> +
> +static IPMI_PROTOCOL  mIpmiProtocol = {
> +  IpmiSubmitCommand
> +};
> +
> +/**
> +  The entry point of the Ipmi DXE driver.
> +
> +  @param[in] ImageHandle - Handle of this driver image  @param[in]
> + SystemTable - Table containing standard EFI services
> +
> +  @retval EFI_SUCCESS    - IPMI Protocol is installed successfully.
> +  @retval Otherwise      - Other errors.
> +**/
> +EFI_STATUS
> +EFIAPI
> +IpmiEntry (
> +  IN EFI_HANDLE        ImageHandle,
> +  IN EFI_SYSTEM_TABLE  *SystemTable
> +  )
> +{
> +  EFI_STATUS  Status;
> +  EFI_HANDLE  Handle;
> +
> +  Handle = NULL;
> +  Status = gSmst->SmmInstallProtocolInterface (
> +                    &Handle,
> +                    &gSmmIpmiProtocolGuid,
> +                    EFI_NATIVE_INTERFACE,
> +                    (VOID **)&mIpmiProtocol
> +                    );
> +  if (EFI_ERROR (Status)) {
> +    DEBUG ((DEBUG_ERROR, "%a: Failed to install IPMI SMM protocol -
> + %r\n", __FUNCTION__, Status));  }
> +
> +  return Status;
> +}
> --
> 2.37.1.windows.1

^ permalink raw reply	[flat|nested] 22+ messages in thread

* Re: [edk2-devel] [edk2-platforms][PATCH 7/7] edk2-platforms: Maintainers.txt
  2023-02-16  1:51     ` Isaac Oram
@ 2023-02-17  7:30       ` Chang, Abner
  0 siblings, 0 replies; 22+ messages in thread
From: Chang, Abner @ 2023-02-17  7:30 UTC (permalink / raw)
  To: Oram, Isaac W, devel@edk2.groups.io
  Cc: Attar, AbdulLateef (Abdul Lateef), Leif Lindholm,
	Kinney, Michael D, Gao, Liming, Desimone, Nathaniel L

[-- Attachment #1: Type: text/plain, Size: 5056 bytes --]

[AMD Official Use Only - General]

Sure!
Abner

From: Oram, Isaac W <isaac.w.oram@intel.com>
Sent: Thursday, February 16, 2023 9:51 AM
To: Chang, Abner <Abner.Chang@amd.com>; devel@edk2.groups.io
Cc: Attar, AbdulLateef (Abdul Lateef) <AbdulLateef.Attar@amd.com>; Leif Lindholm <quic_llindhol@quicinc.com>; Kinney, Michael D <michael.d.kinney@intel.com>; Gao, Liming <gaoliming@byosoft.com.cn>; Desimone, Nathaniel L <nathaniel.l.desimone@intel.com>
Subject: RE: [edk2-devel] [edk2-platforms][PATCH 7/7] edk2-platforms: Maintainers.txt


[AMD Official Use Only - General]

Caution: This message originated from an External Source. Use proper caution when opening attachments, clicking links, or responding.

Please add me as a maintainer.  That gives us redundancy in maintainers and will also incentivize me to provide feedback on proprietary implementations which could hamper adoption.

Regards,
Isaac

From: Chang, Abner <Abner.Chang@amd.com<mailto:Abner.Chang@amd.com>>
Sent: Tuesday, February 7, 2023 10:25 AM
To: devel@edk2.groups.io<mailto:devel@edk2.groups.io>
Cc: Attar, AbdulLateef (Abdul Lateef) <AbdulLateef.Attar@amd.com<mailto:AbdulLateef.Attar@amd.com>>; Leif Lindholm <quic_llindhol@quicinc.com<mailto:quic_llindhol@quicinc.com>>; Kinney, Michael D <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Gao, Liming <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>; Oram, Isaac W <isaac.w.oram@intel.com<mailto:isaac.w.oram@intel.com>>; Desimone, Nathaniel L <nathaniel.l.desimone@intel.com<mailto:nathaniel.l.desimone@intel.com>>
Subject: Re: [edk2-devel] [edk2-platforms][PATCH 7/7] edk2-platforms: Maintainers.txt


[AMD Official Use Only - General]

Hi Isaac, Nate and Liming,
Please let me know if you would like to be the reviewer for ManageabilityPkg or not. I will add you to the maintainer list in the next patch set if you want.
Thanks
Abner


Get Outlook for Android<https://aka.ms/AAb9ysg>
________________________________
From: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>> on behalf of Chang, Abner via groups.io <abner.chang=amd.com@groups.io<mailto:abner.chang=amd.com@groups.io>>
Sent: Tuesday, February 7, 2023 11:22:36 AM
To: devel@edk2.groups.io<mailto:devel@edk2.groups.io> <devel@edk2.groups.io<mailto:devel@edk2.groups.io>>
Cc: Attar, AbdulLateef (Abdul Lateef) <AbdulLateef.Attar@amd.com<mailto:AbdulLateef.Attar@amd.com>>; Leif Lindholm <quic_llindhol@quicinc.com<mailto:quic_llindhol@quicinc.com>>; Michael D Kinney <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>; Liming Gao <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>; Isaac Oram <isaac.w.oram@intel.com<mailto:isaac.w.oram@intel.com>>; Nate DeSimone <nathaniel.l.desimone@intel.com<mailto:nathaniel.l.desimone@intel.com>>
Subject: [edk2-devel] [edk2-platforms][PATCH 7/7] edk2-platforms: Maintainers.txt

Caution: This message originated from an External Source. Use proper caution when opening attachments, clicking links, or responding.


From: Abner Chang <abner.chang@amd.com<mailto:abner.chang@amd.com>>

Add maintainer and reviewer of ManageabilityPkg.

Signed-off-by: Abner Chang <abner.chang@amd.com<mailto:abner.chang@amd.com>>
Cc: Abdul Lateef Attar <abdattar@amd.com<mailto:abdattar@amd.com>>
Cc: Leif Lindholm <quic_llindhol@quicinc.com<mailto:quic_llindhol@quicinc.com>>
Cc: Michael D Kinney <michael.d.kinney@intel.com<mailto:michael.d.kinney@intel.com>>
Cc: Liming Gao <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>
Cc: Isaac Oram <isaac.w.oram@intel.com<mailto:isaac.w.oram@intel.com>>
Cc: Nate DeSimone <nathaniel.l.desimone@intel.com<mailto:nathaniel.l.desimone@intel.com>>
---
 Maintainers.txt | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/Maintainers.txt b/Maintainers.txt
index da1c98638d..1bd7838d61 100644
--- a/Maintainers.txt
+++ b/Maintainers.txt
@@ -164,6 +164,11 @@ F: Features/Intel/UserInterface/
 M: Dandan Bi <dandan.bi@intel.com<mailto:dandan.bi@intel.com>>
 R: Liming Gao <gaoliming@byosoft.com.cn<mailto:gaoliming@byosoft.com.cn>>

+Features/ManageabilityPkg
+F: Features/ManageabilityPkg/
+M: Abner Chang <abner.chang@amd.com<mailto:abner.chang@amd.com>>
+R: Abdul Lateef Attar <AbdulLateef.Attar@amd.com<mailto:AbdulLateef.Attar@amd.com>>
+
 Platform/Intel
 F: Platform/Intel/
 M: Sai Chaganty <rangasai.v.chaganty@intel.com<mailto:rangasai.v.chaganty@intel.com>>
@@ -326,10 +331,10 @@ R: Yuwei Chen <yuwei.chen@intel.com<mailto:yuwei.chen@intel.com>>

 Loongson platforms
 F: Platform/Loongson/
-M: Bibo Mao <maobibo@loongson.cn<mailto:maobibo@loongson.cn>>
+M: Bibo Mao <maobibo@loongson.cn<mailto:maobibo@loongson.cn>>
 M: Xianglai li <lixianglai@loongson.cn<mailto:lixianglai@loongson.cn>>
 M: Chao Li <lichao@loongson.cn<mailto:lichao@loongson.cn>>
-
+
 Marvell platforms and silicon
 F: Platform/Marvell/
 F: Platform/SolidRun/Armada80x0McBin/
--
2.37.1.windows.1





[-- Attachment #2: Type: text/html, Size: 11388 bytes --]

^ permalink raw reply related	[flat|nested] 22+ messages in thread

end of thread, other threads:[~2023-02-17  7:30 UTC | newest]

Thread overview: 22+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-02-07 16:22 [edk2-platforms][PATCH 0/7] Implementation of IPMI Protocol Chang, Abner
2023-02-07 16:22 ` [edk2-platforms][PATCH 1/7] IpmiFeaturePkg: Rename IpmiSubmitCommand function Chang, Abner
2023-02-16  1:43   ` Isaac Oram
2023-02-17  7:28     ` Chang, Abner
2023-02-07 16:22 ` [edk2-platforms][PATCH 2/7] ManageabilityPkg: Add diagrams Chang, Abner
2023-02-07 16:22 ` [edk2-platforms][PATCH 3/7] ManageabilityPkg: Add Readme file Chang, Abner
2023-02-16  1:44   ` Isaac Oram
2023-02-17  7:28     ` Chang, Abner
2023-02-07 16:22 ` [edk2-platforms][PATCH 4/7] ManageabilityPkg: Initial package Chang, Abner
2023-02-16  1:49   ` Isaac Oram
2023-02-17  7:29     ` Chang, Abner
2023-02-07 16:22 ` [edk2-platforms][PATCH 5/7] ManageabilityPkg: Implement Ipmi Protocol/Ppi Chang, Abner
2023-02-16  1:47   ` Isaac Oram
2023-02-17  7:29     ` Chang, Abner
2023-02-07 16:22 ` [edk2-platforms][PATCH 6/7] IpmiProtocol: Add to Manageability Package Chang, Abner
2023-02-07 16:22 ` [edk2-platforms][PATCH 7/7] edk2-platforms: Maintainers.txt Chang, Abner
2023-02-08  7:34   ` Michael D Kinney
     [not found] ` <174197631C900AFE.27199@groups.io>
2023-02-07 18:24   ` [edk2-devel] " Chang, Abner
2023-02-16  1:51     ` Isaac Oram
2023-02-17  7:30       ` Chang, Abner
2023-02-16  1:42 ` [edk2-platforms][PATCH 0/7] Implementation of IPMI Protocol Isaac Oram
2023-02-17  7:27   ` Chang, Abner

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox