From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) (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 507CE2195407C for ; Mon, 24 Apr 2017 02:35:20 -0700 (PDT) Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga102.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 24 Apr 2017 02:35:20 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.37,244,1488873600"; d="scan'208";a="1139378700" Received: from fmsmsx106.amr.corp.intel.com ([10.18.124.204]) by fmsmga001.fm.intel.com with ESMTP; 24 Apr 2017 02:35:19 -0700 Received: from fmsmsx152.amr.corp.intel.com (10.18.125.5) by FMSMSX106.amr.corp.intel.com (10.18.124.204) with Microsoft SMTP Server (TLS) id 14.3.319.2; Mon, 24 Apr 2017 02:35:19 -0700 Received: from shsmsx151.ccr.corp.intel.com (10.239.6.50) by FMSMSX152.amr.corp.intel.com (10.18.125.5) with Microsoft SMTP Server (TLS) id 14.3.319.2; Mon, 24 Apr 2017 02:35:18 -0700 Received: from shsmsx102.ccr.corp.intel.com ([169.254.2.246]) by SHSMSX151.ccr.corp.intel.com ([169.254.3.224]) with mapi id 14.03.0319.002; Mon, 24 Apr 2017 17:35:15 +0800 From: "Zeng, Star" To: "Gao, Liming" , "edk2-devel@lists.01.org" CC: "Zeng, Star" Thread-Topic: [Patch] MdeModulePkg: Update PiSmmCore to set correct ImageAddress into LoadedImage Thread-Index: AQHSvNjQC/Huyx6MPEe46g5MduqaTqHUQm7g Date: Mon, 24 Apr 2017 09:35:15 +0000 Message-ID: <0C09AFA07DD0434D9E2A0C6AEB0483103B87DD8D@shsmsx102.ccr.corp.intel.com> References: <1493024234-16944-1-git-send-email-liming.gao@intel.com> In-Reply-To: <1493024234-16944-1-git-send-email-liming.gao@intel.com> Accept-Language: zh-CN, en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.127.40] MIME-Version: 1.0 Subject: Re: [Patch] MdeModulePkg: Update PiSmmCore to set correct ImageAddress into LoadedImage 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: , X-List-Received-Date: Mon, 24 Apr 2017 09:35:20 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Reviewed-by: Star Zeng Thanks, Star -----Original Message----- From: Gao, Liming=20 Sent: Monday, April 24, 2017 4:57 PM To: edk2-devel@lists.01.org Cc: Zeng, Star Subject: [Patch] MdeModulePkg: Update PiSmmCore to set correct ImageAddress= into LoadedImage Cc: Star Zeng Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Liming Gao --- MdeModulePkg/Core/PiSmmCore/Dispatcher.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/MdeModulePkg/Core/PiSmmCore/Dispatcher.c b/MdeModulePkg/Core/P= iSmmCore/Dispatcher.c index b2a6822..f32bbbd 100644 --- a/MdeModulePkg/Core/PiSmmCore/Dispatcher.c +++ b/MdeModulePkg/Core/PiSmmCore/Dispatcher.c @@ -596,7 +596,7 @@ SmmLoadImage ( } CopyMem (DriverEntry->LoadedImage->FilePath, FilePath, GetDevicePathSize= (FilePath)); =20 - DriverEntry->LoadedImage->ImageBase =3D (VOID *)(UINTN)DriverEntry->= ImageBuffer; + DriverEntry->LoadedImage->ImageBase =3D (VOID *)(UINTN) ImageContext= .ImageAddress; DriverEntry->LoadedImage->ImageSize =3D ImageContext.ImageSize; DriverEntry->LoadedImage->ImageCodeType =3D EfiRuntimeServicesCode; DriverEntry->LoadedImage->ImageDataType =3D EfiRuntimeServicesData; @@ -= 615,7 +615,7 @@ SmmLoadImage ( } CopyMem (DriverEntry->SmmLoadedImage.FilePath, FilePath, GetDevicePathSi= ze(FilePath)); =20 - DriverEntry->SmmLoadedImage.ImageBase =3D (VOID *)(UINTN)DriverEntry->Im= ageBuffer; + DriverEntry->SmmLoadedImage.ImageBase =3D (VOID *)(UINTN)=20 + ImageContext.ImageAddress; DriverEntry->SmmLoadedImage.ImageSize =3D ImageContext.ImageSize; DriverEntry->SmmLoadedImage.ImageCodeType =3D EfiRuntimeServicesCode; DriverEntry->SmmLoadedImage.ImageDataType =3D EfiRuntimeServicesData; -- 2.8.0.windows.1