summaryrefslogtreecommitdiff
path: root/drivers/net/vxlan.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/vxlan.c')
-rw-r--r--drivers/net/vxlan.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/net/vxlan.c b/drivers/net/vxlan.c
index 25b70cad055c..4e1d427d340c 100644
--- a/drivers/net/vxlan.c
+++ b/drivers/net/vxlan.c
@@ -1584,10 +1584,8 @@ static struct sk_buff *vxlan_na_create(struct sk_buff *request,
skb_pull(reply, sizeof(struct ipv6hdr));
skb_reset_transport_header(reply);
- na = (struct nd_msg *)skb_put(reply, sizeof(*na) + na_olen);
-
/* Neighbor Advertisement */
- memset(na, 0, sizeof(*na)+na_olen);
+ na = skb_put_zero(reply, sizeof(*na) + na_olen);
na->icmph.icmp6_type = NDISC_NEIGHBOUR_ADVERTISEMENT;
na->icmph.icmp6_router = isrouter;
na->icmph.icmp6_override = 1;