aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/scripts/generate_rust_analyzer.py
diff options
context:
space:
mode:
authorFelix Riemann <felix.riemann@sma.de>2023-02-10 13:36:44 +0100
committerDavid S. Miller <davem@davemloft.net>2023-02-13 09:53:25 +0000
commit9b55d3f0a69af649c62cbc2633e6d695bb3cc583 (patch)
tree58706818f76fa04d27f5c8523537021bcc6d3dea /scripts/generate_rust_analyzer.py
parentnet/usb: kalmia: Don't pass act_len in usb_bulk_msg error path (diff)
downloadwireguard-linux-9b55d3f0a69af649c62cbc2633e6d695bb3cc583.tar.xz
wireguard-linux-9b55d3f0a69af649c62cbc2633e6d695bb3cc583.zip
net: Fix unwanted sign extension in netdev_stats_to_stats64()
When converting net_device_stats to rtnl_link_stats64 sign extension is triggered on ILP32 machines as 6c1c509778 changed the previous "ulong -> u64" conversion to "long -> u64" by accessing the net_device_stats fields through a (signed) atomic_long_t. This causes for example the received bytes counter to jump to 16EiB after having received 2^31 bytes. Casting the atomic value to "unsigned long" beforehand converting it into u64 avoids this. Fixes: 6c1c5097781f ("net: add atomic_long_t to net_device_stats fields") Signed-off-by: Felix Riemann <felix.riemann@sma.de> Reviewed-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'scripts/generate_rust_analyzer.py')
0 files changed, 0 insertions, 0 deletions