Received: by 10.213.65.68 with SMTP id h4csp677357imn; Fri, 23 Mar 2018 13:14:12 -0700 (PDT) X-Google-Smtp-Source: AG47ELtzVI/ClnKHGzt4X1MQTFdSsQqoDAG/0fYv7tP5/yfU0Ow0cimgxqXhLMlQjIhAstGxlQZ6 X-Received: by 2002:a17:902:341:: with SMTP id 59-v6mr29914958pld.407.1521836052242; Fri, 23 Mar 2018 13:14:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1521836052; cv=none; d=google.com; s=arc-20160816; b=0tm/6N90yV1auPbzxmF2wGFCQ97gqbx3OPhn8OYJvXubnP4LO3U5B2Sqi8XavvnF8e rUomNzX9W2t4MUjDrjkUh2ZyuuRRC+8F4BIQfPibk6wilzHGUtvOrcVBVYa37ugxLzSp DbeMVGFD5h1DYaXC5KM0Ii5mpqbS2CP1ND1kkbkoZObCtTAUQDdXpCyeTlhV7boSpbI5 50ol97KgjLFHF4yyztU5XOWawzSWg7jAKMFOTT6hqo/PWkAC6rcNGrdF5u/yngJ93NWz FOJq3BsIxPq1wwHAv7q7OBVHZf/fRfOIkKELa0ZLGWxhU3jia2sQOHHomX67Wjk2UjX0 g60Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :arc-authentication-results; bh=oplKhshGQrokjJ5uQfMhRcgx6+wcgbgx+d6taaHuk7I=; b=zUbYu97i3b9Iifz8eO9utduj++pu7ahExf6eYqYprPqVYgwv+m/orUq65oIJ+1AmUv JgjqykkX2ja9epJVX6xGErjmf1pQEjQxpp5BnBbr9hBMzq7FM/T/0vdtD3tc5fSTzo9r psVBDDGKPGGACSkG58hGTDIb+QJU8PiUbVfzQt9q9vzdPkoQCVI1HqvaObh1rauqIwZo r91QM8N8N8UJMnHbKAXV+z/kRKuHoyjlnFuvV1nVqPEleq5v1oZVyK8mQOVDy8ITrNKs RvHLvUg2lxA1hBsh+sqrs5vDVaK7hL9oAml3WMjfj5/16WQgl+HoAUfWLlOu856s4fLm 3NEQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id w64si7207119pfi.227.2018.03.23.13.13.57; Fri, 23 Mar 2018 13:14:12 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752159AbeCWULk (ORCPT + 99 others); Fri, 23 Mar 2018 16:11:40 -0400 Received: from mail.bootlin.com ([62.4.15.54]:34883 "EHLO mail.bootlin.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751691AbeCWULh (ORCPT ); Fri, 23 Mar 2018 16:11:37 -0400 Received: by mail.bootlin.com (Postfix, from userid 110) id 6AFB82083D; Fri, 23 Mar 2018 21:11:34 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on mail.bootlin.com X-Spam-Level: X-Spam-Status: No, score=-1.0 required=5.0 tests=ALL_TRUSTED,SHORTCIRCUIT shortcircuit=ham autolearn=disabled version=3.4.0 Received: from localhost (unknown [88.191.26.124]) by mail.bootlin.com (Postfix) with ESMTPSA id 125D020715; Fri, 23 Mar 2018 21:11:34 +0100 (CET) From: Alexandre Belloni To: "David S . Miller" Cc: Allan Nielsen , razvan.stefanescu@nxp.com, po.liu@nxp.com, Thomas Petazzoni , Andrew Lunn , Florian Fainelli , netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mips@linux-mips.org, Alexandre Belloni , James Hogan Subject: [PATCH net-next 0/8] Microsemi Ocelot switch support Date: Fri, 23 Mar 2018 21:11:09 +0100 Message-Id: <20180323201117.8416-1-alexandre.belloni@bootlin.com> X-Mailer: git-send-email 2.16.2 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, This series adds initial support for the Microsemi Ethernet switch present on Ocelot SoCs. This only has bridging (and STP) support for now and it uses the switchdev framework. Coming features are VLAN filtering, link aggregation, IGMP snooping. The switch can also be connected to an external CPU using PCIe. I have a PoC for that but it is still a bit clunky. Also, support for integration on other SoCs will be submitted. The ocelot dts changes are here for reference and should probably go through the MIPS tree once the bindings are accepted. Cc: James Hogan Alexandre Belloni (8): net: phy: Add initial support for Microsemi Ocelot internal PHYs. dt-bindings: net: add DT bindings for Microsemi MIIM net: mscc: Add MDIO driver dt-bindings: net: add DT bindings for Microsemi Ocelot Switch net: mscc: Add initial Ocelot switch support MIPS: mscc: Add switch to ocelot MIPS: mscc: connect phys to ports on ocelot_pcb123 MAINTAINERS: Add entry for Microsemi Ethernet switches .../devicetree/bindings/net/mscc-miim.txt | 25 + .../devicetree/bindings/net/mscc-ocelot.txt | 62 + MAINTAINERS | 6 + arch/mips/boot/dts/mscc/ocelot.dtsi | 84 ++ arch/mips/boot/dts/mscc/ocelot_pcb123.dts | 16 + drivers/net/ethernet/Kconfig | 1 + drivers/net/ethernet/Makefile | 1 + drivers/net/ethernet/mscc/Kconfig | 36 + drivers/net/ethernet/mscc/Makefile | 6 + drivers/net/ethernet/mscc/mscc_miim.c | 210 +++ drivers/net/ethernet/mscc/ocelot.c | 1346 ++++++++++++++++++++ drivers/net/ethernet/mscc/ocelot.h | 554 ++++++++ drivers/net/ethernet/mscc/ocelot_ana.h | 625 +++++++++ drivers/net/ethernet/mscc/ocelot_board.c | 329 +++++ drivers/net/ethernet/mscc/ocelot_dev.h | 275 ++++ drivers/net/ethernet/mscc/ocelot_dev_gmii.h | 154 +++ drivers/net/ethernet/mscc/ocelot_hsio.h | 785 ++++++++++++ drivers/net/ethernet/mscc/ocelot_io.c | 116 ++ drivers/net/ethernet/mscc/ocelot_qs.h | 78 ++ drivers/net/ethernet/mscc/ocelot_qsys.h | 270 ++++ drivers/net/ethernet/mscc/ocelot_regs.c | 399 ++++++ drivers/net/ethernet/mscc/ocelot_rew.h | 81 ++ drivers/net/ethernet/mscc/ocelot_sys.h | 140 ++ drivers/net/phy/mscc.c | 15 + 24 files changed, 5614 insertions(+) create mode 100644 Documentation/devicetree/bindings/net/mscc-miim.txt create mode 100644 Documentation/devicetree/bindings/net/mscc-ocelot.txt create mode 100644 drivers/net/ethernet/mscc/Kconfig create mode 100644 drivers/net/ethernet/mscc/Makefile create mode 100644 drivers/net/ethernet/mscc/mscc_miim.c create mode 100644 drivers/net/ethernet/mscc/ocelot.c create mode 100644 drivers/net/ethernet/mscc/ocelot.h create mode 100644 drivers/net/ethernet/mscc/ocelot_ana.h create mode 100644 drivers/net/ethernet/mscc/ocelot_board.c create mode 100644 drivers/net/ethernet/mscc/ocelot_dev.h create mode 100644 drivers/net/ethernet/mscc/ocelot_dev_gmii.h create mode 100644 drivers/net/ethernet/mscc/ocelot_hsio.h create mode 100644 drivers/net/ethernet/mscc/ocelot_io.c create mode 100644 drivers/net/ethernet/mscc/ocelot_qs.h create mode 100644 drivers/net/ethernet/mscc/ocelot_qsys.h create mode 100644 drivers/net/ethernet/mscc/ocelot_regs.c create mode 100644 drivers/net/ethernet/mscc/ocelot_rew.h create mode 100644 drivers/net/ethernet/mscc/ocelot_sys.h -- 2.16.2