diff options
-rwxr-xr-x | target/linux/ramips/base-files/etc/board.d/01_leds | 3 | ||||
-rwxr-xr-x | target/linux/ramips/base-files/etc/board.d/02_network | 4 | ||||
-rwxr-xr-x | target/linux/ramips/base-files/lib/upgrade/platform.sh | 1 | ||||
-rw-r--r-- | target/linux/ramips/dts/R6350.dts | 156 | ||||
-rw-r--r-- | target/linux/ramips/image/mt7621.mk | 17 |
5 files changed, 179 insertions, 2 deletions
diff --git a/target/linux/ramips/base-files/etc/board.d/01_leds b/target/linux/ramips/base-files/etc/board.d/01_leds index 0fca40e1e0..400183acc5 100755 --- a/target/linux/ramips/base-files/etc/board.d/01_leds +++ b/target/linux/ramips/base-files/etc/board.d/01_leds @@ -266,7 +266,8 @@ px-4885-4M|\ px-4885-8M) set_wifi_led "px-4885:orange:wifi" ;; -r6220) +r6220|\ +netgear,r6350) ucidef_set_led_netdev "wan" "wan" "$boardname:green:wan" eth0.2 set_wifi_led "$boardname:green:wifi" ;; diff --git a/target/linux/ramips/base-files/etc/board.d/02_network b/target/linux/ramips/base-files/etc/board.d/02_network index eed8d50392..4cf6159745 100755 --- a/target/linux/ramips/base-files/etc/board.d/02_network +++ b/target/linux/ramips/base-files/etc/board.d/02_network @@ -113,6 +113,7 @@ ramips_setup_interfaces() psg1208|\ psg1218a|\ r6220|\ + netgear,r6350|\ rt-n12p|\ sap-g3200u3|\ sk-wb8|\ @@ -561,7 +562,8 @@ ramips_setup_macs() lan_mac=$(mtd_get_mac_binary factory 40) wan_mac=$(mtd_get_mac_binary factory 46) ;; - r6220) + r6220|\ + netgear,r6350) wan_mac=$(mtd_get_mac_binary factory 4) lan_mac=$(macaddr_add "$wan_mac" 1) ;; diff --git a/target/linux/ramips/base-files/lib/upgrade/platform.sh b/target/linux/ramips/base-files/lib/upgrade/platform.sh index 2fad95021c..97fbaefea6 100755 --- a/target/linux/ramips/base-files/lib/upgrade/platform.sh +++ b/target/linux/ramips/base-files/lib/upgrade/platform.sh @@ -38,6 +38,7 @@ platform_do_upgrade() { hc5962|\ mir3g|\ r6220|\ + netgear,r6350|\ ubnt-erx|\ ubnt-erx-sfp) nand_do_upgrade "$ARGV" diff --git a/target/linux/ramips/dts/R6350.dts b/target/linux/ramips/dts/R6350.dts new file mode 100644 index 0000000000..cdf9a72c86 --- /dev/null +++ b/target/linux/ramips/dts/R6350.dts @@ -0,0 +1,156 @@ +/dts-v1/; + +#include "mt7621.dtsi" + +#include <dt-bindings/gpio/gpio.h> +#include <dt-bindings/input/input.h> + +/ { + compatible = "netgear,r6350", "mediatek,mt7621-soc"; + model = "Netgear R6350"; + + aliases { + led-boot = &led_power; + led-failsafe = &led_power; + led-running = &led_power; + led-upgrade = &led_power; + }; + + memory@0 { + device_type = "memory"; + reg = <0x0 0x8000000>; + }; + + chosen { + bootargs = "console=ttyS0,57600"; + }; + + gpio-leds { + compatible = "gpio-leds"; + + led_power: power { + label = "r6350:green:power"; + gpios = <&gpio0 18 GPIO_ACTIVE_LOW>; + }; + + usb { + label = "r6350:green:usb"; + gpios = <&gpio0 15 GPIO_ACTIVE_LOW>; + trigger-sources = <&xhci_ehci_port1>, <&ehci_port2>; + linux,default-trigger = "usbport"; + }; + + internet { + label = "r6350:green:wan"; + gpios = <&gpio0 13 GPIO_ACTIVE_LOW>; + }; + + wifi { + label = "r6350:green:wifi"; + gpios = <&gpio0 16 GPIO_ACTIVE_LOW>; + }; + }; + + gpio-keys-polled { + compatible = "gpio-keys-polled"; + poll-interval = <20>; + + wps { + label = "wps"; + gpios = <&gpio0 7 GPIO_ACTIVE_LOW>; + linux,code = <KEY_WPS_BUTTON>; + }; + + reset { + label = "reset"; + gpios = <&gpio0 14 GPIO_ACTIVE_LOW>; + linux,code = <KEY_RESTART>; + }; + }; + + gpio_export { + compatible = "gpio-export"; + #size-cells = <0>; + + usbpower { + gpio-export,name = "usbpower"; + gpio-export,output = <1>; + gpios = <&gpio0 10 GPIO_ACTIVE_HIGH>; + }; + }; +}; + +&nand { + status = "okay"; + + partitions { + compatible = "fixed-partitions"; + #address-cells = <1>; + #size-cells = <1>; + + partition@0 { + label = "u-boot"; + reg = <0x0 0x100000>; + read-only; + }; + + partition@100000 { + label = "SC PART_MAP"; + reg = <0x100000 0x100000>; + read-only; + }; + + partition@200000 { + label = "kernel"; + reg = <0x200000 0x400000>; + }; + + partition@600000 { + label = "ubi"; + reg = <0x600000 0x2800000>; + }; + + partition@2e00000 { + label = "reserved0"; + reg = <0x2e00000 0x1800000>; + read-only; + }; + + factory: partition@4600000 { + label = "factory"; + reg = <0x4600000 0x200000>; + read-only; + }; + + partition@4800000 { + label = "reserved1"; + reg = <0x4800000 0x3800000>; + read-only; + }; + }; +}; + +&pcie { + status = "okay"; +}; + +&pcie1 { + wifi@0,0 { + reg = <0x0 0 0 0 0>; + mediatek,mtd-eeprom = <&factory 0x0>; + ieee80211-freq-limit = <2400000 2500000>; + }; +}; + +ðernet { + mtd-mac-address = <&factory 0x4>; +}; + +&pinctrl { + state_default: pinctrl0 { + gpio { + ralink,group = "uart3", "uart2", "jtag", "wdt"; + ralink,function = "gpio"; + }; + }; +}; diff --git a/target/linux/ramips/image/mt7621.mk b/target/linux/ramips/image/mt7621.mk index 92bdbcf743..d4c9a100ed 100644 --- a/target/linux/ramips/image/mt7621.mk +++ b/target/linux/ramips/image/mt7621.mk @@ -297,6 +297,23 @@ define Device/r6220 endef TARGET_DEVICES += r6220 +define Device/netgear_r6350 + DTS := R6350 + BLOCKSIZE := 128k + PAGESIZE := 2048 + KERNEL_SIZE := 4096k + IMAGE_SIZE := 40960k + UBINIZE_OPTS := -E 5 + IMAGES += kernel.bin rootfs.bin + IMAGE/sysupgrade.bin := sysupgrade-tar | append-metadata + IMAGE/kernel.bin := append-kernel + IMAGE/rootfs.bin := append-ubi | check-size $$$$(IMAGE_SIZE) + DEVICE_TITLE := Netgear R6350 + DEVICE_PACKAGES := \ + kmod-mt7603 kmod-usb3 kmod-usb-ledtrig-usbport wpad-basic +endef +TARGET_DEVICES += netgear_r6350 + define Device/rb750gr3 DTS := RB750Gr3 IMAGE_SIZE := $(ralink_default_fw_size_16M) |