aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--net/openvswitch/datapath.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/net/openvswitch/datapath.c b/net/openvswitch/datapath.c
index 7228ec3faf19..35d866f036e7 100644
--- a/net/openvswitch/datapath.c
+++ b/net/openvswitch/datapath.c
@@ -404,7 +404,7 @@ static int queue_userspace_packet(struct datapath *dp, struct sk_buff *skb,
404{ 404{
405 struct ovs_header *upcall; 405 struct ovs_header *upcall;
406 struct sk_buff *nskb = NULL; 406 struct sk_buff *nskb = NULL;
407 struct sk_buff *user_skb; /* to be queued to userspace */ 407 struct sk_buff *user_skb = NULL; /* to be queued to userspace */
408 struct nlattr *nla; 408 struct nlattr *nla;
409 struct genl_info info = { 409 struct genl_info info = {
410 .dst_sk = ovs_dp_get_net(dp)->genl_sock, 410 .dst_sk = ovs_dp_get_net(dp)->genl_sock,
@@ -494,9 +494,11 @@ static int queue_userspace_packet(struct datapath *dp, struct sk_buff *skb,
494 ((struct nlmsghdr *) user_skb->data)->nlmsg_len = user_skb->len; 494 ((struct nlmsghdr *) user_skb->data)->nlmsg_len = user_skb->len;
495 495
496 err = genlmsg_unicast(ovs_dp_get_net(dp), user_skb, upcall_info->portid); 496 err = genlmsg_unicast(ovs_dp_get_net(dp), user_skb, upcall_info->portid);
497 user_skb = NULL;
497out: 498out:
498 if (err) 499 if (err)
499 skb_tx_error(skb); 500 skb_tx_error(skb);
501 kfree_skb(user_skb);
500 kfree_skb(nskb); 502 kfree_skb(nskb);
501 return err; 503 return err;
502} 504}