From nobody Sun May 19 17:22:30 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of groups.io designates 66.175.222.12 as permitted sender) client-ip=66.175.222.12; envelope-from=bounce+27952+39995+1787277+3901457@groups.io; helo=web01.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zoho.com: domain of groups.io designates 66.175.222.12 as permitted sender) smtp.mailfrom=bounce+27952+39995+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=intel.com ARC-Seal: i=1; a=rsa-sha256; t=1557042741; cv=none; d=zoho.com; s=zohoarc; b=JxRE3hV9/6AczObQwOJFnfVMX+U4XtmpqWfW6MumsNRzJ50qjrEx4CJTHA3p5fADkBmiBjuojfOUJ7RUv5rCvVfyvxibOTuI/1avAAhTqginnKFsBHbvXLev5cettb7f77ep9Y5ic1VX949ysUQ3dtNvCAMuhs/+gh/mBpqCXkU= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1557042741; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Id:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To:ARC-Authentication-Results; bh=unB/0gYgyCcdZ+NeKaDc+z8DGJyXWKadzc+jI6Bc7es=; b=bauDzGJbFKMl0b6PHBwl1riPw944FZL69oC8LSqeFX4I2wP70ikz3UHnBpT+bxwBJw/vaDdY4bKPeY0wqXYUvqQ1v1nEwgK4ET4ocdBeekcP483c1MCF+dYeDcGMLM9P8VmEI6KckP9jE2DFJAx/pPojJyemO9NkAsZolFkhOtE= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=pass; spf=pass (zoho.com: domain of groups.io designates 66.175.222.12 as permitted sender) smtp.mailfrom=bounce+27952+39995+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) header.from= Received: from web01.groups.io (web01.groups.io [66.175.222.12]) by mx.zohomail.com with SMTPS id 1557042741690385.85471056489575; Sun, 5 May 2019 00:52:21 -0700 (PDT) Return-Path: X-Received: from mga14.intel.com (mga14.intel.com []) by groups.io with SMTP; Sun, 05 May 2019 00:52:20 -0700 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False X-Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by fmsmga103.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 05 May 2019 00:52:20 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.60,433,1549958400"; d="scan'208";a="155041544" X-Received: from fieedk001.ccr.corp.intel.com ([10.239.33.119]) by FMSMGA003.fm.intel.com with ESMTP; 05 May 2019 00:52:19 -0700 From: "Gao, Zhichao" To: devel@edk2.groups.io Cc: Bret Barkelew , Jian J Wang , Hao Wu , Ray Ni , Star Zeng , Liming Gao , Sean Brogan , Michael Turner Subject: [edk2-devel] [PATCH 1/4] MdeModulePkg: Add reset data difinition and guid Date: Sun, 5 May 2019 15:50:43 +0800 Message-Id: <20190505075046.14464-2-zhichao.gao@intel.com> In-Reply-To: <20190505075046.14464-1-zhichao.gao@intel.com> References: <20190505075046.14464-1-zhichao.gao@intel.com> MIME-Version: 1.0 Precedence: Bulk List-Unsubscribe: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,zhichao.gao@intel.com Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1557042741; bh=z99KVfQx0I1gE/UFXvJyOtxvcdXtTF7vPopm9wggBvo=; h=Cc:Date:From:Reply-To:Subject:To; b=HGJlg/Xzh2sXs98nUmHiBDCzpwDW3T1+elIX78/gXYoeoUrUPWbr+SjNhV5/HpzUz+r CydRZAsNIt9QSZFjtRViFZO/84QnUTYpnMcvSfSdQPjDUonZiBoqGtSsNmSZmHG840aJd bkPiNmhC7b8JEX2NSoPKZCIkrp78I1xdksY= X-ZohoMail-DKIM: pass (identity @groups.io) Content-Type: text/plain; charset="utf-8" From: Bret Barkelew REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D1772 Add a useful definition of reset data for capsule function. And add two guids gCapsuleArmedResetGuid and gCapsuleUpdateCompleteResetGuid. Cc: Jian J Wang Cc: Hao Wu Cc: Ray Ni Cc: Star Zeng Cc: Liming Gao Cc: Sean Brogan Cc: Michael Turner Cc: Bret Barkelew Signed-off-by: Zhichao Gao --- MdeModulePkg/Include/Guid/CapsuleResetData.h | 40 ++++++++++++++++++++ MdeModulePkg/MdeModulePkg.dec | 5 +++ 2 files changed, 45 insertions(+) create mode 100644 MdeModulePkg/Include/Guid/CapsuleResetData.h diff --git a/MdeModulePkg/Include/Guid/CapsuleResetData.h b/MdeModulePkg/In= clude/Guid/CapsuleResetData.h new file mode 100644 index 0000000000..b0666a0da2 --- /dev/null +++ b/MdeModulePkg/Include/Guid/CapsuleResetData.h @@ -0,0 +1,40 @@ +/** @file + The capsule reset data difinition and guids. + + Copyright (c) 2019, Intel Corporation. All rights reserved.
+ SPDX-License-Identifier: BSD-2-Clause-Patent + +**/ +#ifndef __CAPSULE_RESET_DATA_H__ +#define __CAPSULE_RESET_DATA_H__ + +#include + +// +// reset data started with a null string and followed by a guid data +// +#pragma pack(1) +typedef struct { + CHAR16 NullString; + EFI_GUID ResetGuid; +} RESET_DATA_WITH_NULL_STRING; +#pragma pack() + +VERIFY_SIZE_OF (RESET_DATA_WITH_NULL_STRING, 18); + +#define CAPSULE_ARMED_RESET_GUID \ + { \ + 0xc6b4eea7, 0xfce2, 0x4625, { 0x9c, 0x4f, 0xc4, 0xb0, 0x82, 0x37, 0xae= , 0x23 } \ + } + +#define CAPSULE_UPDATE_COMPLETE_RESET_GUID \ + { \ + 0x5d512714, 0xa4df, 0x4e46, { 0xb6, 0xc7, 0xbc, 0x9f, 0x97, 0x9d, 0x59= , 0xa0 } \ + } + +extern EFI_GUID gCapsuleArmedResetGuid; + +extern EFI_GUID gCapsuleUpdateCompleteResetGuid; + +#endif + diff --git a/MdeModulePkg/MdeModulePkg.dec b/MdeModulePkg/MdeModulePkg.dec index 2ef48f2c37..c12b836c24 100644 --- a/MdeModulePkg/MdeModulePkg.dec +++ b/MdeModulePkg/MdeModulePkg.dec @@ -423,6 +423,11 @@ ## Include/Guid/S3StorageDeviceInitList.h gS3StorageDeviceInitListGuid =3D { 0x310e9b8c, 0xcf90, 0x421e, { 0x8e, 0= x9b, 0x9e, 0xef, 0xb6, 0x17, 0xc8, 0xef } } =20 + ## Guid to use for gRT->ResetSystem() to indicate the type of reset that= is being performed. + # Include/Guid/CapsuleResetData.h + gCapsuleArmedResetGuid =3D {0xc6b4eea7, 0xfce2, 0x4625, {0x9c= , 0x4f, 0xc4, 0xb0, 0x82, 0x37, 0xae, 0x23}} + gCapsuleUpdateCompleteResetGuid =3D {0x5d512714, 0xa4df, 0x4e46, {0xb6= , 0xc7, 0xbc, 0x9f, 0x97, 0x9d, 0x59, 0xa0}} + [Ppis] ## Include/Ppi/AtaController.h gPeiAtaControllerPpiGuid =3D { 0xa45e60d1, 0xc719, 0x44aa, { 0xb0,= 0x7a, 0xaa, 0x77, 0x7f, 0x85, 0x90, 0x6d }} --=20 2.21.0.windows.1 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#39995): https://edk2.groups.io/g/devel/message/39995 Mute This Topic: https://groups.io/mt/31507358/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- From nobody Sun May 19 17:22:30 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of groups.io designates 66.175.222.12 as permitted sender) client-ip=66.175.222.12; envelope-from=bounce+27952+39996+1787277+3901457@groups.io; helo=web01.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zoho.com: domain of groups.io designates 66.175.222.12 as permitted sender) smtp.mailfrom=bounce+27952+39996+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=intel.com ARC-Seal: i=1; a=rsa-sha256; t=1557042744; cv=none; d=zoho.com; s=zohoarc; b=Wpwery/Tr19jmki28qyrmAGqBRMnLX5hrDTMSok670Fz1q+sOxSzVwv92e31RwLgZ//LcG/RnNGOGu6U5GDaNzXJJ4h9xPhC6zdRbMjbD3Ls287tQjB+/734trjcxjsdQVfWBVN3L+hdaNQQXhfkFq6G2m8QPsozzUxcztBKIbY= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1557042744; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Id:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To:ARC-Authentication-Results; bh=SL5/Nnwe5tZ6Q4YsH9YanCO25WJUCaEJWF9RXffQNzw=; b=iP0DjQMcOlaBtAfn2REDazpOllBKA/AmKd6VpGvjwYydIqxfkSVbtIN+MIDHaySFk1inOFQRMZydRXt1FREAPBmG5aN8QPpDLhmFzgExjXo0kHB4TOplK9TFqpfy+U9h+a6xw9LSQTYCvBglQe40w8+lUz3c3ncpKBH3s85oGFw= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=pass; spf=pass (zoho.com: domain of groups.io designates 66.175.222.12 as permitted sender) smtp.mailfrom=bounce+27952+39996+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) header.from= Received: from web01.groups.io (web01.groups.io [66.175.222.12]) by mx.zohomail.com with SMTPS id 155704274444199.02021135245195; Sun, 5 May 2019 00:52:24 -0700 (PDT) Return-Path: X-Received: from mga14.intel.com (mga14.intel.com []) by groups.io with SMTP; Sun, 05 May 2019 00:52:23 -0700 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False X-Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by fmsmga103.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 05 May 2019 00:52:23 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.60,433,1549958400"; d="scan'208";a="155041560" X-Received: from fieedk001.ccr.corp.intel.com ([10.239.33.119]) by FMSMGA003.fm.intel.com with ESMTP; 05 May 2019 00:52:20 -0700 From: "Gao, Zhichao" To: devel@edk2.groups.io Cc: Bret Barkelew , Jian J Wang , Hao Wu , Ray Ni , Star Zeng , Liming Gao , Sean Brogan , Michael Turner Subject: [edk2-devel] [PATCH 2/4] MdeModulePkg/CapsuleRuntimeDxe: Transfer reset data Date: Sun, 5 May 2019 15:50:44 +0800 Message-Id: <20190505075046.14464-3-zhichao.gao@intel.com> In-Reply-To: <20190505075046.14464-1-zhichao.gao@intel.com> References: <20190505075046.14464-1-zhichao.gao@intel.com> MIME-Version: 1.0 Precedence: Bulk List-Unsubscribe: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,zhichao.gao@intel.com Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1557042744; bh=3Q3pMa562ZWPywch58ccpLmigAWnWekXvkDQPcQ6WVs=; h=Cc:Date:From:Reply-To:Subject:To; b=o711TFgQO5yBGA4HpfP8eqC9M1+q+cRityaDogyxsXixODwIdIlNYtySaT9pdFtHbpu FJOd3dYsVp0fkeZQRisw7F3fzR3Mo2aee+LY48ETjlIRVe0nanZ7iLl9Ofeg4dEFtYwZd v8pomm4ovUerZ4gyM1JeUUQVnZ1qLnFrBQc= X-ZohoMail-DKIM: pass (identity @groups.io) Content-Type: text/plain; charset="utf-8" From: Bret Barkelew REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D1772 Transfer reset data start with a null sting and followed by gCapsuleArmedResetGuid for capsule update. Cc: Jian J Wang Cc: Hao Wu Cc: Ray Ni Cc: Star Zeng Cc: Liming Gao Cc: Sean Brogan Cc: Michael Turner Cc: Bret Barkelew Signed-off-by: Zhichao Gao --- .../Universal/CapsuleRuntimeDxe/CapsuleRuntimeDxe.inf | 1 + MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleService.c | 4 ++-- MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleService.h | 3 ++- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleRuntimeDxe.inf= b/MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleRuntimeDxe.inf index 338577e293..d80b5094d3 100644 --- a/MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleRuntimeDxe.inf +++ b/MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleRuntimeDxe.inf @@ -72,6 +72,7 @@ ## SOMETIMES_PRODUCES ## Variable:L"CapsuleLongModeBuffer" # The long = mode buffer used by IA32 Capsule PEIM to call X64 CapsuleCoalesce code to h= andle >4GB capsule blocks gEfiCapsuleVendorGuid gEfiFmpCapsuleGuid ## SOMETIMES_CONSUMES ##= GUID # FMP capsule GUID + gCapsuleArmedResetGuid ## SOMETIMES_CONSUMES =20 [Protocols] gEfiCapsuleArchProtocolGuid ## PRODUCES diff --git a/MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleService.c b/Md= eModulePkg/Universal/CapsuleRuntimeDxe/CapsuleService.c index aaf819c4c6..109541c17f 100644 --- a/MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleService.c +++ b/MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleService.c @@ -4,7 +4,7 @@ It installs the Capsule Architectural Protocol defined in PI1.0a to sign= ify the capsule runtime services are ready. =20 -Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.
+Copyright (c) 2006 - 2019, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent =20 **/ @@ -210,7 +210,7 @@ UpdateCapsule ( // will initiate a reset of the platform which is compatible with t= he passed-in capsule request and will // not return back to the caller. // - EfiResetSystem (EfiResetWarm, EFI_SUCCESS, 0, NULL); + EfiResetSystem (EfiResetWarm, EFI_SUCCESS, sizeof (RESET_DATA_WITH_= NULL_STRING), &gCapsuleArmedResetGuid); } } return Status; diff --git a/MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleService.h b/Md= eModulePkg/Universal/CapsuleRuntimeDxe/CapsuleService.h index 069df3c750..ab35f1c42e 100644 --- a/MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleService.h +++ b/MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleService.h @@ -4,7 +4,7 @@ It installs the Capsule Architectural Protocol defined in PI1.0a to sign= ify the capsule runtime services are ready. =20 - Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.
+ Copyright (c) 2006 - 2019, Intel Corporation. All rights reserved.
Copyright (c) 2018, Linaro, Ltd. All rights reserved.
=20 SPDX-License-Identifier: BSD-2-Clause-Patent @@ -19,6 +19,7 @@ #include #include #include +#include =20 #include #include --=20 2.21.0.windows.1 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#39996): https://edk2.groups.io/g/devel/message/39996 Mute This Topic: https://groups.io/mt/31507359/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- From nobody Sun May 19 17:22:30 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of groups.io designates 66.175.222.12 as permitted sender) client-ip=66.175.222.12; envelope-from=bounce+27952+39997+1787277+3901457@groups.io; helo=web01.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zoho.com: domain of groups.io designates 66.175.222.12 as permitted sender) smtp.mailfrom=bounce+27952+39997+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=intel.com ARC-Seal: i=1; a=rsa-sha256; t=1557042760; cv=none; d=zoho.com; s=zohoarc; b=OvxFzAZuIgWE+/ZZ3tpa8jy03AILCdYfxAKBAr1HydjTCRsDdIxNCpr+M+fW8Tmm/YoQQxTQ4WZqEh7Qyb74+O++ZBJXwzcz04OQhOEleVBOTWUD9jJAiUqRn30Cwk6hV87XRaeokbnACFfCVm9JTQLn9FhJPFOnjkYsHGsoOGU= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1557042760; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Id:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To:ARC-Authentication-Results; bh=YhNQlBLJhEt8AGL+CLksi0kaXcFfVCDJqf3n+XS65NY=; b=lZM+6CeqiGGUgfiC/F9Scy2HyRwJ/rK/VZRccwL976OctqCNzneC/aXIxW8F8SgXTg/qDQN7IuFzbTG2Xo+TD7RMEVwDb7KrgdYjfddS5jbAQW42W6RoCxcawt9Dc7VXdgRS8K8T7/Jj92X0D8OhyFiB7mVnYCONCDmVq6itg8c= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=pass; spf=pass (zoho.com: domain of groups.io designates 66.175.222.12 as permitted sender) smtp.mailfrom=bounce+27952+39997+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) header.from= Received: from web01.groups.io (web01.groups.io [66.175.222.12]) by mx.zohomail.com with SMTPS id 1557042760443773.38546466245; Sun, 5 May 2019 00:52:40 -0700 (PDT) Return-Path: X-Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by groups.io with SMTP; Sun, 05 May 2019 00:52:39 -0700 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False X-Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by fmsmga103.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 05 May 2019 00:52:26 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.60,433,1549958400"; d="scan'208";a="155041589" X-Received: from fieedk001.ccr.corp.intel.com ([10.239.33.119]) by FMSMGA003.fm.intel.com with ESMTP; 05 May 2019 00:52:24 -0700 From: "Gao, Zhichao" To: devel@edk2.groups.io Cc: Bret Barkelew , Jian J Wang , Hao Wu , Ray Ni , Star Zeng , Liming Gao , Sean Brogan , Michael Turner Subject: [edk2-devel] [PATCH 3/4] MdeModulePkg/CapsuleLib: Transfer reset data Date: Sun, 5 May 2019 15:50:45 +0800 Message-Id: <20190505075046.14464-4-zhichao.gao@intel.com> In-Reply-To: <20190505075046.14464-1-zhichao.gao@intel.com> References: <20190505075046.14464-1-zhichao.gao@intel.com> MIME-Version: 1.0 Precedence: Bulk List-Unsubscribe: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,zhichao.gao@intel.com Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1557042760; bh=ZJo9vfNUZuEQroiW5DfT6qRfuGnXBCnvDtNfYzxMj6Q=; h=Cc:Date:From:Reply-To:Subject:To; b=HHCWijDf1505gDztdCN78hDZMODtCRUdd+O0KTW0Rugat/bDn/z8zIE8EOWicKr/VKP Ds93kn9IYBqC38q3y5w0p3oKbHAgB0tdK1mXFKoQzVjgU4y21lEC4A+4as4ufcX5VoVGF bzQdj8Niyl9Iqjwxa8IzTJwF6hTmmwhFhNo= X-ZohoMail-DKIM: pass (identity @groups.io) Content-Type: text/plain; charset="utf-8" From: Bret Barkelew REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D1772 Transfer reset data start with a null sting and followed by gCapsuleUpdateCompleteResetGuid for capsule update. Cc: Jian J Wang Cc: Hao Wu Cc: Ray Ni Cc: Star Zeng Cc: Liming Gao Cc: Sean Brogan Cc: Michael Turner Cc: Bret Barkelew Signed-off-by: Zhichao Gao --- MdeModulePkg/Library/DxeCapsuleLibFmp/DxeCapsuleLib.inf | 3 ++- .../Library/DxeCapsuleLibFmp/DxeCapsuleProcessLib.c | 6 ++++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/MdeModulePkg/Library/DxeCapsuleLibFmp/DxeCapsuleLib.inf b/MdeM= odulePkg/Library/DxeCapsuleLibFmp/DxeCapsuleLib.inf index 14c3d19bc3..78e4958995 100644 --- a/MdeModulePkg/Library/DxeCapsuleLibFmp/DxeCapsuleLib.inf +++ b/MdeModulePkg/Library/DxeCapsuleLibFmp/DxeCapsuleLib.inf @@ -3,7 +3,7 @@ # # Capsule library instance for DXE_DRIVER module types. # -# Copyright (c) 2016 - 2018, Intel Corporation. All rights reserved.
+# Copyright (c) 2016 - 2019, Intel Corporation. All rights reserved.
# SPDX-License-Identifier: BSD-2-Clause-Patent # ## @@ -74,6 +74,7 @@ gEfiCapsuleReportGuid gEfiCapsuleVendorGuid ## SOMETIMES_CONSUMES ## Variabl= e:L"CapsuleUpdateData" gEfiEndOfDxeEventGroupGuid ## CONSUMES ## Event + gCapsuleUpdateCompleteResetGuid ## SOMETIMES_CONSUMES =20 [Depex] gEfiVariableWriteArchProtocolGuid diff --git a/MdeModulePkg/Library/DxeCapsuleLibFmp/DxeCapsuleProcessLib.c b= /MdeModulePkg/Library/DxeCapsuleLibFmp/DxeCapsuleProcessLib.c index 5e2d2b87a8..dbc4287bfa 100644 --- a/MdeModulePkg/Library/DxeCapsuleLibFmp/DxeCapsuleProcessLib.c +++ b/MdeModulePkg/Library/DxeCapsuleLibFmp/DxeCapsuleProcessLib.c @@ -9,7 +9,7 @@ ProcessCapsules(), ProcessTheseCapsules() will receive untrusted input and do basic validation. =20 - Copyright (c) 2016 - 2018, Intel Corporation. All rights reserved.
+ Copyright (c) 2016 - 2019, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent =20 **/ @@ -33,6 +33,8 @@ =20 #include =20 +#include + extern EDKII_FIRMWARE_MANAGEMENT_PROGRESS_PROTOCOL *mFmpProgress; =20 /** @@ -518,7 +520,7 @@ DoResetSystem ( =20 REPORT_STATUS_CODE(EFI_PROGRESS_CODE, (EFI_SOFTWARE | PcdGet32(PcdStatus= CodeSubClassCapsule) | PcdGet32(PcdCapsuleStatusCodeResettingSystem))); =20 - gRT->ResetSystem(EfiResetCold, EFI_SUCCESS, 0, NULL); + gRT->ResetSystem(EfiResetCold, EFI_SUCCESS, sizeof (RESET_DATA_WITH_NULL= _STRING), &gCapsuleUpdateCompleteResetGuid); =20 CpuDeadLoop(); } --=20 2.21.0.windows.1 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#39997): https://edk2.groups.io/g/devel/message/39997 Mute This Topic: https://groups.io/mt/31507360/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- From nobody Sun May 19 17:22:30 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of groups.io designates 66.175.222.12 as permitted sender) client-ip=66.175.222.12; envelope-from=bounce+27952+39998+1787277+3901457@groups.io; helo=web01.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zoho.com: domain of groups.io designates 66.175.222.12 as permitted sender) smtp.mailfrom=bounce+27952+39998+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=intel.com ARC-Seal: i=1; a=rsa-sha256; t=1557042761; cv=none; d=zoho.com; s=zohoarc; b=h98mCOzHq5hTd7QifegnbMhD4YgYxSgW5fm9P+u5lH1ZBKdsL8Gqvh1B5iUzwbQkBCoWCqLoAEtz/Mz8jOIfbp0O0V8sBt8KgSKxATMG+Whuyf3ZvDTjhtMQrEDfDDYhW0ugVZZrkOI0fSEfkhvgM1WQ6KUYc14LKva2xPdLMPA= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1557042761; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Id:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To:ARC-Authentication-Results; bh=baHwGFVfY6FaGIVetlQAKdxC8s5nLn5nOBbYXGgbpic=; b=odGQgq0eJqwbRvC1pNgifnhXpIsDw2xsHvzqSpcFscKMoA+8t/XqejP3+yHZk6lONt5axKh7qHiOkkb8NWGfaeD8sUhhwpBSh3wPc+Z1Z7qi0i6zrdYyoWRL+IsN2pYmI8nypeStRGamzVQGo5EeqhAa+ieEFjq2xhrF7L96/Bk= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=pass; spf=pass (zoho.com: domain of groups.io designates 66.175.222.12 as permitted sender) smtp.mailfrom=bounce+27952+39998+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) header.from= Received: from web01.groups.io (web01.groups.io [66.175.222.12]) by mx.zohomail.com with SMTPS id 1557042761795906.2738254877679; Sun, 5 May 2019 00:52:41 -0700 (PDT) Return-Path: X-Received: from mga14.intel.com (mga14.intel.com []) by groups.io with SMTP; Sun, 05 May 2019 00:52:40 -0700 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False X-Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by fmsmga103.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 05 May 2019 00:52:28 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.60,433,1549958400"; d="scan'208";a="155041593" X-Received: from fieedk001.ccr.corp.intel.com ([10.239.33.119]) by FMSMGA003.fm.intel.com with ESMTP; 05 May 2019 00:52:27 -0700 From: "Gao, Zhichao" To: devel@edk2.groups.io Cc: Jian J Wang , Hao Wu , Ray Ni , Star Zeng , Liming Gao , Sean Brogan , Michael Turner , Bret Barkelew Subject: [edk2-devel] [PATCH 4/4] MdeModulePkg/ResetUtilityLib: Replace the reset data difinition Date: Sun, 5 May 2019 15:50:46 +0800 Message-Id: <20190505075046.14464-5-zhichao.gao@intel.com> In-Reply-To: <20190505075046.14464-1-zhichao.gao@intel.com> References: <20190505075046.14464-1-zhichao.gao@intel.com> MIME-Version: 1.0 Precedence: Bulk List-Unsubscribe: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,zhichao.gao@intel.com Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1557042761; bh=vnNi99oLuRg5ZO0t9nIfEV31H/BtvoZ3CtHWIwEBCXM=; h=Cc:Date:From:Reply-To:Subject:To; b=uJ/aMWkFCd8g4ALPpdOe7GN84rLL8jtdJEqYFFK253YoviV/Hg+V1RkgLUFtf6krt5X 5sTqETj9VBAliJZsI/aJde6FQRaAKwh7DUhY488kTgesoYCa4wT8E4kDDkj0Mi68B0qLR I2UC2tWGS8TlAI2JvwFoWBbsi4dvutkgV+Y= X-ZohoMail-DKIM: pass (identity @groups.io) Content-Type: text/plain; charset="utf-8" REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D1772 Replace the definition of 'RESET_UTILITY_GUID_SPECIFIC_RESET_DATA' with 'RESET_DATA_WITH_NULL_STRING'. Cc: Jian J Wang Cc: Hao Wu Cc: Ray Ni Cc: Star Zeng Cc: Liming Gao Cc: Sean Brogan Cc: Michael Turner Cc: Bret Barkelew Signed-off-by: Zhichao Gao --- .../Library/ResetUtilityLib/ResetUtility.c | 16 ++++------------ 1 file changed, 4 insertions(+), 12 deletions(-) diff --git a/MdeModulePkg/Library/ResetUtilityLib/ResetUtility.c b/MdeModul= ePkg/Library/ResetUtilityLib/ResetUtility.c index 2b5af4b95a..c420e0e36a 100644 --- a/MdeModulePkg/Library/ResetUtilityLib/ResetUtility.c +++ b/MdeModulePkg/Library/ResetUtilityLib/ResetUtility.c @@ -12,15 +12,7 @@ #include #include #include - -#pragma pack(1) -typedef struct { - CHAR16 NullTerminator; - GUID ResetSubtype; -} RESET_UTILITY_GUID_SPECIFIC_RESET_DATA; -#pragma pack() - -VERIFY_SIZE_OF (RESET_UTILITY_GUID_SPECIFIC_RESET_DATA, 18); +#include =20 /** This is a shorthand helper function to reset with reset type and a subty= pe @@ -46,11 +38,11 @@ ResetSystemWithSubtype ( IN CONST GUID *ResetSubtype ) { - RESET_UTILITY_GUID_SPECIFIC_RESET_DATA ResetData; + RESET_DATA_WITH_NULL_STRING ResetData; =20 - ResetData.NullTerminator =3D CHAR_NULL; + ResetData.NullString =3D CHAR_NULL; CopyGuid ( - (GUID *)((UINT8 *)&ResetData + OFFSET_OF (RESET_UTILITY_GUID_SPECIFIC_= RESET_DATA, ResetSubtype)), + (GUID *)((UINT8 *)&ResetData + OFFSET_OF (RESET_DATA_WITH_NULL_STRING,= ResetGuid)), ResetSubtype ); =20 --=20 2.21.0.windows.1 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#39998): https://edk2.groups.io/g/devel/message/39998 Mute This Topic: https://groups.io/mt/31507361/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-