From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932320AbcBCOD7 (ORCPT ); Wed, 3 Feb 2016 09:03:59 -0500 Received: from out1-smtp.messagingengine.com ([66.111.4.25]:39729 "EHLO out1-smtp.messagingengine.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754383AbcBCODy (ORCPT ); Wed, 3 Feb 2016 09:03:54 -0500 X-Sasl-enc: XY6tjk4FByhEE81mQMh0qPTZnwCNZgYCYwlYdlIF+6Kg 1454508233 Subject: Re: [PATCH v3] net:Add sysctl_max_skb_frags To: Herbert Xu References: <568F87AC.60405@oracle.com> <1454488017-8822-1-git-send-email-hans.westgaard.ry@oracle.com> <20160203112550.GB28003@gondor.apana.org.au> <56B1E635.8020707@stressinduktion.org> <20160203122052.GA28619@gondor.apana.org.au> Cc: Hans Westgaard Ry , "David S. Miller" , Alexey Kuznetsov , James Morris , Hideaki YOSHIFUJI , Patrick McHardy , Tom Herbert , Pablo Neira Ayuso , Eric Dumazet , Florian Westphal , Jiri Pirko , Alexander Duyck , Michal Hocko , =?UTF-8?Q?Linus_L=c3=bcssing?= , Tejun Heo , Andrew Morton , Alexey Kodanev , =?UTF-8?Q?H=c3=a5kon_Bugge?= , open list , "open list:NETWORKING [GENERAL]" From: Hannes Frederic Sowa Message-ID: <56B208C6.2080201@stressinduktion.org> Date: Wed, 3 Feb 2016 15:03:50 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.5.0 MIME-Version: 1.0 In-Reply-To: <20160203122052.GA28619@gondor.apana.org.au> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 03.02.2016 13:20, Herbert Xu wrote: > On Wed, Feb 03, 2016 at 12:36:21PM +0100, Hannes Frederic Sowa wrote: >> >> Agreed that it feels like a hack, but a rather simple one. I would >> consider this to be just a performance improvement. We certainly need >> a slow-path when virtio drivers submit gso packets to the stack (and >> already discussed with Hans). The sysctl can't help here. But without >> the sysctl the packets would constantly hit the slow-path in case of >> e.g. IPoIB and that would also be rather bad. > > So you want to penalise every NIC in the system if just one of > them is broken? This is insane. Just do the partial linearisation > in that one driver that needs it and not only won't you have to > penalise anyone else but you still get the best result for that > driver that needs it. Most normal Ethernet systems and drivers currently don't need tweating this knob at all, only some special kinds of installations. This patch referred to IPoIB as a possible user which drivers/firmware/cards seem to have this problem. Current behavior just leaves everything as-is. If you use IPoIB you probably use it quite regular and linearizing an skbs *always* seems to be much more work than simply capping the number of frags globally. > Besides, you have to implement the linearisation anyway because > of virtualisation. Yes, the slow-path is necessary. But instead of writing a new complicated linearizing function to just reduce the fragments we could also simply linearize it completely and ask the admin to also tune the vm guests. I only see this tuning in kind in very specific environments where the admins now what they do. Bye, Hannes