From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from NAM12-BN8-obe.outbound.protection.outlook.com (NAM12-BN8-obe.outbound.protection.outlook.com [40.107.237.40]) by mx.groups.io with SMTP id smtpd.web10.71100.1671798850234269434 for ; Fri, 23 Dec 2022 04:34:10 -0800 Authentication-Results: mx.groups.io; dkim=fail reason="body hash did not verify" header.i=@amd.com header.s=selector1 header.b=m2UTlpKv; spf=permerror, err=parse error for token &{10 18 %{i}._ip.%{h}._ehlo.%{d}._spf.vali.email}: invalid domain name (domain: amd.com, ip: 40.107.237.40, mailfrom: abner.chang@amd.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=hLGUUksi1oESzdQtaKlfdQ4E00ruDuVn7HkbpJLXPJGc/bvsVsd66PmVM9zyuMMPE9Lj4wk25TLFmURsxYdT29nB5+rdbmwp/OE6erjInbBjpnhAwtu8v0oQvxQHLjE92X5GJfu3NHej3CCTkqRCdXplOT1m67XSmh2nsUOnAfNCUdQIq1axiU+fC6ZalPLXEmiIaEe2LO221C4prSyXDwZUuURezB4kwS7LdZKCxNbgd4abfMSU+yBdAmGXK+GlrALAw4luTNazNEm3nz1w/uq9MUsVJ4oKwbrbt1ZEdDUuqLC/LGaJjrc+qIH3xFibOLncLjXXciYIxm3A3lomfQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=xyIi+eAfJyqW/bukcHW4X3StutdYua0jpmwFPeT3nT8=; b=Gk+Nmr9cMXYPr4xLw1xWbGXSzTZhcQaY41GWDugrifz9ioQvaAL0arnW9ASHLrym74wPGMKEWgJQImYt2usWsIOcWL2N1OVIVymt6ZcCoKNysGya9nXrgPB4HhKMVuFF1JhX/uwGVDEJ3ppPYmlUEyvoE3I8DuDjR607zlNIbcCIVbzEuc67+KJ/eB2LcTDu5e/S8k8qaqWRH9zI49H22nG9olAgUISPi9k4o3aDp25XFt7tCZKSz02NYVZbD4svLwAvqQsa8XCMAhaPGvcnE5NhOxDPsfGlsY2Bb6RoRbCyUDnm8JSHFyVkwnPU7MHY+H53IfVBX2sGS8u5GmjBFg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=edk2.groups.io smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=xyIi+eAfJyqW/bukcHW4X3StutdYua0jpmwFPeT3nT8=; b=m2UTlpKviFLiLKomcIVQAyIqJ3WUkIhtVJCoOe28OOqf1hX2Zp8c2XlFfy86A6SID/t8NB6ul6F7R8O8x9wEfsgtqkj9AHmzzFL8xcdt6yhJXkO+7W73BuA0lj3Do30BvbiwWu1y/QtiFHyMpiaYHwFC1dRjCM6rAwTSkgmYQIY= Received: from DM6PR08CA0048.namprd08.prod.outlook.com (2603:10b6:5:1e0::22) by BN9PR12MB5367.namprd12.prod.outlook.com (2603:10b6:408:104::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5944.12; Fri, 23 Dec 2022 12:34:08 +0000 Received: from DS1PEPF0000E647.namprd02.prod.outlook.com (2603:10b6:5:1e0:cafe::a8) by DM6PR08CA0048.outlook.office365.com (2603:10b6:5:1e0::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5944.13 via Frontend Transport; Fri, 23 Dec 2022 12:34:07 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; pr=C Received: from SATLEXMB04.amd.com (165.204.84.17) by DS1PEPF0000E647.mail.protection.outlook.com (10.167.18.37) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.5944.8 via Frontend Transport; Fri, 23 Dec 2022 12:34:07 +0000 Received: from TPE-L1-ABNCHANG.amd.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.34; Fri, 23 Dec 2022 06:34:03 -0600 From: "Chang, Abner" To: CC: Michael D Kinney , Liming Gao , Zhiguang Liu , Nickle Wang , Igor Kulchytskyy , Isaac Oram , Nate DeSimone Subject: [PATCH 1/3] MdePkg/IndustryStandard: Update IPMI definitions Date: Fri, 23 Dec 2022 20:33:34 +0800 Message-ID: <20221223123336.2014-2-abner.chang@amd.com> X-Mailer: git-send-email 2.37.1.windows.1 In-Reply-To: <20221223123336.2014-1-abner.chang@amd.com> References: <20221223123336.2014-1-abner.chang@amd.com> MIME-Version: 1.0 Return-Path: Abner.Chang@amd.com X-Originating-IP: [10.180.168.240] X-ClientProxiedBy: SATLEXMB04.amd.com (10.181.40.145) To SATLEXMB04.amd.com (10.181.40.145) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DS1PEPF0000E647:EE_|BN9PR12MB5367:EE_ X-MS-Office365-Filtering-Correlation-Id: 78ebddc3-51ca-451d-809b-08dae4e1fc58 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: UwqCv5Z0MFh+sjJYHMgq8s/6/Jjgfx0rugO4NrkvXTkl/zUGjb2cS2WSnEcD3cwvFl7yGixUO7d5xT5DP0OSi8DjrEL5NYxCeoxQKx63Gttz/46lGN5sh2TSioVWRUzfP2fXGnyA6pxwM1T8Rk3E1PVyhkufyM7ykpEIR+Y7bnWNYnbqqIWqyagVU1kGQvAzRO25qcPJCFeYAPWU2SwFuSGEUHvgLWpCFFmrAhQgSHZ+mOnLa+0YmdelZ18ClncbzHME9TvNJp4GdOPirbK2fx+IfV58VBAD3VC/N8xd9/eaKwk5K7abor7etQNFUSAUsiAzAyGG1ExzaTx3iL6VP1/k83lZK86ObCrdNiNOv0HwFnwrhNoKSL/ocS4b4bBFkFgURy+nlrVsueojrl/wBI47ftOpJxoj7L4VjkOMuwlfCWB/BFN6XErS0EOvjhbRJrzB//m+vjbzZ/H/CTXimG68w7l2jR93xWKeng8EzTLYVFA39dTtzBQdPvBNRzAIFKy+mTANMicRiQAM1F8236fTMHE+h7p2W11A7aIWH2PkiW5BQ1iIimRNydQg2b4wzLD/+++DA+FQo5hsSurB56JkHdjVe1Cr6eiSInel0OXrDLDFt23gGnFYsU/lr5s4kDnuUe+WzO78MAF2E+P2p0ATCccLVDANPFyK8xVielnQuVH61Wv1Qt+uHYM5pp0YANEs9NFCZIZtgKClAjhEGCl3Emwe2rK04wT64Zru9fU= X-Forefront-Antispam-Report: CIP:165.204.84.17;CTRY:US;LANG:en;SCL:1;SRV:;IPV:CAL;SFV:NSPM;H:SATLEXMB04.amd.com;PTR:InfoDomainNonexistent;CAT:NONE;SFS:(13230022)(4636009)(376002)(136003)(346002)(396003)(39860400002)(451199015)(40470700004)(36840700001)(46966006)(478600001)(81166007)(7696005)(40480700001)(16526019)(26005)(186003)(356005)(6666004)(82740400003)(2616005)(19627235002)(316002)(36756003)(6916009)(1076003)(54906003)(70206006)(4326008)(8676002)(70586007)(426003)(8936002)(47076005)(83380400001)(82310400005)(5660300002)(40460700003)(336012)(41300700001)(15650500001)(2906002)(2876002)(36860700001)(86362001)(36900700001);DIR:OUT;SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Dec 2022 12:34:07.7998 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 78ebddc3-51ca-451d-809b-08dae4e1fc58 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d;Ip=[165.204.84.17];Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: DS1PEPF0000E647.namprd02.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN9PR12MB5367 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain From: Abner Chang 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 Cc: Michael D Kinney Cc: Liming Gao Cc: Zhiguang Liu Cc: Nickle Wang Cc: Igor Kulchytskyy Cc: Isaac Oram Cc: Nate DeSimone --- 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/Indust= ryStandard/Ipmi.h index 9d1d412b53e..e16c1281862 100644 --- a/MdePkg/Include/IndustryStandard/Ipmi.h +++ b/MdePkg/Include/IndustryStandard/Ipmi.h @@ -6,6 +6,7 @@ and Appendix H, Sub-function Assignments. =20 Copyright (c) 1999 - 2018, Intel Corporation. All rights reserved.
+ Copyright (C) 2022 Advanced Micro Devices, Inc. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent **/ =20 @@ -52,4 +53,20 @@ #define IPMI_COMP_CODE_SUBFUNCTION_DISABLED 0xD6 #define IPMI_COMP_CODE_UNSPECIFIED 0xFF =20 +#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/Includ= e/IndustryStandard/IpmiNetFnApp.h index 0721bc6b271..08f977f2087 100644 --- a/MdePkg/Include/IndustryStandard/IpmiNetFnApp.h +++ b/MdePkg/Include/IndustryStandard/IpmiNetFnApp.h @@ -12,6 +12,7 @@ and Appendix H, Sub-function Assignments. =20 Copyright (c) 1999 - 2018, Intel Corporation. All rights reserved.
+ Copyright (C) 2022 Advanced Micro Devices, Inc. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent **/ =20 @@ -486,6 +487,11 @@ typedef struct { // #define IPMI_APP_GET_SYSTEM_GUID 0x37 =20 +typedef struct { + UINT8 CompletionCode; + EFI_GUID SystemUuid; +} IPMI_GET_SYSTEM_UUID_RESPONSE; + // // Constants and Structure definitions for "Get System GUID" command to f= ollow here // @@ -671,6 +677,30 @@ typedef struct { #define IPMI_CHANNEL_MEDIA_TYPE_OEM_START 0x60 #define IPMI_CHANNEL_MEDIA_TYPE_OEM_END 0x7F =20 +// +// 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; =20 -// -// 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; =20 // // 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..2eb6cd9b344 100644 --- a/MdePkg/Include/IndustryStandard/IpmiNetFnTransport.h +++ b/MdePkg/Include/IndustryStandard/IpmiNetFnTransport.h @@ -11,6 +11,7 @@ and Appendix H, Sub-function Assignments. =20 Copyright (c) 1999 - 2018, Intel Corporation. All rights reserved.
+ Copyright (C) 2022 Advanced Micro Devices, Inc. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent **/ =20 @@ -60,6 +61,7 @@ typedef enum { IpmiLanReserved3, IpmiLanDestinationType, IpmiLanDestinationAddress, + IpmiLanVlanId =3D 0x14, IpmiIpv4OrIpv6Support =3D 0x32, IpmiIpv4OrIpv6AddressEnable, IpmiIpv6HdrStatTrafficClass, @@ -103,6 +105,14 @@ typedef enum { IpmiOem2 } IPMI_LAN_DEST_TYPE_DEST_TYPE; =20 +// +// 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; =20 +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; =20 +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; --=20 2.37.1.windows.1