summaryrefslogtreecommitdiff
path: root/target/linux/brcm63xx/base-files
diff options
context:
space:
mode:
Diffstat (limited to 'target/linux/brcm63xx/base-files')
-rwxr-xr-xtarget/linux/brcm63xx/base-files/etc/diag.sh23
-rw-r--r--target/linux/brcm63xx/base-files/etc/hotplug.d/firmware/10-rt2x00-eeprom42
-rw-r--r--target/linux/brcm63xx/base-files/etc/uci-defaults/01_leds33
-rwxr-xr-xtarget/linux/brcm63xx/base-files/etc/uci-defaults/02_network139
-rwxr-xr-xtarget/linux/brcm63xx/base-files/etc/uci-defaults/09_fix_crc39
-rwxr-xr-xtarget/linux/brcm63xx/base-files/lib/brcm63xx.sh183
-rw-r--r--target/linux/brcm63xx/base-files/lib/preinit/03_do_brcm63xx.sh7
-rw-r--r--target/linux/brcm63xx/base-files/lib/preinit/05_failsafe_config_switch_brcm63xx10
-rw-r--r--target/linux/brcm63xx/base-files/lib/preinit/05_init_interfaces_brcm63xx7
-rw-r--r--target/linux/brcm63xx/base-files/lib/preinit/15_set_preinit_interface_brcm63xx27
-rw-r--r--target/linux/brcm63xx/base-files/lib/preinit/20_failsafe_net_echo_brcm63xx12
-rw-r--r--target/linux/brcm63xx/base-files/lib/upgrade/platform.sh16
12 files changed, 0 insertions, 538 deletions
diff --git a/target/linux/brcm63xx/base-files/etc/diag.sh b/target/linux/brcm63xx/base-files/etc/diag.sh
deleted file mode 100755
index bbf5c0b..0000000
--- a/target/linux/brcm63xx/base-files/etc/diag.sh
+++ /dev/null
@@ -1,23 +0,0 @@
-#!/bin/sh
-# Copyright (C) 2007-2013 OpenWrt.org
-
-. /lib/functions/leds.sh
-. /lib/brcm63xx.sh
-
-set_state() {
- case "$1" in
- preinit)
- status_led_set_timer 200 200
- ;;
- failsafe)
- status_led_set_timer 50 50
- ;;
- done)
- if [ "${status_led/power}" != "$status_led" ]; then
- status_led_on
- else
- status_led_off
- fi
- ;;
- esac
-}
diff --git a/target/linux/brcm63xx/base-files/etc/hotplug.d/firmware/10-rt2x00-eeprom b/target/linux/brcm63xx/base-files/etc/hotplug.d/firmware/10-rt2x00-eeprom
deleted file mode 100644
index 2d8f1f5..0000000
--- a/target/linux/brcm63xx/base-files/etc/hotplug.d/firmware/10-rt2x00-eeprom
+++ /dev/null
@@ -1,42 +0,0 @@
-#!/bin/sh
-# Based on gabors ralink wisoc implementation.
-
-rt2x00_eeprom_die() {
- echo "rt2x00 eeprom: " "$*"
- exit 1
-}
-
-rt2x00_eeprom_extract() {
- local part=$1
- local offset=$2
- local count=$3
- local mtd
-
- . /lib/functions.sh
-
- mtd=$(find_mtd_part $part)
- [ -n "$mtd" ] || \
- rt2x00_eeprom_die "no mtd device found for partition $part"
-
- dd if=$mtd of=/lib/firmware/$FIRMWARE bs=1 skip=$offset count=$count || \
- rt2x00_eeprom_die "failed to extract from $mtd"
-}
-
-[ -e /lib/firmware/$FIRMWARE ] && exit 0
-
-. /lib/brcm63xx.sh
-
-board=$board_name
-
-case "$FIRMWARE" in
-"rt2x00.eeprom" )
- case $board in
- HW556_C)
- rt2x00_eeprom_extract "cal_data" 130560 512
- ;;
- *)
- rt2x00_eeprom_die "board $board is not supported yet"
- ;;
- esac
- ;;
-esac
diff --git a/target/linux/brcm63xx/base-files/etc/uci-defaults/01_leds b/target/linux/brcm63xx/base-files/etc/uci-defaults/01_leds
deleted file mode 100644
index 854b3b2..0000000
--- a/target/linux/brcm63xx/base-files/etc/uci-defaults/01_leds
+++ /dev/null
@@ -1,33 +0,0 @@
-#!/bin/sh
-#
-# Copyright (C) 2013-2014 OpenWrt.org
-#
-
-. /lib/functions/uci-defaults.sh
-. /lib/brcm63xx.sh
-
-case "$board_name" in
-963281T_TEF)
- ucidef_set_led_netdev "lan" "LAN" "A4001N1:green:eth" "eth0"
- ucidef_set_led_usbdev "usb" "USB" "A4001N1:green:3g" "1-1"
- ;;
-96328dg2x2)
- ucidef_set_led_usbdev "usb" "USB" "A4001N:green:usb" "1-1"
- ;;
-'F@ST2704V2')
- ucidef_set_led_usbdev "usb" "USB" "F@ST2704V2:green:usb" "1-1"
- ;;
-HW553)
- ucidef_set_led_netdev "lan" "LAN" "HW553:blue:lan" "eth0"
- ucidef_set_led_usbdev "usb1" "USB1" "HW553:red:hspa" "1-1"
- ucidef_set_led_usbdev "usb2" "USB2" "HW553:blue:hspa" "1-2"
- ;;
-HW556*)
- ucidef_set_led_netdev "lan" "LAN" "HW556:red:dsl" "eth0"
- ucidef_set_led_usbdev "usb" "USB" "HW556:red:hspa" "1-2"
- ;;
-esac
-
-ucidef_commit_leds
-
-exit 0
diff --git a/target/linux/brcm63xx/base-files/etc/uci-defaults/02_network b/target/linux/brcm63xx/base-files/etc/uci-defaults/02_network
deleted file mode 100755
index 3884e07..0000000
--- a/target/linux/brcm63xx/base-files/etc/uci-defaults/02_network
+++ /dev/null
@@ -1,139 +0,0 @@
-#!/bin/sh
-#
-# Copyright (C) 2012 OpenWrt.org
-#
-
-[ -e /etc/config/network ] && exit 0
-
-touch /etc/config/network
-
-. /lib/functions/uci-defaults.sh
-. /lib/brcm63xx.sh
-
-ucidef_set_interface_loopback
-
-case "$board_name" in
-
-96348W3 |\
-96358-502V |\
-CVG834G_E15R3921 |\
-RTA770BW |\
-RTA770W |\
-SPW500V)
- ucidef_set_interface_lan "eth0"
- ;;
-
-96338GW |\
-96338W |\
-96338W2_E7T |\
-96348A-122 |\
-96348W3 |\
-AR1004G |\
-CPVA642 |\
-CT536_CT5621 |\
-CT6373-1 |\
-D-4P-W |\
-"F@ST2604" |\
-RTA1320_16M |\
-V2110)
- ucidef_set_interface_lan "eth0"
- ucidef_add_switch "eth0" "1" "1"
- ucidef_add_switch_vlan "eth0" "1" "0 1 2 3 4 5"
- ;;
-
-96348GW |\
-96348GW-10 |\
-96348GW-11 |\
-96348GW-A |\
-96358VW |\
-96358VW2 |\
-AGPF-S0 |\
-"CPVA502+" |\
-DV201AMR |\
-DWV-S0 |\
-"F@ST2404" |\
-MAGIC |\
-RTA1025W_16 |\
-V2500V_BB)
- ucidef_set_interfaces_lan_wan "eth1" "eth0"
- ucidef_add_switch "eth1" "1" "1"
- ucidef_add_switch_vlan "eth1" "1" "0 1 2 3 4 5"
- ;;
-
-AW4139 |\
-AW4339U |\
-HW553 |\
-HW556*)
- ucidef_set_interface_lan "eth0.1"
- ucidef_add_switch "eth0" "1" "1"
- ucidef_add_switch_vlan "eth0" "1" "0 1 2 3 4 5t"
- ;;
-
-NB4-* |\
-DVG3810BN |\
-HW6358GW_B)
- ucidef_set_interfaces_lan_wan "eth1.1" "eth0"
- ucidef_add_switch "eth1" "1" "1"
- ucidef_add_switch_vlan "eth1" "1" "0 1 2 3 4 5t"
- ;;
-
-96328avng |\
-96328A-1241N |\
-96328A-1441N1 |\
-963281TAN |\
-963281T_TEF |\
-96328dg2x2 |\
-96368M-1341N |\
-96368M-1541N |\
-96368MVNgr |\
-AW5200B |\
-"F@ST2504n" |\
-"F@ST2704V2" |\
-P870HW-51a_v2)
- ucidef_set_interface_lan "eth0.1"
- ucidef_add_switch "eth0" "1" "1"
- ucidef_add_switch_vlan "eth0" "1" "0 1 2 3 8t"
- ;;
-
-96368MVWG)
- ucidef_set_interface_lan "eth0.1"
- ucidef_add_switch "eth0" "1" "1"
- ucidef_add_switch_vlan "eth0" "1" "1 2 4 5 8t"
- ;;
-
-96369R-1231N)
- ucidef_set_interfaces_lan_wan "eth0.1" "eth0.2"
- ucidef_add_switch "eth0" "1" "1"
- ucidef_add_switch_vlan "eth0" "1" "0 1 2 3 5t"
- ucidef_add_switch_vlan "eth0" "2" "4 5t"
- ;;
-
-NB6)
- ucidef_set_interfaces_lan_wan "eth0.1" "eth0.2"
- ucidef_add_switch "switch0" "1" "1"
- ucidef_add_switch_vlan "switch0" "1" "1 2 3 4 9t"
- ucidef_add_switch_vlan "switch0" "2" "0 9t"
- ;;
-
-VW6339GU)
- 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 8t"
- ucidef_add_switch_vlan "switch0" "2" "4 8t"
- ;;
-
-963268BU_P300)
- ucidef_set_interface_lan "eth0.1"
- ucidef_add_switch "switch0" "1" "1"
- ucidef_add_switch_vlan "switch0" "1" "0 3 4 5 6 7 8t"
- ;;
-
-*)
- ucidef_set_interfaces_lan_wan "eth1" "eth0"
- ;;
-
-esac
-
-uci commit network
-
-exit 0
diff --git a/target/linux/brcm63xx/base-files/etc/uci-defaults/09_fix_crc b/target/linux/brcm63xx/base-files/etc/uci-defaults/09_fix_crc
deleted file mode 100755
index 2840eb1..0000000
--- a/target/linux/brcm63xx/base-files/etc/uci-defaults/09_fix_crc
+++ /dev/null
@@ -1,39 +0,0 @@
-#!/bin/sh
-#
-# Copyright (C) 2007 OpenWrt.org
-#
-#
-
-. /lib/brcm63xx.sh
-
-do_fixcrc() {
- mtd fixtrx linux
-}
-
-brcm63xx_detect
-
-case "$board_name" in
- 96328avng |\
- 96328A-1241N |\
- 96328A-1441N1 |\
- 963281TAN |\
- 963281T_TEF |\
- 96328dg2x2 |\
- 96358-502V |\
- 96368M-1341N |\
- 96368M-1541N |\
- 96369R-1231N |\
- AW4339U |\
- "CPVA502+" |\
- CPVA642 |\
- CT6373-1 |\
- MAGIC |\
- P870HW-51a_v2 |\
- RTA770BW |\
- RTA770W |\
- V2110 |\
- V2500V_BB)
- do_fixcrc
- ;;
-esac
-
diff --git a/target/linux/brcm63xx/base-files/lib/brcm63xx.sh b/target/linux/brcm63xx/base-files/lib/brcm63xx.sh
deleted file mode 100755
index 58ce71e..0000000
--- a/target/linux/brcm63xx/base-files/lib/brcm63xx.sh
+++ /dev/null
@@ -1,183 +0,0 @@
-#!/bin/sh
-#
-# Copyright (C) 2007 OpenWrt.org
-#
-#
-
-board_name=""
-status_led=""
-status_led2=""
-sys_mtd_part=""
-brcm63xx_has_reset_button=""
-ifname=""
-
-brcm63xx_detect() {
- board_name=$(awk 'BEGIN{FS="[ \t:/]+"} /system type/ {print $4}' /proc/cpuinfo)
-
- if [ "$board_name" = "96358VW" ] && [ -n "$(swconfig dev eth1 help 2>/dev/null)" ]; then
- board_name="DVAG3810BN"
- fi
-
- case "$board_name" in
- 963281TAN)
- status_led="963281TAN::power"
- ifname=eth0
- ;;
- 963281T_TEF)
- brcm63xx_has_reset_button="true"
- status_led="A4001N1:green:power"
- ifname=eth0
- ;;
- 96328avng)
- status_led="96328avng::power"
- ifname=eth0
- ;;
- 96328dg2x2)
- brcm63xx_has_reset_button="true"
- status_led="A4001N:green:power"
- ifname="eth0"
- ;;
- 96328A-1241N)
- brcm63xx_has_reset_button="true"
- status_led="AR-5381u:green:power"
- ifname=eth0
- ;;
- 96328A-1441N1)
- brcm63xx_has_reset_button="true"
- status_led="AR-5387un:green:power"
- ifname=eth0
- ;;
- 96348GW)
- status_led="96348GW:green:power"
- brcm63xx_has_reset_button="true"
- ifname=eth1
- ;;
- 96348GW-11)
- status_led="96348GW-11:green:power"
- brcm63xx_has_reset_button="true"
- ifname=eth1
- ;;
- 96358-502V)
- status_led="spw303v:green:power+adsl"
- brcm63xx_has_reset_button="true"
- ifname=eth0
- ;;
- 96368M-1341N)
- brcm63xx_has_reset_button="true"
- status_led="VR-3025un:green:power"
- ifname="eth0"
- ;;
- 96368M-1541N)
- brcm63xx_has_reset_button="true"
- status_led="VR-3025u:green:power"
- ifname="eth0"
- ;;
- 96369R-1231N)
- brcm63xx_has_reset_button="true"
- status_led="WAP-5813n:green:power"
- ifname="eth0"
- ;;
- AR1004G)
- status_led="AR1004G:green:power"
- brcm63xx_has_reset_button="true"
- ;;
- AW4139 |\
- AW4339U)
- status_led="dsl-274xb:green:power"
- brcm63xx_has_reset_button="true"
- ifname=eth0
- ;;
- AW5200B)
- status_led="dsl-275xb:green:power"
- brcm63xx_has_reset_button="true"
- ifname=eth0
- ;;
- CPVA642)
- status_led="CPVA642:green:power:"
- brcm63xx_has_reset_button="true"
- ifname=eth0
- ;;
- CT536_CT5621)
- status_led="CT536_CT5621:green:power"
- brcm63xx_has_reset_button="true"
- ifname=eth0
- ;;
- CVG834G_E15R3921)
- status_led="CVG834G:green:power"
- ifname=eth0
- ;;
- D-4P-W)
- status_led="D-4P-W:green:power"
- brcm63xx_has_reset_button="true"
- ifname=eth0
- ;;
- "F@ST2504n")
- status_led="fast2504n:green:ok"
- brcm63xx_has_reset_button="true"
- ifname=eth0
- ;;
- 'F@ST2704V2')
- status_led="F@ST2704V2:green:power"
- brcm63xx_has_reset_button="true"
- ifname=eth0
- ;;
- GW6000)
- brcm63xx_has_reset_button="true"
- ifname=eth1
- ;;
- GW6200)
- status_led="GW6200:green:line1"
- status_led2="GW6200:green:tel"
- brcm63xx_has_reset_button="true"
- ifname=eth1
- ;;
- HW553)
- status_led="HW553:blue:power"
- brcm63xx_has_reset_button="true"
- ifname=eth0
- ;;
- HW556*)
- status_led="HW556:red:power"
- brcm63xx_has_reset_button="true"
- ifname=eth0
- ;;
- HW6358GW_B)
- status_led="HW520:green:net"
- brcm63xx_has_reset_button="true"
- ifname="eth0"
- ;;
- NB6)
- brcm63xx_has_reset_button="true"
- ifname=eth0
- ;;
- P870HW-51a_v2)
- brcm63xx_has_reset_button="true"
- status_led="P870HW-51a:green:power"
- ifname="eth0"
- ;;
- RTA770BW)
- brcm63xx_has_reset_button="true"
- status_led="RTA770BW:green:diag"
- ifname=eth0
- ;;
- RTA770W)
- brcm63xx_has_reset_button="true"
- status_led="RTA770W:green:diag"
- ifname=eth0
- ;;
- SPW500V)
- status_led="SPW500V:green:power"
- brcm63xx_has_reset_button="true"
- ifname=eth0
- ;;
- V2110)
- status_led="V2110:power:green"
- brcm63xx_has_reset_button="true"
- ifname=eth0
- ;;
- *)
- ;;
- esac
-}
-
-brcm63xx_detect
diff --git a/target/linux/brcm63xx/base-files/lib/preinit/03_do_brcm63xx.sh b/target/linux/brcm63xx/base-files/lib/preinit/03_do_brcm63xx.sh
deleted file mode 100644
index dd60c49..0000000
--- a/target/linux/brcm63xx/base-files/lib/preinit/03_do_brcm63xx.sh
+++ /dev/null
@@ -1,7 +0,0 @@
-#!/bin/sh
-
-do_brcm63xx() {
- . /lib/brcm63xx.sh
-}
-
-boot_hook_add preinit_main do_brcm63xx
diff --git a/target/linux/brcm63xx/base-files/lib/preinit/05_failsafe_config_switch_brcm63xx b/target/linux/brcm63xx/base-files/lib/preinit/05_failsafe_config_switch_brcm63xx
deleted file mode 100644
index e1653e3..0000000
--- a/target/linux/brcm63xx/base-files/lib/preinit/05_failsafe_config_switch_brcm63xx
+++ /dev/null
@@ -1,10 +0,0 @@
-#!/bin/sh
-
-failsafe_ip() {
- [ -n "$pi_ifname" ] && grep -q "$pi_ifname" /proc/net/dev && {
- ifconfig $pi_ifname $pi_ip netmask $pi_netmask broadcast $pi_broadcast up
- }
-}
-
-boot_hook_add failsafe failsafe_ip
-
diff --git a/target/linux/brcm63xx/base-files/lib/preinit/05_init_interfaces_brcm63xx b/target/linux/brcm63xx/base-files/lib/preinit/05_init_interfaces_brcm63xx
deleted file mode 100644
index 1de59b7..0000000
--- a/target/linux/brcm63xx/base-files/lib/preinit/05_init_interfaces_brcm63xx
+++ /dev/null
@@ -1,7 +0,0 @@
-#!/bin/sh
-
-set_preinit_iface() {
- ifconfig $ifname 0.0.0.0 up
-}
-
-boot_hook_add preinit_main set_preinit_iface
diff --git a/target/linux/brcm63xx/base-files/lib/preinit/15_set_preinit_interface_brcm63xx b/target/linux/brcm63xx/base-files/lib/preinit/15_set_preinit_interface_brcm63xx
deleted file mode 100644
index 7655fb7..0000000
--- a/target/linux/brcm63xx/base-files/lib/preinit/15_set_preinit_interface_brcm63xx
+++ /dev/null
@@ -1,27 +0,0 @@
-#!/bin/sh
-
-port_net_echo() {
- [ -n "$pi_ifname" ] && grep -q "$pi_ifname" /proc/net/dev && {
- if [ "$pi_preinit_net_messages" = "y" ] || [ "$pi_failsafe_net_message" = "true" ] && [ "$pi_preinit_no_failsafe_netmsg" != "y" ]; then
- netmsg $pi_broadcast "$1"
- fi
- }
-}
-
-preinit_ip_deconfig() {
- if [ -z "$pi_ifname" ]; then
- ifconfig $ifname 0.0.0.0 down
- else
- grep -q "$pi_ifname" /proc/net/dev && {
- ifconfig $pi_ifname 0.0.0.0 down
- }
- fi
-}
-
-preinit_net_echo() {
- preinit_ip
-
- port_net_echo $1
-}
-
-
diff --git a/target/linux/brcm63xx/base-files/lib/preinit/20_failsafe_net_echo_brcm63xx b/target/linux/brcm63xx/base-files/lib/preinit/20_failsafe_net_echo_brcm63xx
deleted file mode 100644
index f030cb2..0000000
--- a/target/linux/brcm63xx/base-files/lib/preinit/20_failsafe_net_echo_brcm63xx
+++ /dev/null
@@ -1,12 +0,0 @@
-#!/bin/sh
-
-indicate_failsafe() {
- preinit_net_echo() {
- port_net_echo $1
- }
- echo "- failsafe -"
- preinit_net_echo "Entering Failsafe!\n"
- indicate_failsafe_led
-}
-
-
diff --git a/target/linux/brcm63xx/base-files/lib/upgrade/platform.sh b/target/linux/brcm63xx/base-files/lib/upgrade/platform.sh
deleted file mode 100644
index 5c9e2c2..0000000
--- a/target/linux/brcm63xx/base-files/lib/upgrade/platform.sh
+++ /dev/null
@@ -1,16 +0,0 @@
-PART_NAME=linux
-platform_check_image() {
- [ "$#" -gt 1 ] && return 1
- case "$(get_magic_word "$1")" in
- 3600|3700|3800)
- # 6348GW-11 boards use openwrt-96348GW-11-squashfs-cfe.bin files
- return 0
- ;;
- *)
- echo "Invalid image type. Please use only .bin files"
- return 1
- ;;
- esac
-}
-
-# use default for platform_do_upgrade()