Re: [PATCH net v4] net: xdp: account for layer 3 packets in generic skb handler

2020-08-15 Thread Jason A. Donenfeld
On Fri, Aug 14, 2020 at 11:27 PM David Miller wrote: > > From: "Jason A. Donenfeld" > Date: Fri, 14 Aug 2020 23:04:56 +0200 > > > What? No. It comes up repeatedly because people want to reuse their > > XDP processing logic with layer 3 devices. > > XDP is a layer 2 packet processing technology.

Re: [PATCH net v4] net: xdp: account for layer 3 packets in generic skb handler

2020-08-14 Thread David Miller
From: "Jason A. Donenfeld" Date: Fri, 14 Aug 2020 23:04:56 +0200 > What? No. It comes up repeatedly because people want to reuse their > XDP processing logic with layer 3 devices. XDP is a layer 2 packet processing technology. It assumes an L2 ethernet and/or VLAN header is going to be there.

Re: [PATCH net v4] net: xdp: account for layer 3 packets in generic skb handler

2020-08-14 Thread David Miller
From: Jakub Kicinski Date: Fri, 14 Aug 2020 08:31:53 -0700 > I'm sure it comes up repeatedly because we don't return any errors, > so people waste time investigating why it doesn't work. +1

Re: [PATCH net v4] net: xdp: account for layer 3 packets in generic skb handler

2020-08-14 Thread Jason A. Donenfeld
On 8/14/20, Jakub Kicinski wrote: > On Fri, 14 Aug 2020 08:56:48 +0200 Jason A. Donenfeld wrote: >> On Thu, Aug 13, 2020 at 11:01 PM Jakub Kicinski wrote: >> > > I had originally dropped this patch, but the issue kept coming up in >> > > user reports, so here's a v4 of it. Testing of it is still

Re: [PATCH net v4] net: xdp: account for layer 3 packets in generic skb handler

2020-08-14 Thread Jakub Kicinski
On Fri, 14 Aug 2020 08:56:48 +0200 Jason A. Donenfeld wrote: > On Thu, Aug 13, 2020 at 11:01 PM Jakub Kicinski wrote: > > > I had originally dropped this patch, but the issue kept coming up in > > > user reports, so here's a v4 of it. Testing of it is still rather slim, > > > but hopefully that wi

Re: [PATCH net v4] net: xdp: account for layer 3 packets in generic skb handler

2020-08-13 Thread Jason A. Donenfeld
On Thu, Aug 13, 2020 at 11:01 PM Jakub Kicinski wrote: > > I had originally dropped this patch, but the issue kept coming up in > > user reports, so here's a v4 of it. Testing of it is still rather slim, > > but hopefully that will change in the coming days. > > Here an alternative patch, untested

Re: [PATCH net v4] net: xdp: account for layer 3 packets in generic skb handler

2020-08-13 Thread Jakub Kicinski
On Thu, 13 Aug 2020 21:58:16 +0200 Jason A. Donenfeld wrote: > - cls_bpf does not support the same feature set as XDP, and operates at > a slightly different stage in the networking stack. Please elaborate. > I had originally dropped this patch, but the issue kept coming up in > user reports, s

[PATCH net v4] net: xdp: account for layer 3 packets in generic skb handler

2020-08-13 Thread Jason A. Donenfeld
A user reported that packets from wireguard were possibly ignored by XDP [1]. Another user reported that modifying packets from layer 3 interfaces results in impossible to diagnose drops. Apparently, the generic skb xdp handler path seems to assume that packets will always have an ethernet header,