Merge Official Source

This commit is contained in:
CN_SZTL 2019-11-29 00:51:17 +08:00
commit d4f453a85f
No known key found for this signature in database
GPG Key ID: 6850B6345C862176
21 changed files with 397 additions and 214 deletions

View File

@ -782,7 +782,7 @@ menu "Filesystem ACL and attr support options"
select KERNEL_FS_POSIX_ACL select KERNEL_FS_POSIX_ACL
default y if USE_FS_ACL_ATTR default y if USE_FS_ACL_ATTR
config KERNEL_HFSPLUG_FS_POSIX_ACL config KERNEL_HFSPLUS_FS_POSIX_ACL
bool "Enable POSIX ACL for HFS+ Filesystems" bool "Enable POSIX ACL for HFS+ Filesystems"
select KERNEL_FS_POSIX_ACL select KERNEL_FS_POSIX_ACL
default y if USE_FS_ACL_ATTR default y if USE_FS_ACL_ATTR

View File

@ -11,12 +11,12 @@ include $(INCLUDE_DIR)/kernel.mk
PKG_NAME:=wireguard PKG_NAME:=wireguard
PKG_VERSION:=0.0.20191012 PKG_VERSION:=0.0.20191127
PKG_RELEASE:=1 PKG_RELEASE:=1
PKG_SOURCE:=WireGuard-$(PKG_VERSION).tar.xz PKG_SOURCE:=WireGuard-$(PKG_VERSION).tar.xz
PKG_SOURCE_URL:=https://git.zx2c4.com/WireGuard/snapshot/ PKG_SOURCE_URL:=https://git.zx2c4.com/WireGuard/snapshot/
PKG_HASH:=93573193c9c1c22fde31eb1729ad428ca39da77a603a3d81561a9816ccecfa8e PKG_HASH:=7d4e80a6f84564d4826dd05da2b59e8d17645072c0345d0fc0d197be176c3d06
PKG_LICENSE:=GPL-2.0 Apache-2.0 PKG_LICENSE:=GPL-2.0 Apache-2.0
PKG_LICENSE_FILES:=COPYING PKG_LICENSE_FILES:=COPYING

View File

@ -26,7 +26,7 @@
/* default for ar934x, except for 1000M and 10M */ /* default for ar934x, except for 1000M and 10M */
pll-data = <0x06000000 0x00000101 0x00001313>; pll-data = <0x06000000 0x00000101 0x00001313>;
mtd-mac-address = <&eeprom 0x0>; mtd-mac-address = <&art 0x0>;
phy-mode = "rgmii"; phy-mode = "rgmii";
phy-handle = <&phy4>; phy-handle = <&phy4>;

View File

@ -51,7 +51,7 @@
/* default for ar934x, except for 1000M and 10M */ /* default for ar934x, except for 1000M and 10M */
pll-data = <0x06000000 0x00000101 0x00001313>; pll-data = <0x06000000 0x00000101 0x00001313>;
mtd-mac-address = <&eeprom 0x0>; mtd-mac-address = <&art 0x0>;
phy-mode = "rgmii"; phy-mode = "rgmii";
phy-handle = <&phy4>; phy-handle = <&phy4>;

View File

@ -27,7 +27,7 @@
/* default for ar934x, except for 1000M and 10M */ /* default for ar934x, except for 1000M and 10M */
pll-data = <0x06000000 0x00000101 0x00001313>; pll-data = <0x06000000 0x00000101 0x00001313>;
mtd-mac-address = <&eeprom 0x0>; mtd-mac-address = <&art 0x0>;
phy-mode = "rgmii"; phy-mode = "rgmii";
phy-handle = <&phy4>; phy-handle = <&phy4>;

View File

@ -58,7 +58,7 @@
/* default for ar934x, except for 1000M and 10M */ /* default for ar934x, except for 1000M and 10M */
pll-data = <0x06000000 0x00000101 0x00001313>; pll-data = <0x06000000 0x00000101 0x00001313>;
mtd-mac-address = <&eeprom 0x0>; mtd-mac-address = <&art 0x0>;
phy-mode = "rgmii"; phy-mode = "rgmii";
phy-handle = <&phy0>; phy-handle = <&phy0>;
@ -73,5 +73,5 @@
&wmac { &wmac {
status = "okay"; status = "okay";
mtd-cal-data = <&eeprom 0x1000>; mtd-cal-data = <&art 0x1000>;
}; };

View File

@ -75,8 +75,8 @@
read-only; read-only;
}; };
eeprom: partition@ff0000 { art: partition@ff0000 {
label = "EEPROM"; label = "art";
reg = <0xff0000 0x010000>; reg = <0xff0000 0x010000>;
read-only; read-only;
}; };
@ -88,5 +88,5 @@
status = "okay"; status = "okay";
qca,disable-5ghz; qca,disable-5ghz;
mtd-cal-data = <&eeprom 0x1000>; mtd-cal-data = <&art 0x1000>;
}; };

View File

@ -103,8 +103,8 @@
read-only; read-only;
}; };
eeprom: partition@7f0000 { art: partition@7f0000 {
label = "EEPROM"; label = "art";
reg = <0x7f0000 0x010000>; reg = <0x7f0000 0x010000>;
read-only; read-only;
}; };
@ -115,9 +115,9 @@
&wmac { &wmac {
status = "okay"; status = "okay";
mtd-cal-data = <&eeprom 0x1000>; mtd-cal-data = <&art 0x1000>;
}; };
&eth0 { &eth0 {
mtd-mac-address = <&eeprom 0x0>; mtd-mac-address = <&art 0x0>;
}; };

View File

@ -64,8 +64,8 @@
read-only; read-only;
}; };
eeprom: partition@ff0000 { art: partition@ff0000 {
label = "EEPROM"; label = "art";
reg = <0xff0000 0x010000>; reg = <0xff0000 0x010000>;
read-only; read-only;
}; };
@ -79,13 +79,13 @@
&eth0 { &eth0 {
status = "okay"; status = "okay";
mtd-mac-address = <&eeprom 0x0>; mtd-mac-address = <&art 0x0>;
phy-handle = <&swphy4>; phy-handle = <&swphy4>;
}; };
&eth1 { &eth1 {
status = "okay"; status = "okay";
mtd-mac-address = <&eeprom 0x6>; mtd-mac-address = <&art 0x6>;
gmac-config { gmac-config {
device = <&gmac>; device = <&gmac>;
@ -94,5 +94,5 @@
&wmac { &wmac {
status = "okay"; status = "okay";
mtd-cal-data = <&eeprom 0x1000>; mtd-cal-data = <&art 0x1000>;
}; };

View File

@ -0,0 +1,130 @@
// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
/dts-v1/;
#include "qca9563_tplink_archer-x6-v2.dtsi"
/ {
compatible = "tplink,archer-c6-v2-us", "qca,qca9563";
model = "TP-Link Archer C6 v2 (US) / A6 v2 (US/TW)";
aliases {
led-boot = &led_power;
led-failsafe = &led_power;
led-running = &led_power;
led-upgrade = &led_power;
};
leds {
compatible = "gpio-leds";
led_power: power {
label = "tp-link:green:power";
gpios = <&gpio 6 GPIO_ACTIVE_LOW>;
default-state = "on";
};
wlan2g {
label = "tp-link:green:wlan2g";
gpios = <&gpio 14 GPIO_ACTIVE_LOW>;
linux,default-trigger = "phy1tpt";
};
wlan5g {
label = "tp-link:green:wlan5g";
gpios = <&gpio 9 GPIO_ACTIVE_LOW>;
linux,default-trigger = "phy0tpt";
};
lan {
label = "tp-link:green:lan";
gpios = <&gpio 15 GPIO_ACTIVE_LOW>;
};
wan {
label = "tp-link:green:wan";
gpios = <&gpio 8 GPIO_ACTIVE_LOW>;
};
wan_fail {
label = "tp-link:amber:wan";
gpios = <&gpio 7 GPIO_ACTIVE_LOW>;
};
wps {
label = "tp-link:green:wps";
gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
};
};
keys {
compatible = "gpio-keys";
reset {
label = "Reset button";
linux,code = <KEY_RESTART>;
gpios = <&gpio 5 GPIO_ACTIVE_LOW>;
debounce-interval = <60>;
};
wps {
label = "WPS button";
linux,code = <KEY_WPS_BUTTON>;
gpios = <&gpio 2 GPIO_ACTIVE_LOW>;
debounce-interval = <60>;
};
};
};
&spi {
status = "okay";
num-cs = <1>;
flash@0 {
compatible = "jedec,spi-nor";
reg = <0>;
spi-max-frequency = <25000000>;
partitions {
compatible = "fixed-partitions";
#address-cells = <1>;
#size-cells = <1>;
partition@0 {
label = "factory-boot";
reg = <0x000000 0x020000>;
read-only;
};
mac: partition@20000 {
label = "mac";
reg = <0x020000 0x010000>;
read-only;
};
partition@30000 {
label = "u-boot";
reg = <0x030000 0x020000>;
read-only;
};
partition@50000 {
compatible = "denx,uimage";
label = "firmware";
reg = <0x050000 0xf80000>;
};
partition@fd0000 {
label = "tplink";
reg = <0xfd0000 0x020000>;
read-only;
};
art: partition@ff0000 {
label = "art";
reg = <0xff0000 0x010000>;
read-only;
};
};
};
};

View File

@ -5,5 +5,120 @@
/ { / {
compatible = "tplink,archer-c6-v2", "qca,qca9563"; compatible = "tplink,archer-c6-v2", "qca,qca9563";
model = "TP-Link Archer C6 v2"; model = "TP-Link Archer C6 v2 (EU/RU/JP)";
aliases {
led-boot = &led_power;
led-failsafe = &led_power;
led-running = &led_power;
led-upgrade = &led_power;
};
leds {
compatible = "gpio-leds";
led_power: power {
label = "tp-link:green:power";
gpios = <&gpio 17 GPIO_ACTIVE_LOW>;
default-state = "on";
};
wlan2g {
label = "tp-link:green:wlan2g";
gpios = <&gpio 15 GPIO_ACTIVE_LOW>;
linux,default-trigger = "phy1tpt";
};
wlan5g {
label = "tp-link:green:wlan5g";
gpios = <&gpio 19 GPIO_ACTIVE_LOW>;
linux,default-trigger = "phy0tpt";
};
lan {
label = "tp-link:green:lan";
gpios = <&gpio 20 GPIO_ACTIVE_LOW>;
};
wan {
label = "tp-link:green:wan";
gpios = <&gpio 7 GPIO_ACTIVE_LOW>;
};
wan_fail {
label = "tp-link:amber:wan";
gpios = <&gpio 8 GPIO_ACTIVE_LOW>;
};
wps {
label = "tp-link:green:wps";
gpios = <&gpio 9 GPIO_ACTIVE_LOW>;
};
};
keys {
compatible = "gpio-keys";
reset {
label = "Reset button";
linux,code = <KEY_RESTART>;
gpios = <&gpio 5 GPIO_ACTIVE_LOW>;
debounce-interval = <60>;
};
wps {
label = "WPS button";
linux,code = <KEY_WPS_BUTTON>;
gpios = <&gpio 6 GPIO_ACTIVE_LOW>;
debounce-interval = <60>;
};
};
};
&spi {
status = "okay";
num-cs = <1>;
flash@0 {
compatible = "jedec,spi-nor";
reg = <0>;
spi-max-frequency = <25000000>;
partitions {
compatible = "fixed-partitions";
#address-cells = <1>;
#size-cells = <1>;
partition@0 {
label = "u-boot";
reg = <0x000000 0x020000>;
read-only;
};
mac: partition@20000 {
label = "mac";
reg = <0x020000 0x010000>;
read-only;
};
partition@30000 {
compatible = "denx,uimage";
label = "firmware";
reg = <0x030000 0x7a0000>;
};
partition@7d0000 {
label = "tplink";
reg = <0x7d0000 0x020000>;
read-only;
};
art: partition@7f0000 {
label = "art";
reg = <0x7f0000 0x010000>;
read-only;
};
};
};
}; };

View File

@ -1,5 +1,4 @@
// SPDX-License-Identifier: GPL-2.0-or-later OR MIT // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
/dts-v1/;
#include <dt-bindings/gpio/gpio.h> #include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/input/input.h> #include <dt-bindings/input/input.h>
@ -7,76 +6,12 @@
#include "qca956x.dtsi" #include "qca956x.dtsi"
/ { / {
chosen {
bootargs = "console=ttyS0,115200n8";
};
aliases { aliases {
led-boot = &led_power;
led-failsafe = &led_power;
led-running = &led_power;
led-upgrade = &led_power;
label-mac-device = &eth0; label-mac-device = &eth0;
}; };
leds { chosen {
compatible = "gpio-leds"; bootargs = "console=ttyS0,115200n8";
led_power: power {
label = "tp-link:green:power";
gpios = <&gpio 17 GPIO_ACTIVE_LOW>;
default-state = "on";
};
wlan2g {
label = "tp-link:green:wlan2g";
gpios = <&gpio 15 GPIO_ACTIVE_LOW>;
linux,default-trigger = "phy1tpt";
};
wlan5g {
label = "tp-link:green:wlan5g";
gpios = <&gpio 19 GPIO_ACTIVE_LOW>;
linux,default-trigger = "phy0tpt";
};
lan {
label = "tp-link:green:lan";
gpios = <&gpio 20 GPIO_ACTIVE_LOW>;
};
wan {
label = "tp-link:green:wan";
gpios = <&gpio 7 GPIO_ACTIVE_LOW>;
};
wan_fail {
label = "tp-link:amber:wan";
gpios = <&gpio 8 GPIO_ACTIVE_LOW>;
};
wps {
label = "tp-link:green:wps";
gpios = <&gpio 9 GPIO_ACTIVE_LOW>;
};
};
keys {
compatible = "gpio-keys";
reset {
label = "Reset button";
linux,code = <KEY_RESTART>;
gpios = <&gpio 5 GPIO_ACTIVE_LOW>;
debounce-interval = <60>;
};
wps {
label = "WPS button";
linux,code = <KEY_WPS_BUTTON>;
gpios = <&gpio 6 GPIO_ACTIVE_LOW>;
debounce-interval = <60>;
};
}; };
}; };
@ -92,54 +27,6 @@
status = "okay"; status = "okay";
}; };
&spi {
status = "okay";
num-cs = <1>;
flash@0 {
compatible = "jedec,spi-nor";
reg = <0>;
spi-max-frequency = <25000000>;
partitions {
compatible = "fixed-partitions";
#address-cells = <1>;
#size-cells = <1>;
partition@0 {
label = "u-boot";
reg = <0x000000 0x020000>;
read-only;
};
mac: partition@20000 {
label = "mac";
reg = <0x020000 0x010000>;
read-only;
};
partition@30000 {
compatible = "denx,uimage";
label = "firmware";
reg = <0x030000 0x7a0000>;
};
partition@7d0000 {
label = "tplink";
reg = <0x7d0000 0x020000>;
read-only;
};
art: partition@7f0000 {
label = "art";
reg = <0x7f0000 0x010000>;
read-only;
};
};
};
};
&mdio0 { &mdio0 {
status = "okay"; status = "okay";
@ -161,8 +48,9 @@
status = "okay"; status = "okay";
phy-mode = "sgmii"; phy-mode = "sgmii";
mtd-mac-address = <&mac 0x8>;
phy-handle = <&phy0>; phy-handle = <&phy0>;
mtd-mac-address = <&mac 0x8>;
}; };
&wmac { &wmac {

View File

@ -21,6 +21,6 @@
&eth0 { &eth0 {
status = "okay"; status = "okay";
mtd-mac-address = <&eeprom 0x0>; mtd-mac-address = <&art 0x0>;
phy-handle = <&phy4>; phy-handle = <&phy4>;
}; };

View File

@ -25,6 +25,6 @@
&eth0 { &eth0 {
status = "okay"; status = "okay";
mtd-mac-address = <&eeprom 0x0>; mtd-mac-address = <&art 0x0>;
phy-handle = <&phy0>; phy-handle = <&phy0>;
}; };

View File

@ -104,8 +104,8 @@
read-only; read-only;
}; };
eeprom: partition@ff0000 { art: partition@ff0000 {
label = "EEPROM"; label = "art";
reg = <0xff0000 0x010000>; reg = <0xff0000 0x010000>;
read-only; read-only;
}; };
@ -116,5 +116,5 @@
&wmac { &wmac {
status = "okay"; status = "okay";
mtd-cal-data = <&eeprom 0x1000>; mtd-cal-data = <&art 0x1000>;
}; };

View File

@ -146,7 +146,8 @@ tplink,tl-wr1043n-v5)
ucidef_set_led_switch "lan3" "LAN3" "tp-link:green:lan3" "switch0" "0x04" ucidef_set_led_switch "lan3" "LAN3" "tp-link:green:lan3" "switch0" "0x04"
ucidef_set_led_switch "lan4" "LAN4" "tp-link:green:lan4" "switch0" "0x02" ucidef_set_led_switch "lan4" "LAN4" "tp-link:green:lan4" "switch0" "0x02"
;; ;;
tplink,archer-c6-v2) tplink,archer-c6-v2|\
tplink,archer-c6-v2-us)
ucidef_set_led_switch "lan" "LAN" "tp-link:green:lan" "switch0" "0x3C" ucidef_set_led_switch "lan" "LAN" "tp-link:green:lan" "switch0" "0x3C"
ucidef_set_led_switch "wan" "WAN" "tp-link:green:wan" "switch0" "0x02" ucidef_set_led_switch "wan" "WAN" "tp-link:green:wan" "switch0" "0x02"
;; ;;

View File

@ -207,6 +207,7 @@ ath79_setup_interfaces()
;; ;;
tplink,archer-a7-v5|\ tplink,archer-a7-v5|\
tplink,archer-c6-v2|\ tplink,archer-c6-v2|\
tplink,archer-c6-v2-us|\
tplink,archer-c7-v4|\ tplink,archer-c7-v4|\
tplink,archer-c7-v5|\ tplink,archer-c7-v5|\
tplink,tl-wdr3600-v1|\ tplink,tl-wdr3600-v1|\

View File

@ -12,6 +12,15 @@ case "$FIRMWARE" in
case $board in case $board in
comfast,cf-wr650ac-v1|\ comfast,cf-wr650ac-v1|\
comfast,cf-wr650ac-v2|\ comfast,cf-wr650ac-v2|\
ubnt,unifiac-lite|\
ubnt,unifiac-lr|\
ubnt,unifiac-mesh|\
ubnt,unifiac-mesh-pro|\
ubnt,lap-120|\
ubnt,nanobeam-ac|\
ubnt,nanostation-ac|\
ubnt,nanostation-ac-loco|\
ubnt,unifiac-pro|\
yuncore,a770) yuncore,a770)
caldata_extract "art" 0x5000 0x844 caldata_extract "art" 0x5000 0x844
;; ;;
@ -101,17 +110,6 @@ case "$FIRMWARE" in
caldata_extract "art" 0x5000 0x844 caldata_extract "art" 0x5000 0x844
ath10k_patch_mac $(macaddr_add $(mtd_get_mac_binary info 0x8) +1) ath10k_patch_mac $(macaddr_add $(mtd_get_mac_binary info 0x8) +1)
;; ;;
ubnt,unifiac-lite|\
ubnt,unifiac-lr|\
ubnt,unifiac-mesh|\
ubnt,unifiac-mesh-pro|\
ubnt,lap-120|\
ubnt,nanobeam-ac|\
ubnt,nanostation-ac|\
ubnt,nanostation-ac-loco|\
ubnt,unifiac-pro)
caldata_extract "EEPROM" 0x5000 0x844
;;
esac esac
;; ;;
"ath10k/pre-cal-pci-0000:00:00.0.bin") "ath10k/pre-cal-pci-0000:00:00.0.bin")
@ -148,7 +146,8 @@ case "$FIRMWARE" in
tplink,archer-c59-v2|\ tplink,archer-c59-v2|\
tplink,archer-c60-v1|\ tplink,archer-c60-v1|\
tplink,archer-c60-v2|\ tplink,archer-c60-v2|\
tplink,archer-c6-v2) tplink,archer-c6-v2|\
tplink,archer-c6-v2-us)
caldata_extract "art" 0x5000 0x2f20 caldata_extract "art" 0x5000 0x2f20
ath10k_patch_mac $(macaddr_add $(mtd_get_mac_binary mac 0x8) -1) ath10k_patch_mac $(macaddr_add $(mtd_get_mac_binary mac 0x8) -1)
ln -sf /lib/firmware/ath10k/pre-cal-pci-0000\:00\:00.0.bin \ ln -sf /lib/firmware/ath10k/pre-cal-pci-0000\:00\:00.0.bin \

View File

@ -88,12 +88,26 @@ define Device/tplink_archer-c6-v2
ATH_SOC := qca9563 ATH_SOC := qca9563
IMAGE_SIZE := 7808k IMAGE_SIZE := 7808k
DEVICE_MODEL := Archer C6 DEVICE_MODEL := Archer C6
DEVICE_VARIANT := v2 DEVICE_VARIANT := v2 (EU/RU/JP)
TPLINK_BOARD_ID := ARCHER-C6-V2 TPLINK_BOARD_ID := ARCHER-C6-V2
DEVICE_PACKAGES := kmod-ath10k-ct ath10k-firmware-qca9888-ct DEVICE_PACKAGES := kmod-ath10k-ct ath10k-firmware-qca9888-ct
endef endef
TARGET_DEVICES += tplink_archer-c6-v2 TARGET_DEVICES += tplink_archer-c6-v2
define Device/tplink_archer-c6-v2-us
$(Device/tplink-safeloader-uimage)
ATH_SOC := qca9563
IMAGE_SIZE := 15872k
DEVICE_MODEL := Archer C6
DEVICE_VARIANT := v2 (US)
DEVICE_ALT0_VENDOR := TP-Link
DEVICE_ALT0_MODEL := Archer A6
DEVICE_ALT0_VARIANT := v2 (US/TW)
TPLINK_BOARD_ID := ARCHER-C6-V2-US
DEVICE_PACKAGES := kmod-ath10k-ct ath10k-firmware-qca9888-ct
endef
TARGET_DEVICES += tplink_archer-c6-v2-us
define Device/tplink_archer-c60-v1 define Device/tplink_archer-c60-v1
$(Device/tplink-safeloader-uimage) $(Device/tplink-safeloader-uimage)
ATH_SOC := qca9561 ATH_SOC := qca9561

View File

