aboutsummaryrefslogtreecommitdiffstats
path: root/target
diff options
context:
space:
mode:
authorJohn Crispin <blogic@openwrt.org>2014-10-29 11:01:17 +0000
committerJohn Crispin <blogic@openwrt.org>2014-10-29 11:01:17 +0000
commit1968a036e6394688dc4a76d5569ba69adf5bd0c3 (patch)
tree23d7e563b74359504abefab5624618987baeed5f /target
parent5b5a4abf83eb1c3d2a3403a6e61b682ebfe8e409 (diff)
downloadmaster-187ad058-1968a036e6394688dc4a76d5569ba69adf5bd0c3.tar.gz
master-187ad058-1968a036e6394688dc4a76d5569ba69adf5bd0c3.tar.bz2
master-187ad058-1968a036e6394688dc4a76d5569ba69adf5bd0c3.zip
ramips: add support for A5-V11 board (resubmit)
(Reposted due to an issue with the patchwork server during original submission) Unbranded. Silkscreen on PCB is “A5-V11”, believed to be made by Bococom (or at least uses Bococom image encryption - as used on poray devices - but different key) Signed-off-by: Gareth Bryan <gareth@mx9.org> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@43102 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target')
-rwxr-xr-xtarget/linux/ramips/base-files/etc/board.d/01_leds3
-rwxr-xr-xtarget/linux/ramips/base-files/etc/board.d/02_network7
-rwxr-xr-xtarget/linux/ramips/base-files/lib/ramips.sh3
-rwxr-xr-xtarget/linux/ramips/base-files/lib/upgrade/platform.sh1
-rw-r--r--target/linux/ramips/dts/A5-V11.dts117
-rw-r--r--target/linux/ramips/image/Makefile3
-rw-r--r--target/linux/ramips/rt305x/profiles/misc.mk18
7 files changed, 152 insertions, 0 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 7ca7ffb0fd..4a482b38fd 100755
--- a/target/linux/ramips/base-files/etc/board.d/01_leds
+++ b/target/linux/ramips/base-files/etc/board.d/01_leds
@@ -27,6 +27,9 @@ case $board in
3g300m)
set_usb_led "tenda:blue:3g"
;;
+ a5-v11)
+ ucidef_set_led_default "power" "POWER" "a5-v11:red:power" "1"
+ ;;
air3gii)
set_wifi_led "airlive:green:wlan"
set_usb_led "airlive:green:mobile"
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 ff8fbc079d..6510b1ae90 100755
--- a/target/linux/ramips/base-files/etc/board.d/02_network
+++ b/target/linux/ramips/base-files/etc/board.d/02_network
@@ -37,6 +37,12 @@ ramips_setup_interfaces()
ucidef_set_interface_loopback
case $board in
+ a5-v11)
+ ucidef_set_interface_lan "eth0.1"
+ ucidef_add_switch "switch0" "1" "1"
+ ucidef_add_switch_vlan "switch0" "1" "0 6t"
+ ;;
+
3g300m | \
w150m | \
all0256n | \
@@ -252,6 +258,7 @@ ramips_setup_macs()
lan_mac=$(macaddr_add "$lan_mac" -2)
;;
+ a5-v11 |\
bc2 |\
broadway |\
d105 |\
diff --git a/target/linux/ramips/base-files/lib/ramips.sh b/target/linux/ramips/base-files/lib/ramips.sh
index 88fa623d54..b2b299dc51 100755
--- a/target/linux/ramips/base-files/lib/ramips.sh
+++ b/target/linux/ramips/base-files/lib/ramips.sh
@@ -25,6 +25,9 @@ ramips_board_detect() {
*"Edimax 3g-6200nl")
name="3g-6200nl"
;;
+ *"A5-V11")
+ name="a5-v11"
+ ;;
*"Airlink101 AR725W")
name="ar725w"
;;
diff --git a/target/linux/ramips/base-files/lib/upgrade/platform.sh b/target/linux/ramips/base-files/lib/upgrade/platform.sh
index c9a418e790..4fe0ef46fa 100755
--- a/target/linux/ramips/base-files/lib/upgrade/platform.sh
+++ b/target/linux/ramips/base-files/lib/upgrade/platform.sh
@@ -17,6 +17,7 @@ platform_check_image() {
3g-6200n | \
3g-6200nl | \
3g300m | \
+ a5-v11 | \
air3gii | \
all0239-3g | \
all0256n | \
diff --git a/target/linux/ramips/dts/A5-V11.dts b/target/linux/ramips/dts/A5-V11.dts
new file mode 100644
index 0000000000..154074a0c2
--- /dev/null
+++ b/target/linux/ramips/dts/A5-V11.dts
@@ -0,0 +1,117 @@
+/dts-v1/;
+
+/include/ "rt5350.dtsi"
+
+/ {
+ compatible = "A5-V11", "ralink,rt5350-soc";
+ model = "A5-V11";
+
+ palmbus@10000000 {
+ spi@b00 {
+ status = "okay";
+ m25p80@0 {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ compatible = "pm25lq032";
+ reg = <0 0>;
+ linux,modalias = "m25p80", "pm25lq032";
+ 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 0x3b0000>;
+ };
+ };
+ };
+ gpio1: gpio@660 {
+ status = "okay";
+ };
+ };
+
+ pinctrl {
+ state_default: pinctrl0 {
+ gpio {
+ ralink,group = "i2c", "jtag", "uartf", "led";
+ ralink,function = "gpio";
+ };
+ };
+ };
+
+ ethernet@10100000 {
+ mtd-mac-address = <&factory 0x4>;
+ };
+
+ esw@10110000 {
+ ralink,portmap = <0x2f>;
+ };
+
+ wmac@10180000 {
+ ralink,mtd-eeprom = <&factory 0>;
+ };
+
+ ehci@101c0000 {
+ status = "okay";
+ };
+
+ ohci@101c1000 {
+ status = "okay";
+ };
+
+ gpio-leds {
+ compatible = "gpio-leds";
+ system {
+ label = "a5-v11:blue:system";
+ gpios = <&gpio0 20 1>;
+ };
+ power {
+ label = "a5-v11:red:power";
+ gpios = <&gpio0 17 1>;
+ };
+ };
+
+ gpio-keys-polled {
+ compatible = "gpio-keys-polled";
+ #address-cells = <1>;
+ #size-cells = <0>;
+ poll-interval = <20>;
+ reset {
+ label = "reset";
+ gpios = <&gpio0 0 1>;
+ linux,code = <0x198>;
+ };
+ };
+
+ gpio_export {
+ compatible = "gpio-export";
+ #size-cells = <0>;
+
+ usb {
+ gpio-export,name = "usb";
+ gpio-export,output = <1>;
+ gpios = <&gpio0 7 0>;
+ };
+ root_hub {
+ gpio-export,name = "root_hub";
+ gpio-export,output = <1>;
+ gpios = <&gpio0 12 0>;
+ };
+ };
+};
diff --git a/target/linux/ramips/image/Makefile b/target/linux/ramips/image/Makefile
index 9317779ff4..759de53020 100644
--- a/target/linux/ramips/image/Makefile
+++ b/target/linux/ramips/image/Makefile
@@ -336,6 +336,8 @@ Image/Build/Profile/3G6200NL=$(call BuildFirmware/Edimax/$(1),$(1),3g-6200nl,3G-
Image/Build/Profile/3G300M=$(call BuildFirmware/CustomFlashFactory/$(1),$(1),3g300m,3G300M,$(ralink_default_fw_size_4M),3G150M_SPI Kernel Image,factory)
+Image/Build/Profile/A5-V11=$(call BuildFirmware/Poray4M/$(1),$(1),a5-v11,A5-V11)
+
Image/Build/Profile/AIR3GII=$(call BuildFirmware/Default4M/$(1),$(1),air3gii,AIR3GII)
define BuildFirmware/UIMAGE_8M
@@ -593,6 +595,7 @@ define Image/Build/Profile/Default
$(call Image/Build/Profile/3G6200N,$(1))
$(call Image/Build/Profile/3G6200NL,$(1))
$(call Image/Build/Profile/3G300M,$(1))
+ $(call Image/Build/Profile/A5-11,$(1))
$(call Image/Build/Profile/AIR3GII,$(1))
$(call Image/Build/Profile/ALL02393G,$(1))
$(call Image/Build/Profile/ALL0256N,$(1))
diff --git a/target/linux/ramips/rt305x/profiles/misc.mk b/target/linux/ramips/rt305x/profiles/misc.mk
new file mode 100644
index 0000000000..cf7db6a6cd
--- /dev/null
+++ b/target/linux/ramips/rt305x/profiles/misc.mk
@@ -0,0 +1,18 @@
+#
+# Copyright (C) 2014 OpenWrt.org
+#
+# This is free software, licensed under the GNU General Public License v2.
+# See /LICENSE for more information.
+#
+
+define Profile/A5-V11
+ NAME:=A5-V11
+ PACKAGES:=\
+ kmod-usb-core kmod-usb-ohci kmod-usb2
+endef
+
+define Profile/A5-V11/Description
+ Package set for A5-V11
+endef
+
+$(eval $(call Profile,A5-V11))