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.136; helo=mga12.intel.com; envelope-from=jian.j.wang@intel.com; receiver=edk2-devel-bounces@lists.01.org Received: from mga12.intel.com (mga12.intel.com [192.55.52.136]) (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 3500321125487; Fri, 7 Sep 2018 20:24:42 -0700 (PDT) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by fmsmga106.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 07 Sep 2018 20:24:42 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.53,344,1531810800"; d="scan'208";a="260862605" Received: from fmsmsx104.amr.corp.intel.com ([10.18.124.202]) by fmsmga005.fm.intel.com with ESMTP; 07 Sep 2018 20:24:42 -0700 Received: from fmsmsx157.amr.corp.intel.com (10.18.116.73) by fmsmsx104.amr.corp.intel.com (10.18.124.202) with Microsoft SMTP Server (TLS) id 14.3.319.2; Fri, 7 Sep 2018 20:24:42 -0700 Received: from shsmsx101.ccr.corp.intel.com (10.239.4.153) by FMSMSX157.amr.corp.intel.com (10.18.116.73) with Microsoft SMTP Server (TLS) id 14.3.319.2; Fri, 7 Sep 2018 20:24:41 -0700 Received: from shsmsx103.ccr.corp.intel.com ([169.254.4.240]) by SHSMSX101.ccr.corp.intel.com ([169.254.1.205]) with mapi id 14.03.0319.002; Sat, 8 Sep 2018 11:24:39 +0800 From: "Wang, Jian J" To: edk2-devel , "edk2-devel@lists.01.org" CC: "Wu, Hao A" Thread-Topic: [edk2] [PATCH] UefiCpuPkg/CpuDxe: fix an incorrect bit-wise operation Thread-Index: AQHURx5qN2wAIicRAEG+UKaCfuN6UKTluJIg Date: Sat, 8 Sep 2018 03:24:39 +0000 Message-ID: References: <20180908024802.13488-1-jian.j.wang@intel.com> In-Reply-To: <20180908024802.13488-1-jian.j.wang@intel.com> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiNjc1NDk3YmEtOGZlOC00YWY5LTg1MzktNTFiYzJjNmE1M2JiIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX05UIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjEwLjE4MDQuNDkiLCJUcnVzdGVkTGFiZWxIYXNoIjoiUUEwZytDVFwvSklvQ1pvb0dCZkYyeWJkZyttc3hZOG53RFA3UGdmRDIxMWJ6ZzNrV21kWURxc1JxTGNUb2djTkoifQ== x-ctpclassification: CTP_NT dlp-product: dlpe-windows dlp-version: 11.0.400.15 dlp-reaction: no-action x-originating-ip: [10.239.127.40] MIME-Version: 1.0 Subject: Re: [PATCH] UefiCpuPkg/CpuDxe: fix an incorrect bit-wise operation 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: Sat, 08 Sep 2018 03:24:43 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Forgot to mention BZ info: https://bugzilla.tianocore.org/show_bug.cgi?id=3D1095 Regards, Jian > -----Original Message----- > From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] > Sent: Saturday, September 08, 2018 10:48 AM > To: edk2-devel@lists.01.org > Cc: Wu, Hao A > Subject: [edk2] [PATCH] UefiCpuPkg/CpuDxe: fix an incorrect bit-wise oper= ation >=20 > The left operand is 64-bit but right operand could be 32-bit. > A typecast is a must because of '~' op before it. >=20 > Cc: Hao A Wu > Contributed-under: TianoCore Contribution Agreement 1.1 > Signed-off-by: Jian J Wang > --- > UefiCpuPkg/CpuDxe/CpuPageTable.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) >=20 > diff --git a/UefiCpuPkg/CpuDxe/CpuPageTable.c > b/UefiCpuPkg/CpuDxe/CpuPageTable.c > index ef6e080a07..0a980b9753 100644 > --- a/UefiCpuPkg/CpuDxe/CpuPageTable.c > +++ b/UefiCpuPkg/CpuDxe/CpuPageTable.c > @@ -1181,7 +1181,7 @@ DebugExceptionHandler ( >=20 > for (PFEntry =3D 0; PFEntry < mPFEntryCount[CpuIndex]; PFEntry++) { > if (mLastPFEntryPointer[CpuIndex][PFEntry] !=3D NULL) { > - *mLastPFEntryPointer[CpuIndex][PFEntry] &=3D ~IA32_PG_P; > + *mLastPFEntryPointer[CpuIndex][PFEntry] &=3D ~(UINT64)IA32_PG_P; > } > } >=20 > -- > 2.16.2.windows.1 >=20 > _______________________________________________ > edk2-devel mailing list > edk2-devel@lists.01.org > https://lists.01.org/mailman/listinfo/edk2-devel