From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from NAM11-DM6-obe.outbound.protection.outlook.com (NAM11-DM6-obe.outbound.protection.outlook.com [40.107.223.70]) by mx.groups.io with SMTP id smtpd.web11.197146.1672278908744073634 for ; Wed, 28 Dec 2022 17:55:08 -0800 Authentication-Results: mx.groups.io; dkim=fail reason="body hash did not verify" header.i=@amd.com header.s=selector1 header.b=iMT/IjOC; 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.223.70, mailfrom: abner.chang@amd.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=eVbpkzolOusf50Bmts5Hj9jQ/qCVkxyacP6HSSFIwfjGX9nF/E3CbDhsKfXcuAKw+FUQzCSRKys9rehAF5ClEMdBH59rD6qZcbc8ESWvf3qU3ojS9ntv3mzsPbZrGnYnkdXrAj4+I0sJ+7IJGUzdBjqXEtHODLiw4GPZeoGZbmNa+Lc21KpCPwL/7sOeNLelXaZgsHYKL8BPHOnPFlWmt5ChfjXTFDSXD02r+uwEXpZMql0kxBj6cVfv+OERdzVe2WAJUSifWzqS2h53NusmMr/h1gPEV8A9Sh06yihwLLFr2F3hnKyl/9R2gh5uYahvuuyeSJ/S3LSLCnl8oW+wUA== 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=czrYsbtO6OAetoGtimqSufC8SLReadA5rzrEClIvP1JEj+tVnkxEfkNAa+LdOc3kk4/AArj0w6q7jV7LpygpkMiKVnyiiZJhJ5hMnbP3Xjc2VQKglpb54hVNgHy+6XShnc5xnQrRsATtKhsnzHOU7seWCHwBDJuDShGAOsnmDWcFyumHEBKjzBjemDAJYuaVGMp0Xrb4uMzXGZQuZlap7YA3vVMlehKpw74DIuqhzXVA167+QhET91gN/YNl/nq1oxyDarW5iCFinsYsI4jwOgNl2wJKSO8wk9782MgIcZy+3BdR8aMklPWsSeDatc1MtpNjd2ADoUj8MF86ZItKtg== 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=iMT/IjOCI567RJiUFa2Z/C2ZaqIifQQ4VqEElA0OCuyAY3H2c4T8DhK0Hl8bQJGYKfMo6UbtwK6RGhxVpfm/Ckj8fMQuJE8s2K5zDDAcuWSQ9ZRAgvcuiJIeVSv4neXcRJktVJ9kpHly+8kWscsX6nLI8fUqJ3/x47Rkjqxhw9Y= Received: from CY5P221CA0017.NAMP221.PROD.OUTLOOK.COM (2603:10b6:930:b::18) by CY5PR12MB6478.namprd12.prod.outlook.com (2603:10b6:930:35::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5944.16; Thu, 29 Dec 2022 01:55:06 +0000 Received: from CY4PEPF0000C97D.namprd02.prod.outlook.com (2603:10b6:930:b:cafe::96) by CY5P221CA0017.outlook.office365.com (2603:10b6:930:b::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5944.16 via Frontend Transport; Thu, 29 Dec 2022 01:55:06 +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 CY4PEPF0000C97D.mail.protection.outlook.com (10.167.241.136) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.5944.8 via Frontend Transport; Thu, 29 Dec 2022 01:55:06 +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; Wed, 28 Dec 2022 19:55:03 -0600 From: "Chang, Abner" To: CC: Michael D Kinney , Liming Gao , Zhiguang Liu , Nickle Wang , Igor Kulchytskyy , Isaac Oram , Nate DeSimone Subject: [PATCH V3 1/3] MdePkg/IndustryStandard: Update IPMI definitions Date: Thu, 29 Dec 2022 09:54:35 +0800 Message-ID: <20221229015437.1353-2-abner.chang@amd.com> X-Mailer: git-send-email 2.37.1.windows.1 In-Reply-To: <20221229015437.1353-1-abner.chang@amd.com> References: <20221229015437.1353-1-abner.chang@amd.com> MIME-Version: 1.0 Return-Path: Abner.Chang@amd.com X-Originating-IP: [10.180.168.240] X-ClientProxiedBy: SATLEXMB03.amd.com (10.181.40.144) To SATLEXMB04.amd.com (10.181.40.145) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: CY4PEPF0000C97D:EE_|CY5PR12MB6478:EE_ X-MS-Office365-Filtering-Correlation-Id: 74a4b701-45e0-462a-f23a-08dae93fb594 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 7biXOHvJpvFC3dn8bImKVJ0tDTC/Acoa5j3plJs4uCSpa+spMJPI+qk20XRdeHv4KAoAZZi/xJiCx5y+dKzp3Gsr8qolT+Ap6FPjRcz5KUOQLUM+L7l/iXWXktDnij0+MOB6hQ7UACjfMk5QWm/3roREqQbfmGsW3Cyz/sNZ7KkfGkAMfEoNUbEpr+WR2U7ouaKUlZ8NLNSubqfUqog6wIrlHrujp+BRgsP8vXzgE+xYJIDWfuBvOVU3cUmKFVJBaEnIXUPHCyIjVc4FFNpoiVLuaNx9JDeO02PtJusYZR+WUOb8f1MNj+zWbU9Dz1FF7KWZg2nyZp4h5gEXWa/OJNZTb88zavb2/5N/fv/ZADyHZtlS+J2KQeRBn38Nruu4hGi/9Eg2mUy1KQWzfX9x1G52EOdshw8xHJPk1sqIEIJfO61LJq4sTMJYUKVp4bWRMcoktKaUMrMv9nSmasmmVyBvMsSikKEi5J20tRqoa4uPrvHofmrgqHJ0ralXibPS+dZTTGh/EiW7TzKUIUZYArCZWDxKMkP599Ri9yhV56cZqDJjGtgPT/3kxJbQcEM3e5lL4j8vE74OZj7HFiTWbnQ1MIF8HY7AkmQ17Q1+JQ8HV8tlaVizJu8STkHBwSzWccHXQ0VdtEk6aq/QmqNAcw/0esiQ7dqJsKqwbL3AQyuuBqA6lylgEiRMZl9u7UWg6JD4MwYMNhZAS0aBes3Grr2OjoJB0uSTTh60dT4mabM= 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)(396003)(39860400002)(346002)(136003)(451199015)(40470700004)(36840700001)(46966006)(40480700001)(356005)(40460700003)(86362001)(36756003)(316002)(54906003)(6916009)(19627235002)(6666004)(478600001)(8936002)(5660300002)(2876002)(2906002)(15650500001)(4326008)(70586007)(70206006)(8676002)(41300700001)(36860700001)(82740400003)(81166007)(336012)(1076003)(7696005)(2616005)(16526019)(82310400005)(26005)(47076005)(186003)(83380400001)(426003)(36900700001);DIR:OUT;SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 29 Dec 2022 01:55:06.3900 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 74a4b701-45e0-462a-f23a-08dae93fb594 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: CY4PEPF0000C97D.namprd02.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY5PR12MB6478 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