diff options
author | 2020-11-05 11:24:27 +0000 | |
---|---|---|
committer | 2020-11-15 18:24:35 +0100 | |
commit | 8a68cc0d690c9e5730d676b764c6f059343b842c (patch) | |
tree | aa4f38431a99345738a83b5b880ba2110c3be39c /tools/perf/scripts/python | |
parent | can: mcba_usb: mcba_usb_start_xmit(): first fill skb, then pass to can_put_echo_skb() (diff) | |
download | wireguard-linux-8a68cc0d690c9e5730d676b764c6f059343b842c.tar.xz wireguard-linux-8a68cc0d690c9e5730d676b764c6f059343b842c.zip |
can: peak_usb: fix potential integer overflow on shift of a int
The left shift of int 32 bit integer constant 1 is evaluated using 32 bit
arithmetic and then assigned to a signed 64 bit variable. In the case where
time_ref->adapter->ts_used_bits is 32 or more this can lead to an oveflow.
Avoid this by shifting using the BIT_ULL macro instead.
Fixes: bb4785551f64 ("can: usb: PEAK-System Technik USB adapters driver core")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Link: https://lore.kernel.org/r/20201105112427.40688-1-colin.king@canonical.com
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions