From mboxrd@z Thu Jan 1 00:00:00 1970 Subject: Re: [edk2-devel] [PATCH 5/5] StandaloneMmPkg/StandaloneMmCoreEntryPoint: relocate StMM core on the fly To: Ard Biesheuvel ,devel@edk2.groups.io From: "Sami Mujawar" X-Originating-Location: Fremont, California, US (217.140.99.251) X-Originating-Platform: Windows Firefox 77 User-Agent: GROUPS.IO Web Poster MIME-Version: 1.0 Date: Mon, 15 Jun 2020 07:40:43 -0700 References: <75f6a173-239e-bf3f-3394-22fef4a030c1@arm.com> In-Reply-To: <75f6a173-239e-bf3f-3394-22fef4a030c1@arm.com> Message-ID: <30869.1592232043589643915@groups.io> Content-Type: multipart/alternative; boundary="9DtwYV1xpdZLeXl2tmfK" --9DtwYV1xpdZLeXl2tmfK Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable On Mon, Jun 15, 2020 at 07:12 AM, Ard Biesheuvel wrote: >=20 >=20 >> On Wed, Jun 10, 2020 at 01:17 AM, Ard Biesheuvel wrote: >> + *ImageBase =3D3D ImageContext->ImageAddress;=3D0D >> I think the '*ImageBase =3D ImageContext->ImageAddress;' statement can = be >> moved inside the if condition. >=20 > No, the TE branch of the if() does a subtraction so it needs the value t= o > be set beforehand. Sorry, I missed the -=3D. Please ignore. Regards, Sami Mujawar --9DtwYV1xpdZLeXl2tmfK Content-Type: text/html; charset="utf-8" Content-Transfer-Encoding: quoted-printable On Mon, Jun 15, 2020 at 07:12 AM, Ard Biesheuvel wrote:
On Wed, Jun 10, 2020 at 01:17 AM, Ard Biesheuvel wrote:
+= *ImageBase =3D3D ImageContext->ImageAddress;=3D0D
I think the '*Im= ageBase =3D ImageContext->ImageAddress;' statement can be moved inside t= he if condition.
No, the TE branch of the if() does a subtraction so it needs the value to = be set beforehand.
Sorry, I missed the -=3D. Please ignore.

Regards,

Sa= mi Mujawar
--9DtwYV1xpdZLeXl2tmfK--