Add support for TL-WR1043N/ND v2

This commit is contained in:
Matthias Schiffer 2014-08-07 14:47:16 +02:00
parent e164bac87a
commit e53f3102a7
2 changed files with 34 additions and 1 deletions

View File

@ -0,0 +1,32 @@
From: Matthias Schiffer <mschiffer@universe-factory.net>
Date: Thu, 7 Aug 2014 15:07:15 +0200
Subject: ar71xx: TL-WR1043N/ND v2: Fix MAC address of WMAC
This sets the MAC address of the WLAN interface to the "official" primary MAC
address (the one on the label under the devices, and the one used with the stock
firmware). The MAC address used so far (primary-1) isn't even used at all with
the stock firmware, which sets (primary) on LAN and WLAN and (primary+1) on the
WAN interface (like OpenWrt does with this patch).
diff --git a/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wr1043nd-v2.c b/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wr1043nd-v2.c
index 4f873e2..3e79ee1 100644
--- a/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wr1043nd-v2.c
+++ b/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wr1043nd-v2.c
@@ -168,7 +168,6 @@ static void __init tl_wr1043nd_v2_setup(void)
{
u8 *mac = (u8 *) KSEG1ADDR(0x1f01fc00);
u8 *art = (u8 *) KSEG1ADDR(0x1fff0000);
- u8 tmpmac[ETH_ALEN];
ath79_register_m25p80(&wr1043nd_v2_flash_data);
@@ -178,8 +177,7 @@ static void __init tl_wr1043nd_v2_setup(void)
ARRAY_SIZE(tl_wr1043_v2_gpio_keys),
tl_wr1043_v2_gpio_keys);
- ath79_init_mac(tmpmac, mac, -1);
- ath79_register_wmac(art + TL_WR1043_V2_WMAC_CALDATA_OFFSET, tmpmac);
+ ath79_register_wmac(art + TL_WR1043_V2_WMAC_CALDATA_OFFSET, mac);
mdiobus_register_board_info(wr1043nd_v2_mdio0_info,
ARRAY_SIZE(wr1043nd_v2_mdio0_info));

View File

@ -39,9 +39,10 @@ $(eval $(call GluonModel,TLWR941,tl-wr941nd-v2-squashfs,tp-link-tl-wr941n-nd-v2)
$(eval $(call GluonModel,TLWR941,tl-wr941nd-v3-squashfs,tp-link-tl-wr941n-nd-v3))
$(eval $(call GluonModel,TLWR941,tl-wr941nd-v4-squashfs,tp-link-tl-wr941n-nd-v4))
# TL-WR1043N/ND v1
# TL-WR1043N/ND v1, v2
$(eval $(call GluonProfile,TLWR1043))
$(eval $(call GluonModel,TLWR1043,tl-wr1043nd-v1-squashfs,tp-link-tl-wr1043n-nd-v1))
$(eval $(call GluonModel,TLWR1043,tl-wr1043nd-v2-squashfs,tp-link-tl-wr1043n-nd-v2))
# TL-WDR3500/3600/4300 v1
$(eval $(call GluonProfile,TLWDR4300))