Acked-by: Jarno Rajahalme <ja...@ovn.org> > On Jun 22, 2016, at 6:00 PM, Joe Stringer <j...@ovn.org> wrote: > > From: "Eric W. Biederman" <ebied...@xmission.com> > > Upstream commit: > openvswitch: Pass net into ovs_fragment > > In preparation for the ipv4 and ipv6 fragmentation code taking a net > parameter pass a struct net into ovs_fragment where the v4 and v6 > fragmentation code is called. > > Signed-off-by: "Eric W. Biederman" <ebied...@xmission.com> > > Upstream: c559cd3ad32b ("openvswitch: Pass net into ovs_fragment") > Signed-off-by: Joe Stringer <j...@ovn.org> > --- > datapath/actions.c | 7 ++++--- > 1 file changed, 4 insertions(+), 3 deletions(-) > > diff --git a/datapath/actions.c b/datapath/actions.c > index 117bdae21b62..7f439f471104 100644 > --- a/datapath/actions.c > +++ b/datapath/actions.c > @@ -681,8 +681,8 @@ static void prepare_frag(struct vport *vport, struct > sk_buff *skb) > skb_pull(skb, hlen); > } > > -static void ovs_fragment(struct vport *vport, struct sk_buff *skb, u16 mru, > - __be16 ethertype) > +static void ovs_fragment(struct net *net, struct vport *vport, > + struct sk_buff *skb, u16 mru, __be16 ethertype) > { > if (skb_network_offset(skb) > MAX_L2_LEN) { > OVS_NLERR(1, "L2 header too long to fragment"); > @@ -748,6 +748,7 @@ static void do_output(struct datapath *dp, struct sk_buff > *skb, int out_port, > if (likely(!mru || (skb->len <= mru + ETH_HLEN))) { > ovs_vport_send(vport, skb); > } else if (mru <= vport->dev->mtu) { > + struct net *net = ovs_dp_get_net(dp); > __be16 ethertype = key->eth.type; > > if (!is_flow_key_valid(key)) { > @@ -757,7 +758,7 @@ static void do_output(struct datapath *dp, struct sk_buff > *skb, int out_port, > ethertype = vlan_get_protocol(skb); > } > > - ovs_fragment(vport, skb, mru, ethertype); > + ovs_fragment(net, vport, skb, mru, ethertype); > } else { > OVS_NLERR(true, "Cannot fragment IP frames"); > kfree_skb(skb); > -- > 2.8.2 > > _______________________________________________ > dev mailing list > dev@openvswitch.org > http://openvswitch.org/mailman/listinfo/dev
_______________________________________________ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev