Skip to content

Commit 60d9d4c

Browse files
Pravin B Shelarshemminger
authored andcommitted
vxlan: Fix sparse warnings.
Fix following sparse warnings. drivers/net/vxlan.c:238:44: warning: incorrect type in argument 3 (different base types) drivers/net/vxlan.c:238:44: expected restricted __be32 [usertype] value drivers/net/vxlan.c:238:44: got unsigned int const [unsigned] [usertype] remote_vni drivers/net/vxlan.c:1735:18: warning: incorrect type in initializer (different signedness) drivers/net/vxlan.c:1735:18: expected int *id drivers/net/vxlan.c:1735:18: got unsigned int static [toplevel] *<noident> Signed-off-by: Pravin B Shelar <[email protected]> Signed-off-by: Stephen Hemminger <[email protected]>
1 parent 234f5b7 commit 60d9d4c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

drivers/net/vxlan.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ static bool log_ecn_error = true;
7878
module_param(log_ecn_error, bool, 0644);
7979
MODULE_PARM_DESC(log_ecn_error, "Log packets received with corrupted ECN");
8080

81-
static unsigned int vxlan_net_id;
81+
static int vxlan_net_id;
8282

8383
/* per UDP socket information */
8484
struct vxlan_sock {
@@ -250,7 +250,7 @@ static int vxlan_fdb_info(struct sk_buff *skb, struct vxlan_dev *vxlan,
250250
nla_put_be16(skb, NDA_PORT, rdst->remote_port))
251251
goto nla_put_failure;
252252
if (rdst->remote_vni != vxlan->default_dst.remote_vni &&
253-
nla_put_be32(skb, NDA_VNI, rdst->remote_vni))
253+
nla_put_u32(skb, NDA_VNI, rdst->remote_vni))
254254
goto nla_put_failure;
255255
if (rdst->remote_ifindex &&
256256
nla_put_u32(skb, NDA_IFINDEX, rdst->remote_ifindex))

0 commit comments

Comments
 (0)