Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp2508139pxb; Mon, 18 Jan 2021 21:36:07 -0800 (PST) X-Google-Smtp-Source: ABdhPJy7vmeOPlv+uYCJTzGpBJlCiz6+Wx+t3zEpDtCse1/jDeyrHiT+bg7/pjZGCcd4s8YvWBS8 X-Received: by 2002:a17:906:f950:: with SMTP id ld16mr1912414ejb.553.1611034567026; Mon, 18 Jan 2021 21:36:07 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1611034567; cv=none; d=google.com; s=arc-20160816; b=WktUggsFpftkR8uVdRVGkdCKC/KPDgWi9jTAZ36B2TiacVkgqz8ZqmwLEqelhfz6oH H01SLLD1y07hBzNvW9nNp1nw7Ph8/fzl6drI2zfzkrwVgXf2gCSLUz/X4VQRMXVBfwcs qUXjZIUZCbIxThV/W5bTP0/U8Hxi3AVcdqR+FhyuMjOokGYcCk8zv5a50M+oVFKFPe/h 5uE/RR1kq8utmh0f48+Nc/Lf9xwJd1TlOIHMaC/g82OSDnXCz5tDwwV5P9eTASuBWFyJ dbuyUSBYlY54CDzGfS5MOCmivGpi6hzr913Vltl1ILOM7WjDv6B/MfQuGVdKbuBo6zVG Tlpw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:dkim-signature; bh=YKM2X4wwUdQ578gqAdzYuCY1qiQMQTEjO9ZyJU1dqug=; b=mdAmPLCccIzrkLwXSmJrvAc1C+/XmluIF+XCEwZNDqKL0Be+RB+r0Oyot3HiWbhj/g CeCQ5LrePtc5Yvux+T3K0RSqobnnedw6yPkTAkrWhxZNwOyW3BvhFu5ngLdFIlbnDnK6 PtqRYRLbWVFZzfPD1nL1n1i61sOu8sYQqJN8rCwWCr87LDv1xB45SCO5qUDRFY5WelUH Kz0N+KRb3OX1e3OGEManq+aKWzP5iMBjUBJ+GaTy8ZLiG8/OnDMamlXxMCGHQk2uo3xL K8p/iGVR/k3INlATQNa/JufaACaq8Wl39rJ2JEMd/Q67/fZA0NKZXd61oJSoqNFNf4ZV taTw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=G2+vvjnu; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id e8si4997866ejj.540.2021.01.18.21.35.44; Mon, 18 Jan 2021 21:36:07 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=G2+vvjnu; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2387426AbhARXLW (ORCPT + 99 others); Mon, 18 Jan 2021 18:11:22 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53538 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730963AbhARXLU (ORCPT ); Mon, 18 Jan 2021 18:11:20 -0500 Received: from mail-ot1-x333.google.com (mail-ot1-x333.google.com [IPv6:2607:f8b0:4864:20::333]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 708C0C061573; Mon, 18 Jan 2021 15:10:40 -0800 (PST) Received: by mail-ot1-x333.google.com with SMTP id 34so7150459otd.5; Mon, 18 Jan 2021 15:10:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=YKM2X4wwUdQ578gqAdzYuCY1qiQMQTEjO9ZyJU1dqug=; b=G2+vvjnutm+/HGZ9GjAjoAtP4zO26tu4TC44KdNHyc6BKPHNpiILtGGDx8GX/MJMqK 13am9cCPL8CJnCH9/GXbUuvuJ+8VVYl4Uc14tx3qQF4DNw33Yz2vsLZ7ItamlR0GVoby xeDXm4DX7KeGgI/wzlAiIw91QZpUkzkZS5RC4lEcBxyJv/MgvqIIW/ceffrX1p2w+exl TkeQ5FsOT6XDgJuxHsNKz8SojlxnX8ULvSi+j6jZ3voVFQBJh1OvW3kFenDgENx+wlX4 ceoZzaV/5+JWzGmJWodVjU2w5+eFnbjJQ1e0XwfqfFn1OMGhjlvlJN3Hg93wmWEgaBae EYJQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=YKM2X4wwUdQ578gqAdzYuCY1qiQMQTEjO9ZyJU1dqug=; b=NQxX9X5rXI62jgV8S6cPm6xzVTi6buYYu6nf36zGcymD+TKaxe6/uWzjnJ1Mm4PhQ6 Ryji1W2IWnfXfb7vsGsAFWFiDFK5J9ZxAs3F60KVeXJkQgQbWTY6JGuIKRHHjGlawRFZ o8TCuIM661W7WthZB1sm25K80AI6yCvFFeh0ctrZZktiFmJreTeNWDUMFx5GO1rpyTH2 ha8CfcuSTfhf1E9NRWQwqhDgNEQAJY3IUZfGybdWYqbRXWSZDG6WZdgWSWJcPPMqUtJW ZuGp01icf8DkLvxfHRUJlrKAouyo07P2kDxF7GVokoWP+35Z9jWoaGwn3YkE2uNz73Ma Igbg== X-Gm-Message-State: AOAM5306vlv7Ohgt93QRDLKAaXJ3VS6NlMSpMyFR0PEUR0xyuUCp8OIe HmIEywWLzF6aI+jW5GuLW0q8oRb5S/I= X-Received: by 2002:a05:6830:1bef:: with SMTP id k15mr1338351otb.303.1611011439702; Mon, 18 Jan 2021 15:10:39 -0800 (PST) Received: from Davids-MacBook-Pro.local ([8.6.112.162]) by smtp.googlemail.com with ESMTPSA id n11sm3563548oij.37.2021.01.18.15.10.38 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 18 Jan 2021 15:10:39 -0800 (PST) Subject: Re: [PATCH net-next v3] bonding: add a vlan+srcmac tx hashing option To: Jarod Wilson , linux-kernel@vger.kernel.org Cc: Jay Vosburgh , Veaceslav Falico , Andy Gospodarek , "David S. Miller" , Jakub Kicinski , Thomas Davis , netdev@vger.kernel.org References: <20210113223548.1171655-1-jarod@redhat.com> <20210115192103.1179450-1-jarod@redhat.com> From: David Ahern Message-ID: <79af4145-48cc-0961-b341-c0e106beb14b@gmail.com> Date: Mon, 18 Jan 2021 16:10:38 -0700 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.16; rv:78.0) Gecko/20100101 Thunderbird/78.6.1 MIME-Version: 1.0 In-Reply-To: <20210115192103.1179450-1-jarod@redhat.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 1/15/21 12:21 PM, Jarod Wilson wrote: > diff --git a/Documentation/networking/bonding.rst b/Documentation/networking/bonding.rst > index adc314639085..36562dcd3e1e 100644 > --- a/Documentation/networking/bonding.rst > +++ b/Documentation/networking/bonding.rst > @@ -951,6 +951,19 @@ xmit_hash_policy > packets will be distributed according to the encapsulated > flows. > > + vlan+srcmac > + > + This policy uses a very rudimentary vland ID and source mac s/vland/vlan/ > + ID hash to load-balance traffic per-vlan, with failover drop ID on this line; just 'source mac'. > + should one leg fail. The intended use case is for a bond > + shared by multiple virtual machines, all configured to > + use their own vlan, to give lacp-like functionality > + without requiring lacp-capable switching hardware. > + > + The formula for the hash is simply > + > + hash = (vlan ID) XOR (source MAC vendor) XOR (source MAC dev) > + > The default value is layer2. This option was added in bonding > version 2.6.3. In earlier versions of bonding, this parameter > does not exist, and the layer2 policy is the only policy. The