mirror of https://gitee.com/openkylin/linux.git
13ffe9a26d
The current shift of st->rx[2] left shifts a u8 24 bits left,
promotes the integer to a an int and then to a unsigned u64. If
the top bit of st->rx[2] is set then we end up with all the upper
bits being set to 1. Fix this by casting st->rx[2] to a u64 before
the 24 bit left shift.
Detected by CoverityScan CID#144940 ("Unintended sign extension")
Fixes:
|
||
---|---|---|
.. | ||
Documentation | ||
accel | ||
adc | ||
addac | ||
cdc | ||
frequency | ||
gyro | ||
impedance-analyzer | ||
light | ||
meter | ||
resolver | ||
trigger | ||
Kconfig | ||
Makefile | ||
TODO |