From nobody Sun May 5 09:22:14 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 1495127001675334.06267359099763; Thu, 18 May 2017 10:03:21 -0700 (PDT) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id 5A69621A1349C; Thu, 18 May 2017 10:03:15 -0700 (PDT) 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 B0DA221A13499 for ; Thu, 18 May 2017 10:03:13 -0700 (PDT) Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by fmsmga102.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 18 May 2017 10:03:13 -0700 Received: from mdkinney-mobl.amr.corp.intel.com ([10.254.56.31]) by fmsmga004.fm.intel.com with ESMTP; 18 May 2017 10:03:12 -0700 X-Original-To: edk2-devel@lists.01.org X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.38,359,1491289200"; d="scan'208";a="263642447" From: Michael Kinney To: edk2-devel@lists.01.org Date: Thu, 18 May 2017 10:03:09 -0700 Message-Id: <1495126989-21904-1-git-send-email-michael.d.kinney@intel.com> X-Mailer: git-send-email 2.6.3.windows.1 Subject: [edk2] [Patch] PcAtChipsetPkg/SerialIoLib: Remove negative value shift 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: Ruiyu Ni , Michael D Kinney , Laszlo Ersek , Andrew Fish 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" https://bugzilla.tianocore.org/show_bug.cgi?id=3D553 Remove left shift of negative values that always evaluate to 0 to address build errors from the llvm/clang compiler used in the XCODE5 tool chain. Cc: Ruiyu Ni Cc: Andrew Fish Cc: Laszlo Ersek Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Michael D Kinney Reviewed-by: Laszlo Ersek --- PcAtChipsetPkg/Library/SerialIoLib/SerialPortLib.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/PcAtChipsetPkg/Library/SerialIoLib/SerialPortLib.c b/PcAtChips= etPkg/Library/SerialIoLib/SerialPortLib.c index 95e0db7..0a2e20c 100644 --- a/PcAtChipsetPkg/Library/SerialIoLib/SerialPortLib.c +++ b/PcAtChipsetPkg/Library/SerialIoLib/SerialPortLib.c @@ -102,7 +102,7 @@ SerialPortInitialize ( // // Switch back to bank 0 // - OutputData =3D (UINT8) ((~DLAB << 7) | (gBreakSet << 6) | (gParity << 3)= | (gStop << 2) | Data); + OutputData =3D (UINT8) ( (gBreakSet << 6) | (gParity << 3) | (gStop << 2= ) | Data); IoWrite8 (gUartBase + LCR_OFFSET, OutputData); =20 return RETURN_SUCCESS; @@ -481,7 +481,7 @@ SerialPortSetAttributes ( // // Switch back to bank 0 // - OutputData =3D (UINT8) ((~DLAB << 7) | (gBreakSet << 6) | (LcrParity << = 3) | (LcrStop << 2) | LcrData); + OutputData =3D (UINT8) ((gBreakSet << 6) | (LcrParity << 3) | (LcrStop <= < 2) | LcrData); IoWrite8 (gUartBase + LCR_OFFSET, OutputData); =20 return RETURN_SUCCESS; --=20 2.6.3.windows.1 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel