Re: [PATCH net-next 1/6] net: skbuff: don't use union for napi_id and sender_cpu

2016-04-05 Thread Jason Wang
On 04/01/2016 09:04 PM, Eric Dumazet wrote: > On Fri, 2016-04-01 at 12:49 +0800, Jason Wang wrote: >> On 04/01/2016 10:55 AM, Eric Dumazet wrote: >>> On Fri, 2016-04-01 at 10:13 +0800, Jason Wang wrote: >>> >>> The problem is we want to support busy polling for tun. This needs napi_id t

Re: [PATCH net-next 1/6] net: skbuff: don't use union for napi_id and sender_cpu

2016-04-05 Thread Michael S. Tsirkin
On Fri, Apr 01, 2016 at 06:04:19AM -0700, Eric Dumazet wrote: > On Fri, 2016-04-01 at 12:49 +0800, Jason Wang wrote: > > > > On 04/01/2016 10:55 AM, Eric Dumazet wrote: > > > On Fri, 2016-04-01 at 10:13 +0800, Jason Wang wrote: > > > > > > > > >> The problem is we want to support busy polling for

Re: [PATCH net-next 1/6] net: skbuff: don't use union for napi_id and sender_cpu

2016-04-01 Thread Eric Dumazet
On Fri, 2016-04-01 at 12:49 +0800, Jason Wang wrote: > > On 04/01/2016 10:55 AM, Eric Dumazet wrote: > > On Fri, 2016-04-01 at 10:13 +0800, Jason Wang wrote: > > > > > >> The problem is we want to support busy polling for tun. This needs > >> napi_id to be passed to tun socket by sk_mark_napi_id()

Re: [PATCH net-next 1/6] net: skbuff: don't use union for napi_id and sender_cpu

2016-03-31 Thread Jason Wang
On 04/01/2016 10:55 AM, Eric Dumazet wrote: > On Fri, 2016-04-01 at 10:13 +0800, Jason Wang wrote: > > >> The problem is we want to support busy polling for tun. This needs >> napi_id to be passed to tun socket by sk_mark_napi_id() during >> tun_net_xmit(). But before reaching this, XPS will set

Re: [PATCH net-next 1/6] net: skbuff: don't use union for napi_id and sender_cpu

2016-03-31 Thread Eric Dumazet
On Fri, 2016-04-01 at 10:13 +0800, Jason Wang wrote: > > The problem is we want to support busy polling for tun. This needs > napi_id to be passed to tun socket by sk_mark_napi_id() during > tun_net_xmit(). But before reaching this, XPS will set sender_cpu will > make us can't see correct napi_i

Re: [PATCH net-next 1/6] net: skbuff: don't use union for napi_id and sender_cpu

2016-03-31 Thread Jason Wang
On 04/01/2016 04:01 AM, David Miller wrote: > From: Eric Dumazet > Date: Thu, 31 Mar 2016 03:32:21 -0700 > >> On Thu, 2016-03-31 at 13:50 +0800, Jason Wang wrote: >>> We use a union for napi_id and send_cpu, this is ok for most of the >>> cases except when we want to support busy polling for tun

Re: [PATCH net-next 1/6] net: skbuff: don't use union for napi_id and sender_cpu

2016-03-31 Thread Jason Wang
On 03/31/2016 06:32 PM, Eric Dumazet wrote: > On Thu, 2016-03-31 at 13:50 +0800, Jason Wang wrote: >> We use a union for napi_id and send_cpu, this is ok for most of the >> cases except when we want to support busy polling for tun which needs >> napi_id to be stored and passed to socket during tu

Re: [PATCH net-next 1/6] net: skbuff: don't use union for napi_id and sender_cpu

2016-03-31 Thread David Miller
From: Eric Dumazet Date: Thu, 31 Mar 2016 03:32:21 -0700 > On Thu, 2016-03-31 at 13:50 +0800, Jason Wang wrote: >> We use a union for napi_id and send_cpu, this is ok for most of the >> cases except when we want to support busy polling for tun which needs >> napi_id to be stored and passed to soc

Re: [PATCH net-next 1/6] net: skbuff: don't use union for napi_id and sender_cpu

2016-03-31 Thread Eric Dumazet
On Thu, 2016-03-31 at 13:50 +0800, Jason Wang wrote: > We use a union for napi_id and send_cpu, this is ok for most of the > cases except when we want to support busy polling for tun which needs > napi_id to be stored and passed to socket during tun_net_xmit(). In > this case, napi_id was overridde

[PATCH net-next 1/6] net: skbuff: don't use union for napi_id and sender_cpu

2016-03-30 Thread Jason Wang
We use a union for napi_id and send_cpu, this is ok for most of the cases except when we want to support busy polling for tun which needs napi_id to be stored and passed to socket during tun_net_xmit(). In this case, napi_id was overridden with sender_cpu before tun_net_xmit() was called if XPS was