From patchwork Thu Jan 12 17:56:03 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Colin Foster X-Patchwork-Id: 13098528 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 18104C61DB3 for ; Thu, 12 Jan 2023 17:58:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:MIME-Version: Content-Transfer-Encoding:Content-Type:Message-Id:Date:Subject:Cc:To:From: Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender :Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Owner; bh=vuRJYGVT/Vh49Xb904JLBrCmEXn3TP7z+ALpsSWKcjM=; b=Nu4I3FajWGMTIy05qH8dNUSkG8 mgpK/ddYcIWEAXMqpWlDi1wzXjZqcf82s9MkSMt2nycXy1v/yIlQMGlv89NK4VMiN4O6RGCOOBLGd NgPXfGf/WoGeLcLYlcNbaPGH0dcgDP+zT5IbYan8AxTXTugYDUI5O3QawpuEYwz5rFwtHQTLR7ps5 b+pv3WfQ/VEOk5uCSyvdUqncVpS49e3SYrFCHJhVhmvZwHyscEKe/WqPgLXoFM351pdR9QeTKIWnb RY5eKtl3S2zT44rlP5s/bWk3ldZSQ51OI4jfpoUlJbIsjKi5L6yggSNT0OqFegkoM8hUBXRXqkbtj FWaH8UAA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pG1py-00G9fy-Kj; Thu, 12 Jan 2023 17:58:02 +0000 Received: from mail-bn8nam11on2100.outbound.protection.outlook.com ([40.107.236.100] helo=NAM11-BN8-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1pG1ob-00G9Dv-2Z; Thu, 12 Jan 2023 17:56:40 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=JsTSCd+wONXXHvmtPrb9906Dr9NSF7/Q2r8d1+8w1EqGhA3OUkj4ypqmNrOKjDOjzzSi1W/l9Xi1JkftWmkIhsqYuq2Hp731WXXn78L8lZpss5QryowoYgblsp5flhr6R1TymmZupFTHLONnT4Rf4b6mXZrYCvx5JH0Fm6EDGgpEP1e5s9XAIu6T3qoSfXVAkFM+7ABvojI2sBivXarPvD+HtolXZEMlD9vSAD8wU+yHD8LBueBbAVkby2oYxRqFw5VOGe8fUkXPLa7B6EhjLhypLHsWWPrOxgEZ+kmkPs1yBzsOy4oriPyoIt/d012HNmMmI1QazUl1YN1wXK5lXg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=vuRJYGVT/Vh49Xb904JLBrCmEXn3TP7z+ALpsSWKcjM=; b=Cu7uyRu8eUlEcU/SD3SDSuiutiRnka9AO3dAoWofwumhr/UUGjOiXAmUiKjkN5gNg+CtNCKpYSd9QI9WJBb7n39hAmo8AXoWYPEkWGht2lLK6sYPUQnHzP33Wm11c6otSpQEJG5UJf0oUINzyVGTnefEH19/+tDU8DabBQJjuNjU1QMpM3+/jqdQh3JQpAGHG5ZHGPESmLlAnQxvzai84CxNU9tD3a9ykW49/sTmli9ltNTYz1H0ds+o+4iyHduaT+VEdlmjrEiT8HgLj3Xr70uRj326aSn9YtIdbDjILiUDvowmfNQ9jWjCDMJFMXYslXYZkJunjVrRWHeHLVoyKg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=in-advantage.com; dmarc=pass action=none header.from=in-advantage.com; dkim=pass header.d=in-advantage.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=inadvantage.onmicrosoft.com; s=selector2-inadvantage-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=vuRJYGVT/Vh49Xb904JLBrCmEXn3TP7z+ALpsSWKcjM=; b=V5Rw+HTfn0Mu83QQJ3As7F05N7tTqEVDf/47nGlntvCM+mnLQFZj0kEzO82qrvhO5eyMRFUSrZ8Bh3EIJwqPQKY0/Hv3STAnTSoDSeoD4bN2V/iQQdo3vysknuFFEAlyuKSpuDW20Ny8NTAs7ETlrEpapfNxv43Y0S04EeKyi/E= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=in-advantage.com; Received: from MWHPR1001MB2351.namprd10.prod.outlook.com (2603:10b6:301:35::37) by SN7PR10MB6548.namprd10.prod.outlook.com (2603:10b6:806:2ab::5) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6002.12; Thu, 12 Jan 2023 17:56:29 +0000 Received: from MWHPR1001MB2351.namprd10.prod.outlook.com ([fe80::2015:3589:3e96:2acd]) by MWHPR1001MB2351.namprd10.prod.outlook.com ([fe80::2015:3589:3e96:2acd%5]) with mapi id 15.20.6002.012; Thu, 12 Jan 2023 17:56:28 +0000 From: Colin Foster To: linux-renesas-soc@vger.kernel.org, linux-mediatek@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, netdev@vger.kernel.org Cc: John Crispin , Alexandre Belloni , Claudiu Manoil , Marek Vasut , Sean Wang , DENG Qingfang , Landen Chao , =?utf-8?b?bsOnIMOcTkFM?= , =?utf-8?b?Q2zDqW1lbnQg?= =?utf-8?b?TMOpZ2Vy?= , =?utf-8?q?Alvin_=C5=A0ipr?= =?utf-8?q?aga?= , Linus Walleij , UNGLinuxDriver@microchip.com, Woojung Huh , Matthias Brugger , Kurt Kanzenbach , Rob Herring , Paolo Abeni , Jakub Kicinski , Eric Dumazet , "David S. Miller" , Vladimir Oltean , Florian Fainelli , Andrew Lunn , George McCollister Subject: [PATCH v7 net-next 00/10] dt-binding preparation for ocelot switches Date: Thu, 12 Jan 2023 07:56:03 -1000 Message-Id: <20230112175613.18211-1-colin.foster@in-advantage.com> X-Mailer: git-send-email 2.25.1 X-ClientProxiedBy: BY3PR03CA0002.namprd03.prod.outlook.com (2603:10b6:a03:39a::7) To MWHPR1001MB2351.namprd10.prod.outlook.com (2603:10b6:301:35::37) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: MWHPR1001MB2351:EE_|SN7PR10MB6548:EE_ X-MS-Office365-Filtering-Correlation-Id: e1771c84-3c66-41ba-c0e6-08daf4c6548b X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: Nk/B+jlyoDc+uNeCGAfJq71wyv59XHQ/Thbxj+DEhWnReROg5KbF0OSiOGxTHXaomAhRVHQIpKQGKGFoycwGNndV5oCC/QGs/5ym23n1ytvCqh3EfaSG6a6k6R/BMtLmlXdTXNActThqvVeVcciFL5k1Mgn9P5s3vEEvFyUcc9Hd7Mkobrs5NErEJAxowOa4y5aFCWhiSrykx1N8PRUMGpB7aYDPP3RQhmydU93Yv4nhA3WtYmYh+APljdXHyKaBgYCLbeMy6J2vSZGmErlUCVxbnRuw9BmAVmTHhno2Y6UWpPc1IQQn4LE7rKphli/Mh5ByRI4v95wQTLWuqbWzucBeyIsvWnS1hV+qkQ8iin0qq8FPcvThmgGK4w4CRu2TVujFmhJWmrPmpgonDQBboH7WEFprHBKlKbkIntj8qgGm83Qk+jrA7VS0eDCaT1N/YLhzmvpoQPvYnKbQ9HpXgEImoSFGyNi7Vdvp5VH8UA7i0vMdQ5Ra6TkL4PVEmOb8immVfFck5zyl2yTaFhqDtkLWWHkGkd1lS7oOGkPfbTh/tmOdh7LsT5tNx5OfKRxmlbH1EVurebsem+90BOFH85YNTVNNMbhE2zE8hfzpQDlSY0d8FJb4Bnmz2DRu81ZIzrQWfr8giPbXzBuuGxFOQg== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:MWHPR1001MB2351.namprd10.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230022)(396003)(136003)(376002)(366004)(39830400003)(346002)(451199015)(66476007)(41300700001)(66556008)(66946007)(8676002)(7406005)(5660300002)(7416002)(316002)(44832011)(54906003)(66899015)(4326008)(8936002)(2906002)(86362001)(38100700002)(478600001)(36756003)(6486002)(52116002)(6666004)(186003)(6506007)(1076003)(2616005)(6512007)(83380400001);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?q?bzVcM3e9fe2RycNkMiy6qjEvfq2W?= =?utf-8?q?2rwJyS4UZQwqyDv3eQqrjD6QCVeGRXU5ALW20OK+w8DWwUrKoWUmGnxhv5b9ekCKl?= =?utf-8?q?cDw+aOB1bAaW9ulvaQYzxX6Q8FCbwY0exHKw7jtAPAppGCl71EuA8L4brbK4A3Zls?= =?utf-8?q?17MzDltsZABZmtIbiYuC5RHwvm6K5X+56R0WXYkMcmL32hpZFar+cT1TS6hpKJRkn?= =?utf-8?q?jX0ES8r/qzz01J5qivr5/Nlm/OTZlII7qczrfHJfyPq2F32rNgKcEhkgPGrTdsvwi?= =?utf-8?q?tl+OjSS3JTmNBZZF3atfJuftgWta9R4oPJaqMYaV6PZ9Dsf/ULPse2/P1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rTfjgQGgvwxitDrT1pg9spVgQD?= =?utf-8?q?UV85S/aKq23XGJgc2Cek6QTuJLduEef8atrLINZeszJjE9vl+QfRiwU2oeuY/5p9n?= =?utf-8?q?ARB19nbFOocE5mHo6wvVk7DxXGp7tQvZCi49j6o2gBXtTRiWfq8wQBY+aaKX6A7+7?= =?utf-8?q?wEAOBxZYrcVtf6yFE/X4XB8emluquQ+MxUJCGQvbS6fkxmhyj/k9HZlvPQ0fu2qcX?= =?utf-8?q?t4F9JngeRExaypUOc4Suo3cLjbhgvwH0VOFUw9kauKcpi5jwu3n8tF5TPtE3bBmwh?= =?utf-8?q?lR68uICw06y3Yea6yCaOJh/ZyugZZADJ4HGuTrkH/NHjrl3kjGJ05/l1/V7irLiX/?= =?utf-8?q?dpUiz+YVKdTqsd5QYEFgtTzB9Nrga0D/7ATXl8POt/AJdg1R3TesZp2HO9NVTfrY/?= =?utf-8?q?bX3isBco5ogZ+xQ+RkV2MfAPb1skRGSeFq2opJThTQuivQ0anB1HEw=3D?= X-OriginatorOrg: in-advantage.com X-MS-Exchange-CrossTenant-Network-Message-Id: e1771c84-3c66-41ba-c0e6-08daf4c6548b X-MS-Exchange-CrossTenant-AuthSource: MWHPR1001MB2351.namprd10.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 12 Jan 2023 17:56:28.8462 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 48e842ca-fbd8-4633-a79d-0c955a7d3aae X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: FdDB5/vxWA8qf9EIEUg/aUJcX23+kDqH+52mi/X51QsVRvXxs90n5Fiq9DFyjaQqH2BhnC4W6XLlkwNUqN3ePRJe4Tr4WJ3EVw0M7BwgEgE= X-MS-Exchange-Transport-CrossTenantHeadersStamped: SN7PR10MB6548 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230112_095637_352770_4D6D1EE1 X-CRM114-Status: GOOD ( 19.11 ) X-BeenThere: linux-mediatek@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Linux-mediatek" Errors-To: linux-mediatek-bounces+linux-mediatek=archiver.kernel.org@lists.infradead.org Ocelot switches have the abilitiy to be used internally via memory-mapped IO or externally via SPI or PCIe. This brings up issues for documentation, where the same chip might be accessed internally in a switchdev manner, or externally in a DSA configuration. This patch set is perparation to bring DSA functionality to the VSC7512, utilizing as much as possible with an almost identical VSC7514 chip. This patch set changed quite a bit from v2, so I'll omit the background of how those sets came to be. Rob offered a lot of very useful guidance. My thanks. At the end of the day, with this patch set, there should be a framework to document Ocelot switches (and any switch) in scenarios where they can be controlled internally (ethernet-switch) or externally (dsa-switch). --- v6 -> v7 * Add Reviewed / Acked on patch 1 * Clean up descriptions on Ethernet / DSA switch port bindings v5 -> v6 * Rebase so it applies to net-next cleanly. * No other changes - during the last submission round I said I'd submit v6 with a change to move $dsa-port.yaml to outside the allOf list. In retrospect that wasn't the right thing to do, because later in the patch series the $dsa-port.yaml is removed outright. So I believe the submission in v5 to keep "type: object" was correct. v4 -> v5 * Sync DSA maintainers with MAINTAINERS file (new patch 1) * Undo move of port description of mediatek,mt7530.yaml (patch 4) * Move removal of "^(ethernet-)?switch(@.*)?$" in dsa.yaml from patch 4 to patch 8 * Add more consistent capitalization in title lines and better Ethernet switch port description. (patch 8) v3 -> v4 * Renamed "base" to "ethernet-ports" to avoid confusion with the concept of a base class. * Squash ("dt-bindings: net: dsa: mediatek,mt7530: fix port description location") patch into ("dt-bindings: net: dsa: utilize base definitions for standard dsa switches") * Corrections to fix confusion about additonalProperties vs unevaluatedProperties. See specific patches for details. v2 -> v3 * Restructured everything to use a "base" iref for devices that don't have additional properties, and simply a "ref" for devices that do. * New patches to fix up brcm,sf2, qca8k, and mt7530 * Fix unevaluatedProperties errors from previous sets (see specific patches for more detail) * Removed redundant "Device Tree Binding" from titles, where applicable. v1 -> v2 * Two MFD patches were brought into the MFD tree, so are dropped * Add first patch 1/6 to allow DSA devices to add ports and port properties * Test qca8k against new dt-bindings and fix warnings. (patch 2/6) * Add tags (patch 3/6) * Fix vsc7514 refs and properties --- Colin Foster (10): dt-bindings: dsa: sync with maintainers dt-bindings: net: dsa: sf2: fix brcm,use-bcm-hdr documentation dt-bindings: net: dsa: qca8k: remove address-cells and size-cells from switch node dt-bindings: net: dsa: utilize base definitions for standard dsa switches dt-bindings: net: dsa: allow additional ethernet-port properties dt-bindings: net: dsa: qca8k: utilize shared dsa.yaml dt-bindings: net: dsa: mediatek,mt7530: remove unnecessary dsa-port reference dt-bindings: net: add generic ethernet-switch dt-bindings: net: add generic ethernet-switch-port binding dt-bindings: net: mscc,vsc7514-switch: utilize generic ethernet-switch.yaml .../bindings/net/dsa/arrow,xrs700x.yaml | 2 +- .../devicetree/bindings/net/dsa/brcm,b53.yaml | 2 +- .../devicetree/bindings/net/dsa/brcm,sf2.yaml | 15 +++-- .../devicetree/bindings/net/dsa/dsa-port.yaml | 30 ++------- .../devicetree/bindings/net/dsa/dsa.yaml | 49 +++++++-------- .../net/dsa/hirschmann,hellcreek.yaml | 2 +- .../bindings/net/dsa/mediatek,mt7530.yaml | 6 +- .../bindings/net/dsa/microchip,ksz.yaml | 2 +- .../bindings/net/dsa/microchip,lan937x.yaml | 2 +- .../bindings/net/dsa/mscc,ocelot.yaml | 2 +- .../bindings/net/dsa/nxp,sja1105.yaml | 2 +- .../devicetree/bindings/net/dsa/qca8k.yaml | 14 +---- .../devicetree/bindings/net/dsa/realtek.yaml | 2 +- .../bindings/net/dsa/renesas,rzn1-a5psw.yaml | 2 +- .../bindings/net/ethernet-switch-port.yaml | 26 ++++++++ .../bindings/net/ethernet-switch.yaml | 62 +++++++++++++++++++ .../bindings/net/mscc,vsc7514-switch.yaml | 31 +--------- MAINTAINERS | 2 + 18 files changed, 145 insertions(+), 108 deletions(-) create mode 100644 Documentation/devicetree/bindings/net/ethernet-switch-port.yaml create mode 100644 Documentation/devicetree/bindings/net/ethernet-switch.yaml