Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.5 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, USER_AGENT_GIT autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id D604DECE58E for ; Thu, 17 Oct 2019 19:21:26 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 9D8D32054F for ; Thu, 17 Oct 2019 19:21:26 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (1024-bit key) header.d=lunn.ch header.i=@lunn.ch header.b="NGoaf/rG" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2503446AbfJQTVZ (ORCPT ); Thu, 17 Oct 2019 15:21:25 -0400 Received: from vps0.lunn.ch ([185.16.172.187]:51278 "EHLO vps0.lunn.ch" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727397AbfJQTVZ (ORCPT ); Thu, 17 Oct 2019 15:21:25 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lunn.ch; s=20171124; h=Content-Transfer-Encoding:MIME-Version:Message-Id:Date:Subject: Cc:To:From:Sender:Reply-To:Content-Type:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: In-Reply-To:References:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=w3KL5b18wZLP4nZzqDXQ8CG5n9e9bEnP5OqnBiNrMcQ=; b=NGoaf/rGGX3DXg2bZtAWSIomYo yUcQKPsrEw8BUsCAbyhrxTslBel2v7kH/Q6jLva3oh92b/zabqwKxMlPN3JWB3SD2w4MJoNw6D1p9 hKdEqnjzkibvAYEZ7+AVukKnl6h2b5exev3wwpMjrX+COReNARoN7xSa2btQO/3Zr/d8=; Received: from andrew by vps0.lunn.ch with local (Exim 4.92.2) (envelope-from ) id 1iLBKd-0006C7-5n; Thu, 17 Oct 2019 21:21:07 +0200 From: Andrew Lunn To: David Miller Cc: netdev , Vivien Didelot , Florian Fainelli , Andrew Lunn Subject: [PATCH net-next v3 0/2] mv88e6xxx: Allow config of ATU hash algorithm Date: Thu, 17 Oct 2019 21:20:53 +0200 Message-Id: <20191017192055.23770-1-andrew@lunn.ch> X-Mailer: git-send-email 2.23.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org The Marvell switches allow the hash algorithm for MAC addresses in the address translation unit to be configured. Add support to the DSA core to allow DSA drivers to make use of devlink parameters, and allow the ATU hash to be get/set via such a parameter. v2: Pass a pointer for where the hash should be stored, return a plain errno, or 0. Document the parameter. v3: Document type of parameter, and valid range Add break statements to default clause of switch Directly use ctx->val.vu8 Andrew Lunn (2): net: dsa: Add support for devlink device parameters net: dsa: mv88e6xxx: Add devlink param for ATU hash algorithm. .../networking/devlink-params-mv88e6xxx.txt | 7 + MAINTAINERS | 1 + drivers/net/dsa/mv88e6xxx/chip.c | 131 +++++++++++++++++- drivers/net/dsa/mv88e6xxx/chip.h | 4 + drivers/net/dsa/mv88e6xxx/global1.h | 3 + drivers/net/dsa/mv88e6xxx/global1_atu.c | 32 +++++ include/net/dsa.h | 23 +++ net/dsa/dsa.c | 48 +++++++ net/dsa/dsa2.c | 7 +- 9 files changed, 254 insertions(+), 2 deletions(-) create mode 100644 Documentation/networking/devlink-params-mv88e6xxx.txt -- 2.23.0