Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ar71xx-generic: update support list for CPE210/510/...
Fixes #975
- Loading branch information
Showing
2 changed files
with
85 additions
and
0 deletions.
There are no files selected for viewing
40 changes: 40 additions & 0 deletions
40
patches/openwrt/0083-ar71xx-simplify-model-detection-for-TP-Link-Pharos-devices.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
From: Matthias Schiffer <mschiffer@universe-factory.net> | ||
Date: Sun, 11 Dec 2016 17:54:49 +0100 | ||
Subject: ar71xx: simplify model detection for TP-Link Pharos devices | ||
|
||
This also makes the detection more flexible, as it doesn't need to check | ||
for each model explicitly. | ||
|
||
Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net> | ||
|
||
diff --git a/target/linux/ar71xx/base-files/lib/ar71xx.sh b/target/linux/ar71xx/base-files/lib/ar71xx.sh | ||
index 5928439..4a9a730 100755 | ||
--- a/target/linux/ar71xx/base-files/lib/ar71xx.sh | ||
+++ b/target/linux/ar71xx/base-files/lib/ar71xx.sh | ||
@@ -329,24 +329,10 @@ tplink_pharos_get_model_string() { | ||
tplink_pharos_board_detect() { | ||
local model_string="$(tplink_pharos_get_model_string | tr -d '\r')" | ||
local oIFS="$IFS"; IFS=":"; set -- $model_string; IFS="$oIFS" | ||
- local model | ||
|
||
- case "$1" in | ||
- 'CPE210(TP-LINK|UN|N300-2)') | ||
- model='TP-Link CPE210' | ||
- ;; | ||
- 'CPE220(TP-LINK|UN|N300-2)') | ||
- model='TP-Link CPE220' | ||
- ;; | ||
- 'CPE510(TP-LINK|UN|N300-5)') | ||
- model='TP-Link CPE510' | ||
- ;; | ||
- 'CPE520(TP-LINK|UN|N300-5)') | ||
- model='TP-Link CPE520' | ||
- ;; | ||
- esac | ||
+ local model="${1%%\(*}" | ||
|
||
- [ -n "$model" ] && AR71XX_MODEL="$model v$2" | ||
+ AR71XX_MODEL="TP-Link $model v$2" | ||
} | ||
|
||
gl_inet_board_detect() { |
45 changes: 45 additions & 0 deletions
45
...es/openwrt/0084-firmware-utils-tplink-safeloader-update-support-list-for-CPE210-510.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
From: Matthias Schiffer <mschiffer@universe-factory.net> | ||
Date: Sun, 11 Dec 2016 18:00:13 +0100 | ||
Subject: firmware-utils: tplink-safeloader: update support list for CPE210/510/... | ||
|
||
Adds support for new EU and US variants, removes a few strings that were | ||
never actually used and have been removed from the stock firmwares. | ||
|
||
Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net> | ||
|
||
diff --git a/tools/firmware-utils/src/tplink-safeloader.c b/tools/firmware-utils/src/tplink-safeloader.c | ||
index 4938f74..4a38dff 100644 | ||
--- a/tools/firmware-utils/src/tplink-safeloader.c | ||
+++ b/tools/firmware-utils/src/tplink-safeloader.c | ||
@@ -169,8 +169,13 @@ static const char cpe210_support_list[] = | ||
"SupportList:\r\n" | ||
"CPE210(TP-LINK|UN|N300-2):1.0\r\n" | ||
"CPE210(TP-LINK|UN|N300-2):1.1\r\n" | ||
- "CPE220(TP-LINK|UN|N300-2):1.0\r\n" | ||
- "CPE220(TP-LINK|UN|N300-2):1.1\r\n"; | ||
+ "CPE210(TP-LINK|US|N300-2):1.1\r\n" | ||
+ "CPE210(TP-LINK|EU|N300-2):1.1\r\n" | ||
+ "CPE220(TP-LINK|UN|N300-2):1.1\r\n" | ||
+ "CPE220(TP-LINK|US|N300-2):1.1\r\n" | ||
+ "CPE220(TP-LINK|EU|N300-2):1.1\r\n" | ||
+ ; | ||
+ | ||
/** | ||
The support list for CPE210/220/510/520 | ||
*/ | ||
@@ -178,8 +183,13 @@ static const char cpe510_support_list[] = | ||
"SupportList:\r\n" | ||
"CPE510(TP-LINK|UN|N300-5):1.0\r\n" | ||
"CPE510(TP-LINK|UN|N300-5):1.1\r\n" | ||
- "CPE520(TP-LINK|UN|N300-5):1.0\r\n" | ||
- "CPE520(TP-LINK|UN|N300-5):1.1\r\n"; | ||
+ "CPE510(TP-LINK|UN|N300-5):1.1\r\n" | ||
+ "CPE510(TP-LINK|US|N300-5):1.1\r\n" | ||
+ "CPE510(TP-LINK|EU|N300-5):1.1\r\n" | ||
+ "CPE520(TP-LINK|UN|N300-5):1.1\r\n" | ||
+ "CPE520(TP-LINK|US|N300-5):1.1\r\n" | ||
+ "CPE520(TP-LINK|EU|N300-5):1.1\r\n" | ||
+ ; | ||
|
||
/** | ||
The support list for C2600 |