audk/PcAtChipsetPkg
Michael Kinney bbd61de5db PcAtChipsetPkg/SerialIoLib: Remove negative value shift
https://bugzilla.tianocore.org/show_bug.cgi?id=553

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.

Clang rightfully complains about left-shifting ~DLAB. DLAB is #defined
as 0x01 (an "int"), hence ~DLAB has value (-2) on all edk2 platforms.
Left-shifting a negative int is undefined behavior.

Rather than replacing ~DLAB with ~(UINT32)DLAB, realize that the nonzero
bits of (~(UINT32)DLAB << 7) would all be truncated away in the final
conversion to UINT8 anyway. So just remove (~DLAB << 7).

Cc: Ruiyu Ni <ruiyu.ni@intel.com>
Cc: Andrew Fish <afish@apple.com>
Cc: Laszlo Ersek <lersek@redhat.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Michael D Kinney <michael.d.kinney@intel.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
2017-05-19 12:12:06 -07:00
..
8254TimerDxe PcAtChipsetPkg: Fix typing errors 2017-01-20 08:50:09 +08:00
8259InterruptControllerDxe PcAtChipsetPkg: Fix typing errors 2017-01-20 08:50:09 +08:00
Bus/Pci/IdeControllerDxe PcAtChipsetPkg: Fix typing errors 2017-01-20 08:50:09 +08:00
HpetTimerDxe PcAtChipsetPkg: Fix typing errors 2017-01-20 08:50:09 +08:00
Include
IsaAcpiDxe PcAtChipsetPkg: Fix typing errors 2017-01-20 08:50:09 +08:00
Library PcAtChipsetPkg/SerialIoLib: Remove negative value shift 2017-05-19 12:12:06 -07:00
PcatRealTimeClockRuntimeDxe PcAtChipsetPkg/PcRtc: Fix bad EOL 2016-12-06 17:07:47 +08:00
Contributions.txt
License.txt
PcAtChipsetPkg.dec PcAtChipsetPkg: Add two PCDs for Reset Control Register and Value 2016-06-28 10:08:58 +08:00
PcAtChipsetPkg.dsc PcAtChipsetPkg: Remove KbcResetDxe 2016-09-02 10:07:17 +08:00
PcAtChipsetPkg.uni PcAtChipsetPkg: Add two PCDs for Reset Control Register and Value 2016-06-28 10:08:58 +08:00
PcAtChipsetPkgExtra.uni PcAtChipsetPkg: Convert all .uni files to utf-8 2015-12-15 04:57:25 +00:00