ramips: basic support for Planex MZK-750DHP
authorJohn Crispin <john@openwrt.org>
Mon, 14 Jul 2014 17:10:39 +0000 (17:10 +0000)
committerJohn Crispin <john@openwrt.org>
Mon, 14 Jul 2014 17:10:39 +0000 (17:10 +0000)
some gpios are still missing.

Signed-off-by: John Crispin <blogic@openwrt.org>
SVN-Revision: 41654

target/linux/ramips/base-files/etc/hotplug.d/firmware/10-rt2x00-eeprom
target/linux/ramips/base-files/etc/uci-defaults/02_network
target/linux/ramips/base-files/lib/ramips.sh
target/linux/ramips/dts/MZK-750DHP.dts [new file with mode: 0644]
target/linux/ramips/image/Makefile

index e958899ca1dad6ef7a081263821d38fa9e97cc28..18a0448de42037c23aaedaddeb9ae4faaa39714f 100644 (file)
@@ -90,6 +90,7 @@ case "$FIRMWARE" in
        mofi3500-3gn | \
        mpr-a1 | \
        mpr-a2 | \
+       mzk-750dhp | \
        pwh2004 | \
        ncs601w | \
        nbg-419n | \
index 39f46bb979a6c5030346bc94bee0519de823cce9..b54b55532698951162d2fa4f02117c39a5a8980d 100755 (executable)
@@ -97,7 +97,8 @@ ramips_setup_interfaces()
        dir-320-b1 | \
        dir-615-h1 | \
        hlk-rm04 | \
-       mzk-w300nh2)
+       mzk-w300nh2 | \
+       mzk-750dhp)
                ucidef_set_interfaces_lan_wan "eth0.1" "eth0.2"
                ucidef_add_switch "switch0" "1" "1"
                ucidef_add_switch_vlan "switch0" "1" "0 1 2 3 6t"
index b36b53c302ccefc7296081f9d5c655afa1c01cda..2e831d29313ead4f5816559f6ef74d70cb62984f 100755 (executable)
@@ -160,6 +160,9 @@ ramips_board_detect() {
        *"HAME MPR-A2")
                name="mpr-a2"
                ;;
+       *"Planex MZK-750DHP")
+               name="mzk-750dhp"
+               ;;
        *"NBG-419N")
                name="nbg-419n"
                ;;
diff --git a/target/linux/ramips/dts/MZK-750DHP.dts b/target/linux/ramips/dts/MZK-750DHP.dts
new file mode 100644 (file)
index 0000000..e251187
--- /dev/null
@@ -0,0 +1,87 @@
+/dts-v1/;
+
+/include/ "mt7620a.dtsi"
+
+/ {
+       compatible = "ralink,mt7620a-soc";
+       model = "Planex MZK-750DHP";
+
+       palmbus@10000000 {
+               gpio1: gpio@638 {
+                       status = "okay";
+               };
+
+               spi@b00 {
+                       status = "okay";
+
+                       m25p80@0 {
+                               #address-cells = <1>;
+                               #size-cells = <1>;
+                               compatible = "en25q64";
+                               reg = <0 0>;
+                               linux,modalias = "m25p80", "mx25l6405d";
+                               spi-max-frequency = <10000000>;
+
+                               partition@0 {
+                                       label = "u-boot";
+                                       reg = <0x0 0x30000>;
+                                       read-only;
+                               };
+
+                               partition@30000 {
+                                       label = "u-boot-env";
+                                       reg = <0x30000 0x10000>;
+                                       read-only;
+                               };
+
+                               factory: partition@40000 {
+                                       label = "factory";
+                                       reg = <0x40000 0x10000>;
+                                       read-only;
+                               };
+
+                               partition@50000 {
+                                       label = "firmware";
+                                       reg = <0x50000 0x7b0000>;
+                               };
+                       };
+               };
+       };
+
+       pinctrl {
+               state_default: pinctrl0 {
+                       gpio {
+                               ralink,group = "i2c", "uartf", "mdio", "wdt", "spi refclk", "pa", "rgmii1", "rgmii2", "wled", "nd_sd";
+                               ralink,function = "gpio";
+                       };
+               };
+       };
+
+       ethernet@10100000 {
+               pinctrl-names = "default";
+               pinctrl-0 = <&ephy_pins>;
+
+               mtd-mac-address = <&factory 0x4>;
+               ralink,port-map = "llllw";
+       };
+
+       gsw@10110000 {
+               ralink,port4 = "ephy";
+       };
+
+       pcie@10140000 {
+               status = "okay";
+       };
+       
+       gpio-keys-polled {
+               compatible = "gpio-keys-polled";
+               #address-cells = <1>;
+               #size-cells = <0>;
+               poll-interval = <20>;
+               s1 {
+                       label = "reset";
+                       gpios = <&gpio0 1 1>;
+                       linux,code = <0x100>;
+               };
+       };
+};
index 25889ea0528ae6936c145e33315b1d109c58687d..c7225a6a39a7da867856466f9b596fbaa7e9a9b5 100644 (file)
@@ -714,6 +714,7 @@ dlink810l_mtd_size=6881280
 Image/Build/Profile/DIR-810L=$(call BuildFirmware/CustomFlash/$(1),$(1),dir-810l,DIR-810L,$(dlink810l_mtd_size))
 na930_mtd_size=20971520
 Image/Build/Profile/NA930=$(call BuildFirmware/CustomFlash/$(1),$(1),na930,NA930,$(na930_mtd_size))
+Image/Build/Profile/MZK-750DHP=$(call BuildFirmware/Default8M/$(1),$(1),mzk-750dhp,MZK-750DHP)
 
 ifeq ($(SUBTARGET),mt7620a)
 define Image/Build/Profile/Default
@@ -726,6 +727,7 @@ define Image/Build/Profile/Default
        $(call Image/Build/Profile/WHR300HP2,$(1))
        $(call Image/Build/Profile/WHR600D,$(1))
        $(call Image/Build/Profile/WHR1166D,$(1))
+       $(call Image/Build/Profile/MZK-750DHP,$(1))
        $(call Image/Build/Profile/NA930,$(1))
 endef
 endif