[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAF=yD-Kvbm8_bgAGqPcrm=6t=sbrkW7a_v+TR4w9Gww_TP0c2w@mail.gmail.com>
Date: Fri, 3 Nov 2017 17:49:01 +0900
From: Willem de Bruijn <willemdebruijn.kernel@...il.com>
To: Jason Wang <jasowang@...hat.com>
Cc: "Michael S. Tsirkin" <mst@...hat.com>,
Network Development <netdev@...r.kernel.org>,
LKML <linux-kernel@...r.kernel.org>,
Tom Herbert <tom@...bertland.com>
Subject: Re: [PATCH net-next V2 1/3] tun: abstract flow steering logic
On Thu, Nov 2, 2017 at 12:51 PM, Jason Wang <jasowang@...hat.com> wrote:
>
>
> On 2017年11月02日 11:45, Michael S. Tsirkin wrote:
>>
>> On Thu, Nov 02, 2017 at 11:43:48AM +0800, Jason Wang wrote:
>>>
>>>
>>> On 2017年11月02日 09:11, Willem de Bruijn wrote:
>>>>
>>>> On Tue, Oct 31, 2017 at 7:32 PM, Jason Wang <jasowang@...hat.com> wrote:
>>>>>
>>>>> tun now use flow caches based automatic queue steering method. This
>>>>> may not suffice all user cases. To extend it to be able to use more
>>>>> flow steering policy, this patch abstracts flow steering logic into
>>>>> tun_steering_ops, then we can declare and use different methods in
>>>>> the future.
>>>>> Signed-off-by: Jason Wang <jasowang@...hat.com>
>>>>> ---
>>>>> drivers/net/tun.c | 85
>>>>> +++++++++++++++++++++++++++++++++++++++++--------------
>>>>> 1 file changed, 63 insertions(+), 22 deletions(-)
>>>>>
>>>>> diff --git a/drivers/net/tun.c b/drivers/net/tun.c
>>>>> index ea29da9..bff6259 100644
>>>>
>>>> The previous RFC enabled support for multiple pluggable steering
>>>> policies. But as all can be implemented in BPF and we only plan to
>>>> support an eBPF policy besides the legacy one, this patch is no longer
>>>> needed. We can save a few indirect function calls.
>>>
>>> But we should at least support two kinds of steering policy, so this is
>>> still needed?
>>>
>>> And I'm not quite sure we can implement all kinds of policies through BPF
>>> e.g RSS or we may want to offload the queue selection to underlayer
>>> switch
>>> or nic .
>>>
>>> Thanks
>>
>> I think a simple if condition is preferable for now, too. Let's wait
>> until we get some 3/4 of these.
>>
>
> That's a solution but we may need if in at least four places. If this is ok,
> I will do it in next version.
That sounds good to me.
I only see three places that need to be modified, the callback sites
that this patch introduces. Strictly speaking, it's not even necessary
to forgo the rxhash operations. Though a nice optimization.
Powered by blists - more mailing lists