aboutsummaryrefslogtreecommitdiffstats
path: root/tools/firmware-utils/src/tplink-safeloader.c
diff options
context:
space:
mode:
authorArvid E. Picciani <aep@exys.org>2018-04-16 13:18:37 +0200
committerJo-Philipp Wich <jo@mein.io>2018-06-21 07:02:51 +0200
commit4e9fa569b0279c81aa9ca96a6669bc08115d4227 (patch)
treed54c229503c07de9915372c3354ad98a259584e7 /tools/firmware-utils/src/tplink-safeloader.c
parent29934e5f0373a7f06c02c3bd6b23fd47cbd48ca2 (diff)
downloadupstream-4e9fa569b0279c81aa9ca96a6669bc08115d4227.tar.gz
upstream-4e9fa569b0279c81aa9ca96a6669bc08115d4227.tar.bz2
upstream-4e9fa569b0279c81aa9ca96a6669bc08115d4227.zip
ar71xx: add support for TP-LINK Archer C7 v5
TP-Link Archer C7 v5 is a dual-band AC1750 router, based on Qualcomm/Atheros QCA9563+QCA9880. Specification: - 750/400/250 MHz (CPU/DDR/AHB - 128 MB of RAM (DDR2) - 16 MB of FLASH (SPI NOR) - 3T3R 2.4 GHz - 3T3R 5 GHz - 5x 10/100/1000 Mbps Ethernet - 10x LED, 2x button - UART header on PCB Flash instruction: 1. Upload lede-ar71xx-generic-archer-c7-v5-squashfs-factory.bin via Web interface Flash instruction using TFTP recovery: 1. Set PC to fixed ip address 192.168.0.66 2. Download lede-ar71xx-generic-archer-c7-v5-squashfs-factory.bin and rename it to ArcherC7v5_tp_recovery.bin 3. Start a tftp server with the file tp_recovery.bin in its root directory 4. Turn off the router 5. Press and hold Reset button 6. Turn on router with the reset button pressed and wait ~15 seconds 7. Release the reset button and after a short time the firmware should be transferred from the tftp server 8. Wait ~30 second to complete recovery. Signed-off-by: Arvid E. Picciani <aep@exys.org> (cherry picked from commit bf39d5594b3c8f9409e6d9408a1f370c9f18d0dd)
Diffstat (limited to 'tools/firmware-utils/src/tplink-safeloader.c')
-rw-r--r--tools/firmware-utils/src/tplink-safeloader.c48
1 files changed, 47 insertions, 1 deletions
diff --git a/tools/firmware-utils/src/tplink-safeloader.c b/tools/firmware-utils/src/tplink-safeloader.c
index 22bbc17d07..bdefb24e0c 100644
--- a/tools/firmware-utils/src/tplink-safeloader.c
+++ b/tools/firmware-utils/src/tplink-safeloader.c
@@ -578,6 +578,52 @@ static struct device_info boards[] = {
.last_sysupgrade_partition = "file-system",
},
+ /** Firmware layout for the C7 v5*/
+ {
+ .id = "ARCHER-C7-V5",
+ .support_list =
+ "SupportList:\n"
+ "{product_name:Archer C7,product_ver:5.0.0,special_id:00000000}\n"
+ "{product_name:Archer C7,product_ver:5.0.0,special_id:55530000}\n",
+
+ .support_trail = '\x00',
+ .soft_ver = "soft_ver:1.0.0\n",
+
+ /**
+ We use a bigger os-image partition than the stock images (and thus
+ smaller file-system), as our kernel doesn't fit in the stock firmware's
+ 1MB os-image.
+ */
+ .partitions = {
+ {"factory-boot", 0x00000, 0x20000},
+ {"fs-uboot", 0x20000, 0x20000},
+ {"partition-table", 0x40000, 0x10000},
+ {"radio", 0x50000, 0x10000},
+ {"default-mac", 0x60000, 0x00200},
+ {"pin", 0x60200, 0x00200},
+ {"device-id", 0x60400, 0x00100},
+ {"product-info", 0x60500, 0x0fb00},
+ {"soft-version", 0x70000, 0x01000},
+ {"extra-para", 0x71000, 0x01000},
+ {"support-list", 0x72000, 0x0a000},
+ {"profile", 0x7c000, 0x04000},
+ {"user-config", 0x80000, 0x40000},
+
+
+ {"os-image", 0xc0000, 0x180000}, /* Stock: base 0xc0000 size 0x120000 */
+ {"file-system", 0x240000, 0xd80000}, /* Stock: base 0x1e0000 size 0xde0000 */
+
+ {"log", 0xfc0000, 0x20000},
+ {"certificate", 0xfe0000, 0x10000},
+ {"default-config", 0xff0000, 0x10000},
+ {NULL, 0, 0}
+
+ },
+
+ .first_sysupgrade_partition = "os-image",
+ .last_sysupgrade_partition = "file-system",
+ },
+
/** Firmware layout for the C9 */
{
.id = "ARCHERC9",
@@ -1389,7 +1435,7 @@ static void build_image(const char *output,
strcasecmp(info->id, "TLWR1043NV5") == 0) {
const char mdat[11] = {0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00};
parts[5] = put_data("extra-para", mdat, 11);
- } else if (strcasecmp(info->id, "ARCHER-C7-V4") == 0) {
+ } else if (strcasecmp(info->id, "ARCHER-C7-V4") == 0 || strcasecmp(info->id, "ARCHER-C7-V5") == 0) {
const char mdat[11] = {0x01, 0x00, 0x00, 0x02, 0x00, 0x00, 0xca, 0x00, 0x01, 0x00, 0x00};
parts[5] = put_data("extra-para", mdat, 11);
}