@ -37,16 +37,17 @@ endef
define Device/Default define Device/Default
PROFILES := Default PROFILES := Default
DEVICE_DTS := $(1) DEVICE_DTS := $(lastword $(subst _, ,$(1)))
KERNEL_DEPENDS = $$(wildcard $(DTS_DIR)/$$(DEVICE_DTS).dts) KERNEL_DEPENDS = $$(wildcard $(DTS_DIR)/$$(DEVICE_DTS).dts)
KERNEL_ENTRY := 0x00000000 KERNEL_ENTRY := 0x00000000
KERNEL_LOADADDR := 0x00000000 KERNEL_LOADADDR := 0x00000000
KERNEL := kernel-bin KERNEL := kernel-bin
SUPPORTED_DEVICES := $(subst _,$(comma),$(1))
endef endef
ifeq ($(SUBTARGET),generic) ifeq ($(SUBTARGET),generic)
define Device/tl-wdr4900-v1 define Device/tplink_tl-wdr4900-v1
DEVICE_VENDOR := TP-Link DEVICE_VENDOR := TP-Link
DEVICE_MODEL := TL-WDR4900 DEVICE_MODEL := TL-WDR4900
DEVICE_VARIANT := v1 DEVICE_VARIANT := v1
@ -59,33 +60,32 @@ define Device/tl-wdr4900-v1
KERNEL := kernel-bin | uImage none KERNEL := kernel-bin | uImage none
KERNEL_ENTRY := 0x1000000 KERNEL_ENTRY := 0x1000000
KERNEL_LOADADDR := 0x1000000 KERNEL_LOADADDR := 0x1000000
SUPPORTED_DEVICES:=tl-wdr4900-v1 tplink,tl-wdr4900-v1 SUPPORTED_DEVICES += tl-wdr4900-v1
ARTIFACTS := fdt.bin ARTIFACTS := fdt.bin
ARTIFACT/fdt.bin := append-dtb ARTIFACT/fdt.bin := append-dtb
IMAGES := fdt.bin factory.bin sysupgrade.bin IMAGES := fdt.bin factory.bin sysupgrade.bin
IMAGE/sysupgrade.bin := append-rootfs | mktplinkfw sysupgrade | append-metadata IMAGE/sysupgrade.bin := append-rootfs | mktplinkfw sysupgrade | append-metadata
IMAGE/factory.bin := append-rootfs | mktplinkfw factory IMAGE/factory.bin := append-rootfs | mktplinkfw factory
endef endef
TARGET_DEVICES += tl-wdr4900-v1 TARGET_DEVICES += tplink_tl-wdr4900-v1
define Device/red-15w-rev1 define Device/sophos_red-15w-rev1
DEVICE_VENDOR := Sophos DEVICE_VENDOR := Sophos
DEVICE_MODEL := RED 15w DEVICE_MODEL := RED 15w
DEVICE_VARIANT := Rev.1 DEVICE_VARIANT := Rev.1
# Original firmware uses a dedicated DTB-partition. # Original firmware uses a dedicated DTB-partition.
# The bootloader however supports FIT-images. # The bootloader however supports FIT-images.
KERNEL = kernel-bin | gzip | fit gzip $(KDIR)/image-$$(DEVICE_DTS).dtb KERNEL = kernel-bin | gzip | fit gzip $(KDIR)/image-$$(DEVICE_DTS).dtb
SUPPORTED_DEVICES := sophos,red-15w-rev1
IMAGES := sysupgrade.bin IMAGES := sysupgrade.bin
IMAGE/sysupgrade.bin := sysupgrade-tar | append-metadata IMAGE/sysupgrade.bin := sysupgrade-tar | append-metadata
endef endef
TARGET_DEVICES += red-15w-rev1 TARGET_DEVICES += sophos_red-15w-rev1
endif endif
ifeq ($(SUBTARGET),p1020) ifeq ($(SUBTARGET),p1020)
define Device/hiveap-330 define Device/aerohive_hiveap-330
DEVICE_VENDOR := Aerohive DEVICE_VENDOR := Aerohive
DEVICE_MODEL := HiveAP-330 DEVICE_MODEL := HiveAP-330
DEVICE_PACKAGES := kmod-tpm-i2c-atmel DEVICE_PACKAGES := kmod-tpm-i2c-atmel
@ -93,7 +93,6 @@ define Device/hiveap-330
KERNEL := kernel-bin | gzip | uImage gzip KERNEL := kernel-bin | gzip | uImage gzip
KERNEL_SIZE := 8m KERNEL_SIZE := 8m
KERNEL_INITRAMFS := copy-file $(KDIR)/vmlinux-initramfs | uImage none KERNEL_INITRAMFS := copy-file $(KDIR)/vmlinux-initramfs | uImage none
SUPPORTED_DEVICES := aerohive,hiveap-330
IMAGES := fdt.bin sysupgrade.bin IMAGES := fdt.bin sysupgrade.bin
IMAGE/fdt.bin := append-dtb IMAGE/fdt.bin := append-dtb
IMAGE/sysupgrade.bin := append-dtb | pad-to 256k | check-size 256k | \ IMAGE/sysupgrade.bin := append-dtb | pad-to 256k | check-size 256k | \
@ -101,9 +100,9 @@ define Device/hiveap-330
append-rootfs | pad-rootfs $$(BLOCKSIZE) | pad-to 41216k | check-size 41216k | \ append-rootfs | pad-rootfs $$(BLOCKSIZE) | pad-to 41216k | check-size 41216k | \
append-kernel | append-metadata append-kernel | append-metadata
endef endef
TARGET_DEVICES += hiveap-330 TARGET_DEVICES += aerohive_hiveap-330
define Device/panda define Device/ocedo_panda
DEVICE_VENDOR := OCEDO DEVICE_VENDOR := OCEDO
DEVICE_MODEL := Panda DEVICE_MODEL := Panda
DEVICE_PACKAGES := kmod-rtc-ds1307 uboot-envtools DEVICE_PACKAGES := kmod-rtc-ds1307 uboot-envtools
@ -111,18 +110,17 @@ define Device/panda
PAGESIZE := 2048 PAGESIZE := 2048
SUBPAGESIZE := 512 SUBPAGESIZE := 512
BLOCKSIZE := 128k BLOCKSIZE := 128k
SUPPORTED_DEVICES := ocedo,panda
IMAGES := fdt.bin sysupgrade.bin IMAGES := fdt.bin sysupgrade.bin
IMAGE/sysupgrade.bin := sysupgrade-tar | append-metadata IMAGE/sysupgrade.bin := sysupgrade-tar | append-metadata
IMAGE/fdt.bin := append-dtb IMAGE/fdt.bin := append-dtb
endef endef
TARGET_DEVICES += panda TARGET_DEVICES += ocedo_panda
endif endif
ifeq ($(SUBTARGET),p2020) ifeq ($(SUBTARGET),p2020)
define Device/p2020rdb define Device/freescale_p2020rdb
DEVICE_VENDOR := Freescale DEVICE_VENDOR := Freescale
DEVICE_MODEL := P2020RDB DEVICE_MODEL := P2020RDB
DEVICE_DTS_DIR := $(DTS_DIR)/fsl DEVICE_DTS_DIR := $(DTS_DIR)/fsl
@ -136,7 +134,7 @@ define Device/p2020rdb
IMAGE/sysupgrade.bin := append-kernel | append-rootfs | \ IMAGE/sysupgrade.bin := append-kernel | append-rootfs | \
pad-rootfs $$(BLOCKSIZE) | append-metadata pad-rootfs $$(BLOCKSIZE) | append-metadata
endef endef
TARGET_DEVICES += p2020rdb TARGET_DEVICES += freescale_p2020rdb
endif endif

View File

@ -120,8 +120,8 @@ static const uint8_t md5_salt[16] = {
static struct device_info boards[] = { static struct device_info boards[] = {
/** Firmware layout for the CPE210/220 V1 */ /** Firmware layout for the CPE210/220 V1 */
{ {
.id = "CPE210", .id = "CPE210",
.vendor = "CPE510(TP-LINK|UN|N300-5):1.0\r\n", .vendor = "CPE510(TP-LINK|UN|N300-5):1.0\r\n",
.support_list = .support_list =
"SupportList:\r\n" "SupportList:\r\n"
"CPE210(TP-LINK|UN|N300-2):1.0\r\n" "CPE210(TP-LINK|UN|N300-2):1.0\r\n"
@ -233,8 +233,8 @@ static struct device_info boards[] = {
/** Firmware layout for the CPE220 V2 */ /** Firmware layout for the CPE220 V2 */
{ {
.id = "CPE220V2", .id = "CPE220V2",
.vendor = "CPE510(TP-LINK|UN|N300-5):1.0\r\n", .vendor = "CPE510(TP-LINK|UN|N300-5):1.0\r\n",
.support_list = .support_list =
"SupportList:\r\n" "SupportList:\r\n"
"CPE220(TP-LINK|EU|N300-2|00000000):2.0\r\n" "CPE220(TP-LINK|EU|N300-2|00000000):2.0\r\n"
@ -314,8 +314,8 @@ static struct device_info boards[] = {
/** Firmware layout for the CPE510/520 V1 */ /** Firmware layout for the CPE510/520 V1 */
{ {
.id = "CPE510", .id = "CPE510",
.vendor = "CPE510(TP-LINK|UN|N300-5):1.0\r\n", .vendor = "CPE510(TP-LINK|UN|N300-5):1.0\r\n",
.support_list = .support_list =
"SupportList:\r\n" "SupportList:\r\n"
"CPE510(TP-LINK|UN|N300-5):1.0\r\n" "CPE510(TP-LINK|UN|N300-5):1.0\r\n"
@ -475,8 +475,8 @@ static struct device_info boards[] = {
}, },
{ {
.id = "WBS210", .id = "WBS210",
.vendor = "CPE510(TP-LINK|UN|N300-5):1.0\r\n", .vendor = "CPE510(TP-LINK|UN|N300-5):1.0\r\n",
.support_list = .support_list =
"SupportList:\r\n" "SupportList:\r\n"
"WBS210(TP-LINK|UN|N300-2):1.20\r\n" "WBS210(TP-LINK|UN|N300-2):1.20\r\n"
@ -507,8 +507,8 @@ static struct device_info boards[] = {
}, },
{ {
.id = "WBS210V2", .id = "WBS210V2",
.vendor = "CPE510(TP-LINK|UN|N300-5):1.0\r\n", .vendor = "CPE510(TP-LINK|UN|N300-5):1.0\r\n",
.support_list = .support_list =
"SupportList:\r\n" "SupportList:\r\n"
"WBS210(TP-LINK|UN|N300-2|00000000):2.0\r\n" "WBS210(TP-LINK|UN|N300-2|00000000):2.0\r\n"
@ -539,8 +539,8 @@ static struct device_info boards[] = {
}, },
{ {
.id = "WBS510", .id = "WBS510",
.vendor = "CPE510(TP-LINK|UN|N300-5):1.0\r\n", .vendor = "CPE510(TP-LINK|UN|N300-5):1.0\r\n",
.support_list = .support_list =
"SupportList:\r\n" "SupportList:\r\n"
"WBS510(TP-LINK|UN|N300-5):1.20\r\n" "WBS510(TP-LINK|UN|N300-5):1.20\r\n"
@ -572,8 +572,8 @@ static struct device_info boards[] = {
}, },
{ {
.id = "WBS510V2", .id = "WBS510V2",
.vendor = "CPE510(TP-LINK|UN|N300-5):1.0\r\n", .vendor = "CPE510(TP-LINK|UN|N300-5):1.0\r\n",
.support_list = .support_list =
"SupportList:\r\n" "SupportList:\r\n"
"WBS510(TP-LINK|UN|N300-5|00000000):2.0\r\n" "WBS510(TP-LINK|UN|N300-5|00000000):2.0\r\n"
@ -606,7 +606,7 @@ static struct device_info boards[] = {
/** Firmware layout for the C2600 */ /** Firmware layout for the C2600 */
{ {
.id = "C2600", .id = "C2600",
.vendor = "", .vendor = "",
.support_list = .support_list =
"SupportList:\r\n" "SupportList:\r\n"
@ -654,7 +654,7 @@ static struct device_info boards[] = {
/** Firmware layout for the A7-V5 */ /** Firmware layout for the A7-V5 */
{ {
.id = "ARCHER-A7-V5", .id = "ARCHER-A7-V5",
.support_list = .support_list =
"SupportList:\n" "SupportList:\n"
"{product_name:Archer A7,product_ver:5.0.0,special_id:45550000}\n" "{product_name:Archer A7,product_ver:5.0.0,special_id:45550000}\n"
@ -694,7 +694,7 @@ static struct device_info boards[] = {
/** Firmware layout for the C2v3 */ /** Firmware layout for the C2v3 */
{ {
.id = "ARCHER-C2-V3", .id = "ARCHER-C2-V3",
.support_list = .support_list =
"SupportList:\n" "SupportList:\n"
"{product_name:ArcherC2,product_ver:3.0.0,special_id:00000000}\n" "{product_name:ArcherC2,product_ver:3.0.0,special_id:00000000}\n"
@ -732,7 +732,7 @@ static struct device_info boards[] = {
/** Firmware layout for the C25v1 */ /** Firmware layout for the C25v1 */
{ {
.id = "ARCHER-C25-V1", .id = "ARCHER-C25-V1",
.support_list = .support_list =
"SupportList:\n" "SupportList:\n"
"{product_name:ArcherC25,product_ver:1.0.0,special_id:00000000}\n" "{product_name:ArcherC25,product_ver:1.0.0,special_id:00000000}\n"
@ -770,8 +770,8 @@ static struct device_info boards[] = {
/** Firmware layout for the C58v1 */ /** Firmware layout for the C58v1 */
{ {
.id = "ARCHER-C58-V1", .id = "ARCHER-C58-V1",
.vendor = "", .vendor = "",
.support_list = .support_list =
"SupportList:\r\n" "SupportList:\r\n"
"{product_name:Archer C58,product_ver:1.0.0,special_id:00000000}\r\n" "{product_name:Archer C58,product_ver:1.0.0,special_id:00000000}\r\n"
@ -804,8 +804,8 @@ static struct device_info boards[] = {
/** Firmware layout for the C59v1 */ /** Firmware layout for the C59v1 */
{ {
.id = "ARCHER-C59-V1", .id = "ARCHER-C59-V1",
.vendor = "", .vendor = "",
.support_list = .support_list =
"SupportList:\r\n" "SupportList:\r\n"
"{product_name:Archer C59,product_ver:1.0.0,special_id:00000000}\r\n" "{product_name:Archer C59,product_ver:1.0.0,special_id:00000000}\r\n"
@ -843,8 +843,8 @@ static struct device_info boards[] = {
/** Firmware layout for the C59v2 */ /** Firmware layout for the C59v2 */
{ {
.id = "ARCHER-C59-V2", .id = "ARCHER-C59-V2",
.vendor = "", .vendor = "",
.support_list = .support_list =
"SupportList:\r\n" "SupportList:\r\n"
"{product_name:Archer C59,product_ver:2.0.0,special_id:00000000}\r\n" "{product_name:Archer C59,product_ver:2.0.0,special_id:00000000}\r\n"
@ -881,10 +881,10 @@ static struct device_info boards[] = {
.last_sysupgrade_partition = "file-system", .last_sysupgrade_partition = "file-system",
}, },
/** Firmware layout for the C6v2 */ /** Firmware layout for the Archer C6 v2 (EU/RU/JP) */
{ {
.id = "ARCHER-C6-V2", .id = "ARCHER-C6-V2",
.vendor = "", .vendor = "",
.support_list = .support_list =
"SupportList:\r\n" "SupportList:\r\n"
"{product_name:Archer C6,product_ver:2.0.0,special_id:45550000}\r\n" "{product_name:Archer C6,product_ver:2.0.0,special_id:45550000}\r\n"
@ -916,11 +916,45 @@ static struct device_info boards[] = {
.last_sysupgrade_partition = "file-system", .last_sysupgrade_partition = "file-system",
}, },
/** Firmware layout for the Archer C6 v2 (US) and A6 v2 (US/TW) */
{
.id = "ARCHER-C6-V2-US",
.vendor = "",
.support_list =
"SupportList:\n"
"{product_name:Archer A6,product_ver:2.0.0,special_id:55530000}\n"
"{product_name:Archer A6,product_ver:2.0.0,special_id:54570000}\n"
"{product_name:Archer C6,product_ver:2.0.0,special_id:55530000}\n",
.support_trail = '\x00',
.soft_ver = "soft_ver:1.1.1\n",
.partitions = {
{"factory-boot", 0x00000, 0x20000},
{"default-mac", 0x20000, 0x00200},
{"pin", 0x20200, 0x00100},
{"product-info", 0x20300, 0x00200},
{"device-id", 0x20500, 0x0fb00},
{"fs-uboot", 0x30000, 0x20000},
{"firmware", 0x50000, 0xf89400},
{"soft-version", 0xfd9400, 0x00100},
{"extra-para", 0xfd9500, 0x00100},
{"support-list", 0xfd9600, 0x00200},
{"profile", 0xfd9800, 0x03000},
{"default-config", 0xfdc800, 0x03000},
{"partition-table", 0xfdf800, 0x00800},
{"user-config", 0xfe0000, 0x0c000},
{"certificate", 0xfec000, 0x04000},
{"radio", 0xff0000, 0x10000},
{NULL, 0, 0}
},
.first_sysupgrade_partition = "os-image",
.last_sysupgrade_partition = "file-system",
},
/** Firmware layout for the C60v1 */ /** Firmware layout for the C60v1 */
{ {
.id = "ARCHER-C60-V1", .id = "ARCHER-C60-V1",
.vendor = "", .vendor = "",
.support_list = .support_list =
"SupportList:\r\n" "SupportList:\r\n"
"{product_name:Archer C60,product_ver:1.0.0,special_id:00000000}\r\n" "{product_name:Archer C60,product_ver:1.0.0,special_id:00000000}\r\n"
@ -953,8 +987,8 @@ static struct device_info boards[] = {
/** Firmware layout for the C60v2 */ /** Firmware layout for the C60v2 */
{ {
.id = "ARCHER-C60-V2", .id = "ARCHER-C60-V2",
.vendor = "", .vendor = "",
.support_list = .support_list =
"SupportList:\r\n" "SupportList:\r\n"
"{product_name:Archer C60,product_ver:2.0.0,special_id:42520000}\r\n" "{product_name:Archer C60,product_ver:2.0.0,special_id:42520000}\r\n"
@ -989,7 +1023,7 @@ static struct device_info boards[] = {
/** Firmware layout for the C5 */ /** Firmware layout for the C5 */
{ {
.id = "ARCHER-C5-V2", .id = "ARCHER-C5-V2",
.vendor = "", .vendor = "",
.support_list = .support_list =
"SupportList:\r\n" "SupportList:\r\n"
@ -1024,7 +1058,7 @@ static struct device_info boards[] = {
/** Firmware layout for the C7 */ /** Firmware layout for the C7 */
{ {
.id = "ARCHER-C7-V4", .id = "ARCHER-C7-V4",
.support_list = .support_list =
"SupportList:\n" "SupportList:\n"
"{product_name:Archer C7,product_ver:4.0.0,special_id:00000000}\n" "{product_name:Archer C7,product_ver:4.0.0,special_id:00000000}\n"
@ -1070,7 +1104,7 @@ static struct device_info boards[] = {
/** Firmware layout for the C7 v5*/ /** Firmware layout for the C7 v5*/
{ {
.id = "ARCHER-C7-V5", .id = "ARCHER-C7-V5",
.support_list = .support_list =
"SupportList:\n" "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:00000000}\n"
@ -1118,7 +1152,7 @@ static struct device_info boards[] = {
/** Firmware layout for the C9 */ /** Firmware layout for the C9 */
{ {
.id = "ARCHERC9", .id = "ARCHERC9",
.vendor = "", .vendor = "",
.support_list = .support_list =
"SupportList:\n" "SupportList:\n"
@ -1405,7 +1439,7 @@ static struct device_info boards[] = {
/** Firmware layout for the RE350 v1 */ /** Firmware layout for the RE350 v1 */
{ {
.id = "RE350-V1", .id = "RE350-V1",
.vendor = "", .vendor = "",
.support_list = .support_list =
"SupportList:\n" "SupportList:\n"
@ -1442,7 +1476,7 @@ static struct device_info boards[] = {
/** Firmware layout for the RE350K v1 */ /** Firmware layout for the RE350K v1 */
{ {
.id = "RE350K-V1", .id = "RE350K-V1",
.vendor = "", .vendor = "",
.support_list = .support_list =
"SupportList:\n" "SupportList:\n"
@ -1474,7 +1508,7 @@ static struct device_info boards[] = {
/** Firmware layout for the RE355 */ /** Firmware layout for the RE355 */
{ {
.id = "RE355", .id = "RE355",
.vendor = "", .vendor = "",
.support_list = .support_list =
"SupportList:\r\n" "SupportList:\r\n"
@ -1512,7 +1546,7 @@ static struct device_info boards[] = {
/** Firmware layout for the RE450 */ /** Firmware layout for the RE450 */
{ {
.id = "RE450", .id = "RE450",
.vendor = "", .vendor = "",
.support_list = .support_list =
"SupportList:\r\n" "SupportList:\r\n"
@ -1550,7 +1584,7 @@ static struct device_info boards[] = {
/** Firmware layout for the RE450 v2 */ /** Firmware layout for the RE450 v2 */
{ {
.id = "RE450-V2", .id = "RE450-V2",
.vendor = "", .vendor = "",
.support_list = .support_list =
"SupportList:\r\n" "SupportList:\r\n"
@ -1590,7 +1624,7 @@ static struct device_info boards[] = {
/** Firmware layout for the RE650 */ /** Firmware layout for the RE650 */
{ {
.id = "RE650-V1", .id = "RE650-V1",
.vendor = "", .vendor = "",
.support_list = .support_list =
"SupportList:\r\n" "SupportList:\r\n"
@ -1664,13 +1698,13 @@ static void set_source_date_epoch() {
char *env = getenv("SOURCE_DATE_EPOCH"); char *env = getenv("SOURCE_DATE_EPOCH");
char *endptr = env; char *endptr = env;
errno = 0; errno = 0;
if (env && *env) { if (env && *env) {
source_date_epoch = strtoull(env, &endptr, 10); source_date_epoch = strtoull(env, &endptr, 10);
if (errno || (endptr && *endptr != '\0')) { if (errno || (endptr && *endptr != '\0')) {
fprintf(stderr, "Invalid SOURCE_DATE_EPOCH"); fprintf(stderr, "Invalid SOURCE_DATE_EPOCH");
exit(1); exit(1);
} }
} }
} }
/** Generates the partition-table partition */ /** Generates the partition-table partition */
@ -2069,6 +2103,9 @@ static void build_image(const char *output,
} else if (strcasecmp(info->id, "ARCHER-C6-V2") == 0) { } else if (strcasecmp(info->id, "ARCHER-C6-V2") == 0) {
const char mdat[11] = {0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00}; const char mdat[11] = {0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00};
parts[5] = put_data("extra-para", mdat, 11); parts[5] = put_data("extra-para", mdat, 11);
} else if (strcasecmp(info->id, "ARCHER-C6-V2-US") == 0) {
const char mdat[11] = {0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x00};
parts[5] = put_data("extra-para", mdat, 11);
} }
size_t len; size_t len;