From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) by mx.groups.io with SMTP id smtpd.web10.8884.1626359879550897210 for ; Thu, 15 Jul 2021 07:37:59 -0700 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: intel.com, ip: 134.134.136.31, mailfrom: chasel.chiu@intel.com) X-IronPort-AV: E=McAfee;i="6200,9189,10045"; a="271672247" X-IronPort-AV: E=Sophos;i="5.84,242,1620716400"; d="scan'208";a="271672247" Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 15 Jul 2021 07:37:52 -0700 X-IronPort-AV: E=Sophos;i="5.84,242,1620716400"; d="scan'208";a="505842757" Received: from cchiu4-mobl.gar.corp.intel.com ([10.252.186.253]) by fmsmga002-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 15 Jul 2021 07:37:51 -0700 From: "Chiu, Chasel" To: devel@edk2.groups.io Cc: Chasel Chiu , Nate DeSimone , Sai Chaganty , Liming Gao , Isaac Oram Subject: [edk2-platforms: PATCH] Features/Intel/IpmiFeaturePkg: Use MdePkg macros instead of redefining. Date: Thu, 15 Jul 2021 22:37:41 +0800 Message-Id: <20210715143741.1295-1-chasel.chiu@intel.com> X-Mailer: git-send-email 2.28.0.windows.1 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D3494 Renamed below macros and structure to use MdePkg ones. IPMI_MSG_GET_BMC_EXEC_RSP IPMI_GET_BMC_EXECUTION_CONTEXT IPMI_BMC_IN_FORCED_UPDATE_MODE Cc: Nate DeSimone Cc: Sai Chaganty Cc: Liming Gao Cc: Isaac Oram Signed-off-by: Chasel Chiu --- Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Dxe/IpmiInit= .c | 8 ++++---- Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/ServerManagement= .h | 17 ----------------- 2 files changed, 4 insertions(+), 21 deletions(-) diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/= Dxe/IpmiInit.c b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericI= pmi/Dxe/IpmiInit.c index 1e0c132508..d788b48867 100644 --- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Dxe/Ipm= iInit.c +++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/GenericIpmi/Dxe/Ipm= iInit.c @@ -242,7 +242,7 @@ Returns: EFI_STATUS Status;=0D UINT32 DataSize;=0D SM_CTRL_INFO *pBmcInfo;=0D - EFI_IPMI_MSG_GET_BMC_EXEC_RSP *pBmcExecContext;=0D + IPMI_MSG_GET_BMC_EXEC_RSP *pBmcExecContext;=0D UINT32 Retries;=0D #ifdef FAST_VIDEO_SUPPORT=0D EFI_VIDEOPRINT_PROTOCOL *VideoPrintProtocol;=0D @@ -301,14 +301,14 @@ Returns: Status =3D IpmiSendCommand (=0D &IpmiInstance->IpmiTransport,=0D IPMI_NETFN_FIRMWARE, 0,=0D - EFI_FIRMWARE_GET_BMC_EXECUTION_CONTEXT,=0D + IPMI_GET_BMC_EXECUTION_CONTEXT,=0D NULL, 0,=0D IpmiInstance->TempData, &DataSize=0D );=0D =0D - pBmcExecContext =3D (EFI_IPMI_MSG_GET_BMC_EXEC_RSP*)&IpmiInstance->Tem= pData[0];=0D + pBmcExecContext =3D (IPMI_MSG_GET_BMC_EXEC_RSP*)&IpmiInstance->TempDat= a[0];=0D DEBUG ((DEBUG_INFO, "[IPMI] Operational status of BMC: 0x%x\n", pBmcEx= ecContext->CurrentExecutionContext));=0D - if ((pBmcExecContext->CurrentExecutionContext =3D=3D EFI_FIRMWARE_BMC_= IN_FORCED_UPDATE_MODE) &&=0D + if ((pBmcExecContext->CurrentExecutionContext =3D=3D IPMI_BMC_IN_FORCE= D_UPDATE_MODE) &&=0D !EFI_ERROR (Status)) {=0D DEBUG ((DEBUG_ERROR, "[IPMI] BMC in Forced Update mode, skip waiting= for BMC_READY.\n"));=0D IpmiInstance->BmcStatus =3D BMC_UPDATE_IN_PROGRESS;=0D diff --git a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/Serv= erManagement.h b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/= ServerManagement.h index 7591f33aba..244b86e91a 100644 --- a/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/ServerManag= ement.h +++ b/Features/Intel/OutOfBandManagement/IpmiFeaturePkg/Include/ServerManag= ement.h @@ -149,15 +149,6 @@ typedef enum { #define UPPER_NON_RECOVER_GOING_LOW 0x400=0D #define UPPER_NON_RECOVER_GOING_HI 0x800=0D =0D -//=0D -// Definitions for Get BMC Execution Context=0D -//=0D -#define EFI_FIRMWARE_GET_BMC_EXECUTION_CONTEXT 0x23=0D -//=0D -// Current Execution Context responses=0D -//=0D -#define EFI_FIRMWARE_BMC_IN_FORCED_UPDATE_MODE 0x11=0D -=0D //=0D // Server Management COM Addressing types=0D //=0D @@ -327,14 +318,6 @@ typedef struct { UINT16 IoBasePort;=0D } IPMI_HOB_DATA;=0D =0D -//=0D -// Constants and Structure definitions for "Get Device ID" command to fol= low here=0D -//=0D -typedef struct {=0D - UINT8 CurrentExecutionContext;=0D - UINT8 PartitionPointer;=0D -} EFI_IPMI_MSG_GET_BMC_EXEC_RSP;=0D -=0D //=0D // COM Layer Callback=0D //=0D --=20 2.28.0.windows.1