Received: by 2002:a05:6a10:17d3:0:0:0:0 with SMTP id hz19csp2929020pxb; Tue, 13 Apr 2021 13:59:37 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzb0AF5tOMGv59QJxPpdMLN1iA5g0o+05XfY0OevF62LdaAeYYXaXKECSpS+pev+qDUQiz8 X-Received: by 2002:a17:90a:868c:: with SMTP id p12mr1932200pjn.82.1618347577661; Tue, 13 Apr 2021 13:59:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1618347577; cv=none; d=google.com; s=arc-20160816; b=wbIitrAHtxTu3qzEnwyblakiHC9CKqJOBRrTdy7QxClgbnAj5Jck033G7rF+OO+xT8 2APZNp4ygINU5AVSFHtqgdo4Xhakg5ugoOSFXU9rsfuEqatu8CKfxoh574arCUbDZYV9 o6bJ0rFBGwUC3JWF3c53RwVEGxJpcSX7hoG5q4J4lWaISDuBWsy65z7AvcfOcdTiqCjD 69cw9zRB1T9J6hyBk34jIzsGAH1Us/8vebCqYXgx4ViYeAMQljvbrUsUdTdJjYDr5+fS 4cE8Vh5FJ/5iG4AZPkwJm/s+9wmvei6IZ3QtWkJv5ArMHt6zxZtSyOiOHDfXhF+/leyZ KnVw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date; bh=NAUzXvbA8HvoFVEtiATh3Jq0ucBtkT6g0TQr66QZy58=; b=KMtBanQj/XKO8HpxNGCCGyhrzkTibHnpdv9RwobB2uKNnsSk+lDPBD5oMpVapjEpn4 /Agf0FEgqmr2zmpFFP/F2Nll02uzuCdXaOS6qiAjzo9d1IQkurRKkNLyvksar8TtURjz NUfwRaUNQSWzVJeaL08WZxOj+X/916ZHjd2tUFdCVwjQAf+X/yO0+NtM+ebEzw0OxCNw 6puV4NWcM7TikMhWHsfN2TsJz+00U19F4T6DIXUpVR1PVf25eAJXl13qUMZ2U5g3ItEA yZcA04HOpJEMU4t8bjqq3Wr/L+4hBXJL+qNcgwD7YVd06u7lb5BQOwxPRfmaMmnexiuk IoCw== ARC-Authentication-Results: i=1; mx.google.com; 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=fail (p=NONE sp=NONE dis=NONE) header.from=nic.cz Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id y5si15081567pfg.254.2021.04.13.13.59.25; Tue, 13 Apr 2021 13:59:37 -0700 (PDT) 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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=nic.cz Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S245510AbhDMPPI (ORCPT + 99 others); Tue, 13 Apr 2021 11:15:08 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41306 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S242392AbhDMPPG (ORCPT ); Tue, 13 Apr 2021 11:15:06 -0400 Received: from mail.nic.cz (lists.nic.cz [IPv6:2001:1488:800:400::400]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 052CBC061574; Tue, 13 Apr 2021 08:14:46 -0700 (PDT) Received: from thinkpad (unknown [IPv6:2a0e:b107:ae1:0:3e97:eff:fe61:c680]) by mail.nic.cz (Postfix) with ESMTPSA id 2E28A140A5F; Tue, 13 Apr 2021 17:14:44 +0200 (CEST) Date: Tue, 13 Apr 2021 17:14:43 +0200 From: Marek Behun To: Tobias Waldekranz Cc: Vladimir Oltean , Ansuel Smith , netdev@vger.kernel.org, "David S. Miller" , Jakub Kicinski , Andrew Lunn , Vivien Didelot , Florian Fainelli , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Eric Dumazet , Wei Wang , Cong Wang , Taehee Yoo , =?UTF-8?B?QmrDtnJuIFTDtnBlbA==?= , zhang kai , Weilong Chen , Roopa Prabhu , Di Zhu , Francis Laniel , linux-kernel@vger.kernel.org Subject: Re: [PATCH RFC net-next 0/3] Multi-CPU DSA support Message-ID: <20210413171443.1b2b2f88@thinkpad> In-Reply-To: <87im4qjl87.fsf@waldekranz.com> References: <20210410133454.4768-1-ansuelsmth@gmail.com> <20210411200135.35fb5985@thinkpad> <20210411185017.3xf7kxzzq2vefpwu@skbuf> <878s5nllgs.fsf@waldekranz.com> <20210412213045.4277a598@thinkpad> <8735vvkxju.fsf@waldekranz.com> <20210412235054.73754df9@thinkpad> <87wnt7jgzk.fsf@waldekranz.com> <20210413005518.2f9b9cef@thinkpad> <87r1jfje26.fsf@waldekranz.com> <87o8ejjdu6.fsf@waldekranz.com> <20210413015450.1ae597da@thinkpad> <20210413022730.2a51c083@thinkpad> <87im4qjl87.fsf@waldekranz.com> X-Mailer: Claws Mail 3.17.8 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-100.0 required=5.9 tests=SHORTCIRCUIT, USER_IN_WELCOMELIST,USER_IN_WHITELIST shortcircuit=ham autolearn=disabled version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on mail.nic.cz X-Virus-Scanned: clamav-milter 0.102.2 at mail X-Virus-Status: Clean Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 13 Apr 2021 16:46:32 +0200 Tobias Waldekranz wrote: > On Tue, Apr 13, 2021 at 02:27, Marek Behun wrote: > > On Tue, 13 Apr 2021 01:54:50 +0200 > > Marek Behun wrote: > > > >> I will look into this, maybe ask some follow-up questions. > > > > Tobias, > > > > it seems that currently the LAGs in mv88e6xxx driver do not use the > > HashTrunk feature (which can be enabled via bit 11 of the > > MV88E6XXX_G2_TRUNK_MAPPING register). > > This should be set at the bottom of mv88e6xxx_lag_sync_masks. > > > If we used this feature and if we knew what hash function it uses, we > > could write a userspace tool that could recompute new MAC > > addresses for the CPU ports in order to avoid the problem I explained > > previously... > > > > Or the tool can simply inject frames into the switch and try different > > MAC addresses for the CPU ports until desired load-balancing is reached. > > > > What do you think? > > As you concluded in your followup, not being able to have a fixed MAC > for the CPU seems weird. > > Maybe you could do the inverse? Allow userspace to set the masks for an > individual bond/team port in a hash-based LAG, then you can offload that > to DSA. What masks?