Commit ec762403 authored by David S. Miller's avatar David S. Miller
Browse files

Merge branch 'net-stmmac-Add-Toshiba-Visconti-SoCs-glue-driver'



Nobuhiro Iwamatsu says:

====================
net: stmmac: Add Toshiba Visconti SoCs glue driver

This series is the ethernet driver for Toshiba's ARM SoC, Visconti[0].
This provides DT binding documentation, device driver, MAINTAINER files,
and updates to DT files.
====================

Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parents 3a616b92 ec8a42e7
Loading
Loading
Loading
Loading
+85 −0
Original line number Diff line number Diff line
# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
%YAML 1.2
---
$id: "http://devicetree.org/schemas/net/toshiba,visconti-dwmac.yaml#"
$schema: "http://devicetree.org/meta-schemas/core.yaml#"

title: Toshiba Visconti DWMAC Ethernet controller

maintainers:
  - Nobuhiro Iwamatsu <nobuhiro1.iwamatsu@toshiba.co.jp>

select:
  properties:
    compatible:
      contains:
        enum:
          - toshiba,visconti-dwmac
  required:
    - compatible

allOf:
  - $ref: "snps,dwmac.yaml#"

properties:
  compatible:
    oneOf:
      - items:
          - enum:
              - toshiba,visconti-dwmac
          - const: snps,dwmac-4.20a

  reg:
    maxItems: 1

  clocks:
    items:
      - description: main clock
      - description: PHY reference clock

  clock-names:
    items:
      - const: stmmaceth
      - const: phy_ref_clk

required:
  - compatible
  - reg
  - clocks
  - clock-names

unevaluatedProperties: false

examples:
  - |
    #include <dt-bindings/interrupt-controller/arm-gic.h>

    soc {
        #address-cells = <2>;
        #size-cells = <2>;

        piether: ethernet@28000000 {
            compatible = "toshiba,visconti-dwmac", "snps,dwmac-4.20a";
            reg = <0 0x28000000 0 0x10000>;
            interrupts = <GIC_SPI 156 IRQ_TYPE_LEVEL_HIGH>;
            interrupt-names = "macirq";
            clocks = <&clk300mhz>, <&clk125mhz>;
            clock-names = "stmmaceth", "phy_ref_clk";
            snps,txpbl = <4>;
            snps,rxpbl = <4>;
            snps,tso;
            phy-mode = "rgmii-id";
            phy-handle = <&phy0>;

            mdio0 {
                #address-cells = <0x1>;
                #size-cells = <0x0>;
                compatible = "snps,dwmac-mdio";

                phy0: ethernet-phy@1 {
                    device_type = "ethernet-phy";
                    reg = <0x1>;
                };
            };
        };
    };
+2 −0
Original line number Diff line number Diff line
@@ -2641,8 +2641,10 @@ L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
S:	Supported
T:	git git://git.kernel.org/pub/scm/linux/kernel/git/iwamatsu/linux-visconti.git
F:	Documentation/devicetree/bindings/arm/toshiba.yaml
F:	Documentation/devicetree/bindings/net/toshiba,visconti-dwmac.yaml
F:	Documentation/devicetree/bindings/pinctrl/toshiba,tmpv7700-pinctrl.yaml
F:	arch/arm64/boot/dts/toshiba/
F:	drivers/net/ethernet/stmicro/stmmac/dwmac-visconti.c
F:	drivers/pinctrl/visconti/
N:	visconti
+18 −0
Original line number Diff line number Diff line
@@ -41,3 +41,21 @@
	clocks = <&uart_clk>;
	clock-names = "apb_pclk";
};

&piether {
	status = "okay";
	phy-handle = <&phy0>;
	phy-mode = "rgmii-id";
	clocks = <&clk300mhz>, <&clk125mhz>;
	clock-names = "stmmaceth", "phy_ref_clk";

	mdio0 {
		#address-cells = <1>;
		#size-cells = <0>;
		compatible = "snps,dwmac-mdio";
		phy0: ethernet-phy@1 {
			device_type = "ethernet-phy";
			reg = <0x1>;
		};
	};
};
+25 −0
Original line number Diff line number Diff line
@@ -134,6 +134,20 @@
		#clock-cells = <0>;
	};

	clk125mhz: clk125mhz {
		compatible = "fixed-clock";
		clock-frequency = <125000000>;
		#clock-cells = <0>;
		clock-output-names = "clk125mhz";
	};

	clk300mhz: clk300mhz {
		compatible = "fixed-clock";
		clock-frequency = <300000000>;
		#clock-cells = <0>;
		clock-output-names = "clk300mhz";
	};

	soc {
		#address-cells = <2>;
		#size-cells = <2>;
@@ -384,6 +398,17 @@
			#size-cells = <0>;
			status = "disabled";
		};

		piether: ethernet@28000000 {
			compatible = "toshiba,visconti-dwmac", "snps,dwmac-4.20a";
			reg = <0 0x28000000 0 0x10000>;
			interrupts = <GIC_SPI 156 IRQ_TYPE_LEVEL_HIGH>;
			interrupt-names = "macirq";
			snps,txpbl = <4>;
			snps,rxpbl = <4>;
			snps,tso;
			status = "disabled";
		};
	};
};

+8 −0
Original line number Diff line number Diff line
@@ -219,6 +219,14 @@ config DWMAC_INTEL_PLAT
	  This selects the Intel platform specific glue layer support for
	  the stmmac device driver. This driver is used for the Intel Keem Bay
	  SoC.

config DWMAC_VISCONTI
	tristate "Toshiba Visconti DWMAC support"
	default ARCH_VISCONTI
	depends on OF && COMMON_CLK && (ARCH_VISCONTI || COMPILE_TEST)
	help
	  Support for ethernet controller on Visconti SoCs.

endif

config DWMAC_INTEL
Loading