mirror of https://gitee.com/openkylin/linux.git
ip6tnl: fix sparse warnings in ip6_tnl_netlink_parms()
This change fixes a sparse warning triggered by casting the flowinfo from netlink messages in an u32 instead of be32. This change corrects that in order to resolve the sparse warning. Reported-by: Fengguang Wu <fengguang.wu@intel.com> Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
d440b72068
commit
1ff05fb711
|
@ -1568,7 +1568,7 @@ static void ip6_tnl_netlink_parms(struct nlattr *data[],
|
|||
parms->encap_limit = nla_get_u8(data[IFLA_IPTUN_ENCAP_LIMIT]);
|
||||
|
||||
if (data[IFLA_IPTUN_FLOWINFO])
|
||||
parms->flowinfo = nla_get_u32(data[IFLA_IPTUN_FLOWINFO]);
|
||||
parms->flowinfo = nla_get_be32(data[IFLA_IPTUN_FLOWINFO]);
|
||||
|
||||
if (data[IFLA_IPTUN_FLAGS])
|
||||
parms->flags = nla_get_u32(data[IFLA_IPTUN_FLAGS]);
|
||||
|
|
Loading…
Reference in New Issue