Re: [PATCH net-next v2 1/3] openvswitch: normalize vlan rx path

2016-10-05 Thread Jiri Benc
On Wed, 5 Oct 2016 15:21:32 -0400, Eric Garver wrote: > How about this incremental change? Feel free to submit it as a standalone patch. It has nothing to do with this patchset. In this particular regard, the code is identical before and after the patchset and is in no way altered by this patch.

Re: [PATCH net-next v2 1/3] openvswitch: normalize vlan rx path

2016-10-05 Thread Eric Garver
On Wed, Oct 05, 2016 at 09:07:09PM +0200, Jiri Benc wrote: > On Wed, 5 Oct 2016 14:44:26 -0400, Eric Garver wrote: > > On Wed, Oct 05, 2016 at 08:31:52PM +0300, Eyal Birger wrote: > > > Just seemed less future safe to keep a pointer to an old packet lying > > > around. > > > > I agree. Alternativ

Re: [PATCH net-next v2 1/3] openvswitch: normalize vlan rx path

2016-10-05 Thread Jiri Benc
On Wed, 5 Oct 2016 14:44:26 -0400, Eric Garver wrote: > On Wed, Oct 05, 2016 at 08:31:52PM +0300, Eyal Birger wrote: > > Just seemed less future safe to keep a pointer to an old packet lying > > around. > > I agree. Alternatively refresh the eth pointer. Sorry guys, that just doesn't make sense.

Re: [PATCH net-next v2 1/3] openvswitch: normalize vlan rx path

2016-10-05 Thread Eric Garver
On Wed, Oct 05, 2016 at 08:31:52PM +0300, Eyal Birger wrote: > On Wed, Oct 5, 2016 at 8:23 PM, Jiri Benc wrote: > > On Wed, 5 Oct 2016 17:18:08 +0300, Eyal Birger wrote: > >> I think at this point, 'eth' may point to a freed packet. > > > > It may but how does that matter? eth is not used beyond t

Re: [PATCH net-next v2 1/3] openvswitch: normalize vlan rx path

2016-10-05 Thread Eyal Birger
On Wed, Oct 5, 2016 at 8:23 PM, Jiri Benc wrote: > On Wed, 5 Oct 2016 17:18:08 +0300, Eyal Birger wrote: >> I think at this point, 'eth' may point to a freed packet. > > It may but how does that matter? eth is not used beyond that point. Definitely a nit. For sure not critical. Just seemed less

Re: [PATCH net-next v2 1/3] openvswitch: normalize vlan rx path

2016-10-05 Thread Jiri Benc
On Wed, 5 Oct 2016 17:18:08 +0300, Eyal Birger wrote: > I think at this point, 'eth' may point to a freed packet. It may but how does that matter? eth is not used beyond that point. Jiri

Re: [PATCH net-next v2 1/3] openvswitch: normalize vlan rx path

2016-10-05 Thread Eyal Birger
Hi, On Wed, Oct 5, 2016 at 4:07 PM, Jiri Benc wrote: > diff --git a/net/openvswitch/datapath.c b/net/openvswitch/datapath.c > index 4d67ea856067..c47b3da8ecf2 100644 > --- a/net/openvswitch/datapath.c > +++ b/net/openvswitch/datapath.c > @@ -594,6 +594,16 @@ static int ovs_packet_cmd_execute(stru

[PATCH net-next v2 1/3] openvswitch: normalize vlan rx path

2016-10-05 Thread Jiri Benc
Similarly to how the core networking stack behaves, let the first vlan tag be always stored in skb->vlan_tci. This is already ensured in __netif_receive_skb_core for packets that were received from the kernel and honored by skb_vlan_push and skb_vlan_pop. The only remaining place are packets receiv