ip: silence udp zerocopy smatch false positive
authorWillem de Bruijn <willemb@google.com>
Sat, 8 Dec 2018 11:22:46 +0000 (06:22 -0500)
committerDavid S. Miller <davem@davemloft.net>
Sat, 8 Dec 2018 20:26:20 +0000 (12:26 -0800)
commit97ef7b4c5501b081c6144a08bba6d87baf69b6e5
tree0162a188876cd854112e5416d63f79c95721bd46
parent83af01ba1c2d38d3075b38af2a2116eb1ebe67e6
ip: silence udp zerocopy smatch false positive

extra_uref is used in __ip(6)_append_data only if uarg is set.

Smatch sees that the variable is passed to sock_zerocopy_put_abort.
This function accesses it only when uarg is set, but smatch cannot
infer this.

Make this dependency explicit.

Fixes: 52900d22288e ("udp: elide zerocopy operation in hot path")
Signed-off-by: Willem de Bruijn <willemb@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/ip_output.c
net/ipv6/ip6_output.c