Adding OpenWrt support for Archer A6 v3

Since I can easily replicate the problem, is there a place I can look for any error?

I am checking logread and dmesg, and no error is shown when the radio stops. I've also tried to increase hostapd log level to "debug" and still no error is shown. The radio just stops, and I have to reboot the router to restore it. But the issue only happens when two or more wifi clients are transferring lots of data simultaneously.

BTW, another issue (minor for me). I noticed that if I change SSID without rebooting, for some reason the clients can see and initially connect to the new SSID, but they are unable to communicate. A reboot is also needed to solve this problem.

To me it all seems related to the Wifi driver. I understand from @Borromini 's comment above that we should get mt76 "gold" drivers at some point in time. Hopefully this would help with these issues.

I was referring to 21.02 getting its release, at which point I intend to offer mt76 packages with the hack included.

1 Like

I got a c6 v3.2 and with this bug, mesh is useless. However, I am able to use my clients without too many problems with this snapshot: r17245-ac4e8aa2f8 ... and I programmed a daily auto-reboot at 4AM which seems to make it last for almost a day without issues. I am using that router with sometimes around 6 5GHz clients on a link ~200Mbps.
I have another router that has connectivity issues and built this crappy python script executed on it via a cronjob every 2 minutes:

import os
import datetime
import subprocess

MAX_LATENCY = 10
PING_COUNT = 3
SERVER_IP = '192.168.10.1'
RESTART_CMD = 'killall -HUP wpa_supplicant && sleep 5 && wifi up'

def ping(server='example.com', count=1, wait_sec=1):
    """

    :rtype: dict or None
    """
    cmd = "ping -c {} -W {} {}".format(count, wait_sec, server).split(' ')
    try:
        output = subprocess.check_output(cmd).decode().strip()
        lines = output.split("\n")
        loss = lines[-2].split(',')[2].split()[0]
        timing = lines[-1].split()[3].split('/')
        return {
            'type': 'rtt',
            'min': timing[0],
            'avg': timing[1],
            'max': timing[2],
            'loss': loss,
        }
    except Exception as e:
        print(e)
        return None

if __name__ == '__main__':
    print(datetime.datetime.now(), 'connection check')
    ping_result = ping(server=SERVER_IP, count=PING_COUNT)
    if not (ping_result and float(ping_result['avg']) < MAX_LATENCY):
        print(f'ping average is worse than {MAX_LATENCY} ({ping_result})')
        os.system(RESTART_CMD)
    else:
        print(f'connection stable: {ping_result} ')
root@openwrt-c6v2:~#

A watchdog :slightly_smiling_face:

I am fine building my own firmware. Is the patch I need to apply this one? If so, is there an example Makefile for the corresponding package you can share with me so I ca build it?

Nope. This is a ready made patch that you can apply to your OpenWrt git tree. Then recompile the mt76 package.

@Borromini - I patched the latest HEAD but got build errors. Any thoughts?

