Andrew Lunn | 14c7b3c | 2016-05-10 23:27:21 +0200 | [diff] [blame] | 1 | Marvell DSA Switch Device Tree Bindings |
| 2 | --------------------------------------- |
| 3 | |
| 4 | WARNING: This binding is currently unstable. Do not program it into a |
| 5 | FLASH never to be changed again. Once this binding is stable, this |
| 6 | warning will be removed. |
| 7 | |
| 8 | If you need a stable binding, use the old dsa.txt binding. |
| 9 | |
| 10 | Marvell Switches are MDIO devices. The following properties should be |
| 11 | placed as a child node of an mdio device. |
| 12 | |
Andrew Lunn | 52638f7 | 2016-05-10 23:27:22 +0200 | [diff] [blame] | 13 | The properties described here are those specific to Marvell devices. |
| 14 | Additional required and optional properties can be found in dsa.txt. |
| 15 | |
Andrew Lunn | 14c7b3c | 2016-05-10 23:27:21 +0200 | [diff] [blame] | 16 | Required properties: |
Andrew Lunn | d234559 | 2017-01-25 02:44:48 +0100 | [diff] [blame] | 17 | - compatible : Should be one of "marvell,mv88e6085" or |
| 18 | "marvell,mv88e6190" |
| 19 | - reg : Address on the MII bus for the switch. |
Andrew Lunn | 14c7b3c | 2016-05-10 23:27:21 +0200 | [diff] [blame] | 20 | |
Andrew Lunn | 52638f7 | 2016-05-10 23:27:22 +0200 | [diff] [blame] | 21 | Optional properties: |
| 22 | |
| 23 | - reset-gpios : Should be a gpio specifier for a reset line |
Andrew Lunn | dc30c35 | 2016-10-16 19:56:49 +0200 | [diff] [blame] | 24 | - interrupt-parent : Parent interrupt controller |
| 25 | - interrupts : Interrupt from the switch |
| 26 | - interrupt-controller : Indicates the switch is itself an interrupt |
| 27 | controller. This is used for the PHY interrupts. |
| 28 | #interrupt-cells = <2> : Controller uses two cells, number and flag |
Andrew Lunn | a3c53be | 2017-01-24 14:53:50 +0100 | [diff] [blame] | 29 | - mdio : Container of PHY and devices on the switches MDIO |
| 30 | bus. |
Andrew Lunn | d234559 | 2017-01-25 02:44:48 +0100 | [diff] [blame] | 31 | - mdio? : Container of PHYs and devices on the external MDIO |
Andrew Lunn | a3c53be | 2017-01-24 14:53:50 +0100 | [diff] [blame] | 32 | bus. The node must contains a compatible string of |
| 33 | "marvell,mv88e6xxx-mdio-external" |
| 34 | |
Andrew Lunn | 14c7b3c | 2016-05-10 23:27:21 +0200 | [diff] [blame] | 35 | Example: |
| 36 | |
Andrew Lunn | d234559 | 2017-01-25 02:44:48 +0100 | [diff] [blame] | 37 | mdio { |
| 38 | #address-cells = <1>; |
| 39 | #size-cells = <0>; |
| 40 | interrupt-parent = <&gpio0>; |
| 41 | interrupts = <27 IRQ_TYPE_LEVEL_LOW>; |
| 42 | interrupt-controller; |
| 43 | #interrupt-cells = <2>; |
Andrew Lunn | 14c7b3c | 2016-05-10 23:27:21 +0200 | [diff] [blame] | 44 | |
Andrew Lunn | d234559 | 2017-01-25 02:44:48 +0100 | [diff] [blame] | 45 | switch0: switch@0 { |
| 46 | compatible = "marvell,mv88e6085"; |
| 47 | reg = <0>; |
| 48 | reset-gpios = <&gpio5 1 GPIO_ACTIVE_LOW>; |
| 49 | }; |
| 50 | mdio { |
| 51 | #address-cells = <1>; |
| 52 | #size-cells = <0>; |
| 53 | switch1phy0: switch1phy0@0 { |
| 54 | reg = <0>; |
| 55 | interrupt-parent = <&switch0>; |
| 56 | interrupts = <0 IRQ_TYPE_LEVEL_HIGH>; |
| 57 | }; |
| 58 | }; |
| 59 | }; |
Andrew Lunn | a3c53be | 2017-01-24 14:53:50 +0100 | [diff] [blame] | 60 | |
Andrew Lunn | d234559 | 2017-01-25 02:44:48 +0100 | [diff] [blame] | 61 | mdio { |
| 62 | #address-cells = <1>; |
| 63 | #size-cells = <0>; |
| 64 | interrupt-parent = <&gpio0>; |
| 65 | interrupts = <27 IRQ_TYPE_LEVEL_LOW>; |
| 66 | interrupt-controller; |
| 67 | #interrupt-cells = <2>; |
Andrew Lunn | a3c53be | 2017-01-24 14:53:50 +0100 | [diff] [blame] | 68 | |
Andrew Lunn | d234559 | 2017-01-25 02:44:48 +0100 | [diff] [blame] | 69 | switch0: switch@0 { |
| 70 | compatible = "marvell,mv88e6390"; |
| 71 | reg = <0>; |
| 72 | reset-gpios = <&gpio5 1 GPIO_ACTIVE_LOW>; |
| 73 | }; |
| 74 | mdio { |
| 75 | #address-cells = <1>; |
| 76 | #size-cells = <0>; |
| 77 | switch1phy0: switch1phy0@0 { |
| 78 | reg = <0>; |
| 79 | interrupt-parent = <&switch0>; |
| 80 | interrupts = <0 IRQ_TYPE_LEVEL_HIGH>; |
| 81 | }; |
| 82 | }; |
Andrew Lunn | a3c53be | 2017-01-24 14:53:50 +0100 | [diff] [blame] | 83 | |
Andrew Lunn | d234559 | 2017-01-25 02:44:48 +0100 | [diff] [blame] | 84 | mdio1 { |
| 85 | compatible = "marvell,mv88e6xxx-mdio-external"; |
| 86 | #address-cells = <1>; |
| 87 | #size-cells = <0>; |
| 88 | switch1phy9: switch1phy0@9 { |
| 89 | reg = <9>; |
| 90 | }; |
| 91 | }; |
| 92 | }; |