From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by mx.groups.io with SMTP id smtpd.web11.7640.1581044813067425390 for ; Thu, 06 Feb 2020 19:06:53 -0800 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: intel.com, ip: 134.134.136.100, mailfrom: liming.gao@intel.com) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by orsmga105.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 06 Feb 2020 19:06:52 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.70,411,1574150400"; d="scan'208";a="264843384" Received: from fmsmsx106.amr.corp.intel.com ([10.18.124.204]) by fmsmga002.fm.intel.com with ESMTP; 06 Feb 2020 19:06:52 -0800 Received: from shsmsx603.ccr.corp.intel.com (10.109.6.143) by FMSMSX106.amr.corp.intel.com (10.18.124.204) with Microsoft SMTP Server (TLS) id 14.3.439.0; Thu, 6 Feb 2020 19:06:51 -0800 Received: from shsmsx606.ccr.corp.intel.com (10.109.6.216) by SHSMSX603.ccr.corp.intel.com (10.109.6.143) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1713.5; Fri, 7 Feb 2020 11:06:50 +0800 Received: from shsmsx606.ccr.corp.intel.com ([10.109.6.216]) by SHSMSX606.ccr.corp.intel.com ([10.109.6.216]) with mapi id 15.01.1713.004; Fri, 7 Feb 2020 11:06:50 +0800 From: "Liming Gao" To: "Fu, Siyuan" , "devel@edk2.groups.io" CC: "Wu, Hao A" Subject: Re: [Patch] MdeModulePkg/Capsule: Remove RT restriction in UpdateCapsule service. Thread-Topic: [Patch] MdeModulePkg/Capsule: Remove RT restriction in UpdateCapsule service. Thread-Index: AQHV2wQP76kqgSU9EEyMfP97x+cReKgPEOZg Date: Fri, 7 Feb 2020 03:06:49 +0000 Message-ID: References: In-Reply-To: Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-version: 11.2.0.6 dlp-product: dlpe-windows dlp-reaction: no-action x-originating-ip: [10.239.127.36] MIME-Version: 1.0 Return-Path: liming.gao@intel.com Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Siyuan: I suggest to introduce new FeaturePcd to control this behavior. And, PCD = default value is FALSE to keep current behavior without change. Thanks Liming > -----Original Message----- > From: Fu, Siyuan > Sent: Tuesday, February 4, 2020 10:37 AM > To: devel@edk2.groups.io > Cc: Wu, Hao A ; Gao, Liming > Subject: [Patch] MdeModulePkg/Capsule: Remove RT restriction in UpdateCap= sule service. >=20 > Current UpdateCapsule service will reject all non-reset capsule images an= d > return EFI_OUT_OF_RESOURCE if the system is at runtime. This will block a > platform CapsuleLib from implementing ProcessCapsuleImage() with runtime > capsule processing capability. This patch removes this restriction. >=20 > BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=3D2501 >=20 > Cc: Hao A Wu > Cc: Liming Gao > Signed-off-by: Siyuan Fu > --- > MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleService.c | 8 ++------ > 1 file changed, 2 insertions(+), 6 deletions(-) >=20 > diff --git a/MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleService.c > b/MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleService.c > index 77b8f00062..99a52f053d 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 si= gnify > the capsule runtime services are ready. >=20 > -Copyright (c) 2006 - 2019, Intel Corporation. All rights reserved.
> +Copyright (c) 2006 - 2020, Intel Corporation. All rights reserved.
> SPDX-License-Identifier: BSD-2-Clause-Patent >=20 > **/ > @@ -138,11 +138,7 @@ UpdateCapsule ( > // Platform specific update for the non-reset capsule image. > // > if ((CapsuleHeader->Flags & CAPSULE_FLAGS_PERSIST_ACROSS_RESET) =3D= =3D 0) { > - if (EfiAtRuntime ()) { > - Status =3D EFI_OUT_OF_RESOURCES; > - } else { > - Status =3D ProcessCapsuleImage(CapsuleHeader); > - } > + Status =3D ProcessCapsuleImage(CapsuleHeader); > if (EFI_ERROR(Status)) { > return Status; > } > -- > 2.19.1.windows.1