Skip to content

Commit bae927c

Browse files
apcameronblogic
authored andcommitted
ar71xx: add support for TP-LINK CPE510 V2.0
Adds Support for the TP-LINK CPE510 V2.0 by TP-Link. The hardware is almost the same as the CPE510 V1.0 Follow the same processes as for the CPE510 V1.0 Signed-off-by: Andrew Cameron <[email protected]>
1 parent b9bd328 commit bae927c

File tree

3 files changed

+33
-3
lines changed

3 files changed

+33
-3
lines changed

target/linux/ar71xx/base-files/lib/ar71xx.sh

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -585,7 +585,14 @@ ar71xx_board_detect() {
585585
;;
586586
*"CPE510/520")
587587
name="cpe510"
588-
tplink_pharos_board_detect "$(tplink_pharos_get_model_string | tr -d '\r')"
588+
tplink_pharos_board_detect "$(tplink_pharos_v2_get_model_string)"
589+
case $AR71XX_MODEL in
590+
'TP-Link CPE510 v2.0')
591+
;;
592+
*)
593+
tplink_pharos_board_detect "$(tplink_pharos_get_model_string | tr -d '\r')"
594+
;;
595+
esac
589596
;;
590597
*"CPE830")
591598
name="cpe830"

target/linux/ar71xx/base-files/lib/upgrade/platform.sh

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -582,7 +582,6 @@ platform_check_image() {
582582
return $?
583583
;;
584584
cpe210|\
585-
cpe510|\
586585
eap120|\
587586
wbs210|\
588587
wbs510)
@@ -593,6 +592,20 @@ platform_check_image() {
593592
tplink_pharos_check_image "$1" "01000000" "$(tplink_pharos_v2_get_model_string)" '\0\xff\r' && return 0
594593
return 1
595594
;;
595+
cpe510)
596+
local modelstr="$(tplink_pharos_v2_get_model_string)"
597+
tplink_pharos_board_detect $modelstr
598+
case $AR71XX_MODEL in
599+
'TP-Link CPE510 v2.0')
600+
tplink_pharos_check_image "$1" "7f454c46" "$modelstr" '\0\xff\r' && return 0
601+
return 1
602+
;;
603+
*)
604+
tplink_pharos_check_image "$1" "7f454c46" "$(tplink_pharos_get_model_string)" '' && return 0
605+
return 1
606+
;;
607+
esac
608+
;;
596609
a40|\
597610
a60|\
598611
mr1750|\

tools/firmware-utils/src/tplink-safeloader.c

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -210,7 +210,17 @@ static struct device_info boards[] = {
210210
"CPE510(TP-LINK|EU|N300-5):1.1\r\n"
211211
"CPE520(TP-LINK|UN|N300-5):1.1\r\n"
212212
"CPE520(TP-LINK|US|N300-5):1.1\r\n"
213-
"CPE520(TP-LINK|EU|N300-5):1.1\r\n",
213+
"CPE520(TP-LINK|EU|N300-5):1.1\r\n"
214+
"CPE510(TP-LINK|EU|N300-5|00000000):2.0\r\n"
215+
"CPE510(TP-LINK|EU|N300-5|45550000):2.0\r\n"
216+
"CPE510(TP-LINK|EU|N300-5|55530000):2.0\r\n"
217+
"CPE510(TP-LINK|UN|N300-5|00000000):2.0\r\n"
218+
"CPE510(TP-LINK|UN|N300-5|45550000):2.0\r\n"
219+
"CPE510(TP-LINK|UN|N300-5|55530000):2.0\r\n"
220+
"CPE510(TP-LINK|US|N300-5|55530000):2.0\r\n"
221+
"CPE510(TP-LINK|UN|N300-5):2.0\r\n"
222+
"CPE510(TP-LINK|EU|N300-5):2.0\r\n"
223+
"CPE510(TP-LINK|US|N300-5):2.0\r\n",
214224
.support_trail = '\xff',
215225
.soft_ver = NULL,
216226

0 commit comments

Comments
 (0)