summaryrefslogtreecommitdiff
path: root/target
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@nbd.name>2017-03-17 16:21:30 +0100
committerFelix Fietkau <nbd@nbd.name>2017-03-22 11:43:21 +0100
commit7e798dab56546d6f8e2fe0f913ff41e8f010af51 (patch)
treea3d7680454f5f4973dafce23f20515d1f67f796b /target
parentaa95d6cd20f7e08420562b9747c197c2eac1d2e2 (diff)
downloadmtk-20170518-7e798dab56546d6f8e2fe0f913ff41e8f010af51.zip
mtk-20170518-7e798dab56546d6f8e2fe0f913ff41e8f010af51.tar.gz
mtk-20170518-7e798dab56546d6f8e2fe0f913ff41e8f010af51.tar.bz2
lantiq: remove lantiq_board_name, use the generic function instead
Signed-off-by: Felix Fietkau <nbd@nbd.name>
Diffstat (limited to 'target')
-rwxr-xr-xtarget/linux/lantiq/base-files/etc/board.d/01_leds2
-rwxr-xr-xtarget/linux/lantiq/base-files/etc/board.d/02_network2
-rw-r--r--target/linux/lantiq/base-files/etc/hotplug.d/firmware/11-ath10k-caldata3
-rw-r--r--target/linux/lantiq/base-files/etc/hotplug.d/firmware/12-ath9k-eeprom3
-rw-r--r--target/linux/lantiq/base-files/lib/functions/lantiq.sh9
-rwxr-xr-xtarget/linux/lantiq/base-files/lib/upgrade/platform.sh4
6 files changed, 5 insertions, 18 deletions
diff --git a/target/linux/lantiq/base-files/etc/board.d/01_leds b/target/linux/lantiq/base-files/etc/board.d/01_leds
index 0698d6c..8de222a 100755
--- a/target/linux/lantiq/base-files/etc/board.d/01_leds
+++ b/target/linux/lantiq/base-files/etc/board.d/01_leds
@@ -32,7 +32,7 @@ led_internet="$(lantiq_get_dt_led internet)"
ucidef_set_led_netdev "internet" "internet" "$led_internet" "$interface"
}
-board=$(lantiq_board_name)
+board=$(board_name)
case "$board" in
ARV4525PW)
diff --git a/target/linux/lantiq/base-files/etc/board.d/02_network b/target/linux/lantiq/base-files/etc/board.d/02_network
index 0af555f..2f744f8 100755
--- a/target/linux/lantiq/base-files/etc/board.d/02_network
+++ b/target/linux/lantiq/base-files/etc/board.d/02_network
@@ -18,7 +18,7 @@ lan_mac=""
wan_mac=""
interface_wan=""
-board=$(lantiq_board_name)
+board=$(board_name)
case "$board" in
ACMP252|GIGASX76X)
diff --git a/target/linux/lantiq/base-files/etc/hotplug.d/firmware/11-ath10k-caldata b/target/linux/lantiq/base-files/etc/hotplug.d/firmware/11-ath10k-caldata
index 2511ed6..1c2b845 100644
--- a/target/linux/lantiq/base-files/etc/hotplug.d/firmware/11-ath10k-caldata
+++ b/target/linux/lantiq/base-files/etc/hotplug.d/firmware/11-ath10k-caldata
@@ -5,7 +5,6 @@
. /lib/functions.sh
. /lib/functions/system.sh
-. /lib/functions/lantiq.sh
. /lib/upgrade/nand.sh
ath10k_caldata_die() {
@@ -37,7 +36,7 @@ ath10k_caldata_set_macaddr() {
case "$FIRMWARE" in
"ath10k/cal-pci-0000:02:00.0.bin")
- board=$(lantiq_board_name)
+ board=$(board_name)
case $board in
BTHOMEHUBV5A)
ath10k_caldata_extract_ubi "caldata" 20480 2116
diff --git a/target/linux/lantiq/base-files/etc/hotplug.d/firmware/12-ath9k-eeprom b/target/linux/lantiq/base-files/etc/hotplug.d/firmware/12-ath9k-eeprom
index 1c6b066..6b9d23a7 100644
--- a/target/linux/lantiq/base-files/etc/hotplug.d/firmware/12-ath9k-eeprom
+++ b/target/linux/lantiq/base-files/etc/hotplug.d/firmware/12-ath9k-eeprom
@@ -5,7 +5,6 @@
. /lib/functions.sh
. /lib/functions/system.sh
-. /lib/functions/lantiq.sh
. /lib/upgrade/nand.sh
# xor multiple hex values of the same length
@@ -114,7 +113,7 @@ case "$FIRMWARE" in
"ath9k-eeprom-pci-0000:00:0e.0.bin" | \
"ath9k-eeprom-pci-0000:01:00.0.bin" | \
"ath9k-eeprom-pci-0000:02:00.0.bin")
- board=$(lantiq_board_name)
+ board=$(board_name)
case "$board" in
ARV7518PW)
diff --git a/target/linux/lantiq/base-files/lib/functions/lantiq.sh b/target/linux/lantiq/base-files/lib/functions/lantiq.sh
index 89f194b..5d760d1 100644
--- a/target/linux/lantiq/base-files/lib/functions/lantiq.sh
+++ b/target/linux/lantiq/base-files/lib/functions/lantiq.sh
@@ -9,15 +9,6 @@ lantiq_board_model() {
echo "$model"
}
-lantiq_board_name() {
- local name
-
- [ -f /tmp/sysinfo/board_name ] && name=$(cat /tmp/sysinfo/board_name)
- [ -z "$name" ] && name="unknown"
-
- echo "$name"
-}
-
lantiq_get_dt_led() {
local label
local ledpath
diff --git a/target/linux/lantiq/base-files/lib/upgrade/platform.sh b/target/linux/lantiq/base-files/lib/upgrade/platform.sh
index d4db8d2..9158fa7 100755
--- a/target/linux/lantiq/base-files/lib/upgrade/platform.sh
+++ b/target/linux/lantiq/base-files/lib/upgrade/platform.sh
@@ -1,5 +1,3 @@
-. /lib/functions/lantiq.sh
-
PART_NAME=firmware
REQUIRE_IMAGE_METADATA=1
@@ -8,7 +6,7 @@ platform_check_image() {
}
platform_pre_upgrade() {
- local board=$(lantiq_board_name)
+ local board=$(board_name)
case "$board" in
BTHOMEHUBV2B|BTHOMEHUBV3A|BTHOMEHUBV5A|P2812HNUF* )