From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=192.55.52.115; helo=mga14.intel.com; envelope-from=zhichao.gao@intel.com; receiver=edk2-devel@lists.01.org Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 68B0F211E3490 for ; Thu, 21 Mar 2019 20:09:15 -0700 (PDT) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga007.jf.intel.com ([10.7.209.58]) by fmsmga103.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 21 Mar 2019 20:09:15 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.60,255,1549958400"; d="scan'208";a="124829529" Received: from gaozhic-mobl.ccr.corp.intel.com ([10.239.196.107]) by orsmga007.jf.intel.com with ESMTP; 21 Mar 2019 20:09:13 -0700 From: Zhichao Gao To: edk2-devel@lists.01.org Cc: Jian J Wang , Hao Wu , Ray Ni , Star Zeng , Liming Gao Date: Fri, 22 Mar 2019 11:07:18 +0800 Message-Id: <20190322030718.17676-3-zhichao.gao@intel.com> X-Mailer: git-send-email 2.16.2.windows.1 In-Reply-To: <20190322030718.17676-1-zhichao.gao@intel.com> References: <20190322030718.17676-1-zhichao.gao@intel.com> Subject: [PATCH V2 2/2] MdeModulePkg/ResetSystemRuntimeDxe: Remove DoS3 in warm reset X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 22 Mar 2019 03:09:15 -0000 BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=1462 Original logic is that checking the CapsuleUpdate variable and do the EnterS3WithImmediateWake if the system require a capsule update. The EnterS3WithImmediateWake is usually implemented in Platform ResetSystemLib instance and it may do some operation for capsule update. For now, thess preparations of capsule are platform reset notify functions' duty. Most platforms need flush cache to memory before warm reset during capsule update and this operation is added to capsule flow. So it is safe to remove it and do not affect the capsule update function. Change-Id: I7af8221528c7baee6d16daee79837c7e9584b232 Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Zhichao Gao Cc: Jian J Wang Cc: Hao Wu Cc: Ray Ni Cc: Star Zeng Cc: Liming Gao --- .../Universal/ResetSystemRuntimeDxe/ResetSystem.c | 38 ---------------------- 1 file changed, 38 deletions(-) diff --git a/MdeModulePkg/Universal/ResetSystemRuntimeDxe/ResetSystem.c b/MdeModulePkg/Universal/ResetSystemRuntimeDxe/ResetSystem.c index 4c7107faea..36234f4d5b 100644 --- a/MdeModulePkg/Universal/ResetSystemRuntimeDxe/ResetSystem.c +++ b/MdeModulePkg/Universal/ResetSystemRuntimeDxe/ResetSystem.c @@ -206,22 +206,6 @@ InitializeResetSystem ( return Status; } -/** - Put the system into S3 power state. -**/ -VOID -DoS3 ( - VOID - ) -{ - EnterS3WithImmediateWake (); - - // - // Should not return - // - CpuDeadLoop (); -} - /** Resets the entire platform. @@ -249,9 +233,6 @@ RuntimeServiceResetSystem ( IN VOID *ResetData OPTIONAL ) { - EFI_STATUS Status; - UINTN Size; - UINTN CapsuleDataPtr; LIST_ENTRY *Link; RESET_NOTIFY_ENTRY *Entry; @@ -315,25 +296,6 @@ RuntimeServiceResetSystem ( switch (ResetType) { case EfiResetWarm: - // - //Check if there are pending capsules to process - // - Size = sizeof (CapsuleDataPtr); - Status = EfiGetVariable ( - EFI_CAPSULE_VARIABLE_NAME, - &gEfiCapsuleVendorGuid, - NULL, - &Size, - (VOID *) &CapsuleDataPtr - ); - - if (Status == EFI_SUCCESS) { - // - //Process capsules across a system reset. - // - DoS3(); - } - ResetWarm (); break; -- 2.16.2.windows.1