From patchwork Tue Oct 24 13:20:33 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Linus Walleij X-Patchwork-Id: 157444 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:ce89:0:b0:403:3b70:6f57 with SMTP id p9csp1936977vqx; Tue, 24 Oct 2023 06:21:18 -0700 (PDT) X-Google-Smtp-Source: AGHT+IH/2080LntD2grzrDC6NR6UiY/AoxPKj4Eg/Uud5y0QeDSdohSwlp5Zs2FAG1y9RLyen2dr X-Received: by 2002:a05:6359:6d03:b0:168:e917:e075 with SMTP id te3-20020a0563596d0300b00168e917e075mr3718682rwb.1.1698153678596; Tue, 24 Oct 2023 06:21:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1698153678; cv=none; d=google.com; s=arc-20160816; b=BHYGElSdsFFyW1TL6rQjo+6SPNjT0btYxvtwvtpgAL9F8Dc3iQVHmMAjd3oDiTqo4L XZbD8YtK47Mohd5Cb1TplfCuVFfNkOwRkwfs9OR5agFeeBJmpiomnwvDgx5pONvuDRp8 0iPqq7gup1PA7l7uT1E4JsQn62f4BhDCBGwyZLwcJYx3rHmwA1NfrTbFEdJnKQWhs5zW bopkwtfSVsM9o+MQJj47arzM3ntHS1SkHQv5rDIhBE2KTdfZ+VtDkSeA29cK35m7QzzV AL4DvjU8fY4fdb0LByPW1mDaHY3yx9PIfhSfIlxZBZEMvaZCqH/X0L0RwPKEl8WjkKsA uZPw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:in-reply-to:references:message-id :content-transfer-encoding:mime-version:subject:date:from :dkim-signature; bh=IpZ8b7O2cRe1OvuYy4CjSC9AKU1bWUMAZ3eqzNW29dM=; fh=2+V6Ps3JdvX/yAVqaiftiVHUj1hQH1I9FRVFoPN224g=; b=xDoKnAetIb28WalRAZLS8r8chejA3L+/DVpqEiI0/7+Aa6zUgFdrUZpWIGsbeynN0B t3YcVQdtwUdgw4N8gjcl/9jid6joyooIdmTHTbOdbtoYs75FHvNe0EzBPePb4yyPUets emm8Vcbt6aGZl9dTkxBZWHUtWOTyASEFPTcvqQAwsKrV5aLD48z1FLb/NracFFEaHcZF wp4xJ56OQlptzsuRiEYtcmybRExUnRoSsN3X5gImUrZsGokDCc+QYyjj02EcHL8GS8Iu 9TI+t6o07l5gimk7NM8HseYfpJJOTFUYnmnlRqnFutmpg8LRK3unshGZyf4O0teH5ecx aItw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=IFf5k+VO; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from snail.vger.email (snail.vger.email. [23.128.96.37]) by mx.google.com with ESMTPS id i67-20020a639d46000000b005b8ececd69esi1036539pgd.670.2023.10.24.06.21.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 24 Oct 2023 06:21:18 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) client-ip=23.128.96.37; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=IFf5k+VO; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by snail.vger.email (Postfix) with ESMTP id A444E802CFC0; Tue, 24 Oct 2023 06:21:17 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343495AbjJXNVK (ORCPT + 26 others); Tue, 24 Oct 2023 09:21:10 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44138 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234483AbjJXNUw (ORCPT ); Tue, 24 Oct 2023 09:20:52 -0400 Received: from mail-lf1-x12f.google.com (mail-lf1-x12f.google.com [IPv6:2a00:1450:4864:20::12f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A533FE8 for ; Tue, 24 Oct 2023 06:20:40 -0700 (PDT) Received: by mail-lf1-x12f.google.com with SMTP id 2adb3069b0e04-50802148be9so1667902e87.2 for ; Tue, 24 Oct 2023 06:20:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1698153639; x=1698758439; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=IpZ8b7O2cRe1OvuYy4CjSC9AKU1bWUMAZ3eqzNW29dM=; b=IFf5k+VOFbXindKp11L+8xfJZdZX8KIsLMPpYcuaPCeI3dS6gwGel/I8D4zfhUW+RT FtaSr05apHp1DC7bv2xr5THYhPQlLEbXLhXW+/jRJTdVpFWC4X3SfaNUQmg3VOu5NO9L e/uwwiw0vR2dw09qK2iEKLu4Sj7AV+JeStNcQNLslZljVMERi1haXCvmuWiosf4GeFkH DBaIyZeLeiK/kVopGzxFKX7b/ITfJPHRYyq+8RmVi1T6BDszdpK0ThsY/UUnr6m6qZNT XZOaqMMWzi5K2rmynEOVKvMTauceqqBWCEd8VOfP52EEwunntCfyemziFWkIexR0EKEl eLaw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1698153639; x=1698758439; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=IpZ8b7O2cRe1OvuYy4CjSC9AKU1bWUMAZ3eqzNW29dM=; b=Wf2Ut7d/fGZK80ZKS4uEgI+ukzRt/nLcO7pTp9RyYEDKxMk5F7znUIvDgnl34aDkrl lVInbVECIHqD/Xk9QPNq30NtYhZSXDge6ARuWMl/kuDZnxqdPm1JFS8FF+bgpA2dATsZ 8H2jgCD/lFAmXQD6LQF9r89k1rxImEbPnyBl6orjf4Gk/bM7IqU9PJ/6dQ8oeZpsKwE9 MmS05KmG+LlcalCfHtAs9xmaOlvAikBdzbxjTq9RtLNEagAxHEqWhKuajSk/4teCf6ua NQyUvxv+DOhmJXQuG2mB+TbLRr6qb98DecJm96VATJIZgZRZGF/EBaKrLdzumcv/2ibG PV7A== X-Gm-Message-State: AOJu0YwvQ17b98hsZug19RIYihenYLqa222iF1KSdNd+XcpyPywStLWK 2SWfePDMqv0hQTQ/3bll9h0OIQ== X-Received: by 2002:ac2:4183:0:b0:507:9f51:acee with SMTP id z3-20020ac24183000000b005079f51aceemr7796503lfh.22.1698153638918; Tue, 24 Oct 2023 06:20:38 -0700 (PDT) Received: from [127.0.1.1] ([85.235.12.238]) by smtp.gmail.com with ESMTPSA id d5-20020a193845000000b00507ab956ab9sm2147365lfj.147.2023.10.24.06.20.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 24 Oct 2023 06:20:38 -0700 (PDT) From: Linus Walleij Date: Tue, 24 Oct 2023 15:20:33 +0200 Subject: [PATCH net-next v7 7/7] dt-bindings: marvell: Add Marvell MV88E6060 DSA schema MIME-Version: 1.0 Message-Id: <20231024-marvell-88e6152-wan-led-v7-7-2869347697d1@linaro.org> References: <20231024-marvell-88e6152-wan-led-v7-0-2869347697d1@linaro.org> In-Reply-To: <20231024-marvell-88e6152-wan-led-v7-0-2869347697d1@linaro.org> To: Andrew Lunn , Gregory Clement , Sebastian Hesselbarth , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Russell King , Florian Fainelli , Vladimir Oltean , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , =?utf-8?q?Marek_Beh=C3=BAn?= Cc: Christian Marangi , linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, netdev@vger.kernel.org, Linus Walleij , Vladimir Oltean , Rob Herring X-Mailer: b4 0.12.4 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_BLOCKED, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (snail.vger.email [0.0.0.0]); Tue, 24 Oct 2023 06:21:17 -0700 (PDT) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1780643191762859906 X-GMAIL-MSGID: 1780643191762859906 The Marvell MV88E6060 is one of the oldest DSA switches from Marvell, and it has DT bindings used in the wild. Let's define them properly. It is different enough from the rest of the MV88E6xxx switches that it deserves its own binding. Reviewed-by: Andrew Lunn Reviewed-by: Vladimir Oltean Reviewed-by: Rob Herring Signed-off-by: Linus Walleij Reviewed-by: Florian Fainelli --- .../bindings/net/dsa/marvell,mv88e6060.yaml | 88 ++++++++++++++++++++++ MAINTAINERS | 1 + 2 files changed, 89 insertions(+) diff --git a/Documentation/devicetree/bindings/net/dsa/marvell,mv88e6060.yaml b/Documentation/devicetree/bindings/net/dsa/marvell,mv88e6060.yaml new file mode 100644 index 000000000000..4f1adf00431a --- /dev/null +++ b/Documentation/devicetree/bindings/net/dsa/marvell,mv88e6060.yaml @@ -0,0 +1,88 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/net/dsa/marvell,mv88e6060.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Marvell MV88E6060 DSA switch + +maintainers: + - Andrew Lunn + +description: + The Marvell MV88E6060 switch has been produced and sold by Marvell + since at least 2008. The switch has one pin ADDR4 that controls the + MDIO address of the switch to be 0x10 or 0x00, and on the MDIO bus + connected to the switch, the PHYs inside the switch appear as + independent devices on address 0x00-0x04 or 0x10-0x14, so in difference + from many other DSA switches this switch does not have an internal + MDIO bus for the PHY devices. + +properties: + compatible: + const: marvell,mv88e6060 + description: + The MV88E6060 is the oldest Marvell DSA switch product, and + as such a bit limited in features compared to later hardware. + + reg: + maxItems: 1 + + reset-gpios: + description: + GPIO to be used to reset the whole device + maxItems: 1 + +allOf: + - $ref: dsa.yaml#/$defs/ethernet-ports + +required: + - compatible + - reg + +unevaluatedProperties: false + +examples: + - | + #include + #include + mdio { + #address-cells = <1>; + #size-cells = <0>; + + ethernet-switch@16 { + compatible = "marvell,mv88e6060"; + reg = <16>; + + ethernet-ports { + #address-cells = <1>; + #size-cells = <0>; + + ethernet-port@0 { + reg = <0>; + label = "lan1"; + }; + ethernet-port@1 { + reg = <1>; + label = "lan2"; + }; + ethernet-port@2 { + reg = <2>; + label = "lan3"; + }; + ethernet-port@3 { + reg = <3>; + label = "lan4"; + }; + ethernet-port@5 { + reg = <5>; + phy-mode = "rev-mii"; + ethernet = <ðc>; + fixed-link { + speed = <100>; + full-duplex; + }; + }; + }; + }; + }; diff --git a/MAINTAINERS b/MAINTAINERS index 1b4475254d27..4c933a2a56ad 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -12625,6 +12625,7 @@ MARVELL 88E6XXX ETHERNET SWITCH FABRIC DRIVER M: Andrew Lunn L: netdev@vger.kernel.org S: Maintained +F: Documentation/devicetree/bindings/net/dsa/marvell,mv88e6060.yaml F: Documentation/devicetree/bindings/net/dsa/marvell,mv88e6xxx.yaml F: Documentation/networking/devlink/mv88e6xxx.rst F: drivers/net/dsa/mv88e6xxx/