From nobody Sat Nov 2 10:31:23 2024 Delivered-To: importer@patchew.org Received-SPF: none (zoho.com: 198.145.21.10 is neither permitted nor denied by domain of lists.01.org) client-ip=198.145.21.10; envelope-from=edk2-devel-bounces@lists.01.org; helo=ml01.01.org; Authentication-Results: mx.zoho.com; spf=none (zoho.com: 198.145.21.10 is neither permitted nor denied by domain of lists.01.org) smtp.mailfrom=edk2-devel-bounces@lists.01.org; Return-Path: Received: from ml01.01.org (ml01.01.org [198.145.21.10]) by mx.zohomail.com with SMTPS id 1491876889865150.15202528070688; Mon, 10 Apr 2017 19:14:49 -0700 (PDT) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id 1025C21A04802; Mon, 10 Apr 2017 19:14:18 -0700 (PDT) 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 4832E21A18AAA for ; Mon, 10 Apr 2017 19:14:16 -0700 (PDT) Received: from orsmga001.jf.intel.com ([10.7.209.18]) by fmsmga103.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 10 Apr 2017 19:14:15 -0700 Received: from shwdeopenpsi014.ccr.corp.intel.com ([10.239.9.13]) by orsmga001.jf.intel.com with ESMTP; 10 Apr 2017 19:14:14 -0700 X-Original-To: edk2-devel@lists.01.org DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=intel.com; i=@intel.com; q=dns/txt; s=intel; t=1491876856; x=1523412856; h=from:to:cc:subject:date:message-id; bh=ltSjh9hRnnXzwO1gz/cid+J7qLowEQX4dDO7p1/mk5E=; b=qqyUVLUbJZO4INqk9o2adzYbUFFgwWex3BnlwkWyATU//xIAJK2WZZjY N7vdO+9pQSG9HogdanHSxTN4gFmolg==; X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.37,184,1488873600"; d="scan'208";a="1117993307" From: Hao Wu To: edk2-devel@lists.01.org Date: Tue, 11 Apr 2017 10:14:07 +0800 Message-Id: <20170411021407.14312-1-hao.a.wu@intel.com> X-Mailer: git-send-email 2.12.0.windows.1 Subject: [edk2] [PATCH] MdeModulePkg/Dxe/Image: Restore mCurrentImage on all paths X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Hao Wu , Liming Gao MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Errors-To: edk2-devel-bounces@lists.01.org Sender: "edk2-devel" X-ZohoMail: RSF_4 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" This commit makes sure that in function CoreStartImage(), module variable 'mCurrentImage' is restored to the current start image context on all code paths. Cc: Liming Gao Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Hao Wu Reviewed-by: Liming Gao --- MdeModulePkg/Core/Dxe/Image/Image.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/MdeModulePkg/Core/Dxe/Image/Image.c b/MdeModulePkg/Core/Dxe/Im= age/Image.c index 93720c85cb..03e979a604 100644 --- a/MdeModulePkg/Core/Dxe/Image/Image.c +++ b/MdeModulePkg/Core/Dxe/Image/Image.c @@ -1647,6 +1647,12 @@ CoreStartImage ( // PERF_START (NULL, "StartImage:", NULL, Tick); PERF_END (NULL, "StartImage:", NULL, 0); + + // + // Pop the current start image context + // + mCurrentImage =3D LastImage; + return EFI_OUT_OF_RESOURCES; } Image->JumpContext =3D ALIGN_POINTER (Image->JumpBuffer, BASE_LIBRARY_JU= MP_BUFFER_ALIGNMENT); --=20 2.12.0.windows.1 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel