1f126890aSEmmanuel Vadot// SPDX-License-Identifier: GPL-2.0-only 2f126890aSEmmanuel Vadot// Copyright (C) 2016 Jamie Lentin <jm@lentin.co.uk> 3f126890aSEmmanuel Vadot 4f126890aSEmmanuel Vadot/dts-v1/; 5f126890aSEmmanuel Vadot 6f126890aSEmmanuel Vadot#include <dt-bindings/gpio/gpio.h> 7f126890aSEmmanuel Vadot#include <dt-bindings/input/input.h> 8f126890aSEmmanuel Vadot#include "orion5x-mv88f5181.dtsi" 9f126890aSEmmanuel Vadot 10f126890aSEmmanuel Vadot/ { 11f126890aSEmmanuel Vadot model = "Netgear WNR854-t"; 12f126890aSEmmanuel Vadot compatible = "netgear,wnr854t", "marvell,orion5x-88f5181", 13f126890aSEmmanuel Vadot "marvell,orion5x"; 14f126890aSEmmanuel Vadot aliases { 15f126890aSEmmanuel Vadot serial0 = &uart0; 16f126890aSEmmanuel Vadot }; 17f126890aSEmmanuel Vadot 18f126890aSEmmanuel Vadot memory { 19f126890aSEmmanuel Vadot device_type = "memory"; 20f126890aSEmmanuel Vadot reg = <0x00000000 0x2000000>; /* 32 MB */ 21f126890aSEmmanuel Vadot }; 22f126890aSEmmanuel Vadot 23f126890aSEmmanuel Vadot chosen { 24f126890aSEmmanuel Vadot stdout-path = "serial0:115200n8"; 25f126890aSEmmanuel Vadot }; 26f126890aSEmmanuel Vadot 27f126890aSEmmanuel Vadot soc { 28f126890aSEmmanuel Vadot ranges = <MBUS_ID(0xf0, 0x01) 0 0xf1000000 0x100000>, 29f126890aSEmmanuel Vadot <MBUS_ID(0x09, 0x00) 0 0xf2200000 0x800>, 30f126890aSEmmanuel Vadot <MBUS_ID(0x01, 0x0f) 0 0xf4000000 0x800000>; 31f126890aSEmmanuel Vadot }; 32f126890aSEmmanuel Vadot 33f126890aSEmmanuel Vadot gpio-keys { 34f126890aSEmmanuel Vadot compatible = "gpio-keys"; 35f126890aSEmmanuel Vadot pinctrl-0 = <&pmx_reset_button>; 36f126890aSEmmanuel Vadot pinctrl-names = "default"; 37f126890aSEmmanuel Vadot 38*0e8011faSEmmanuel Vadot key-reset { 39f126890aSEmmanuel Vadot label = "Reset Button"; 40f126890aSEmmanuel Vadot linux,code = <KEY_RESTART>; 41f126890aSEmmanuel Vadot gpios = <&gpio0 1 GPIO_ACTIVE_LOW>; 42f126890aSEmmanuel Vadot }; 43f126890aSEmmanuel Vadot }; 44f126890aSEmmanuel Vadot 45f126890aSEmmanuel Vadot gpio-leds { 46f126890aSEmmanuel Vadot compatible = "gpio-leds"; 47f126890aSEmmanuel Vadot pinctrl-0 = <&pmx_power_led &pmx_power_led_blink &pmx_wan_led>; 48f126890aSEmmanuel Vadot pinctrl-names = "default"; 49f126890aSEmmanuel Vadot 50f126890aSEmmanuel Vadot led@0 { 51f126890aSEmmanuel Vadot label = "wnr854t:green:power"; 52f126890aSEmmanuel Vadot gpios = <&gpio0 0 GPIO_ACTIVE_LOW>; 53f126890aSEmmanuel Vadot }; 54f126890aSEmmanuel Vadot 55f126890aSEmmanuel Vadot led@1 { 56f126890aSEmmanuel Vadot label = "wnr854t:blink:power"; 57f126890aSEmmanuel Vadot gpios = <&gpio0 2 GPIO_ACTIVE_LOW>; 58f126890aSEmmanuel Vadot }; 59f126890aSEmmanuel Vadot 60f126890aSEmmanuel Vadot led@2 { 61f126890aSEmmanuel Vadot label = "wnr854t:green:wan"; 62f126890aSEmmanuel Vadot gpios = <&gpio0 3 GPIO_ACTIVE_LOW>; 63f126890aSEmmanuel Vadot }; 64f126890aSEmmanuel Vadot }; 65f126890aSEmmanuel Vadot}; 66f126890aSEmmanuel Vadot 67f126890aSEmmanuel Vadot&devbus_bootcs { 68f126890aSEmmanuel Vadot status = "okay"; 69f126890aSEmmanuel Vadot 70f126890aSEmmanuel Vadot devbus,keep-config; 71f126890aSEmmanuel Vadot 72f126890aSEmmanuel Vadot flash@0 { 73f126890aSEmmanuel Vadot compatible = "cfi-flash"; 74f126890aSEmmanuel Vadot reg = <0 0x800000>; 75f126890aSEmmanuel Vadot bank-width = <2>; 76f126890aSEmmanuel Vadot 77f126890aSEmmanuel Vadot partitions { 78f126890aSEmmanuel Vadot compatible = "fixed-partitions"; 79f126890aSEmmanuel Vadot #address-cells = <1>; 80f126890aSEmmanuel Vadot #size-cells = <1>; 81f126890aSEmmanuel Vadot 82f126890aSEmmanuel Vadot partition@0 { 83f126890aSEmmanuel Vadot label = "kernel"; 84f126890aSEmmanuel Vadot reg = <0x0 0x100000>; 85f126890aSEmmanuel Vadot }; 86f126890aSEmmanuel Vadot 87f126890aSEmmanuel Vadot partition@100000 { 88f126890aSEmmanuel Vadot label = "rootfs"; 89f126890aSEmmanuel Vadot reg = <0x100000 0x660000>; 90f126890aSEmmanuel Vadot }; 91f126890aSEmmanuel Vadot 92f126890aSEmmanuel Vadot partition@760000 { 93f126890aSEmmanuel Vadot label = "uboot_env"; 94f126890aSEmmanuel Vadot reg = <0x760000 0x20000>; 95f126890aSEmmanuel Vadot }; 96f126890aSEmmanuel Vadot 97f126890aSEmmanuel Vadot partition@780000 { 98f126890aSEmmanuel Vadot label = "uboot"; 99f126890aSEmmanuel Vadot reg = <0x780000 0x80000>; 100f126890aSEmmanuel Vadot read-only; 101f126890aSEmmanuel Vadot }; 102f126890aSEmmanuel Vadot }; 103f126890aSEmmanuel Vadot }; 104f126890aSEmmanuel Vadot}; 105f126890aSEmmanuel Vadot 106f126890aSEmmanuel Vadot&mdio { 107f126890aSEmmanuel Vadot status = "okay"; 108f126890aSEmmanuel Vadot 109f126890aSEmmanuel Vadot switch: switch@0 { 110f126890aSEmmanuel Vadot compatible = "marvell,mv88e6085"; 111f126890aSEmmanuel Vadot #address-cells = <1>; 112f126890aSEmmanuel Vadot #size-cells = <0>; 113f126890aSEmmanuel Vadot reg = <0>; 114f126890aSEmmanuel Vadot dsa,member = <0 0>; 115f126890aSEmmanuel Vadot 116f126890aSEmmanuel Vadot ports { 117f126890aSEmmanuel Vadot #address-cells = <1>; 118f126890aSEmmanuel Vadot #size-cells = <0>; 119f126890aSEmmanuel Vadot 120f126890aSEmmanuel Vadot port@0 { 121f126890aSEmmanuel Vadot reg = <0>; 122f126890aSEmmanuel Vadot label = "lan3"; 123f126890aSEmmanuel Vadot phy-handle = <&lan3phy>; 124f126890aSEmmanuel Vadot }; 125f126890aSEmmanuel Vadot 126f126890aSEmmanuel Vadot port@1 { 127f126890aSEmmanuel Vadot reg = <1>; 128f126890aSEmmanuel Vadot label = "lan4"; 129f126890aSEmmanuel Vadot phy-handle = <&lan4phy>; 130f126890aSEmmanuel Vadot }; 131f126890aSEmmanuel Vadot 132f126890aSEmmanuel Vadot port@2 { 133f126890aSEmmanuel Vadot reg = <2>; 134f126890aSEmmanuel Vadot label = "wan"; 135f126890aSEmmanuel Vadot phy-handle = <&wanphy>; 136f126890aSEmmanuel Vadot }; 137f126890aSEmmanuel Vadot 138f126890aSEmmanuel Vadot port@3 { 139f126890aSEmmanuel Vadot reg = <3>; 140f126890aSEmmanuel Vadot ethernet = <ðport>; 141f126890aSEmmanuel Vadot phy-mode = "rgmii-id"; 142f126890aSEmmanuel Vadot fixed-link { 143f126890aSEmmanuel Vadot speed = <1000>; 144f126890aSEmmanuel Vadot full-duplex; 145f126890aSEmmanuel Vadot }; 146f126890aSEmmanuel Vadot }; 147f126890aSEmmanuel Vadot 148f126890aSEmmanuel Vadot port@5 { 149f126890aSEmmanuel Vadot reg = <5>; 150f126890aSEmmanuel Vadot label = "lan1"; 151f126890aSEmmanuel Vadot phy-handle = <&lan1phy>; 152f126890aSEmmanuel Vadot }; 153f126890aSEmmanuel Vadot 154f126890aSEmmanuel Vadot port@7 { 155f126890aSEmmanuel Vadot reg = <7>; 156f126890aSEmmanuel Vadot label = "lan2"; 157f126890aSEmmanuel Vadot phy-handle = <&lan2phy>; 158f126890aSEmmanuel Vadot }; 159f126890aSEmmanuel Vadot }; 160f126890aSEmmanuel Vadot 161f126890aSEmmanuel Vadot mdio { 162f126890aSEmmanuel Vadot #address-cells = <1>; 163f126890aSEmmanuel Vadot #size-cells = <0>; 164f126890aSEmmanuel Vadot 165f126890aSEmmanuel Vadot lan3phy: ethernet-phy@0 { 166f126890aSEmmanuel Vadot /* Marvell 88E1121R (port 1) */ 167f126890aSEmmanuel Vadot compatible = "ethernet-phy-id0141.0cb0", 168f126890aSEmmanuel Vadot "ethernet-phy-ieee802.3-c22"; 169f126890aSEmmanuel Vadot reg = <0>; 170f126890aSEmmanuel Vadot marvell,reg-init = <3 16 0 0x1777 3 17 0 0x15>; 171f126890aSEmmanuel Vadot }; 172f126890aSEmmanuel Vadot 173f126890aSEmmanuel Vadot lan4phy: ethernet-phy@1 { 174f126890aSEmmanuel Vadot /* Marvell 88E1121R (port 2) */ 175f126890aSEmmanuel Vadot compatible = "ethernet-phy-id0141.0cb0", 176f126890aSEmmanuel Vadot "ethernet-phy-ieee802.3-c22"; 177f126890aSEmmanuel Vadot reg = <1>; 178f126890aSEmmanuel Vadot marvell,reg-init = <3 16 0 0x1777 3 17 0 0x15>; 179f126890aSEmmanuel Vadot }; 180f126890aSEmmanuel Vadot 181f126890aSEmmanuel Vadot wanphy: ethernet-phy@2 { 182f126890aSEmmanuel Vadot /* Marvell 88E1121R (port 1) */ 183f126890aSEmmanuel Vadot compatible = "ethernet-phy-id0141.0cb0", 184f126890aSEmmanuel Vadot "ethernet-phy-ieee802.3-c22"; 185f126890aSEmmanuel Vadot reg = <2>; 186f126890aSEmmanuel Vadot marvell,reg-init = <3 16 0 0x1777 3 17 0 0x15>; 187f126890aSEmmanuel Vadot }; 188f126890aSEmmanuel Vadot 189f126890aSEmmanuel Vadot lan1phy: ethernet-phy@5 { 190f126890aSEmmanuel Vadot /* Marvell 88E1112 */ 191f126890aSEmmanuel Vadot compatible = "ethernet-phy-id0141.0cb0", 192f126890aSEmmanuel Vadot "ethernet-phy-ieee802.3-c22"; 193f126890aSEmmanuel Vadot reg = <5>; 194f126890aSEmmanuel Vadot marvell,reg-init = <3 16 0 0x1777 3 17 0 0x15>; 195f126890aSEmmanuel Vadot }; 196f126890aSEmmanuel Vadot 197f126890aSEmmanuel Vadot lan2phy: ethernet-phy@7 { 198f126890aSEmmanuel Vadot /* Marvell 88E1112 */ 199f126890aSEmmanuel Vadot compatible = "ethernet-phy-id0141.0cb0", 200f126890aSEmmanuel Vadot "ethernet-phy-ieee802.3-c22"; 201f126890aSEmmanuel Vadot reg = <7>; 202f126890aSEmmanuel Vadot marvell,reg-init = <3 16 0 0x1777 3 17 0 0x15>; 203f126890aSEmmanuel Vadot }; 204f126890aSEmmanuel Vadot }; 205f126890aSEmmanuel Vadot }; 206f126890aSEmmanuel Vadot}; 207f126890aSEmmanuel Vadot 208f126890aSEmmanuel Vadotð { 209f126890aSEmmanuel Vadot status = "okay"; 210f126890aSEmmanuel Vadot 211f126890aSEmmanuel Vadot ethernet-port@0 { 212f126890aSEmmanuel Vadot /* Hardwired to DSA switch */ 213f126890aSEmmanuel Vadot speed = <1000>; 214f126890aSEmmanuel Vadot duplex = <1>; 215f126890aSEmmanuel Vadot phy-mode = "rgmii"; 216f126890aSEmmanuel Vadot }; 217f126890aSEmmanuel Vadot}; 218f126890aSEmmanuel Vadot 219f126890aSEmmanuel Vadot&pinctrl { 220f126890aSEmmanuel Vadot pinctrl-0 = <&pmx_pci_gpios>; 221f126890aSEmmanuel Vadot pinctrl-names = "default"; 222f126890aSEmmanuel Vadot 223f126890aSEmmanuel Vadot pmx_power_led: pmx-power-led { 224f126890aSEmmanuel Vadot marvell,pins = "mpp0"; 225f126890aSEmmanuel Vadot marvell,function = "gpio"; 226f126890aSEmmanuel Vadot }; 227f126890aSEmmanuel Vadot 228f126890aSEmmanuel Vadot pmx_reset_button: pmx-reset-button { 229f126890aSEmmanuel Vadot marvell,pins = "mpp1"; 230f126890aSEmmanuel Vadot marvell,function = "gpio"; 231f126890aSEmmanuel Vadot }; 232f126890aSEmmanuel Vadot 233f126890aSEmmanuel Vadot pmx_power_led_blink: pmx-power-led-blink { 234f126890aSEmmanuel Vadot marvell,pins = "mpp2"; 235f126890aSEmmanuel Vadot marvell,function = "gpio"; 236f126890aSEmmanuel Vadot }; 237f126890aSEmmanuel Vadot 238f126890aSEmmanuel Vadot pmx_wan_led: pmx-wan-led { 239f126890aSEmmanuel Vadot marvell,pins = "mpp3"; 240f126890aSEmmanuel Vadot marvell,function = "gpio"; 241f126890aSEmmanuel Vadot }; 242f126890aSEmmanuel Vadot 243f126890aSEmmanuel Vadot pmx_pci_gpios: pmx-pci-gpios { 244f126890aSEmmanuel Vadot marvell,pins = "mpp4"; 245f126890aSEmmanuel Vadot marvell,function = "gpio"; 246f126890aSEmmanuel Vadot }; 247f126890aSEmmanuel Vadot}; 248f126890aSEmmanuel Vadot 249f126890aSEmmanuel Vadot&uart0 { 250f126890aSEmmanuel Vadot /* Pin 1: Tx, Pin 7: Rx, Pin 8: Gnd */ 251f126890aSEmmanuel Vadot status = "okay"; 252f126890aSEmmanuel Vadot}; 253