build log
% make -j1 V=s package/kernel/mt76/compile
WARNING: Makefile 'package/utils/busybox/Makefile' has a dependency on 'libpam', which does not exist
WARNING: Makefile 'package/utils/busybox/Makefile' has a dependency on 'libpam', which does not exist
WARNING: Makefile 'package/utils/busybox/Makefile' has a build dependency on 'libpam', which does not exist
WARNING: Makefile 'package/boot/kexec-tools/Makefile' has a dependency on 'liblzma', which does not exist
WARNING: Makefile 'package/network/services/lldpd/Makefile' has a dependency on 'libnetsnmp', which does not exist
WARNING: Makefile 'package/utils/policycoreutils/Makefile' has a dependency on 'libpam', which does not exist
WARNING: Makefile 'package/utils/policycoreutils/Makefile' has a dependency on 'libpam', which does not exist
WARNING: Makefile 'package/utils/policycoreutils/Makefile' has a build dependency on 'libpam', which does not exist
make[1]: Entering directory '/scratch/union'
cd "/scratch/union"; git log --format=%h -1 toolchain > /scratch/union/tmp/.ver_check
cmp -s /scratch/union/tmp/.ver_check /scratch/union/staging_dir/toolchain-mipsel_24kc_gcc-10.3.0_musl/stamp/.ver_check || { \
	rm -rf /scratch/union/build_dir/target-mipsel_24kc_musl /scratch/union/staging_dir/target-mipsel_24kc_musl /scratch/union/staging_dir/toolchain-mipsel_24kc_gcc-10.3.0_musl /scratch/union/build_dir/toolchain-mipsel_24kc_gcc-10.3.0_musl; \
	mkdir -p /scratch/union/staging_dir/toolchain-mipsel_24kc_gcc-10.3.0_musl/stamp; \
	mv /scratch/union/tmp/.ver_check /scratch/union/staging_dir/toolchain-mipsel_24kc_gcc-10.3.0_musl/stamp/.ver_check; \
}
make[2]: Entering directory '/scratch/union/package/libs/toolchain'
echo "libc" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/toolchain.default.install
echo "libgcc" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/toolchain.default.install
echo "libpthread" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/toolchain.default.install
make[2]: Leaving directory '/scratch/union/package/libs/toolchain'
time: package/libs/toolchain/compile#0.09#0.01#0.09
make[2]: Entering directory '/scratch/union/package/firmware/linux-firmware'
make[2]: Nothing to be done for 'compile'.
make[2]: Leaving directory '/scratch/union/package/firmware/linux-firmware'
time: package/firmware/linux-firmware/compile#0.08#0.02#0.09
make[2]: Entering directory '/scratch/union/package/firmware/prism54-firmware'
make[2]: Nothing to be done for 'compile'.
make[2]: Leaving directory '/scratch/union/package/firmware/prism54-firmware'
time: package/firmware/prism54-firmware/compile#0.10#0.02#0.12
make[2]: Entering directory '/scratch/union/package/kernel/linux'
echo "kernel" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-crypto-aead" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-crypto-ccm" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-crypto-cmac" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-crypto-ctr" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-crypto-gcm" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-crypto-gf128" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-crypto-ghash" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-crypto-hash" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-crypto-hmac" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-crypto-manager" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-crypto-null" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-crypto-rng" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-crypto-seqiv" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-crypto-sha256" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-hwmon-core" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-leds-gpio" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-lib-crc-ccitt" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-nf-reject" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-nf-reject6" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-nf-ipt" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-nf-ipt6" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-ipt-core" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-nf-conntrack" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-nf-conntrack6" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-nf-nat" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-nf-flow" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-ipt-conntrack" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-ipt-offload" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-ipt-nat" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-ip6tables" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-slhc" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-ppp" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-pppox" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
echo "kmod-pppoe" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/linux.default.install
make[2]: Leaving directory '/scratch/union/package/kernel/linux'
time: package/kernel/linux/compile#0.92#0.03#0.95
make[2]: Entering directory '/scratch/union/package/firmware/b43legacy-firmware'
make[2]: Nothing to be done for 'compile'.
make[2]: Leaving directory '/scratch/union/package/firmware/b43legacy-firmware'
time: package/firmware/b43legacy-firmware/compile#0.06#0.01#0.07
make[2]: Entering directory '/scratch/union/package/firmware/wireless-regdb'
mkdir -p /scratch/union/dl
SHELL= flock /scratch/union/tmp/.wireless-regdb-2021.04.21.tar.xz.flock -c '  	/scratch/union/scripts/download.pl "/scratch/union/dl" "wireless-regdb-2021.04.21.tar.xz" "9e4c02b2a9710df4dbdb327c39612e8cbbae6495987afeddaebab28c1ea3d8fa" "" "@KERNEL/software/network/wireless-regdb/"    '
echo "wireless-regdb" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/wireless-regdb.default.install
make[2]: Leaving directory '/scratch/union/package/firmware/wireless-regdb'
time: package/firmware/wireless-regdb/compile#0.09#0.01#0.10
make[2]: Entering directory '/scratch/union/package/libs/openssl'
mkdir -p /scratch/union/dl
SHELL= flock /scratch/union/tmp/.openssl-1.1.1l.tar.gz.flock -c '  	/scratch/union/scripts/download.pl "/scratch/union/dl" "openssl-1.1.1l.tar.gz" "0b7a3e5e59c34827fe0c3a74b7ec8baef302b98fa80088d7f9153aa16fa76bd1" "" "http://www.openssl.org/source/" "http://www.openssl.org/source/old/1.1.1/" "http://ftp.fi.muni.cz/pub/openssl/source/" "http://ftp.fi.muni.cz/pub/openssl/source/old/1.1.1/" "ftp://ftp.pca.dfn.de/pub/tools/net/openssl/source/" "ftp://ftp.pca.dfn.de/pub/tools/net/openssl/source/old/1.1.1/"    '
make[2]: Leaving directory '/scratch/union/package/libs/openssl'
time: package/libs/openssl/compile#0.11#0.03#0.13
make[2]: Entering directory '/scratch/union/package/libs/gettext'
make[2]: Leaving directory '/scratch/union/package/libs/gettext'
time: package/libs/gettext/compile#0.13#0.02#0.14
make[2]: Entering directory '/scratch/union/package/libs/libiconv'
make[2]: Leaving directory '/scratch/union/package/libs/libiconv'
time: package/libs/libiconv/compile#0.14#0.01#0.14
make[2]: Entering directory '/scratch/union/package/libs/libtool'
mkdir -p /scratch/union/dl
SHELL= flock /scratch/union/tmp/.libtool-2.4.6.tar.xz.flock -c '  	/scratch/union/scripts/download.pl "/scratch/union/dl" "libtool-2.4.6.tar.xz" "7c87a8c2c8c0fc9cd5019e402bed4292462d00a718a7cd5f11218153bf28b26f" "" "@GNU/libtool"    '
make[2]: Leaving directory '/scratch/union/package/libs/libtool'
time: package/libs/libtool/compile#0.11#0.02#0.13
make[2]: Entering directory '/scratch/union/package/libs/wolfssl'
mkdir -p /scratch/union/dl
SHELL= flock /scratch/union/tmp/.wolfssl-4.7.0-stable.tar.gz.flock -c '  	/scratch/union/scripts/download.pl "/scratch/union/dl" "wolfssl-4.7.0-stable.tar.gz" "b0e740b31d4d877d540ad50cc539a8873fc41af02bd3091c4357b403f7106e31" "" "https://github.com/wolfSSL/wolfssl/archive/v4.7.0-stable"    '
echo "libwolfssl" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/wolfssl.default.install
make[2]: Leaving directory '/scratch/union/package/libs/wolfssl'
time: package/libs/wolfssl/compile#0.12#0.02#0.13
make[2]: Entering directory '/scratch/union/package/libs/libjson-c'
mkdir -p /scratch/union/dl
SHELL= flock /scratch/union/tmp/.json-c-0.15-nodoc.tar.gz.flock -c '  	/scratch/union/scripts/download.pl "/scratch/union/dl" "json-c-0.15-nodoc.tar.gz" "99bca4f944b8ced8ae0bbc6310d6a3528ca715e69541793a1ef51f8c5b4b0878" "" "https://s3.amazonaws.com/json-c_releases/releases/"    '
echo "libjson-c" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/libjson-c.default.install
make[2]: Leaving directory '/scratch/union/package/libs/libjson-c'
time: package/libs/libjson-c/compile#0.10#0.02#0.11
make[2]: Entering directory '/scratch/union/package/utils/lua'
mkdir -p /scratch/union/dl
SHELL= flock /scratch/union/tmp/.lua-5.1.5.tar.gz.flock -c '  	/scratch/union/scripts/download.pl "/scratch/union/dl" "lua-5.1.5.tar.gz" "2640fc56a795f29d28ef15e13c34a47e223960b0240e8cb0a82d9b0738695333" "" "http://www.lua.org/ftp/" "http://www.tecgraf.puc-rio.br/lua/ftp/"    '
make[2]: Leaving directory '/scratch/union/package/utils/lua'
time: package/utils/lua/compile#0.11#0.02#0.12
make[2]: Entering directory '/scratch/union/package/libs/libubox'
mkdir -p /scratch/union/dl
SHELL= flock /scratch/union/tmp/.libubox-2021-08-19-d716ac4b.tar.xz.flock -c '  	/scratch/union/scripts/download.pl "/scratch/union/dl" "libubox-2021-08-19-d716ac4b.tar.xz" "1cdb91ac0ee925f133ee9f70eac131a99def312fe7cf0aed44df84eb1762e30b" "" || (  	echo "Checking out files from the git repository..."; mkdir -p /scratch/union/tmp/dl && cd /scratch/union/tmp/dl && rm -rf libubox-2021-08-19-d716ac4b && [ \! -d libubox-2021-08-19-d716ac4b ] && git clone  https://git.openwrt.org/project/libubox.git libubox-2021-08-19-d716ac4b && (cd libubox-2021-08-19-d716ac4b && git checkout d716ac4bc4236031d4c3cc1ed362b502e20e3787 && git submodule update --init --recursive) && echo "Packing checkout..." && export TAR_TIMESTAMP=`cd libubox-2021-08-19-d716ac4b && git log -1 --format='\''@%ct'\''` && rm -rf libubox-2021-08-19-d716ac4b/.git && 	tar --numeric-owner --owner=0 --group=0 --mode=a-s --sort=name ${TAR_TIMESTAMP:+--mtime="$TAR_TIMESTAMP"} -c libubox-2021-08-19-d716ac4b | 	xz -zc -7e > /scratch/union/tmp/dl/libubox-2021-08-19-d716ac4b.tar.xz && mv /scratch/union/tmp/dl/libubox-2021-08-19-d716ac4b.tar.xz /scratch/union/dl/ && rm -rf libubox-2021-08-19-d716ac4b;  )    '
echo "libubox" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/libubox.default.install
echo "libblobmsg-json" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/libubox.default.install
echo "jshn" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/libubox.default.install
echo "libjson-script" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/libubox.default.install
make[2]: Leaving directory '/scratch/union/package/libs/libubox'
time: package/libs/libubox/compile#0.11#0.02#0.12
make[2]: Entering directory '/scratch/union/package/system/ubus'
mkdir -p /scratch/union/dl
SHELL= flock /scratch/union/tmp/.ubus-2021-06-30-4fc532c8.tar.xz.flock -c '  	/scratch/union/scripts/download.pl "/scratch/union/dl" "ubus-2021-06-30-4fc532c8.tar.xz" "a5c8205f2e2b2f1f9ad687592e66a6e2bf8900dc54cfe3ceefe6c297d18971a8" "" || (  	echo "Checking out files from the git repository..."; mkdir -p /scratch/union/tmp/dl && cd /scratch/union/tmp/dl && rm -rf ubus-2021-06-30-4fc532c8 && [ \! -d ubus-2021-06-30-4fc532c8 ] && git clone  https://git.openwrt.org/project/ubus.git ubus-2021-06-30-4fc532c8 && (cd ubus-2021-06-30-4fc532c8 && git checkout 4fc532c8a55ba8217ad67d7fd47c5eb9a8aba044 && git submodule update --init --recursive) && echo "Packing checkout..." && export TAR_TIMESTAMP=`cd ubus-2021-06-30-4fc532c8 && git log -1 --format='\''@%ct'\''` && rm -rf ubus-2021-06-30-4fc532c8/.git && 	tar --numeric-owner --owner=0 --group=0 --mode=a-s --sort=name ${TAR_TIMESTAMP:+--mtime="$TAR_TIMESTAMP"} -c ubus-2021-06-30-4fc532c8 | 	xz -zc -7e > /scratch/union/tmp/dl/ubus-2021-06-30-4fc532c8.tar.xz && mv /scratch/union/tmp/dl/ubus-2021-06-30-4fc532c8.tar.xz /scratch/union/dl/ && rm -rf ubus-2021-06-30-4fc532c8;  )    '
echo "libubus" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/ubus.default.install
echo "ubus" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/ubus.default.install
echo "ubusd" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/ubus.default.install
make[2]: Leaving directory '/scratch/union/package/system/ubus'
time: package/system/ubus/compile#0.10#0.01#0.11
make[2]: Entering directory '/scratch/union/package/libs/libnl-tiny'
mkdir -p /scratch/union/dl
SHELL= flock /scratch/union/tmp/.libnl-tiny-2020-08-05-c291088f.tar.xz.flock -c '  	/scratch/union/scripts/download.pl "/scratch/union/dl" "libnl-tiny-2020-08-05-c291088f.tar.xz" "99bcce12701bb34dadb39689d95c2c5cf1e27719d0ecfd645d3957a8947025ac" "" || (  	echo "Checking out files from the git repository..."; mkdir -p /scratch/union/tmp/dl && cd /scratch/union/tmp/dl && rm -rf libnl-tiny-2020-08-05-c291088f && [ \! -d libnl-tiny-2020-08-05-c291088f ] && git clone  https://git.openwrt.org/project/libnl-tiny.git libnl-tiny-2020-08-05-c291088f && (cd libnl-tiny-2020-08-05-c291088f && git checkout c291088f631d1694f7ba0444b59677b194348da8 && git submodule update --init --recursive) && echo "Packing checkout..." && export TAR_TIMESTAMP=`cd libnl-tiny-2020-08-05-c291088f && git log -1 --format='\''@%ct'\''` && rm -rf libnl-tiny-2020-08-05-c291088f/.git && 	tar --numeric-owner --owner=0 --group=0 --mode=a-s --sort=name ${TAR_TIMESTAMP:+--mtime="$TAR_TIMESTAMP"} -c libnl-tiny-2020-08-05-c291088f | 	xz -zc -7e > /scratch/union/tmp/dl/libnl-tiny-2020-08-05-c291088f.tar.xz && mv /scratch/union/tmp/dl/libnl-tiny-2020-08-05-c291088f.tar.xz /scratch/union/dl/ && rm -rf libnl-tiny-2020-08-05-c291088f;  )    '
echo "libnl-tiny" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/libnl-tiny.default.install
make[2]: Leaving directory '/scratch/union/package/libs/libnl-tiny'
time: package/libs/libnl-tiny/compile#0.09#0.02#0.10
make[2]: Entering directory '/scratch/union/package/network/services/hostapd'
mkdir -p /scratch/union/dl
SHELL= flock /scratch/union/tmp/.hostapd-2021-05-22-b102f19b.tar.xz.flock -c '  	/scratch/union/scripts/download.pl "/scratch/union/dl" "hostapd-2021-05-22-b102f19b.tar.xz" "cb3cb968883042fc582752be1607586696c18e6ecf9808c9a8ac50e204584367" "" || (  	echo "Checking out files from the git repository..."; mkdir -p /scratch/union/tmp/dl && cd /scratch/union/tmp/dl && rm -rf hostapd-2021-05-22-b102f19b && [ \! -d hostapd-2021-05-22-b102f19b ] && git clone  http://w1.fi/hostap.git hostapd-2021-05-22-b102f19b && (cd hostapd-2021-05-22-b102f19b && git checkout b102f19bcc53c7f7db3951424d4d46709b4f1986 && git submodule update --init --recursive) && echo "Packing checkout..." && export TAR_TIMESTAMP=`cd hostapd-2021-05-22-b102f19b && git log -1 --format='\''@%ct'\''` && rm -rf hostapd-2021-05-22-b102f19b/.git && 	tar --numeric-owner --owner=0 --group=0 --mode=a-s --sort=name ${TAR_TIMESTAMP:+--mtime="$TAR_TIMESTAMP"} -c hostapd-2021-05-22-b102f19b | 	xz -zc -7e > /scratch/union/tmp/dl/hostapd-2021-05-22-b102f19b.tar.xz && mv /scratch/union/tmp/dl/hostapd-2021-05-22-b102f19b.tar.xz /scratch/union/dl/ && rm -rf hostapd-2021-05-22-b102f19b;  )    '
echo "wpad-basic-wolfssl" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/hostapd.wpad-basic-wolfssl.install
echo "hostapd-common" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/hostapd.wpad-basic-wolfssl.install
make[2]: Leaving directory '/scratch/union/package/network/services/hostapd'
time: package/network/services/hostapd/wpad-basic-wolfssl/compile#0.19#0.05#0.23
make[2]: Entering directory '/scratch/union/package/system/uci'
mkdir -p /scratch/union/dl
SHELL= flock /scratch/union/tmp/.uci-2021-04-14-4b3db117.tar.xz.flock -c '  	/scratch/union/scripts/download.pl "/scratch/union/dl" "uci-2021-04-14-4b3db117.tar.xz" "9d00b5056a0dd4094c7e19f1a0ecaffa90409f22ea28f164d0e36febd06e37d1" "" || (  	echo "Checking out files from the git repository..."; mkdir -p /scratch/union/tmp/dl && cd /scratch/union/tmp/dl && rm -rf uci-2021-04-14-4b3db117 && [ \! -d uci-2021-04-14-4b3db117 ] && git clone  https://git.openwrt.org/project/uci.git uci-2021-04-14-4b3db117 && (cd uci-2021-04-14-4b3db117 && git checkout 4b3db1179747b6a6779029407984bacef851325c && git submodule update --init --recursive) && echo "Packing checkout..." && export TAR_TIMESTAMP=`cd uci-2021-04-14-4b3db117 && git log -1 --format='\''@%ct'\''` && rm -rf uci-2021-04-14-4b3db117/.git && 	tar --numeric-owner --owner=0 --group=0 --mode=a-s --sort=name ${TAR_TIMESTAMP:+--mtime="$TAR_TIMESTAMP"} -c uci-2021-04-14-4b3db117 | 	xz -zc -7e > /scratch/union/tmp/dl/uci-2021-04-14-4b3db117.tar.xz && mv /scratch/union/tmp/dl/uci-2021-04-14-4b3db117.tar.xz /scratch/union/dl/ && rm -rf uci-2021-04-14-4b3db117;  )    '
echo "libuci" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/uci.default.install
echo "uci" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/uci.default.install
make[2]: Leaving directory '/scratch/union/package/system/uci'
time: package/system/uci/compile#0.10#0.01#0.10
make[2]: Entering directory '/scratch/union/package/network/utils/iwinfo'
mkdir -p /scratch/union/dl
SHELL= flock /scratch/union/tmp/.libiwinfo-2021-07-11-a0a0e02d.tar.xz.flock -c '  	/scratch/union/scripts/download.pl "/scratch/union/dl" "libiwinfo-2021-07-11-a0a0e02d.tar.xz" "7b4f745c2cace836e57bd116399973d9ac32cee7f98d4628a17395caa3d0cebc" "" || (  	echo "Checking out files from the git repository..."; mkdir -p /scratch/union/tmp/dl && cd /scratch/union/tmp/dl && rm -rf libiwinfo-2021-07-11-a0a0e02d && [ \! -d libiwinfo-2021-07-11-a0a0e02d ] && git clone  https://git.openwrt.org/project/iwinfo.git libiwinfo-2021-07-11-a0a0e02d && (cd libiwinfo-2021-07-11-a0a0e02d && git checkout a0a0e02dd91d14a50155390d5fd3b95d6ec87bf4 && git submodule update --init --recursive) && echo "Packing checkout..." && export TAR_TIMESTAMP=`cd libiwinfo-2021-07-11-a0a0e02d && git log -1 --format='\''@%ct'\''` && rm -rf libiwinfo-2021-07-11-a0a0e02d/.git && 	tar --numeric-owner --owner=0 --group=0 --mode=a-s --sort=name ${TAR_TIMESTAMP:+--mtime="$TAR_TIMESTAMP"} -c libiwinfo-2021-07-11-a0a0e02d | 	xz -zc -7e > /scratch/union/tmp/dl/libiwinfo-2021-07-11-a0a0e02d.tar.xz && mv /scratch/union/tmp/dl/libiwinfo-2021-07-11-a0a0e02d.tar.xz /scratch/union/dl/ && rm -rf libiwinfo-2021-07-11-a0a0e02d;  )    '
echo "libiwinfo" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/iwinfo.default.install
echo "libiwinfo-data" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/iwinfo.default.install
echo "iwinfo" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/iwinfo.default.install
make[2]: Leaving directory '/scratch/union/package/network/utils/iwinfo'
time: package/network/utils/iwinfo/compile#0.09#0.02#0.10
make[2]: Entering directory '/scratch/union/package/network/utils/iw'
mkdir -p /scratch/union/dl
SHELL= flock /scratch/union/tmp/.iw-5.9-8fab0c9e.tar.xz.flock -c '  	/scratch/union/scripts/download.pl "/scratch/union/dl" "iw-5.9-8fab0c9e.tar.xz" "797b322bc03952f3127ae0a7da476c14ada1bbe9a9ae234a56dd6f864c568e16" "" || (  	echo "Checking out files from the git repository..."; mkdir -p /scratch/union/tmp/dl && cd /scratch/union/tmp/dl && rm -rf iw-5.9-8fab0c9e && [ \! -d iw-5.9-8fab0c9e ] && git clone  https://git.kernel.org/pub/scm/linux/kernel/git/jberg/iw.git iw-5.9-8fab0c9e && (cd iw-5.9-8fab0c9e && git checkout 8fab0c9ee9db217587a58efcc37421c86edcb638 && git submodule update --init --recursive) && echo "Packing checkout..." && export TAR_TIMESTAMP=`cd iw-5.9-8fab0c9e && git log -1 --format='\''@%ct'\''` && rm -rf iw-5.9-8fab0c9e/.git && 	tar --numeric-owner --owner=0 --group=0 --mode=a-s --sort=name ${TAR_TIMESTAMP:+--mtime="$TAR_TIMESTAMP"} -c iw-5.9-8fab0c9e | 	xz -zc -7e > /scratch/union/tmp/dl/iw-5.9-8fab0c9e.tar.xz && mv /scratch/union/tmp/dl/iw-5.9-8fab0c9e.tar.xz /scratch/union/dl/ && rm -rf iw-5.9-8fab0c9e;  )    '
echo "iw" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/iw.tiny.install
make[2]: Leaving directory '/scratch/union/package/network/utils/iw'
time: package/network/utils/iw/tiny/compile#0.11#0.02#0.13
make[2]: Entering directory '/scratch/union/package/kernel/mac80211'
mkdir -p /scratch/union/dl
SHELL= flock /scratch/union/tmp/.backports-5.10.42-1.tar.xz.flock -c '  	/scratch/union/scripts/download.pl "/scratch/union/dl" "backports-5.10.42-1.tar.xz" "6876520105240844fdb32d1dcdf2bfdea291a37a96f16c892fda3776ba714fcb" "" "@KERNEL/linux/kernel/projects/backports/stable/v5.10.42/"    '
echo "kmod-cfg80211" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/mac80211.default.install
echo "kmod-mac80211" >> /scratch/union/staging_dir/target-mipsel_24kc_musl/pkginfo/mac80211.default.install
make[2]: Leaving directory '/scratch/union/package/kernel/mac80211'
time: package/kernel/mac80211/compile#0.21#0.06#0.25
make[2]: Entering directory '/scratch/union/package/kernel/mt76'
mkdir -p /scratch/union/dl
SHELL= flock /scratch/union/tmp/.mt76-2021-07-15-bbebea7d.tar.xz.flock -c '  	/scratch/union/scripts/download.pl "/scratch/union/dl" "mt76-2021-07-15-bbebea7d.tar.xz" "17cd74e72c1f6c8742b698bf6772afacc6fba71b233af8c4d59530600cf44d5b" "" || (  /scratch/union/scripts/dl_github_archive.py --dl-dir="/scratch/union/dl" --url="https://github.com/openwrt/mt76" --version="bbebea7d6dc64313132226adc3f7369d36e9359d" --subdir="mt76-2021-07-15-bbebea7d" --source="mt76-2021-07-15-bbebea7d.tar.xz" --hash="17cd74e72c1f6c8742b698bf6772afacc6fba71b233af8c4d59530600cf44d5b" || ( 	echo "Checking out files from the git repository..."; mkdir -p /scratch/union/tmp/dl && cd /scratch/union/tmp/dl && rm -rf mt76-2021-07-15-bbebea7d && [ \! -d mt76-2021-07-15-bbebea7d ] && git clone  https://github.com/openwrt/mt76 mt76-2021-07-15-bbebea7d && (cd mt76-2021-07-15-bbebea7d && git checkout bbebea7d6dc64313132226adc3f7369d36e9359d && git submodule update --init --recursive) && echo "Packing checkout..." && export TAR_TIMESTAMP=`cd mt76-2021-07-15-bbebea7d && git log -1 --format='\''@%ct'\''` && rm -rf mt76-2021-07-15-bbebea7d/.git && 	tar --numeric-owner --owner=0 --group=0 --mode=a-s --sort=name ${TAR_TIMESTAMP:+--mtime="$TAR_TIMESTAMP"} -c mt76-2021-07-15-bbebea7d | 	xz -zc -7e > /scratch/union/tmp/dl/mt76-2021-07-15-bbebea7d.tar.xz && mv /scratch/union/tmp/dl/mt76-2021-07-15-bbebea7d.tar.xz /scratch/union/dl/ && rm -rf mt76-2021-07-15-bbebea7d; );  )    '
rm -f /scratch/union/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/mt76-2021-07-15-bbebea7d/.built
touch /scratch/union/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/mt76-2021-07-15-bbebea7d/.built_check
make  -C "/scratch/union/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/linux-5.4.143" KCFLAGS="-fmacro-prefix-map=/scratch/union/build_dir/target-mipsel_24kc_musl=target-mipsel_24kc_musl" HOSTCFLAGS="-O2 -I/scratch/union/staging_dir/host/include -I/scratch/union/staging_dir/hostpkg/include -I/scratch/union/staging_dir/target-mipsel_24kc_musl/host/include -Wall -Wmissing-prototypes -Wstrict-prototypes" CROSS_COMPILE="mipsel-openwrt-linux-musl-" ARCH="mips" KBUILD_HAVE_NLS=no KBUILD_BUILD_USER="" KBUILD_BUILD_HOST="" KBUILD_BUILD_TIMESTAMP="Sun Sep  5 09:25:35 2021" KBUILD_BUILD_VERSION="0" HOST_LOADLIBES="-L/scratch/union/staging_dir/host/lib" KBUILD_HOSTLDLIBS="-L/scratch/union/staging_dir/host/lib" CONFIG_SHELL="bash" V=''  cmd_syscalls= KBUILD_EXTRA_SYMBOLS="/scratch/union/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/symvers/gpio-button-hotplug.symvers /scratch/union/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/symvers/mac80211.symvers" KERNELRELEASE=5.4.143 CONFIG_MT7603E=m CONFIG_MT76_CONNAC_LIB=m CONFIG_MT7615_COMMON=m CONFIG_MT7615E=m M="/scratch/union/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/mt76-2021-07-15-bbebea7d" NOSTDINC_FLAGS="-nostdinc  -isystem /scratch/union/staging_dir/toolchain-mipsel_24kc_gcc-10.3.0_musl/lib/gcc/mipsel-openwrt-linux-musl/10.3.0/include -I/scratch/union/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/mt76-2021-07-15-bbebea7d -I/scratch/union/staging_dir/target-mipsel_24kc_musl/usr/include/mac80211-backport/uapi -I/scratch/union/staging_dir/target-mipsel_24kc_musl/usr/include/mac80211-backport -I/scratch/union/staging_dir/target-mipsel_24kc_musl/usr/include/mac80211/uapi -I/scratch/union/staging_dir/target-mipsel_24kc_musl/usr/include/mac80211 -include backport/autoconf.h -include backport/backport.h -DCONFIG_MAC80211_MESH" modules
make[3]: Entering directory '/scratch/union/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/linux-5.4.143'
  CC [M]  /scratch/union/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/mt76-2021-07-15-bbebea7d/mt7615/mcu.o
/scratch/union/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/mt76-2021-07-15-bbebea7d/mt7615/mcu.c:1160:1: error: conflicting types for '__mt7615_mcu_add_sta'
 1160 | __mt7615_mcu_add_sta(struct mt76_phy *phy, struct ieee80211_vif *vif,
      | ^~~~~~~~~~~~~~~~~~~~
/scratch/union/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/mt76-2021-07-15-bbebea7d/mt7615/mcu.c:710:1: note: previous declaration of '__mt7615_mcu_add_sta' was here
  710 | __mt7615_mcu_add_sta(struct mt76_phy *phy, struct ieee80211_vif *vif,
      | ^~~~~~~~~~~~~~~~~~~~
/scratch/union/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/mt76-2021-07-15-bbebea7d/mt7615/mcu.c: In function 'mt7615_mcu_add_sta':
/scratch/union/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/mt76-2021-07-15-bbebea7d/mt7615/mcu.c:1184:3: error: too few arguments to function '__mt7615_mcu_add_sta'
 1184 |   __mt7615_mcu_add_sta(phy->mt76, vif, sta, enable, MCU_EXT_CMD_STA_REC_UPDATE);
      |   ^~~~~~~~~~~~~~~~~~~~
/scratch/union/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/mt76-2021-07-15-bbebea7d/mt7615/mcu.c:1160:1: note: declared here
 1160 | __mt7615_mcu_add_sta(struct mt76_phy *phy, struct ieee80211_vif *vif,
      | ^~~~~~~~~~~~~~~~~~~~
/scratch/union/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/mt76-2021-07-15-bbebea7d/mt7615/mcu.c:1185:3: error: too few arguments to function '__mt7615_mcu_add_sta'
 1185 |   __mt7615_mcu_add_sta(phy->mt76, vif, NULL, false, MCU_EXT_CMD_STA_REC_UPDATE);
      |   ^~~~~~~~~~~~~~~~~~~~
/scratch/union/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/mt76-2021-07-15-bbebea7d/mt7615/mcu.c:1160:1: note: declared here
 1160 | __mt7615_mcu_add_sta(struct mt76_phy *phy, struct ieee80211_vif *vif,
      | ^~~~~~~~~~~~~~~~~~~~
/scratch/union/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/mt76-2021-07-15-bbebea7d/mt7615/mcu.c:1186:3: error: too few arguments to function '__mt7615_mcu_add_sta'
 1186 |   __mt7615_mcu_add_sta(phy->mt76, vif, NULL, true, MCU_EXT_CMD_STA_REC_UPDATE);
      |   ^~~~~~~~~~~~~~~~~~~~
/scratch/union/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/mt76-2021-07-15-bbebea7d/mt7615/mcu.c:1160:1: note: declared here
 1160 | __mt7615_mcu_add_sta(struct mt76_phy *phy, struct ieee80211_vif *vif,
      | ^~~~~~~~~~~~~~~~~~~~
/scratch/union/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/mt76-2021-07-15-bbebea7d/mt7615/mcu.c: At top level:
/scratch/union/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/mt76-2021-07-15-bbebea7d/mt7615/mcu.c:710:1: warning: '__mt7615_mcu_add_sta' used but never defined
  710 | __mt7615_mcu_add_sta(struct mt76_phy *phy, struct ieee80211_vif *vif,
      | ^~~~~~~~~~~~~~~~~~~~
make[5]: *** [scripts/Makefile.build:262: /scratch/union/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/mt76-2021-07-15-bbebea7d/mt7615/mcu.o] Error 1
make[4]: *** [scripts/Makefile.build:497: /scratch/union/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/mt76-2021-07-15-bbebea7d/mt7615] Error 2
make[3]: *** [Makefile:1734: /scratch/union/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/mt76-2021-07-15-bbebea7d] Error 2
make[3]: Leaving directory '/scratch/union/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/linux-5.4.143'
make[2]: *** [Makefile:427: /scratch/union/build_dir/target-mipsel_24kc_musl/linux-ramips_mt7621/mt76-2021-07-15-bbebea7d/.built] Error 2
make[2]: Leaving directory '/scratch/union/package/kernel/mt76'
time: package/kernel/mt76/compile#0.80#0.20#0.93
    ERROR: package/kernel/mt76 failed to build.
make[1]: *** [package/Makefile:116: package/kernel/mt76/compile] Error 1
make[1]: Leaving directory '/scratch/union'
make: *** [/scratch/union/include/toplevel.mk:230: package/kernel/mt76/compile] Error 2

@darksky Is that on master? Mt76 might have seen changes that break the patch. Might be better to ping ptpt52 in the bug report he opened, see his post with the hack.

Yes, it's on master. Interestingly, I just reverted the patch and found that I could not build it. Are you able to build the latest commit from master?

@Borromini - It seems that patch is applied by default to the 21.02.1 image, but running that, I still trigger the bug.

It's not, otherwise my build would break when applying that patch. Just check the git tree:

I'll try a master build when I have the time, at least the patch still applies cleanly to master (checked with a make prepare).

git checkout v21.02.0 after I updated the feeds showed the patch is present. I built 21.02.0 with the patch applied but still have the bug. I built it with the kmod-mt76 enabled "MediaTek MT76x2/MT7603 wireless driver (metapackage)" ... is that right?

What does git status show? I bet that patch shows as an unmanaged file. Which means it's not part of the tree.

It was my mistake... I tried previously to copy a version of it over. It is not an officially unstaged file :smiley:

To me the key point is that when I do apply it to 21.02.1, it doesn't fix the bug.

I purchased this router and my stock tp link firmware is currently 1.0.5 , there is an update available ( firmware 1.0.10 ) from tp link. So should I update tp link firmware before flashing with openwrt or is it ok to flash on the stock firmware?

New firmware might have new checks, so don't upgrade vendor firmware before flashing OpenWrt.

This topic was intended for adding support for this specific device.
Since official 21.02.0 images are available now, I will set a timer for this topic to close.

Why?

Because specific problems for this device with official releases are better handled in separate topics, in order to make finding relevant information easier. Who is going to read the previous 100-something postings, if he has a specific problem with 21.02.0 and wifi?

Therefore: Please open new topics for any open issues with this device.

Thanks! :slight_smile:

3 Likes

This topic has been also used for Archer C6 v3.2 issues (same hardware as the A6 v3) which is not yet included in the official 21.02.0 builds. Anyway I believe there is another topic we can continue the discussions about the C6 v3 if needed. Thanks!

1 Like

I have two TP-Link Archer C6 v3.2 being used as Access Points, both are running a custom build from master (r17470-43f0e386d4 - I just removed a bunch of packages that are not required for access point such as dnsmasq, firewall, ...).

So far they are working OK with some bugs as already discussed in this thread (some instability with 5Ghz radio and reboot required after changing any wi-fi configuration).

Looking at dmesg I've noticed something odd. The size of the "kernel" partition and the start of the "rootfs" partition are different between these two devices (which are exactly the same models).

While they are working fine, I'm wondering what could cause this difference since they are exactly the same model/revision.

The only thing I recall I did different was that for "Device 1" I've upgraded the stock firmware before installing OpenWRT, while on "Device 2" I've installed OpenWRT right out of the box.

Any thoughts?

Archer C6 v3.2 - Device 1:
(...)
[ 0.879165] 4 fixed-partitions partitions found on MTD device spi0.0
[ 0.885486] Creating 4 MTD partitions on "spi0.0":
[ 0.890280] 0x000000000000-0x000000040000 : "u-boot"
[ 0.896688] 0x000000040000-0x000000fa0000 : "firmware"
[ 0.903103] 2 uimage-fw partitions found on MTD device firmware
[ 0.909031] Creating 2 MTD partitions on "firmware":
[ 0.913978] 0x000000000000-0x000000247220 : "kernel"
[ 0.920211] 0x000000247220-0x000000f60000 : "rootfs"
[ 0.926436] mtd: device 3 (rootfs) set to be root filesystem
[ 0.932232] 1 squashfs-split partitions found on MTD device rootfs
[ 0.938633] 0x0000006d0000-0x000000f60000 : "rootfs_data"
[ 0.945307] 0x000000fa0000-0x000000ff0000 : "config"
[ 0.951730] 0x000000ff0000-0x000001000000 : "radio"
(...)

Archer C6 v3.2 - Device 2:

(...)
[ 0.874585] 4 fixed-partitions partitions found on MTD device spi0.0
[ 0.880903] Creating 4 MTD partitions on "spi0.0":
[ 0.885699] 0x000000000000-0x000000040000 : "u-boot"
[ 0.891904] 0x000000040000-0x000000fa0000 : "firmware"
[ 0.898391] 2 uimage-fw partitions found on MTD device firmware
[ 0.904292] Creating 2 MTD partitions on "firmware":
[ 0.909278] 0x000000000000-0x000000250000 : "kernel"
[ 0.915419] 0x000000250000-0x000000f60000 : "rootfs"
[ 0.921480] mtd: device 3 (rootfs) set to be root filesystem
[ 0.927363] 1 squashfs-split partitions found on MTD device rootfs
[ 0.933524] 0x0000006d0000-0x000000f60000 : "rootfs_data"
[ 0.940088] 0x000000fa0000-0x000000ff0000 : "config"
[ 0.946599] 0x000000ff0000-0x000001000000 : "radio"
(...)

AFAIK splitting is dynamic, so it's not abnormal to have differing kernel & rootfs sizes if you're not running the same build on both devices. Are you?

The kernel 'partition' expands to what's needed for it AFAIK (within certain limits) and the remainder is allocated to the rootfs.

2 Likes