public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* [PATCH V4 0/3] IPMI changes for Redfish
@ 2023-01-06  2:57 Chang, Abner
  2023-01-06  2:57 ` [PATCH V4 1/3] MdePkg/IndustryStandard: Update IPMI definitions Chang, Abner
                   ` (3 more replies)
  0 siblings, 4 replies; 10+ messages in thread
From: Chang, Abner @ 2023-01-06  2:57 UTC (permalink / raw)
  To: devel
  Cc: Michael D Kinney, Liming Gao, Zhiguang Liu, Nickle Wang,
	Igor Kulchytskyy, Isaac Oram, Nate DeSimone

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

In V4: Updateed copyright to 2023
       Addressd the comment from Isaac on V3 2/3
In V3: Addressd the comments on V1 2/3
In V2: Addressd the comments on V1 3/3

This patch updates IPMI related definitions for supporting
Redfish Host interface Credential bootstrapping spec and
building up SMBIOS 42 record for the USB NIC host
interface exposed by BMC.
The corresponding updates on IpmiFeaturePkg is in the
separate pacth for edk2-platforms.

This is the part I of upstream, the follow up patche sets are:
- RedfishPlatformCredentialLib contributed by NVidia.
- Relocate IpmiCommandLib.h from edk2-platforms
  to edk2/MdePkg. A NULL instance of IpmiCommandLib is created
  and located under MdePkg. With above, RedfishPkg doesn't have the
  dependence with edk2-platforms. The implementation of IpmiCommandLib
  stays in edk2-platforms without relocation, which can be pulled in
  to platform DSC as needed.
- PlatformHostInterfaceBmcUsbNic would be upstream to edk2-staging
  temporarily because some requirements are necessray to be spec out
  in the Redfish section in UEFI spec.

Signed-off-by: Abner Chang <abner.chang@amd.com>
Cc: Michael D Kinney <michael.d.kinney@intel.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Zhiguang Liu <zhiguang.liu@intel.com>
Cc: Nickle Wang <nicklew@nvidia.com>
Cc: Igor Kulchytskyy <igork@ami.com>
Cc: Isaac Oram <isaac.w.oram@intel.com>
Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
Abner Chang (3):
  MdePkg/IndustryStandard: Update IPMI definitions
  RedfishPkg/Include: Add Redfish IPMI definitions
  RedfishPkg/Include: Redfish USB Interface V2 update

 MdePkg/Include/IndustryStandard/Ipmi.h        | 17 +++++++
 .../Include/IndustryStandard/IpmiNetFnApp.h   | 37 ++++++++++++--
 .../IndustryStandard/IpmiNetFnTransport.h     | 32 ++++++++++++
 .../IndustryStandard/RedfishHostInterface.h   | 25 ++++++++-
 .../RedfishHostInterfaceIpmi.h                | 51 +++++++++++++++++++
 5 files changed, 157 insertions(+), 5 deletions(-)
 create mode 100644 RedfishPkg/Include/IndustryStandard/RedfishHostInterfaceIpmi.h

-- 
2.37.1.windows.1


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

* [PATCH V4 1/3] MdePkg/IndustryStandard: Update IPMI definitions
  2023-01-06  2:57 [PATCH V4 0/3] IPMI changes for Redfish Chang, Abner
@ 2023-01-06  2:57 ` Chang, Abner
  2023-01-18  5:13   ` 回复: [edk2-devel] " gaoliming
  2023-01-06  2:57 ` [PATCH V4 2/3] RedfishPkg/Include: Add Redfish " Chang, Abner
                   ` (2 subsequent siblings)
  3 siblings, 1 reply; 10+ messages in thread
From: Chang, Abner @ 2023-01-06  2:57 UTC (permalink / raw)
  To: devel
  Cc: Michael D Kinney, Liming Gao, Zhiguang Liu, Nickle Wang,
	Igor Kulchytskyy, Isaac Oram, Nate DeSimone

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

This change updates IPMI header files to support
build up SMBIOS 42 Redfish Host Interface record
using the information retrieved via IPMI App/Net
Function.

Signed-off-by: Abner Chang <abner.chang@amd.com>
Cc: Michael D Kinney <michael.d.kinney@intel.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Zhiguang Liu <zhiguang.liu@intel.com>
Cc: Nickle Wang <nicklew@nvidia.com>
Cc: Igor Kulchytskyy <igork@ami.com>
Cc: Isaac Oram <isaac.w.oram@intel.com>
Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
---
 MdePkg/Include/IndustryStandard/Ipmi.h        | 17 +++++++++
 .../Include/IndustryStandard/IpmiNetFnApp.h   | 37 +++++++++++++++++--
 .../IndustryStandard/IpmiNetFnTransport.h     | 32 ++++++++++++++++
 3 files changed, 82 insertions(+), 4 deletions(-)

diff --git a/MdePkg/Include/IndustryStandard/Ipmi.h b/MdePkg/Include/IndustryStandard/Ipmi.h
index 9d1d412b53e..d6e7436b5ae 100644
--- a/MdePkg/Include/IndustryStandard/Ipmi.h
+++ b/MdePkg/Include/IndustryStandard/Ipmi.h
@@ -6,6 +6,7 @@
   and Appendix H, Sub-function Assignments.
 
   Copyright (c) 1999 - 2018, Intel Corporation. All rights reserved.<BR>
+  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights reserved.<BR>
   SPDX-License-Identifier: BSD-2-Clause-Patent
 **/
 
@@ -52,4 +53,20 @@
 #define IPMI_COMP_CODE_SUBFUNCTION_DISABLED             0xD6
 #define IPMI_COMP_CODE_UNSPECIFIED                      0xFF
 
+#define IPMI_CHANNEL_NUMBER_PRIMARY_IPMB                0x00
+#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_1   0x01
+#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_2   0x02
+#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_3   0x03
+#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_4   0x04
+#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_5   0x05
+#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_6   0x06
+#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_7   0x07
+#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_8   0x08
+#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_9   0x09
+#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_10  0x0A
+#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_11  0x0B
+#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_RESERVED_12  0x0C
+#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_RESERVED_13  0x0D
+#define IPMI_CHANNEL_NUMBER_PRIMARY_PRESENT_IF          0x0E
+#define IPMI_CHANNEL_NUMBER_PRIMARY_SYSTEM_INTERFACE    0x0F
 #endif
diff --git a/MdePkg/Include/IndustryStandard/IpmiNetFnApp.h b/MdePkg/Include/IndustryStandard/IpmiNetFnApp.h
index 0721bc6b271..a5835ba08c0 100644
--- a/MdePkg/Include/IndustryStandard/IpmiNetFnApp.h
+++ b/MdePkg/Include/IndustryStandard/IpmiNetFnApp.h
@@ -12,6 +12,7 @@
   and Appendix H, Sub-function Assignments.
 
   Copyright (c) 1999 - 2018, Intel Corporation. All rights reserved.<BR>
+  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights reserved.<BR>
   SPDX-License-Identifier: BSD-2-Clause-Patent
 **/
 
