diff options
author | David S. Miller <davem@davemloft.net> | 2017-08-21 17:06:42 -0700 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2017-08-21 17:06:42 -0700 |
commit | e2a7c34fb2856fd5306e307e170e3dde358d0dce (patch) | |
tree | afeb300b04186b1a1f649b2cd8a401a75878297c /net/openvswitch/datapath.c | |
parent | 7d3f0cd43feea1636dd7746f22fe8249b34d1b79 (diff) | |
parent | 6470812e22261d2342ef1597be62e63a0423d691 (diff) | |
download | op-kernel-dev-e2a7c34fb2856fd5306e307e170e3dde358d0dce.zip op-kernel-dev-e2a7c34fb2856fd5306e307e170e3dde358d0dce.tar.gz |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Diffstat (limited to 'net/openvswitch/datapath.c')
-rw-r--r-- | net/openvswitch/datapath.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/net/openvswitch/datapath.c b/net/openvswitch/datapath.c index f6e229b..76cf273 100644 --- a/net/openvswitch/datapath.c +++ b/net/openvswitch/datapath.c @@ -367,7 +367,7 @@ static int queue_gso_packets(struct datapath *dp, struct sk_buff *skb, } static size_t upcall_msg_size(const struct dp_upcall_info *upcall_info, - unsigned int hdrlen) + unsigned int hdrlen, int actions_attrlen) { size_t size = NLMSG_ALIGN(sizeof(struct ovs_header)) + nla_total_size(hdrlen) /* OVS_PACKET_ATTR_PACKET */ @@ -384,7 +384,7 @@ static size_t upcall_msg_size(const struct dp_upcall_info *upcall_info, /* OVS_PACKET_ATTR_ACTIONS */ if (upcall_info->actions_len) - size += nla_total_size(upcall_info->actions_len); + size += nla_total_size(actions_attrlen); /* OVS_PACKET_ATTR_MRU */ if (upcall_info->mru) @@ -451,7 +451,8 @@ static int queue_userspace_packet(struct datapath *dp, struct sk_buff *skb, else hlen = skb->len; - len = upcall_msg_size(upcall_info, hlen - cutlen); + len = upcall_msg_size(upcall_info, hlen - cutlen, + OVS_CB(skb)->acts_origlen); user_skb = genlmsg_new(len, GFP_ATOMIC); if (!user_skb) { err = -ENOMEM; |