From owner-svn-src-head@freebsd.org Fri Jan 5 18:20:37 2018 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 77615EB7E38; Fri, 5 Jan 2018 18:20:37 +0000 (UTC) (envelope-from eugen@grosbein.net) Received: from hz.grosbein.net (hz.grosbein.net [78.47.246.247]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "hz.grosbein.net", Issuer "hz.grosbein.net" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 090D87628C; Fri, 5 Jan 2018 18:20:36 +0000 (UTC) (envelope-from eugen@grosbein.net) Received: from eg.sd.rdtc.ru (root@eg.sd.rdtc.ru [62.231.161.221] (may be forged)) by hz.grosbein.net (8.15.2/8.15.2) with ESMTPS id w05IKSqn040262 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Fri, 5 Jan 2018 19:20:29 +0100 (CET) (envelope-from eugen@grosbein.net) X-Envelope-From: eugen@grosbein.net X-Envelope-To: mjoras@freebsd.org Received: from [10.58.0.4] ([10.58.0.4]) by eg.sd.rdtc.ru (8.15.2/8.15.2) with ESMTPS id w05IKOHV032644 (version=TLSv1.2 cipher=DHE-RSA-AES128-SHA bits=128 verify=NOT); Sat, 6 Jan 2018 01:20:24 +0700 (+07) (envelope-from eugen@grosbein.net) Subject: Re: svn commit: r327559 - in head: . sys/net To: Matt Joras References: <201801042005.w04K5liB049411@repo.freebsd.org> <5A4E9397.9000308@grosbein.net> <5A4EDC62.50508@grosbein.net> <5A4F824C.1060405@grosbein.net> <97d173fb-4f47-609d-8319-07282a283473@multiplay.co.uk> <5A4FB6BC.6090506@grosbein.net> Cc: Steven Hartland , src-committers , svn-src-all@freebsd.org, svn-src-head@freebsd.org, scottl@freebsd.org From: Eugene Grosbein Message-ID: <5A4FC1E4.9060301@grosbein.net> Date: Sat, 6 Jan 2018 01:20:20 +0700 User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.7.2 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=2.2 required=5.0 tests=BAYES_00, LOCAL_FROM, RDNS_NONE autolearn=no autolearn_force=no version=3.4.1 X-Spam-Report: * -2.3 BAYES_00 BODY: Bayes spam probability is 0 to 1% * [score: 0.0000] * 2.6 LOCAL_FROM From my domains * 1.9 RDNS_NONE Delivered to internal network by a host with no rDNS X-Spam-Level: ** X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on hz.grosbein.net X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 05 Jan 2018 18:20:37 -0000 CC'ng scottl@ as author of the change in question. 06.01.2018 0:39, Matt Joras wrote: >>> For what it's worth, this was the conclusion I came to, and at Isilon >>> we've made the same change being discussed here. For the case of >>> drivers that end up using a queue index for the flowid, you end up >>> with pathological behavior on the lagg; the flowid ends up getting >>> right shifted by (default) 16. So in the case of e.g. two bxe(4) >>> interfaces with 4 queues, you always end up choosing the interface in >>> the lagg at index 0. Then why does if_lagg shifts 16 bits by default? Is seems senseless. This was introduced with r260070 by scottl: > Multi-queue NIC drivers and multi-port lagg tend to use the same lower > bits of the flowid as each other, resulting in a poor distribution of > packets among queues in certain cases. Work around this by adding a > set of sysctls for controlling a bit-shift on the flowid when doing > multi-port aggrigation in lagg and lacp. By default, lagg/lacp will > now use bits 16 and higher instead of 0 and higher. > > Reviewed by: max > Obtained from: Netflix > MFC after: 3 days This commit message does not point to an example of NIC driver that would set non-zero bits 16 and higher for flowid so that shift result would be non-zero. Do we really have such a driver? Anyway, this lagg's default seems to be very driver-centric. For example, Intel driver family also do not use such high bits for flowid just like mentioned bxe(4). We should change flowid_shift default to 0 for if_lagg(4), shouldn't we?