@@ -486,6 +487,11 @@ typedef struct {
 //
 #define IPMI_APP_GET_SYSTEM_GUID  0x37
 
+typedef struct {
+  UINT8       CompletionCode;
+  EFI_GUID    SystemUuid;
+} IPMI_GET_SYSTEM_UUID_RESPONSE;
+
 //
 //  Constants and Structure definitions for "Get System GUID" command to follow here
 //
@@ -671,6 +677,30 @@ typedef struct {
 #define IPMI_CHANNEL_MEDIA_TYPE_OEM_START  0x60
 #define IPMI_CHANNEL_MEDIA_TYPE_OEM_END    0x7F
 
+//
+//  Definitions for channel protocol type
+//
+// Not available
+#define IPMI_CHANNEL_PROTOCOL_TYPE_NA  0x00
+// IPMB-1.0
+#define IPMI_CHANNEL_PROTOCOL_TYPE_IPMB_1_0  0x01
+// ICMB-1.0
+#define IPMI_CHANNEL_PROTOCOL_TYPE_ICMB_1_0  0x02
+// Reserved
+#define IPMI_CHANNEL_PROTOCOL_TYPE_RESERVED  0x03
+// IPMI SMBUS
+#define IPMI_CHANNEL_PROTOCOL_TYPE_IPMI_SMBUS  0x04
+// KCS
+#define IPMI_CHANNEL_PROTOCOL_TYPE_KCS  0x05
+// SMIC
+#define IPMI_CHANNEL_PROTOCOL_TYPE_SMIC  0x06
+// BT-10
+#define IPMI_CHANNEL_PROTOCOL_TYPE_BT_10  0x07
+// BT-15
+#define IPMI_CHANNEL_PROTOCOL_TYPE_BT_15  0x08
+// TMode
+#define IPMI_CHANNEL_PROTOCOL_TYPE_TMODE  0x09
+
 typedef union {
   struct {
     UINT8    ChannelNo : 4;
@@ -713,10 +743,9 @@ typedef struct {
   UINT16                               AuxChannelInfo;
 } IPMI_GET_CHANNEL_INFO_RESPONSE;
 
-//
-//  Definitions for Get Channel Info command
-//
-#define IPMI_APP_GET_CHANNEL_INFO  0x42
+typedef struct {
+  IPMI_CHANNEL_INFO_CHANNEL_NUMBER    ChannelNumber;
+} IPMI_GET_CHANNEL_INFO_REQUEST;
 
 //
 //  Constants and Structure definitions for "Get Channel Info" command to follow here
diff --git a/MdePkg/Include/IndustryStandard/IpmiNetFnTransport.h b/MdePkg/Include/IndustryStandard/IpmiNetFnTransport.h
index 19db84e5122..2024c35f7fa 100644
--- a/MdePkg/Include/IndustryStandard/IpmiNetFnTransport.h
+++ b/MdePkg/Include/IndustryStandard/IpmiNetFnTransport.h
@@ -11,6 +11,7 @@
   and Appendix H, Sub-function Assignments.
 
   Copyright (c) 1999 - 2018, Intel Corporation. All rights reserved.<BR>
+  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights reserved.<BR>
   SPDX-License-Identifier: BSD-2-Clause-Patent
 **/
 
@@ -60,6 +61,7 @@ typedef enum {
   IpmiLanReserved3,
   IpmiLanDestinationType,
   IpmiLanDestinationAddress,
+  IpmiLanVlanId         = 0x14,
   IpmiIpv4OrIpv6Support = 0x32,
   IpmiIpv4OrIpv6AddressEnable,
   IpmiIpv6HdrStatTrafficClass,
@@ -103,6 +105,14 @@ typedef enum {
   IpmiOem2
 } IPMI_LAN_DEST_TYPE_DEST_TYPE;
 
+//
+// Destination address format
+//
+typedef enum {
+  IpmiDestinationAddressVersion4,
+  IpmiDestinationAddressVersion6
+} IPMI_LAN_DEST_ADDRESS_VERSION;
+
 typedef union {
   struct {
     UINT8    NoAuth       : 1;
@@ -177,6 +187,10 @@ typedef struct {
   UINT8    ArpInterval;
 } IPMI_LAN_ARP_INTERVAL;
 
+typedef struct {
+  UINT8    IpAddress[4];
+} IPMI_LAN_DEFAULT_GATEWAY;
+
 typedef struct {
   UINT8    Data[18];
 } IPMI_LAN_COMMUNITY_STRING;
@@ -227,6 +241,24 @@ typedef struct {
   IPMI_LAN_MAC_ADDRESS         AlertingMacAddress;
 } IPMI_LAN_DEST_ADDRESS;
 
+typedef struct {
+  UINT8    VanIdLowByte;
+} IPMI_LAN_VLAN_ID_DATA1;
+
+typedef union {
+  struct {
+    UINT8    VanIdHighByte : 4;
+    UINT8    Reserved      : 3;
+    UINT8    Enabled       : 1;
+  } Bits;
+  UINT8    Uint8;
+} IPMI_LAN_VLAN_ID_DATA2;
+
+typedef struct {
+  IPMI_LAN_VLAN_ID_DATA1    Data1;
+  IPMI_LAN_VLAN_ID_DATA2    Data2;
+} IPMI_LAN_VLAN_ID;
+
 typedef union {
   IPMI_LAN_AUTH_TYPE                    IpmiLanAuthType;
   IPMI_LAN_IP_ADDRESS                   IpmiLanIpAddress;
-- 
2.37.1.windows.1


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

* [PATCH V4 2/3] RedfishPkg/Include: Add Redfish IPMI definitions
  2023-01-06  2:57 [PATCH V4 0/3] IPMI changes for Redfish Chang, Abner
  2023-01-06  2:57 ` [PATCH V4 1/3] MdePkg/IndustryStandard: Update IPMI definitions Chang, Abner
@ 2023-01-06  2:57 ` Chang, Abner
  2023-01-06  2:57 ` [PATCH V4 3/3] RedfishPkg/Include: Redfish USB Interface V2 update Chang, Abner
  2023-01-11 23:11 ` [PATCH V4 0/3] IPMI changes for Redfish Isaac Oram
  3 siblings, 0 replies; 10+ messages in thread
From: Chang, Abner @ 2023-01-06  2:57 UTC (permalink / raw)
  To: devel; +Cc: Abner Chang, Igor Kulchytskyy, Isaac Oram

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

Add the definitions of Redfish Host Interface
credential bootstrapping IPMI commands.

Signed-off-by: Nickle Wang <nicklew@nvidia.com>
Cc: Abner Chang <abner.chang@amd.com>
Cc: Igor Kulchytskyy <igork@ami.com>
Reviewed-by: Igor Kulchytskyy<igork@ami.com>
Reviewed-by: Isaac Oram <isaac.w.oram@intel.com>
---
 .../RedfishHostInterfaceIpmi.h                | 51 +++++++++++++++++++
 1 file changed, 51 insertions(+)
 create mode 100644 RedfishPkg/Include/IndustryStandard/RedfishHostInterfaceIpmi.h

diff --git a/RedfishPkg/Include/IndustryStandard/RedfishHostInterfaceIpmi.h b/RedfishPkg/Include/IndustryStandard/RedfishHostInterfaceIpmi.h
new file mode 100644
index 00000000000..9b4a5eb8e3f
--- /dev/null
+++ b/RedfishPkg/Include/IndustryStandard/RedfishHostInterfaceIpmi.h
@@ -0,0 +1,51 @@
+/** @file
+  Redfish Host Interface IPMI command
+
+  Copyright (c) 2023 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
+  SPDX-License-Identifier: BSD-2-Clause-Patent
+**/
+
+#ifndef REDFISH_HOST_INTERFACE_IPMI_H_
+#define REDFISH_HOST_INTERFACE_IPMI_H_
+
+#include <Uefi.h>
+#include <IndustryStandard/IpmiNetFnGroupExtension.h>
+
+#define REDFISH_IPMI_GROUP_EXTENSION                          0x52
+#define REDFISH_IPMI_GET_BOOTSTRAP_CREDENTIALS_CMD            0x02
+#define REDFISH_IPMI_BOOTSTRAP_CREDENTIAL_ENABLE              0xA5
+#define REDFISH_IPMI_BOOTSTRAP_CREDENTIAL_DISABLE             0x00
+#define REDFISH_IPMI_COMP_CODE_BOOTSTRAP_CREDENTIAL_DISABLED  0x80
+
+///
+/// Per Redfish Host Interface Specification 1.3, The maximum length of
+/// username and password is 16 characters long.
+//
+#define USERNAME_MAX_LENGTH  16
+#define PASSWORD_MAX_LENGTH  16
+#define USERNAME_MAX_SIZE    (USERNAME_MAX_LENGTH + 1)  // NULL terminator
+#define PASSWORD_MAX_SIZE    (PASSWORD_MAX_LENGTH + 1)  // NULL terminator
+
+#pragma pack(1)
+
+///
+/// The definition of IPMI command to get bootstrap account credentials
+///
+typedef struct {
+  UINT8    GroupExtensionId;
+  UINT8    DisableBootstrapControl;
+} IPMI_BOOTSTRAP_CREDENTIALS_COMMAND_DATA;
+
+///
+/// The response data of getting bootstrap credential
+///
+typedef struct {
+  UINT8    CompletionCode;
+  UINT8    GroupExtensionId;
+  CHAR8    Username[USERNAME_MAX_LENGTH];
+  CHAR8    Password[PASSWORD_MAX_LENGTH];
+} IPMI_BOOTSTRAP_CREDENTIALS_RESULT_RESPONSE;
+
+#pragma pack()
+
+#endif
-- 
2.37.1.windows.1


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

* [PATCH V4 3/3] RedfishPkg/Include: Redfish USB Interface V2 update
  2023-01-06  2:57 [PATCH V4 0/3] IPMI changes for Redfish Chang, Abner
  2023-01-06  2:57 ` [PATCH V4 1/3] MdePkg/IndustryStandard: Update IPMI definitions Chang, Abner
  2023-01-06  2:57 ` [PATCH V4 2/3] RedfishPkg/Include: Add Redfish " Chang, Abner
@ 2023-01-06  2:57 ` Chang, Abner
  2023-01-11 23:11 ` [PATCH V4 0/3] IPMI changes for Redfish Isaac Oram
  3 siblings, 0 replies; 10+ messages in thread
From: Chang, Abner @ 2023-01-06  2:57 UTC (permalink / raw)
  To: devel; +Cc: Nickle Wang, Igor Kulchytskyy

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

Support USB_INTERFACE_DEVICE_DESCRIPTOR_V2 which
is updated in Redfish Host Interface spec v1.3.

Signed-off-by: Abner Chang <abner.chang@amd.com>
Cc: Nickle Wang <nicklew@nvidia.com>
Cc: Igor Kulchytskyy <igork@ami.com>
Reviewed-by: Igor Kulchytskyy <igork@ami.com>
Reviewed-by: Nickle Wang <nicklew@nvidia.com>
---
 .../IndustryStandard/RedfishHostInterface.h   | 25 ++++++++++++++++++-
 1 file changed, 24 insertions(+), 1 deletion(-)

diff --git a/RedfishPkg/Include/IndustryStandard/RedfishHostInterface.h b/RedfishPkg/Include/IndustryStandard/RedfishHostInterface.h
index 49b3ceee39c..d125347cc04 100644
--- a/RedfishPkg/Include/IndustryStandard/RedfishHostInterface.h
+++ b/RedfishPkg/Include/IndustryStandard/RedfishHostInterface.h
@@ -3,6 +3,7 @@
 
   Copyright (c) 2019, Intel Corporation. All rights reserved.<BR>
   (C) Copyright 2020 Hewlett Packard Enterprise Development LP<BR>
+  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights reserved.<BR>
 
   SPDX-License-Identifier: BSD-2-Clause-Patent
 **/
@@ -29,6 +30,18 @@
 #define REDFISH_HOST_INTERFACE_HOST_IP_ADDRESS_FORMAT_IP4      0x01
 #define REDFISH_HOST_INTERFACE_HOST_IP_ADDRESS_FORMAT_IP6      0x02
 
+///
+/// Definitions for IP assignment tyeps.
+///
+typedef enum {
+  RedfishHostIpAssignmentUnknown,
+  RedfishHostIpAssignmentStatic,
+  RedfishHostIpAssignmentDhcp,
+  RedfishHostIpAssignmentAutoConfigure,
+  RedfishHostIpAssignmentHostSelected,
+  RedfishHostIpAssignmentReserved
+} REDFISH_HOST_IP_ASSIGNMENT;
+
 #pragma pack(1)
 ///
 /// Structure definitions of Host Interface device type 04h (USB Network Interface V2)
@@ -40,12 +53,18 @@ typedef struct {
                                            ///< idVendor field of the USB descriptor.
   UINT16    IdProduct;                     ///< The Product ID of the device, as read from the
                                            ///< idProduct field of the USB descriptor.
-  UINT8     SecialNumberStr;               ///< The string number for the Serial Number of the
+  UINT8     SerialNumberStr;               ///< The string number for the Serial Number of the
                                            ///< device. The string data is read from the
                                            ///< iSerialNumber.bDescriptorType field of the USB
                                            ///< descriptor, and is converted from Unicode to ASCII
                                            ///< and is NULL terminated.
   UINT8     MacAddress[6];                 ///< The MAC address of the PCI/PCIe network device.
+
+  ///
+  /// Below is defined in Redfish Host Interface spec v1.3
+  ///
+  UINT16    Characteristics;               ///< Additional device characteristics.
+  UINT16    CredentialBootstrappingHandle; ///< Credential bootstrapping handle.
 } USB_INTERFACE_DEVICE_DESCRIPTOR_V2;
 
 //
@@ -74,6 +93,10 @@ typedef struct {
 ///
 /// Define union for the Host Interface Device Descriptor
 ///
+#define USB_INTERFACE_DEVICE_DESCRIPTOR_V2_SIZE_1_3  0x11        ///< Length USB interface device v2 defined in
+                                                                 ///< Redfish host interface spec v1.3
+#define USB_INTERFACE_DEVICE_DESCRIPTOR_V2_SIZE_1_2  0x0d        ///< Length USB interface device v2 defined in
+                                                                 ///< Redfish host interface spec v1.2
 typedef union {
   USB_INTERFACE_DEVICE_DESCRIPTOR_V2            UsbDeviceV2;     ///< Device type USB V2 device discriptor.
   PCI_OR_PCIE_INTERFACE_DEVICE_DESCRIPTOR_V2    PciPcieDeviceV2; ///< Device type PCI/PCIe V2 device discriptor.
-- 
2.37.1.windows.1


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

* Re: [PATCH V4 0/3] IPMI changes for Redfish
  2023-01-06  2:57 [PATCH V4 0/3] IPMI changes for Redfish Chang, Abner
                   ` (2 preceding siblings ...)
  2023-01-06  2:57 ` [PATCH V4 3/3] RedfishPkg/Include: Redfish USB Interface V2 update Chang, Abner
@ 2023-01-11 23:11 ` Isaac Oram
  3 siblings, 0 replies; 10+ messages in thread
From: Isaac Oram @ 2023-01-11 23:11 UTC (permalink / raw)
  To: abner.chang@amd.com, devel@edk2.groups.io
  Cc: Kinney, Michael D, Gao, Liming, Liu, Zhiguang, Nickle Wang,
	Igor Kulchytskyy, Desimone, Nathaniel L

Series Reviewed-by: Isaac Oram <isaac.w.oram@intel.com>

-----Original Message-----
From: abner.chang@amd.com <abner.chang@amd.com> 
Sent: Thursday, January 5, 2023 6:58 PM
To: devel@edk2.groups.io
Cc: Kinney, Michael D <michael.d.kinney@intel.com>; Gao, Liming <gaoliming@byosoft.com.cn>; Liu, Zhiguang <zhiguang.liu@intel.com>; Nickle Wang <nicklew@nvidia.com>; Igor Kulchytskyy <igork@ami.com>; Oram, Isaac W <isaac.w.oram@intel.com>; Desimone, Nathaniel L <nathaniel.l.desimone@intel.com>
Subject: [PATCH V4 0/3] IPMI changes for Redfish

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

In V4: Updateed copyright to 2023
       Addressd the comment from Isaac on V3 2/3 In V3: Addressd the comments on V1 2/3 In V2: Addressd the comments on V1 3/3

This patch updates IPMI related definitions for supporting Redfish Host interface Credential bootstrapping spec and building up SMBIOS 42 record for the USB NIC host interface exposed by BMC.
The corresponding updates on IpmiFeaturePkg is in the separate pacth for edk2-platforms.

This is the part I of upstream, the follow up patche sets are:
- RedfishPlatformCredentialLib contributed by NVidia.
- Relocate IpmiCommandLib.h from edk2-platforms
  to edk2/MdePkg. A NULL instance of IpmiCommandLib is created
  and located under MdePkg. With above, RedfishPkg doesn't have the
  dependence with edk2-platforms. The implementation of IpmiCommandLib
  stays in edk2-platforms without relocation, which can be pulled in
  to platform DSC as needed.
- PlatformHostInterfaceBmcUsbNic would be upstream to edk2-staging
  temporarily because some requirements are necessray to be spec out
  in the Redfish section in UEFI spec.

Signed-off-by: Abner Chang <abner.chang@amd.com>
Cc: Michael D Kinney <michael.d.kinney@intel.com>
Cc: Liming Gao <gaoliming@byosoft.com.cn>
Cc: Zhiguang Liu <zhiguang.liu@intel.com>
Cc: Nickle Wang <nicklew@nvidia.com>
Cc: Igor Kulchytskyy <igork@ami.com>
Cc: Isaac Oram <isaac.w.oram@intel.com>
Cc: Nate DeSimone <nathaniel.l.desimone@intel.com> Abner Chang (3):
  MdePkg/IndustryStandard: Update IPMI definitions
  RedfishPkg/Include: Add Redfish IPMI definitions
  RedfishPkg/Include: Redfish USB Interface V2 update

 MdePkg/Include/IndustryStandard/Ipmi.h        | 17 +++++++
 .../Include/IndustryStandard/IpmiNetFnApp.h   | 37 ++++++++++++--
 .../IndustryStandard/IpmiNetFnTransport.h     | 32 ++++++++++++
 .../IndustryStandard/RedfishHostInterface.h   | 25 ++++++++-
 .../RedfishHostInterfaceIpmi.h                | 51 +++++++++++++++++++
 5 files changed, 157 insertions(+), 5 deletions(-)  create mode 100644 RedfishPkg/Include/IndustryStandard/RedfishHostInterfaceIpmi.h

--
2.37.1.windows.1


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

* 回复: [edk2-devel] [PATCH V4 1/3] MdePkg/IndustryStandard: Update IPMI definitions
  2023-01-06  2:57 ` [PATCH V4 1/3] MdePkg/IndustryStandard: Update IPMI definitions Chang, Abner
@ 2023-01-18  5:13   ` gaoliming
  2023-01-18  6:06     ` Chang, Abner
  0 siblings, 1 reply; 10+ messages in thread
From: gaoliming @ 2023-01-18  5:13 UTC (permalink / raw)
  To: devel, abner.chang
  Cc: 'Michael D Kinney', 'Zhiguang Liu',
	'Nickle Wang', 'Igor Kulchytskyy',
	'Isaac Oram', 'Nate DeSimone'

Abner:
  I see IPMI_APP_GET_CHANNEL_INFO definition is remove in this patch. Can
you help explain it in detail?

Thanks
Liming
> -----邮件原件-----
> 发件人: devel@edk2.groups.io <devel@edk2.groups.io> 代表 Chang, Abner
> via groups.io
> 发送时间: 2023年1月6日 10:58
> 收件人: devel@edk2.groups.io
> 抄送: Michael D Kinney <michael.d.kinney@intel.com>; Liming Gao
> <gaoliming@byosoft.com.cn>; Zhiguang Liu <zhiguang.liu@intel.com>; Nickle
> Wang <nicklew@nvidia.com>; Igor Kulchytskyy <igork@ami.com>; Isaac
> Oram <isaac.w.oram@intel.com>; Nate DeSimone
> <nathaniel.l.desimone@intel.com>
> 主题: [edk2-devel] [PATCH V4 1/3] MdePkg/IndustryStandard: Update IPMI
> definitions
> 
> From: Abner Chang <abner.chang@amd.com>
> 
> This change updates IPMI header files to support
> build up SMBIOS 42 Redfish Host Interface record
> using the information retrieved via IPMI App/Net
> Function.
> 
> Signed-off-by: Abner Chang <abner.chang@amd.com>
> Cc: Michael D Kinney <michael.d.kinney@intel.com>
> Cc: Liming Gao <gaoliming@byosoft.com.cn>
> Cc: Zhiguang Liu <zhiguang.liu@intel.com>
> Cc: Nickle Wang <nicklew@nvidia.com>
> Cc: Igor Kulchytskyy <igork@ami.com>
> Cc: Isaac Oram <isaac.w.oram@intel.com>
> Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
> ---
>  MdePkg/Include/IndustryStandard/Ipmi.h        | 17 +++++++++
>  .../Include/IndustryStandard/IpmiNetFnApp.h   | 37
> +++++++++++++++++--
>  .../IndustryStandard/IpmiNetFnTransport.h     | 32 ++++++++++++++++
>  3 files changed, 82 insertions(+), 4 deletions(-)
> 
> diff --git a/MdePkg/Include/IndustryStandard/Ipmi.h
> b/MdePkg/Include/IndustryStandard/Ipmi.h
> index 9d1d412b53e..d6e7436b5ae 100644
> --- a/MdePkg/Include/IndustryStandard/Ipmi.h
> +++ b/MdePkg/Include/IndustryStandard/Ipmi.h
> @@ -6,6 +6,7 @@
>    and Appendix H, Sub-function Assignments.
> 
>    Copyright (c) 1999 - 2018, Intel Corporation. All rights reserved.<BR>
> +  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights
reserved.<BR>
>    SPDX-License-Identifier: BSD-2-Clause-Patent
>  **/
> 
> @@ -52,4 +53,20 @@
>  #define IPMI_COMP_CODE_SUBFUNCTION_DISABLED             0xD6
>  #define IPMI_COMP_CODE_UNSPECIFIED                      0xFF
> 
> +#define IPMI_CHANNEL_NUMBER_PRIMARY_IPMB
> 0x00
> +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_1   0x01
> +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_2   0x02
> +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_3   0x03
> +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_4   0x04
> +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_5   0x05
> +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_6   0x06
> +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_7   0x07
> +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_8   0x08
> +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_9   0x09
> +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_10  0x0A
> +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_11  0x0B
> +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_RESERVED_12
> 0x0C
> +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_RESERVED_13
> 0x0D
> +#define IPMI_CHANNEL_NUMBER_PRIMARY_PRESENT_IF          0x0E
> +#define IPMI_CHANNEL_NUMBER_PRIMARY_SYSTEM_INTERFACE
> 0x0F
>  #endif
> diff --git a/MdePkg/Include/IndustryStandard/IpmiNetFnApp.h
> b/MdePkg/Include/IndustryStandard/IpmiNetFnApp.h
> index 0721bc6b271..a5835ba08c0 100644
> --- a/MdePkg/Include/IndustryStandard/IpmiNetFnApp.h
> +++ b/MdePkg/Include/IndustryStandard/IpmiNetFnApp.h
> @@ -12,6 +12,7 @@
>    and Appendix H, Sub-function Assignments.
> 
>    Copyright (c) 1999 - 2018, Intel Corporation. All rights reserved.<BR>
> +  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights
reserved.<BR>
>    SPDX-License-Identifier: BSD-2-Clause-Patent
>  **/
> 
> @@ -486,6 +487,11 @@ typedef struct {
>  //
>  #define IPMI_APP_GET_SYSTEM_GUID  0x37
> 
> +typedef struct {
> +  UINT8       CompletionCode;
> +  EFI_GUID    SystemUuid;
> +} IPMI_GET_SYSTEM_UUID_RESPONSE;
> +
>  //
>  //  Constants and Structure definitions for "Get System GUID" command to
> follow here
>  //
> @@ -671,6 +677,30 @@ typedef struct {
>  #define IPMI_CHANNEL_MEDIA_TYPE_OEM_START  0x60
>  #define IPMI_CHANNEL_MEDIA_TYPE_OEM_END    0x7F
> 
> +//
> +//  Definitions for channel protocol type
> +//
> +// Not available
> +#define IPMI_CHANNEL_PROTOCOL_TYPE_NA  0x00
> +// IPMB-1.0
> +#define IPMI_CHANNEL_PROTOCOL_TYPE_IPMB_1_0  0x01
> +// ICMB-1.0
> +#define IPMI_CHANNEL_PROTOCOL_TYPE_ICMB_1_0  0x02
> +// Reserved
> +#define IPMI_CHANNEL_PROTOCOL_TYPE_RESERVED  0x03
> +// IPMI SMBUS
> +#define IPMI_CHANNEL_PROTOCOL_TYPE_IPMI_SMBUS  0x04
> +// KCS
> +#define IPMI_CHANNEL_PROTOCOL_TYPE_KCS  0x05
> +// SMIC
> +#define IPMI_CHANNEL_PROTOCOL_TYPE_SMIC  0x06
> +// BT-10
> +#define IPMI_CHANNEL_PROTOCOL_TYPE_BT_10  0x07
> +// BT-15
> +#define IPMI_CHANNEL_PROTOCOL_TYPE_BT_15  0x08
> +// TMode
> +#define IPMI_CHANNEL_PROTOCOL_TYPE_TMODE  0x09
> +
>  typedef union {
>    struct {
>      UINT8    ChannelNo : 4;
> @@ -713,10 +743,9 @@ typedef struct {
>    UINT16                               AuxChannelInfo;
>  } IPMI_GET_CHANNEL_INFO_RESPONSE;
> 
> -//
> -//  Definitions for Get Channel Info command
> -//
> -#define IPMI_APP_GET_CHANNEL_INFO  0x42
> +typedef struct {
> +  IPMI_CHANNEL_INFO_CHANNEL_NUMBER    ChannelNumber;
> +} IPMI_GET_CHANNEL_INFO_REQUEST;
> 
>  //
>  //  Constants and Structure definitions for "Get Channel Info" command to
> follow here
> diff --git a/MdePkg/Include/IndustryStandard/IpmiNetFnTransport.h
> b/MdePkg/Include/IndustryStandard/IpmiNetFnTransport.h
> index 19db84e5122..2024c35f7fa 100644
> --- a/MdePkg/Include/IndustryStandard/IpmiNetFnTransport.h
> +++ b/MdePkg/Include/IndustryStandard/IpmiNetFnTransport.h
> @@ -11,6 +11,7 @@
>    and Appendix H, Sub-function Assignments.
> 
>    Copyright (c) 1999 - 2018, Intel Corporation. All rights reserved.<BR>
> +  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights
reserved.<BR>
>    SPDX-License-Identifier: BSD-2-Clause-Patent
>  **/
> 
> @@ -60,6 +61,7 @@ typedef enum {
>    IpmiLanReserved3,
>    IpmiLanDestinationType,
>    IpmiLanDestinationAddress,
> +  IpmiLanVlanId         = 0x14,
>    IpmiIpv4OrIpv6Support = 0x32,
>    IpmiIpv4OrIpv6AddressEnable,
>    IpmiIpv6HdrStatTrafficClass,
> @@ -103,6 +105,14 @@ typedef enum {
>    IpmiOem2
>  } IPMI_LAN_DEST_TYPE_DEST_TYPE;
> 
> +//
> +// Destination address format
> +//
> +typedef enum {
> +  IpmiDestinationAddressVersion4,
> +  IpmiDestinationAddressVersion6
> +} IPMI_LAN_DEST_ADDRESS_VERSION;
> +
>  typedef union {
>    struct {
>      UINT8    NoAuth       : 1;
> @@ -177,6 +187,10 @@ typedef struct {
>    UINT8    ArpInterval;
>  } IPMI_LAN_ARP_INTERVAL;
> 
> +typedef struct {
> +  UINT8    IpAddress[4];
> +} IPMI_LAN_DEFAULT_GATEWAY;
> +
>  typedef struct {
>    UINT8    Data[18];
>  } IPMI_LAN_COMMUNITY_STRING;
> @@ -227,6 +241,24 @@ typedef struct {
>    IPMI_LAN_MAC_ADDRESS         AlertingMacAddress;
>  } IPMI_LAN_DEST_ADDRESS;
> 
> +typedef struct {
> +  UINT8    VanIdLowByte;
> +} IPMI_LAN_VLAN_ID_DATA1;
> +
> +typedef union {
> +  struct {
> +    UINT8    VanIdHighByte : 4;
> +    UINT8    Reserved      : 3;
> +    UINT8    Enabled       : 1;
> +  } Bits;
> +  UINT8    Uint8;
> +} IPMI_LAN_VLAN_ID_DATA2;
> +
> +typedef struct {
> +  IPMI_LAN_VLAN_ID_DATA1    Data1;
> +  IPMI_LAN_VLAN_ID_DATA2    Data2;
> +} IPMI_LAN_VLAN_ID;
> +
>  typedef union {
>    IPMI_LAN_AUTH_TYPE                    IpmiLanAuthType;
>    IPMI_LAN_IP_ADDRESS                   IpmiLanIpAddress;
> --
> 2.37.1.windows.1
> 
> 
> 
> 
> 




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

* Re: [edk2-devel] [PATCH V4 1/3] MdePkg/IndustryStandard: Update IPMI definitions
  2023-01-18  5:13   ` 回复: [edk2-devel] " gaoliming
@ 2023-01-18  6:06     ` Chang, Abner
  2023-01-19  1:07       ` 回复: " gaoliming
  0 siblings, 1 reply; 10+ messages in thread
From: Chang, Abner @ 2023-01-18  6:06 UTC (permalink / raw)
  To: gaoliming, devel@edk2.groups.io
  Cc: 'Michael D Kinney', 'Zhiguang Liu',
	'Nickle Wang', 'Igor Kulchytskyy',
	'Isaac Oram', 'Nate DeSimone'

[AMD Official Use Only - General]

This is the duplicate one, there is another above.

Btw Liming, please let me push these two patch sets after you giving Reviewed-by to this one. I will have to rebase them before merging the change.
Thanks
Abner

> -----Original Message-----
> From: gaoliming <gaoliming@byosoft.com.cn>
> Sent: Wednesday, January 18, 2023 1:13 PM
> To: devel@edk2.groups.io; Chang, Abner <Abner.Chang@amd.com>
> Cc: 'Michael D Kinney' <michael.d.kinney@intel.com>; 'Zhiguang Liu'
> <zhiguang.liu@intel.com>; 'Nickle Wang' <nicklew@nvidia.com>; 'Igor
> Kulchytskyy' <igork@ami.com>; 'Isaac Oram' <isaac.w.oram@intel.com>;
> 'Nate DeSimone' <nathaniel.l.desimone@intel.com>
> Subject: 回复: [edk2-devel] [PATCH V4 1/3] MdePkg/IndustryStandard:
> Update IPMI definitions
> 
> Caution: This message originated from an External Source. Use proper
> caution when opening attachments, clicking links, or responding.
> 
> 
> Abner:
>   I see IPMI_APP_GET_CHANNEL_INFO definition is remove in this patch. Can
> you help explain it in detail?
> 
> Thanks
> Liming
> > -----邮件原件-----
> > 发件人: devel@edk2.groups.io <devel@edk2.groups.io> 代表 Chang,
> Abner via
> > groups.io
> > 发送时间: 2023年1月6日 10:58
> > 收件人: devel@edk2.groups.io
> > 抄送: Michael D Kinney <michael.d.kinney@intel.com>; Liming Gao
> > <gaoliming@byosoft.com.cn>; Zhiguang Liu <zhiguang.liu@intel.com>;
> > Nickle Wang <nicklew@nvidia.com>; Igor Kulchytskyy <igork@ami.com>;
> > Isaac Oram <isaac.w.oram@intel.com>; Nate DeSimone
> > <nathaniel.l.desimone@intel.com>
> > 主题: [edk2-devel] [PATCH V4 1/3] MdePkg/IndustryStandard: Update
> IPMI
> > definitions
> >
> > From: Abner Chang <abner.chang@amd.com>
> >
> > This change updates IPMI header files to support build up SMBIOS 42
> > Redfish Host Interface record using the information retrieved via IPMI
> > App/Net Function.
> >
> > Signed-off-by: Abner Chang <abner.chang@amd.com>
> > Cc: Michael D Kinney <michael.d.kinney@intel.com>
> > Cc: Liming Gao <gaoliming@byosoft.com.cn>
> > Cc: Zhiguang Liu <zhiguang.liu@intel.com>
> > Cc: Nickle Wang <nicklew@nvidia.com>
> > Cc: Igor Kulchytskyy <igork@ami.com>
> > Cc: Isaac Oram <isaac.w.oram@intel.com>
> > Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
> > ---
> >  MdePkg/Include/IndustryStandard/Ipmi.h        | 17 +++++++++
> >  .../Include/IndustryStandard/IpmiNetFnApp.h   | 37
> > +++++++++++++++++--
> >  .../IndustryStandard/IpmiNetFnTransport.h     | 32 ++++++++++++++++
> >  3 files changed, 82 insertions(+), 4 deletions(-)
> >
> > diff --git a/MdePkg/Include/IndustryStandard/Ipmi.h
> > b/MdePkg/Include/IndustryStandard/Ipmi.h
> > index 9d1d412b53e..d6e7436b5ae 100644
> > --- a/MdePkg/Include/IndustryStandard/Ipmi.h
> > +++ b/MdePkg/Include/IndustryStandard/Ipmi.h
> > @@ -6,6 +6,7 @@
> >    and Appendix H, Sub-function Assignments.
> >
> >    Copyright (c) 1999 - 2018, Intel Corporation. All rights
> > reserved.<BR>
> > +  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights
> reserved.<BR>
> >    SPDX-License-Identifier: BSD-2-Clause-Patent  **/
> >
> > @@ -52,4 +53,20 @@
> >  #define IPMI_COMP_CODE_SUBFUNCTION_DISABLED             0xD6
> >  #define IPMI_COMP_CODE_UNSPECIFIED                      0xFF
> >
> > +#define IPMI_CHANNEL_NUMBER_PRIMARY_IPMB
> > 0x00
> > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_1   0x01
> > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_2   0x02
> > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_3   0x03
> > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_4   0x04
> > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_5   0x05
> > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_6   0x06
> > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_7   0x07
> > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_8   0x08
> > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_9   0x09
> > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_10
> 0x0A #define
> > +IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_11  0x0B
> #define
> > +IPMI_CHANNEL_NUMBER_IMPLEMENTATION_RESERVED_12
> > 0x0C
> > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_RESERVED_13
> > 0x0D
> > +#define IPMI_CHANNEL_NUMBER_PRIMARY_PRESENT_IF          0x0E
> > +#define IPMI_CHANNEL_NUMBER_PRIMARY_SYSTEM_INTERFACE
> > 0x0F
> >  #endif
> > diff --git a/MdePkg/Include/IndustryStandard/IpmiNetFnApp.h
> > b/MdePkg/Include/IndustryStandard/IpmiNetFnApp.h
> > index 0721bc6b271..a5835ba08c0 100644
> > --- a/MdePkg/Include/IndustryStandard/IpmiNetFnApp.h
> > +++ b/MdePkg/Include/IndustryStandard/IpmiNetFnApp.h
> > @@ -12,6 +12,7 @@
> >    and Appendix H, Sub-function Assignments.
> >
> >    Copyright (c) 1999 - 2018, Intel Corporation. All rights
> > reserved.<BR>
> > +  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights
> reserved.<BR>
> >    SPDX-License-Identifier: BSD-2-Clause-Patent  **/
> >
> > @@ -486,6 +487,11 @@ typedef struct {
> >  //
> >  #define IPMI_APP_GET_SYSTEM_GUID  0x37
> >
> > +typedef struct {
> > +  UINT8       CompletionCode;
> > +  EFI_GUID    SystemUuid;
> > +} IPMI_GET_SYSTEM_UUID_RESPONSE;
> > +
> >  //
> >  //  Constants and Structure definitions for "Get System GUID" command
> > to follow here  // @@ -671,6 +677,30 @@ typedef struct {  #define
> > IPMI_CHANNEL_MEDIA_TYPE_OEM_START  0x60
> >  #define IPMI_CHANNEL_MEDIA_TYPE_OEM_END    0x7F
> >
> > +//
> > +//  Definitions for channel protocol type // // Not available #define
> > +IPMI_CHANNEL_PROTOCOL_TYPE_NA  0x00 // IPMB-1.0 #define
> > +IPMI_CHANNEL_PROTOCOL_TYPE_IPMB_1_0  0x01 // ICMB-1.0 #define
> > +IPMI_CHANNEL_PROTOCOL_TYPE_ICMB_1_0  0x02 // Reserved #define
> > +IPMI_CHANNEL_PROTOCOL_TYPE_RESERVED  0x03 // IPMI SMBUS
> #define
> > +IPMI_CHANNEL_PROTOCOL_TYPE_IPMI_SMBUS  0x04 // KCS #define
> > +IPMI_CHANNEL_PROTOCOL_TYPE_KCS  0x05 // SMIC #define
> > +IPMI_CHANNEL_PROTOCOL_TYPE_SMIC  0x06 // BT-10 #define
> > +IPMI_CHANNEL_PROTOCOL_TYPE_BT_10  0x07 // BT-15 #define
> > +IPMI_CHANNEL_PROTOCOL_TYPE_BT_15  0x08 // TMode #define
> > +IPMI_CHANNEL_PROTOCOL_TYPE_TMODE  0x09
> > +
> >  typedef union {
> >    struct {
> >      UINT8    ChannelNo : 4;
> > @@ -713,10 +743,9 @@ typedef struct {
> >    UINT16                               AuxChannelInfo;
> >  } IPMI_GET_CHANNEL_INFO_RESPONSE;
> >
> > -//
> > -//  Definitions for Get Channel Info command -// -#define
> > IPMI_APP_GET_CHANNEL_INFO  0x42
> > +typedef struct {
> > +  IPMI_CHANNEL_INFO_CHANNEL_NUMBER    ChannelNumber;
> > +} IPMI_GET_CHANNEL_INFO_REQUEST;
> >
> >  //
> >  //  Constants and Structure definitions for "Get Channel Info"
> > command to follow here diff --git
> > a/MdePkg/Include/IndustryStandard/IpmiNetFnTransport.h
> > b/MdePkg/Include/IndustryStandard/IpmiNetFnTransport.h
> > index 19db84e5122..2024c35f7fa 100644
> > --- a/MdePkg/Include/IndustryStandard/IpmiNetFnTransport.h
> > +++ b/MdePkg/Include/IndustryStandard/IpmiNetFnTransport.h
> > @@ -11,6 +11,7 @@
> >    and Appendix H, Sub-function Assignments.
> >
> >    Copyright (c) 1999 - 2018, Intel Corporation. All rights
> > reserved.<BR>
> > +  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights
> reserved.<BR>
> >    SPDX-License-Identifier: BSD-2-Clause-Patent  **/
> >
> > @@ -60,6 +61,7 @@ typedef enum {
> >    IpmiLanReserved3,
> >    IpmiLanDestinationType,
> >    IpmiLanDestinationAddress,
> > +  IpmiLanVlanId         = 0x14,
> >    IpmiIpv4OrIpv6Support = 0x32,
> >    IpmiIpv4OrIpv6AddressEnable,
> >    IpmiIpv6HdrStatTrafficClass,
> > @@ -103,6 +105,14 @@ typedef enum {
> >    IpmiOem2
> >  } IPMI_LAN_DEST_TYPE_DEST_TYPE;
> >
> > +//
> > +// Destination address format
> > +//
> > +typedef enum {
> > +  IpmiDestinationAddressVersion4,
> > +  IpmiDestinationAddressVersion6
> > +} IPMI_LAN_DEST_ADDRESS_VERSION;
> > +
> >  typedef union {
> >    struct {
> >      UINT8    NoAuth       : 1;
> > @@ -177,6 +187,10 @@ typedef struct {
> >    UINT8    ArpInterval;
> >  } IPMI_LAN_ARP_INTERVAL;
> >
> > +typedef struct {
> > +  UINT8    IpAddress[4];
> > +} IPMI_LAN_DEFAULT_GATEWAY;
> > +
> >  typedef struct {
> >    UINT8    Data[18];
> >  } IPMI_LAN_COMMUNITY_STRING;
> > @@ -227,6 +241,24 @@ typedef struct {
> >    IPMI_LAN_MAC_ADDRESS         AlertingMacAddress;
> >  } IPMI_LAN_DEST_ADDRESS;
> >
> > +typedef struct {
> > +  UINT8    VanIdLowByte;
> > +} IPMI_LAN_VLAN_ID_DATA1;
> > +
> > +typedef union {
> > +  struct {
> > +    UINT8    VanIdHighByte : 4;
> > +    UINT8    Reserved      : 3;
> > +    UINT8    Enabled       : 1;
> > +  } Bits;
> > +  UINT8    Uint8;
> > +} IPMI_LAN_VLAN_ID_DATA2;
> > +
> > +typedef struct {
> > +  IPMI_LAN_VLAN_ID_DATA1    Data1;
> > +  IPMI_LAN_VLAN_ID_DATA2    Data2;
> > +} IPMI_LAN_VLAN_ID;
> > +
> >  typedef union {
> >    IPMI_LAN_AUTH_TYPE                    IpmiLanAuthType;
> >    IPMI_LAN_IP_ADDRESS                   IpmiLanIpAddress;
> > --
> > 2.37.1.windows.1
> >
> >
> >
> > 
> >
> 
> 

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

* 回复: [edk2-devel] [PATCH V4 1/3] MdePkg/IndustryStandard: Update IPMI definitions
  2023-01-18  6:06     ` Chang, Abner
@ 2023-01-19  1:07       ` gaoliming
  2023-01-19  1:15         ` Chang, Abner
  2023-01-19  3:31         ` Chang, Abner
  0 siblings, 2 replies; 10+ messages in thread
From: gaoliming @ 2023-01-19  1:07 UTC (permalink / raw)
  To: devel, abner.chang
  Cc: 'Michael D Kinney', 'Zhiguang Liu',
	'Nickle Wang', 'Igor Kulchytskyy',
	'Isaac Oram', 'Nate DeSimone'

Abner:
  Thanks for your confirmation. I suggest you mention this change in the commit message. 

  Reviewed-by: Liming Gao <gaoliming@byosoft.com.cn>

Thanks
Liming
> -----邮件原件-----
> 发件人: devel@edk2.groups.io <devel@edk2.groups.io> 代表 Chang, Abner
> via groups.io
> 发送时间: 2023年1月18日 14:06
> 收件人: gaoliming <gaoliming@byosoft.com.cn>; devel@edk2.groups.io
> 抄送: 'Michael D Kinney' <michael.d.kinney@intel.com>; 'Zhiguang Liu'
> <zhiguang.liu@intel.com>; 'Nickle Wang' <nicklew@nvidia.com>; 'Igor
> Kulchytskyy' <igork@ami.com>; 'Isaac Oram' <isaac.w.oram@intel.com>;
> 'Nate DeSimone' <nathaniel.l.desimone@intel.com>
> 主题: Re: [edk2-devel] [PATCH V4 1/3] MdePkg/IndustryStandard: Update
> IPMI definitions
> 
> [AMD Official Use Only - General]
> 
> This is the duplicate one, there is another above.
> 
> Btw Liming, please let me push these two patch sets after you giving
> Reviewed-by to this one. I will have to rebase them before merging the
> change.
> Thanks
> Abner
> 
> > -----Original Message-----
> > From: gaoliming <gaoliming@byosoft.com.cn>
> > Sent: Wednesday, January 18, 2023 1:13 PM
> > To: devel@edk2.groups.io; Chang, Abner <Abner.Chang@amd.com>
> > Cc: 'Michael D Kinney' <michael.d.kinney@intel.com>; 'Zhiguang Liu'
> > <zhiguang.liu@intel.com>; 'Nickle Wang' <nicklew@nvidia.com>; 'Igor
> > Kulchytskyy' <igork@ami.com>; 'Isaac Oram' <isaac.w.oram@intel.com>;
> > 'Nate DeSimone' <nathaniel.l.desimone@intel.com>
> > Subject: 回复: [edk2-devel] [PATCH V4 1/3] MdePkg/IndustryStandard:
> > Update IPMI definitions
> >
> > Caution: This message originated from an External Source. Use proper
> > caution when opening attachments, clicking links, or responding.
> >
> >
> > Abner:
> >   I see IPMI_APP_GET_CHANNEL_INFO definition is remove in this patch.
> Can
> > you help explain it in detail?
> >
> > Thanks
> > Liming
> > > -----邮件原件-----
> > > 发件人: devel@edk2.groups.io <devel@edk2.groups.io> 代表 Chang,
> > Abner via
> > > groups.io
> > > 发送时间: 2023年1月6日 10:58
> > > 收件人: devel@edk2.groups.io
> > > 抄送: Michael D Kinney <michael.d.kinney@intel.com>; Liming Gao
> > > <gaoliming@byosoft.com.cn>; Zhiguang Liu <zhiguang.liu@intel.com>;
> > > Nickle Wang <nicklew@nvidia.com>; Igor Kulchytskyy <igork@ami.com>;
> > > Isaac Oram <isaac.w.oram@intel.com>; Nate DeSimone
> > > <nathaniel.l.desimone@intel.com>
> > > 主题: [edk2-devel] [PATCH V4 1/3] MdePkg/IndustryStandard: Update
> > IPMI
> > > definitions
> > >
> > > From: Abner Chang <abner.chang@amd.com>
> > >
> > > This change updates IPMI header files to support build up SMBIOS 42
> > > Redfish Host Interface record using the information retrieved via IPMI
> > > App/Net Function.
> > >
> > > Signed-off-by: Abner Chang <abner.chang@amd.com>
> > > Cc: Michael D Kinney <michael.d.kinney@intel.com>
> > > Cc: Liming Gao <gaoliming@byosoft.com.cn>
> > > Cc: Zhiguang Liu <zhiguang.liu@intel.com>
> > > Cc: Nickle Wang <nicklew@nvidia.com>
> > > Cc: Igor Kulchytskyy <igork@ami.com>
> > > Cc: Isaac Oram <isaac.w.oram@intel.com>
> > > Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
> > > ---
> > >  MdePkg/Include/IndustryStandard/Ipmi.h        | 17 +++++++++
> > >  .../Include/IndustryStandard/IpmiNetFnApp.h   | 37
> > > +++++++++++++++++--
> > >  .../IndustryStandard/IpmiNetFnTransport.h     | 32
> ++++++++++++++++
> > >  3 files changed, 82 insertions(+), 4 deletions(-)
> > >
> > > diff --git a/MdePkg/Include/IndustryStandard/Ipmi.h
> > > b/MdePkg/Include/IndustryStandard/Ipmi.h
> > > index 9d1d412b53e..d6e7436b5ae 100644
> > > --- a/MdePkg/Include/IndustryStandard/Ipmi.h
> > > +++ b/MdePkg/Include/IndustryStandard/Ipmi.h
> > > @@ -6,6 +6,7 @@
> > >    and Appendix H, Sub-function Assignments.
> > >
> > >    Copyright (c) 1999 - 2018, Intel Corporation. All rights
> > > reserved.<BR>
> > > +  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights
> > reserved.<BR>
> > >    SPDX-License-Identifier: BSD-2-Clause-Patent  **/
> > >
> > > @@ -52,4 +53,20 @@
> > >  #define IPMI_COMP_CODE_SUBFUNCTION_DISABLED
> 0xD6
> > >  #define IPMI_COMP_CODE_UNSPECIFIED
> 0xFF
> > >
> > > +#define IPMI_CHANNEL_NUMBER_PRIMARY_IPMB
> > > 0x00
> > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_1
> 0x01
> > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_2
> 0x02
> > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_3
> 0x03
> > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_4
> 0x04
> > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_5
> 0x05
> > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_6
> 0x06
> > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_7
> 0x07
> > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_8
> 0x08
> > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_9
> 0x09
> > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_10
> > 0x0A #define
> > > +IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_11  0x0B
> > #define
> > > +IPMI_CHANNEL_NUMBER_IMPLEMENTATION_RESERVED_12
> > > 0x0C
> > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_RESERVED_13
> > > 0x0D
> > > +#define IPMI_CHANNEL_NUMBER_PRIMARY_PRESENT_IF
> 0x0E
> > > +#define IPMI_CHANNEL_NUMBER_PRIMARY_SYSTEM_INTERFACE
> > > 0x0F
> > >  #endif
> > > diff --git a/MdePkg/Include/IndustryStandard/IpmiNetFnApp.h
> > > b/MdePkg/Include/IndustryStandard/IpmiNetFnApp.h
> > > index 0721bc6b271..a5835ba08c0 100644
> > > --- a/MdePkg/Include/IndustryStandard/IpmiNetFnApp.h
> > > +++ b/MdePkg/Include/IndustryStandard/IpmiNetFnApp.h
> > > @@ -12,6 +12,7 @@
> > >    and Appendix H, Sub-function Assignments.
> > >
> > >    Copyright (c) 1999 - 2018, Intel Corporation. All rights
> > > reserved.<BR>
> > > +  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights
> > reserved.<BR>
> > >    SPDX-License-Identifier: BSD-2-Clause-Patent  **/
> > >
> > > @@ -486,6 +487,11 @@ typedef struct {
> > >  //
> > >  #define IPMI_APP_GET_SYSTEM_GUID  0x37
> > >
> > > +typedef struct {
> > > +  UINT8       CompletionCode;
> > > +  EFI_GUID    SystemUuid;
> > > +} IPMI_GET_SYSTEM_UUID_RESPONSE;
> > > +
> > >  //
> > >  //  Constants and Structure definitions for "Get System GUID"
> command
> > > to follow here  // @@ -671,6 +677,30 @@ typedef struct {  #define
> > > IPMI_CHANNEL_MEDIA_TYPE_OEM_START  0x60
> > >  #define IPMI_CHANNEL_MEDIA_TYPE_OEM_END    0x7F
> > >
> > > +//
> > > +//  Definitions for channel protocol type // // Not available #define
> > > +IPMI_CHANNEL_PROTOCOL_TYPE_NA  0x00 // IPMB-1.0 #define
> > > +IPMI_CHANNEL_PROTOCOL_TYPE_IPMB_1_0  0x01 // ICMB-1.0
> #define
> > > +IPMI_CHANNEL_PROTOCOL_TYPE_ICMB_1_0  0x02 // Reserved
> #define
> > > +IPMI_CHANNEL_PROTOCOL_TYPE_RESERVED  0x03 // IPMI SMBUS
> > #define
> > > +IPMI_CHANNEL_PROTOCOL_TYPE_IPMI_SMBUS  0x04 // KCS #define
> > > +IPMI_CHANNEL_PROTOCOL_TYPE_KCS  0x05 // SMIC #define
> > > +IPMI_CHANNEL_PROTOCOL_TYPE_SMIC  0x06 // BT-10 #define
> > > +IPMI_CHANNEL_PROTOCOL_TYPE_BT_10  0x07 // BT-15 #define
> > > +IPMI_CHANNEL_PROTOCOL_TYPE_BT_15  0x08 // TMode #define
> > > +IPMI_CHANNEL_PROTOCOL_TYPE_TMODE  0x09
> > > +
> > >  typedef union {
> > >    struct {
> > >      UINT8    ChannelNo : 4;
> > > @@ -713,10 +743,9 @@ typedef struct {
> > >    UINT16                               AuxChannelInfo;
> > >  } IPMI_GET_CHANNEL_INFO_RESPONSE;
> > >
> > > -//
> > > -//  Definitions for Get Channel Info command -// -#define
> > > IPMI_APP_GET_CHANNEL_INFO  0x42
> > > +typedef struct {
> > > +  IPMI_CHANNEL_INFO_CHANNEL_NUMBER    ChannelNumber;
> > > +} IPMI_GET_CHANNEL_INFO_REQUEST;
> > >
> > >  //
> > >  //  Constants and Structure definitions for "Get Channel Info"
> > > command to follow here diff --git
> > > a/MdePkg/Include/IndustryStandard/IpmiNetFnTransport.h
> > > b/MdePkg/Include/IndustryStandard/IpmiNetFnTransport.h
> > > index 19db84e5122..2024c35f7fa 100644
> > > --- a/MdePkg/Include/IndustryStandard/IpmiNetFnTransport.h
> > > +++ b/MdePkg/Include/IndustryStandard/IpmiNetFnTransport.h
> > > @@ -11,6 +11,7 @@
> > >    and Appendix H, Sub-function Assignments.
> > >
> > >    Copyright (c) 1999 - 2018, Intel Corporation. All rights
> > > reserved.<BR>
> > > +  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights
> > reserved.<BR>
> > >    SPDX-License-Identifier: BSD-2-Clause-Patent  **/
> > >
> > > @@ -60,6 +61,7 @@ typedef enum {
> > >    IpmiLanReserved3,
> > >    IpmiLanDestinationType,
> > >    IpmiLanDestinationAddress,
> > > +  IpmiLanVlanId         = 0x14,
> > >    IpmiIpv4OrIpv6Support = 0x32,
> > >    IpmiIpv4OrIpv6AddressEnable,
> > >    IpmiIpv6HdrStatTrafficClass,
> > > @@ -103,6 +105,14 @@ typedef enum {
> > >    IpmiOem2
> > >  } IPMI_LAN_DEST_TYPE_DEST_TYPE;
> > >
> > > +//
> > > +// Destination address format
> > > +//
> > > +typedef enum {
> > > +  IpmiDestinationAddressVersion4,
> > > +  IpmiDestinationAddressVersion6
> > > +} IPMI_LAN_DEST_ADDRESS_VERSION;
> > > +
> > >  typedef union {
> > >    struct {
> > >      UINT8    NoAuth       : 1;
> > > @@ -177,6 +187,10 @@ typedef struct {
> > >    UINT8    ArpInterval;
> > >  } IPMI_LAN_ARP_INTERVAL;
> > >
> > > +typedef struct {
> > > +  UINT8    IpAddress[4];
> > > +} IPMI_LAN_DEFAULT_GATEWAY;
> > > +
> > >  typedef struct {
> > >    UINT8    Data[18];
> > >  } IPMI_LAN_COMMUNITY_STRING;
> > > @@ -227,6 +241,24 @@ typedef struct {
> > >    IPMI_LAN_MAC_ADDRESS         AlertingMacAddress;
> > >  } IPMI_LAN_DEST_ADDRESS;
> > >
> > > +typedef struct {
> > > +  UINT8    VanIdLowByte;
> > > +} IPMI_LAN_VLAN_ID_DATA1;
> > > +
> > > +typedef union {
> > > +  struct {
> > > +    UINT8    VanIdHighByte : 4;
> > > +    UINT8    Reserved      : 3;
> > > +    UINT8    Enabled       : 1;
> > > +  } Bits;
> > > +  UINT8    Uint8;
> > > +} IPMI_LAN_VLAN_ID_DATA2;
> > > +
> > > +typedef struct {
> > > +  IPMI_LAN_VLAN_ID_DATA1    Data1;
> > > +  IPMI_LAN_VLAN_ID_DATA2    Data2;
> > > +} IPMI_LAN_VLAN_ID;
> > > +
> > >  typedef union {
> > >    IPMI_LAN_AUTH_TYPE                    IpmiLanAuthType;
> > >    IPMI_LAN_IP_ADDRESS                   IpmiLanIpAddress;
> > > --
> > > 2.37.1.windows.1
> > >
> > >
> > >
> > >
> > >
> >
> >
> 
> 
> 
> 




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

* Re: [edk2-devel] [PATCH V4 1/3] MdePkg/IndustryStandard: Update IPMI definitions
  2023-01-19  1:07       ` 回复: " gaoliming
@ 2023-01-19  1:15         ` Chang, Abner
  2023-01-19  3:31         ` Chang, Abner
  1 sibling, 0 replies; 10+ messages in thread
From: Chang, Abner @ 2023-01-19  1:15 UTC (permalink / raw)
  To: gaoliming, devel@edk2.groups.io
  Cc: 'Michael D Kinney', 'Zhiguang Liu',
	'Nickle Wang', 'Igor Kulchytskyy',
	'Isaac Oram', 'Nate DeSimone'

[AMD Official Use Only - General]


> -----Original Message-----
> From: gaoliming <gaoliming@byosoft.com.cn>
> Sent: Thursday, January 19, 2023 9:08 AM
> To: devel@edk2.groups.io; Chang, Abner <Abner.Chang@amd.com>
> Cc: 'Michael D Kinney' <michael.d.kinney@intel.com>; 'Zhiguang Liu'
> <zhiguang.liu@intel.com>; 'Nickle Wang' <nicklew@nvidia.com>; 'Igor
> Kulchytskyy' <igork@ami.com>; 'Isaac Oram' <isaac.w.oram@intel.com>;
> 'Nate DeSimone' <nathaniel.l.desimone@intel.com>
> Subject: 回复: [edk2-devel] [PATCH V4 1/3] MdePkg/IndustryStandard:
> Update IPMI definitions
> 
> Caution: This message originated from an External Source. Use proper
> caution when opening attachments, clicking links, or responding.
> 
> 
> Abner:
>   Thanks for your confirmation. I suggest you mention this change in the
> commit message.
No problem, I will.
I will also create two PR for these two patch sets.

Thanks
Abner

> 
>   Reviewed-by: Liming Gao <gaoliming@byosoft.com.cn>
> 
> Thanks
> Liming
> > -----邮件原件-----
> > 发件人: devel@edk2.groups.io <devel@edk2.groups.io> 代表 Chang,
> Abner via
> > groups.io
> > 发送时间: 2023年1月18日 14:06
> > 收件人: gaoliming <gaoliming@byosoft.com.cn>; devel@edk2.groups.io
> > 抄送: 'Michael D Kinney' <michael.d.kinney@intel.com>; 'Zhiguang Liu'
> > <zhiguang.liu@intel.com>; 'Nickle Wang' <nicklew@nvidia.com>; 'Igor
> > Kulchytskyy' <igork@ami.com>; 'Isaac Oram' <isaac.w.oram@intel.com>;
> > 'Nate DeSimone' <nathaniel.l.desimone@intel.com>
> > 主题: Re: [edk2-devel] [PATCH V4 1/3] MdePkg/IndustryStandard: Update
> > IPMI definitions
> >
> > [AMD Official Use Only - General]
> >
> > This is the duplicate one, there is another above.
> >
> > Btw Liming, please let me push these two patch sets after you giving
> > Reviewed-by to this one. I will have to rebase them before merging the
> > change.
> > Thanks
> > Abner
> >
> > > -----Original Message-----
> > > From: gaoliming <gaoliming@byosoft.com.cn>
> > > Sent: Wednesday, January 18, 2023 1:13 PM
> > > To: devel@edk2.groups.io; Chang, Abner <Abner.Chang@amd.com>
> > > Cc: 'Michael D Kinney' <michael.d.kinney@intel.com>; 'Zhiguang Liu'
> > > <zhiguang.liu@intel.com>; 'Nickle Wang' <nicklew@nvidia.com>; 'Igor
> > > Kulchytskyy' <igork@ami.com>; 'Isaac Oram' <isaac.w.oram@intel.com>;
> > > 'Nate DeSimone' <nathaniel.l.desimone@intel.com>
> > > Subject: 回复: [edk2-devel] [PATCH V4 1/3] MdePkg/IndustryStandard:
> > > Update IPMI definitions
> > >
> > > Caution: This message originated from an External Source. Use proper
> > > caution when opening attachments, clicking links, or responding.
> > >
> > >
> > > Abner:
> > >   I see IPMI_APP_GET_CHANNEL_INFO definition is remove in this patch.
> > Can
> > > you help explain it in detail?
> > >
> > > Thanks
> > > Liming
> > > > -----邮件原件-----
> > > > 发件人: devel@edk2.groups.io <devel@edk2.groups.io> 代表 Chang,
> > > Abner via
> > > > groups.io
> > > > 发送时间: 2023年1月6日 10:58
> > > > 收件人: devel@edk2.groups.io
> > > > 抄送: Michael D Kinney <michael.d.kinney@intel.com>; Liming Gao
> > > > <gaoliming@byosoft.com.cn>; Zhiguang Liu <zhiguang.liu@intel.com>;
> > > > Nickle Wang <nicklew@nvidia.com>; Igor Kulchytskyy
> > > > <igork@ami.com>; Isaac Oram <isaac.w.oram@intel.com>; Nate
> > > > DeSimone <nathaniel.l.desimone@intel.com>
> > > > 主题: [edk2-devel] [PATCH V4 1/3] MdePkg/IndustryStandard: Update
> > > IPMI
> > > > definitions
> > > >
> > > > From: Abner Chang <abner.chang@amd.com>
> > > >
> > > > This change updates IPMI header files to support build up SMBIOS
> > > > 42 Redfish Host Interface record using the information retrieved
> > > > via IPMI App/Net Function.
> > > >
> > > > Signed-off-by: Abner Chang <abner.chang@amd.com>
> > > > Cc: Michael D Kinney <michael.d.kinney@intel.com>
> > > > Cc: Liming Gao <gaoliming@byosoft.com.cn>
> > > > Cc: Zhiguang Liu <zhiguang.liu@intel.com>
> > > > Cc: Nickle Wang <nicklew@nvidia.com>
> > > > Cc: Igor Kulchytskyy <igork@ami.com>
> > > > Cc: Isaac Oram <isaac.w.oram@intel.com>
> > > > Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
> > > > ---
> > > >  MdePkg/Include/IndustryStandard/Ipmi.h        | 17 +++++++++
> > > >  .../Include/IndustryStandard/IpmiNetFnApp.h   | 37
> > > > +++++++++++++++++--
> > > >  .../IndustryStandard/IpmiNetFnTransport.h     | 32
> > ++++++++++++++++
> > > >  3 files changed, 82 insertions(+), 4 deletions(-)
> > > >
> > > > diff --git a/MdePkg/Include/IndustryStandard/Ipmi.h
> > > > b/MdePkg/Include/IndustryStandard/Ipmi.h
> > > > index 9d1d412b53e..d6e7436b5ae 100644
> > > > --- a/MdePkg/Include/IndustryStandard/Ipmi.h
> > > > +++ b/MdePkg/Include/IndustryStandard/Ipmi.h
> > > > @@ -6,6 +6,7 @@
> > > >    and Appendix H, Sub-function Assignments.
> > > >
> > > >    Copyright (c) 1999 - 2018, Intel Corporation. All rights
> > > > reserved.<BR>
> > > > +  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights
> > > reserved.<BR>
> > > >    SPDX-License-Identifier: BSD-2-Clause-Patent  **/
> > > >
> > > > @@ -52,4 +53,20 @@
> > > >  #define IPMI_COMP_CODE_SUBFUNCTION_DISABLED
> > 0xD6
> > > >  #define IPMI_COMP_CODE_UNSPECIFIED
> > 0xFF
> > > >
> > > > +#define IPMI_CHANNEL_NUMBER_PRIMARY_IPMB
> > > > 0x00
> > > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_1
> > 0x01
> > > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_2
> > 0x02
> > > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_3
> > 0x03
> > > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_4
> > 0x04
> > > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_5
> > 0x05
> > > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_6
> > 0x06
> > > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_7
> > 0x07
> > > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_8
> > 0x08
> > > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_9
> > 0x09
> > > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_10
> > > 0x0A #define
> > > > +IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_11  0x0B
> > > #define
> > > > +IPMI_CHANNEL_NUMBER_IMPLEMENTATION_RESERVED_12
> > > > 0x0C
> > > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_RESERVED_13
> > > > 0x0D
> > > > +#define IPMI_CHANNEL_NUMBER_PRIMARY_PRESENT_IF
> > 0x0E
> > > > +#define IPMI_CHANNEL_NUMBER_PRIMARY_SYSTEM_INTERFACE
> > > > 0x0F
> > > >  #endif
> > > > diff --git a/MdePkg/Include/IndustryStandard/IpmiNetFnApp.h
> > > > b/MdePkg/Include/IndustryStandard/IpmiNetFnApp.h
> > > > index 0721bc6b271..a5835ba08c0 100644
> > > > --- a/MdePkg/Include/IndustryStandard/IpmiNetFnApp.h
> > > > +++ b/MdePkg/Include/IndustryStandard/IpmiNetFnApp.h
> > > > @@ -12,6 +12,7 @@
> > > >    and Appendix H, Sub-function Assignments.
> > > >
> > > >    Copyright (c) 1999 - 2018, Intel Corporation. All rights
> > > > reserved.<BR>
> > > > +  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights
> > > reserved.<BR>
> > > >    SPDX-License-Identifier: BSD-2-Clause-Patent  **/
> > > >
> > > > @@ -486,6 +487,11 @@ typedef struct {  //  #define
> > > > IPMI_APP_GET_SYSTEM_GUID  0x37
> > > >
> > > > +typedef struct {
> > > > +  UINT8       CompletionCode;
> > > > +  EFI_GUID    SystemUuid;
> > > > +} IPMI_GET_SYSTEM_UUID_RESPONSE;
> > > > +
> > > >  //
> > > >  //  Constants and Structure definitions for "Get System GUID"
> > command
> > > > to follow here  // @@ -671,6 +677,30 @@ typedef struct {  #define
> > > > IPMI_CHANNEL_MEDIA_TYPE_OEM_START  0x60
> > > >  #define IPMI_CHANNEL_MEDIA_TYPE_OEM_END    0x7F
> > > >
> > > > +//
> > > > +//  Definitions for channel protocol type // // Not available
> > > > +#define IPMI_CHANNEL_PROTOCOL_TYPE_NA  0x00 // IPMB-1.0
> #define
> > > > +IPMI_CHANNEL_PROTOCOL_TYPE_IPMB_1_0  0x01 // ICMB-1.0
> > #define
> > > > +IPMI_CHANNEL_PROTOCOL_TYPE_ICMB_1_0  0x02 // Reserved
> > #define
> > > > +IPMI_CHANNEL_PROTOCOL_TYPE_RESERVED  0x03 // IPMI SMBUS
> > > #define
> > > > +IPMI_CHANNEL_PROTOCOL_TYPE_IPMI_SMBUS  0x04 // KCS #define
> > > > +IPMI_CHANNEL_PROTOCOL_TYPE_KCS  0x05 // SMIC #define
> > > > +IPMI_CHANNEL_PROTOCOL_TYPE_SMIC  0x06 // BT-10 #define
> > > > +IPMI_CHANNEL_PROTOCOL_TYPE_BT_10  0x07 // BT-15 #define
> > > > +IPMI_CHANNEL_PROTOCOL_TYPE_BT_15  0x08 // TMode #define
> > > > +IPMI_CHANNEL_PROTOCOL_TYPE_TMODE  0x09
> > > > +
> > > >  typedef union {
> > > >    struct {
> > > >      UINT8    ChannelNo : 4;
> > > > @@ -713,10 +743,9 @@ typedef struct {
> > > >    UINT16                               AuxChannelInfo;
> > > >  } IPMI_GET_CHANNEL_INFO_RESPONSE;
> > > >
> > > > -//
> > > > -//  Definitions for Get Channel Info command -// -#define
> > > > IPMI_APP_GET_CHANNEL_INFO  0x42
> > > > +typedef struct {
> > > > +  IPMI_CHANNEL_INFO_CHANNEL_NUMBER    ChannelNumber;
> > > > +} IPMI_GET_CHANNEL_INFO_REQUEST;
> > > >
> > > >  //
> > > >  //  Constants and Structure definitions for "Get Channel Info"
> > > > command to follow here diff --git
> > > > a/MdePkg/Include/IndustryStandard/IpmiNetFnTransport.h
> > > > b/MdePkg/Include/IndustryStandard/IpmiNetFnTransport.h
> > > > index 19db84e5122..2024c35f7fa 100644
> > > > --- a/MdePkg/Include/IndustryStandard/IpmiNetFnTransport.h
> > > > +++ b/MdePkg/Include/IndustryStandard/IpmiNetFnTransport.h
> > > > @@ -11,6 +11,7 @@
> > > >    and Appendix H, Sub-function Assignments.
> > > >
> > > >    Copyright (c) 1999 - 2018, Intel Corporation. All rights
> > > > reserved.<BR>
> > > > +  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights
> > > reserved.<BR>
> > > >    SPDX-License-Identifier: BSD-2-Clause-Patent  **/
> > > >
> > > > @@ -60,6 +61,7 @@ typedef enum {
> > > >    IpmiLanReserved3,
> > > >    IpmiLanDestinationType,
> > > >    IpmiLanDestinationAddress,
> > > > +  IpmiLanVlanId         = 0x14,
> > > >    IpmiIpv4OrIpv6Support = 0x32,
> > > >    IpmiIpv4OrIpv6AddressEnable,
> > > >    IpmiIpv6HdrStatTrafficClass,
> > > > @@ -103,6 +105,14 @@ typedef enum {
> > > >    IpmiOem2
> > > >  } IPMI_LAN_DEST_TYPE_DEST_TYPE;
> > > >
> > > > +//
> > > > +// Destination address format
> > > > +//
> > > > +typedef enum {
> > > > +  IpmiDestinationAddressVersion4,
> > > > +  IpmiDestinationAddressVersion6
> > > > +} IPMI_LAN_DEST_ADDRESS_VERSION;
> > > > +
> > > >  typedef union {
> > > >    struct {
> > > >      UINT8    NoAuth       : 1;
> > > > @@ -177,6 +187,10 @@ typedef struct {
> > > >    UINT8    ArpInterval;
> > > >  } IPMI_LAN_ARP_INTERVAL;
> > > >
> > > > +typedef struct {
> > > > +  UINT8    IpAddress[4];
> > > > +} IPMI_LAN_DEFAULT_GATEWAY;
> > > > +
> > > >  typedef struct {
> > > >    UINT8    Data[18];
> > > >  } IPMI_LAN_COMMUNITY_STRING;
> > > > @@ -227,6 +241,24 @@ typedef struct {
> > > >    IPMI_LAN_MAC_ADDRESS         AlertingMacAddress;
> > > >  } IPMI_LAN_DEST_ADDRESS;
> > > >
> > > > +typedef struct {
> > > > +  UINT8    VanIdLowByte;
> > > > +} IPMI_LAN_VLAN_ID_DATA1;
> > > > +
> > > > +typedef union {
> > > > +  struct {
> > > > +    UINT8    VanIdHighByte : 4;
> > > > +    UINT8    Reserved      : 3;
> > > > +    UINT8    Enabled       : 1;
> > > > +  } Bits;
> > > > +  UINT8    Uint8;
> > > > +} IPMI_LAN_VLAN_ID_DATA2;
> > > > +
> > > > +typedef struct {
> > > > +  IPMI_LAN_VLAN_ID_DATA1    Data1;
> > > > +  IPMI_LAN_VLAN_ID_DATA2    Data2;
> > > > +} IPMI_LAN_VLAN_ID;
> > > > +
> > > >  typedef union {
> > > >    IPMI_LAN_AUTH_TYPE                    IpmiLanAuthType;
> > > >    IPMI_LAN_IP_ADDRESS                   IpmiLanIpAddress;
> > > > --
> > > > 2.37.1.windows.1
> > > >
> > > >
> > > >
> > > >
> > > >
> > >
> > >
> >
> >
> > 
> >
> 
> 

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

* Re: [edk2-devel] [PATCH V4 1/3] MdePkg/IndustryStandard: Update IPMI definitions
  2023-01-19  1:07       ` 回复: " gaoliming
  2023-01-19  1:15         ` Chang, Abner
@ 2023-01-19  3:31         ` Chang, Abner
  1 sibling, 0 replies; 10+ messages in thread
From: Chang, Abner @ 2023-01-19  3:31 UTC (permalink / raw)
  To: gaoliming, devel@edk2.groups.io
  Cc: 'Michael D Kinney', 'Zhiguang Liu',
	'Nickle Wang', 'Igor Kulchytskyy',
	'Isaac Oram', 'Nate DeSimone'

[AMD Official Use Only - General]

Merged.

> -----Original Message-----
> From: gaoliming <gaoliming@byosoft.com.cn>
> Sent: Thursday, January 19, 2023 9:08 AM
> To: devel@edk2.groups.io; Chang, Abner <Abner.Chang@amd.com>
> Cc: 'Michael D Kinney' <michael.d.kinney@intel.com>; 'Zhiguang Liu'
> <zhiguang.liu@intel.com>; 'Nickle Wang' <nicklew@nvidia.com>; 'Igor
> Kulchytskyy' <igork@ami.com>; 'Isaac Oram' <isaac.w.oram@intel.com>;
> 'Nate DeSimone' <nathaniel.l.desimone@intel.com>
> Subject: 回复: [edk2-devel] [PATCH V4 1/3] MdePkg/IndustryStandard:
> Update IPMI definitions
> 
> Caution: This message originated from an External Source. Use proper
> caution when opening attachments, clicking links, or responding.
> 
> 
> Abner:
>   Thanks for your confirmation. I suggest you mention this change in the
> commit message.
> 
>   Reviewed-by: Liming Gao <gaoliming@byosoft.com.cn>
> 
> Thanks
> Liming
> > -----邮件原件-----
> > 发件人: devel@edk2.groups.io <devel@edk2.groups.io> 代表 Chang,
> Abner via
> > groups.io
> > 发送时间: 2023年1月18日 14:06
> > 收件人: gaoliming <gaoliming@byosoft.com.cn>; devel@edk2.groups.io
> > 抄送: 'Michael D Kinney' <michael.d.kinney@intel.com>; 'Zhiguang Liu'
> > <zhiguang.liu@intel.com>; 'Nickle Wang' <nicklew@nvidia.com>; 'Igor
> > Kulchytskyy' <igork@ami.com>; 'Isaac Oram' <isaac.w.oram@intel.com>;
> > 'Nate DeSimone' <nathaniel.l.desimone@intel.com>
> > 主题: Re: [edk2-devel] [PATCH V4 1/3] MdePkg/IndustryStandard: Update
> > IPMI definitions
> >
> > [AMD Official Use Only - General]
> >
> > This is the duplicate one, there is another above.
> >
> > Btw Liming, please let me push these two patch sets after you giving
> > Reviewed-by to this one. I will have to rebase them before merging the
> > change.
> > Thanks
> > Abner
> >
> > > -----Original Message-----
> > > From: gaoliming <gaoliming@byosoft.com.cn>
> > > Sent: Wednesday, January 18, 2023 1:13 PM
> > > To: devel@edk2.groups.io; Chang, Abner <Abner.Chang@amd.com>
> > > Cc: 'Michael D Kinney' <michael.d.kinney@intel.com>; 'Zhiguang Liu'
> > > <zhiguang.liu@intel.com>; 'Nickle Wang' <nicklew@nvidia.com>; 'Igor
> > > Kulchytskyy' <igork@ami.com>; 'Isaac Oram' <isaac.w.oram@intel.com>;
> > > 'Nate DeSimone' <nathaniel.l.desimone@intel.com>
> > > Subject: 回复: [edk2-devel] [PATCH V4 1/3] MdePkg/IndustryStandard:
> > > Update IPMI definitions
> > >
> > > Caution: This message originated from an External Source. Use proper
> > > caution when opening attachments, clicking links, or responding.
> > >
> > >
> > > Abner:
> > >   I see IPMI_APP_GET_CHANNEL_INFO definition is remove in this patch.
> > Can
> > > you help explain it in detail?
> > >
> > > Thanks
> > > Liming
> > > > -----邮件原件-----
> > > > 发件人: devel@edk2.groups.io <devel@edk2.groups.io> 代表 Chang,
> > > Abner via
> > > > groups.io
> > > > 发送时间: 2023年1月6日 10:58
> > > > 收件人: devel@edk2.groups.io
> > > > 抄送: Michael D Kinney <michael.d.kinney@intel.com>; Liming Gao
> > > > <gaoliming@byosoft.com.cn>; Zhiguang Liu <zhiguang.liu@intel.com>;
> > > > Nickle Wang <nicklew@nvidia.com>; Igor Kulchytskyy
> > > > <igork@ami.com>; Isaac Oram <isaac.w.oram@intel.com>; Nate
> > > > DeSimone <nathaniel.l.desimone@intel.com>
> > > > 主题: [edk2-devel] [PATCH V4 1/3] MdePkg/IndustryStandard: Update
> > > IPMI
> > > > definitions
> > > >
> > > > From: Abner Chang <abner.chang@amd.com>
> > > >
> > > > This change updates IPMI header files to support build up SMBIOS
> > > > 42 Redfish Host Interface record using the information retrieved
> > > > via IPMI App/Net Function.
> > > >
> > > > Signed-off-by: Abner Chang <abner.chang@amd.com>
> > > > Cc: Michael D Kinney <michael.d.kinney@intel.com>
> > > > Cc: Liming Gao <gaoliming@byosoft.com.cn>
> > > > Cc: Zhiguang Liu <zhiguang.liu@intel.com>
> > > > Cc: Nickle Wang <nicklew@nvidia.com>
> > > > Cc: Igor Kulchytskyy <igork@ami.com>
> > > > Cc: Isaac Oram <isaac.w.oram@intel.com>
> > > > Cc: Nate DeSimone <nathaniel.l.desimone@intel.com>
> > > > ---
> > > >  MdePkg/Include/IndustryStandard/Ipmi.h        | 17 +++++++++
> > > >  .../Include/IndustryStandard/IpmiNetFnApp.h   | 37
> > > > +++++++++++++++++--
> > > >  .../IndustryStandard/IpmiNetFnTransport.h     | 32
> > ++++++++++++++++
> > > >  3 files changed, 82 insertions(+), 4 deletions(-)
> > > >
> > > > diff --git a/MdePkg/Include/IndustryStandard/Ipmi.h
> > > > b/MdePkg/Include/IndustryStandard/Ipmi.h
> > > > index 9d1d412b53e..d6e7436b5ae 100644
> > > > --- a/MdePkg/Include/IndustryStandard/Ipmi.h
> > > > +++ b/MdePkg/Include/IndustryStandard/Ipmi.h
> > > > @@ -6,6 +6,7 @@
> > > >    and Appendix H, Sub-function Assignments.
> > > >
> > > >    Copyright (c) 1999 - 2018, Intel Corporation. All rights
> > > > reserved.<BR>
> > > > +  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights
> > > reserved.<BR>
> > > >    SPDX-License-Identifier: BSD-2-Clause-Patent  **/
> > > >
> > > > @@ -52,4 +53,20 @@
> > > >  #define IPMI_COMP_CODE_SUBFUNCTION_DISABLED
> > 0xD6
> > > >  #define IPMI_COMP_CODE_UNSPECIFIED
> > 0xFF
> > > >
> > > > +#define IPMI_CHANNEL_NUMBER_PRIMARY_IPMB
> > > > 0x00
> > > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_1
> > 0x01
> > > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_2
> > 0x02
> > > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_3
> > 0x03
> > > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_4
> > 0x04
> > > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_5
> > 0x05
> > > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_6
> > 0x06
> > > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_7
> > 0x07
> > > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_8
> > 0x08
> > > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_9
> > 0x09
> > > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_10
> > > 0x0A #define
> > > > +IPMI_CHANNEL_NUMBER_IMPLEMENTATION_SPECIFIC_11  0x0B
> > > #define
> > > > +IPMI_CHANNEL_NUMBER_IMPLEMENTATION_RESERVED_12
> > > > 0x0C
> > > > +#define IPMI_CHANNEL_NUMBER_IMPLEMENTATION_RESERVED_13
> > > > 0x0D
> > > > +#define IPMI_CHANNEL_NUMBER_PRIMARY_PRESENT_IF
> > 0x0E
> > > > +#define IPMI_CHANNEL_NUMBER_PRIMARY_SYSTEM_INTERFACE
> > > > 0x0F
> > > >  #endif
> > > > diff --git a/MdePkg/Include/IndustryStandard/IpmiNetFnApp.h
> > > > b/MdePkg/Include/IndustryStandard/IpmiNetFnApp.h
> > > > index 0721bc6b271..a5835ba08c0 100644
> > > > --- a/MdePkg/Include/IndustryStandard/IpmiNetFnApp.h
> > > > +++ b/MdePkg/Include/IndustryStandard/IpmiNetFnApp.h
> > > > @@ -12,6 +12,7 @@
> > > >    and Appendix H, Sub-function Assignments.
> > > >
> > > >    Copyright (c) 1999 - 2018, Intel Corporation. All rights
> > > > reserved.<BR>
> > > > +  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights
> > > reserved.<BR>
> > > >    SPDX-License-Identifier: BSD-2-Clause-Patent  **/
> > > >
> > > > @@ -486,6 +487,11 @@ typedef struct {  //  #define
> > > > IPMI_APP_GET_SYSTEM_GUID  0x37
> > > >
> > > > +typedef struct {
> > > > +  UINT8       CompletionCode;
> > > > +  EFI_GUID    SystemUuid;
> > > > +} IPMI_GET_SYSTEM_UUID_RESPONSE;
> > > > +
> > > >  //
> > > >  //  Constants and Structure definitions for "Get System GUID"
> > command
> > > > to follow here  // @@ -671,6 +677,30 @@ typedef struct {  #define
> > > > IPMI_CHANNEL_MEDIA_TYPE_OEM_START  0x60
> > > >  #define IPMI_CHANNEL_MEDIA_TYPE_OEM_END    0x7F
> > > >
> > > > +//
> > > > +//  Definitions for channel protocol type // // Not available
> > > > +#define IPMI_CHANNEL_PROTOCOL_TYPE_NA  0x00 // IPMB-1.0
> #define
> > > > +IPMI_CHANNEL_PROTOCOL_TYPE_IPMB_1_0  0x01 // ICMB-1.0
> > #define
> > > > +IPMI_CHANNEL_PROTOCOL_TYPE_ICMB_1_0  0x02 // Reserved
> > #define
> > > > +IPMI_CHANNEL_PROTOCOL_TYPE_RESERVED  0x03 // IPMI SMBUS
> > > #define
> > > > +IPMI_CHANNEL_PROTOCOL_TYPE_IPMI_SMBUS  0x04 // KCS #define
> > > > +IPMI_CHANNEL_PROTOCOL_TYPE_KCS  0x05 // SMIC #define
> > > > +IPMI_CHANNEL_PROTOCOL_TYPE_SMIC  0x06 // BT-10 #define
> > > > +IPMI_CHANNEL_PROTOCOL_TYPE_BT_10  0x07 // BT-15 #define
> > > > +IPMI_CHANNEL_PROTOCOL_TYPE_BT_15  0x08 // TMode #define
> > > > +IPMI_CHANNEL_PROTOCOL_TYPE_TMODE  0x09
> > > > +
> > > >  typedef union {
> > > >    struct {
> > > >      UINT8    ChannelNo : 4;
> > > > @@ -713,10 +743,9 @@ typedef struct {
> > > >    UINT16                               AuxChannelInfo;
> > > >  } IPMI_GET_CHANNEL_INFO_RESPONSE;
> > > >
> > > > -//
> > > > -//  Definitions for Get Channel Info command -// -#define
> > > > IPMI_APP_GET_CHANNEL_INFO  0x42
> > > > +typedef struct {
> > > > +  IPMI_CHANNEL_INFO_CHANNEL_NUMBER    ChannelNumber;
> > > > +} IPMI_GET_CHANNEL_INFO_REQUEST;
> > > >
> > > >  //
> > > >  //  Constants and Structure definitions for "Get Channel Info"
> > > > command to follow here diff --git
> > > > a/MdePkg/Include/IndustryStandard/IpmiNetFnTransport.h
> > > > b/MdePkg/Include/IndustryStandard/IpmiNetFnTransport.h
> > > > index 19db84e5122..2024c35f7fa 100644
> > > > --- a/MdePkg/Include/IndustryStandard/IpmiNetFnTransport.h
> > > > +++ b/MdePkg/Include/IndustryStandard/IpmiNetFnTransport.h
> > > > @@ -11,6 +11,7 @@
> > > >    and Appendix H, Sub-function Assignments.
> > > >
> > > >    Copyright (c) 1999 - 2018, Intel Corporation. All rights
> > > > reserved.<BR>
> > > > +  Copyright (C) 2023 Advanced Micro Devices, Inc. All rights
> > > reserved.<BR>
> > > >    SPDX-License-Identifier: BSD-2-Clause-Patent  **/
> > > >
> > > > @@ -60,6 +61,7 @@ typedef enum {
> > > >    IpmiLanReserved3,
> > > >    IpmiLanDestinationType,
> > > >    IpmiLanDestinationAddress,
> > > > +  IpmiLanVlanId         = 0x14,
> > > >    IpmiIpv4OrIpv6Support = 0x32,
> > > >    IpmiIpv4OrIpv6AddressEnable,
> > > >    IpmiIpv6HdrStatTrafficClass,
> > > > @@ -103,6 +105,14 @@ typedef enum {
> > > >    IpmiOem2
> > > >  } IPMI_LAN_DEST_TYPE_DEST_TYPE;
> > > >
> > > > +//
> > > > +// Destination address format
> > > > +//
> > > > +typedef enum {
> > > > +  IpmiDestinationAddressVersion4,
> > > > +  IpmiDestinationAddressVersion6
> > > > +} IPMI_LAN_DEST_ADDRESS_VERSION;
> > > > +
> > > >  typedef union {
> > > >    struct {
> > > >      UINT8    NoAuth       : 1;
> > > > @@ -177,6 +187,10 @@ typedef struct {
> > > >    UINT8    ArpInterval;
> > > >  } IPMI_LAN_ARP_INTERVAL;
> > > >
> > > > +typedef struct {
> > > > +  UINT8    IpAddress[4];
> > > > +} IPMI_LAN_DEFAULT_GATEWAY;
> > > > +
> > > >  typedef struct {
> > > >    UINT8    Data[18];
> > > >  } IPMI_LAN_COMMUNITY_STRING;
> > > > @@ -227,6 +241,24 @@ typedef struct {
> > > >    IPMI_LAN_MAC_ADDRESS         AlertingMacAddress;
> > > >  } IPMI_LAN_DEST_ADDRESS;
> > > >
> > > > +typedef struct {
> > > > +  UINT8    VanIdLowByte;
> > > > +} IPMI_LAN_VLAN_ID_DATA1;
> > > > +
> > > > +typedef union {
> > > > +  struct {
> > > > +    UINT8    VanIdHighByte : 4;
> > > > +    UINT8    Reserved      : 3;
> > > > +    UINT8    Enabled       : 1;
> > > > +  } Bits;
> > > > +  UINT8    Uint8;
> > > > +} IPMI_LAN_VLAN_ID_DATA2;
> > > > +
> > > > +typedef struct {
> > > > +  IPMI_LAN_VLAN_ID_DATA1    Data1;
> > > > +  IPMI_LAN_VLAN_ID_DATA2    Data2;
> > > > +} IPMI_LAN_VLAN_ID;
> > > > +
> > > >  typedef union {
> > > >    IPMI_LAN_AUTH_TYPE                    IpmiLanAuthType;
> > > >    IPMI_LAN_IP_ADDRESS                   IpmiLanIpAddress;
> > > > --
> > > > 2.37.1.windows.1
> > > >
> > > >
> > > >
> > > >
> > > >
> > >
> > >
> >
> >
> > 
> >
> 
> 

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

end of thread, other threads:[~2023-01-19  3:31 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-01-06  2:57 [PATCH V4 0/3] IPMI changes for Redfish Chang, Abner
2023-01-06  2:57 ` [PATCH V4 1/3] MdePkg/IndustryStandard: Update IPMI definitions Chang, Abner
2023-01-18  5:13   ` 回复: [edk2-devel] " gaoliming
2023-01-18  6:06     ` Chang, Abner
2023-01-19  1:07       ` 回复: " gaoliming
2023-01-19  1:15         ` Chang, Abner
2023-01-19  3:31         ` Chang, Abner
2023-01-06  2:57 ` [PATCH V4 2/3] RedfishPkg/Include: Add Redfish " Chang, Abner
2023-01-06  2:57 ` [PATCH V4 3/3] RedfishPkg/Include: Redfish USB Interface V2 update Chang, Abner
2023-01-11 23:11 ` [PATCH V4 0/3] IPMI changes for Redfish Isaac Oram

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