Adding OpenWrt support for Xiaomi AX3600 (Part 1)

I managed to bricked my AX3600 (got a bit greedy with adding too many packages to my OpenWRT image, making it too large). I did have a few issues reflashing the AX3600 and pulling all the info on how to do it from loads of different sources, so I thought I'd document the process in a bit more detail and in one place here (if only for me to find again next time I go a bit mad with packages). Sorry this is so long, I try to go into as much detail as possible, and also include my working .config at the end (well the diffconfig of my .config).

RECOVERY:

NOTE: Items in BOLD are not to be typed literally, but are pointers on what you need to type.

  • Connect the serial cable to the router (NOT THE VCC CABLE THOUGH), in putty the setting are Speed: 115200, Data Bits: 8, Stop Bits: 1, Parity: None, Flow Control: None in the Connection -> serial screen. The power for the router will come from it's normal mains cable (you don't need to connect this yet).

  • Create somewhere to place your firmware for the tftp server and download the default xiaomi firmware:
    mkdir /tmp/tftp
    wget http://cdn.cnbj1.fds.api.mi-img.com/xiaoqiang/rom/r3600/miwifi_r3600_firmware_5da25_1.0.17.bin

  • Please note the name of the firmwarefile will probably be wrong, it seems to change with reboots and ip address changes:
    cp miwifi_r3600_firmware_5da25_1.0.17.bin /tmp/tftp/C0A81F0F.img

  • Also copy your compiled version of OpenWRT to the ftp folder:
    cp <location of openwrt-ipq807x-generic-xiaomi_ax3600-squashfs-nand-factory.ubi> /tmp/tftp/factory.ubi

  • Set a static address on your PC to serve the firmware from, here I use eno1 change this to the name of your adapter, also I use an ip address of 192.168.31.100 here as that is what the router expects:
    sudo ip address flush dev <adapter name, such as eno1>
    sudo ip address add 192.168.31.100/24 dev <adapter name, such as eno1>
    sudo dnsmasq --no-daemon --listen-address=192.168.31.100 --bind-interfaces --dhcp-range=192.168.31.1,192.168.31.99 --enable-tftp --tftp-root=/tmp/tftp

  • Then restart the router (unplug and then replug the power cable), with the reset button pushed in until the amber light starts flashing (follow in serial console if you like).

  • If it can't connect after a few goes, use a switch and only have the router and your PC plug in to it, this should stop the problem where Linux doesn't bring the interface up before u-boot just restarts the interface again. Please note, even when working it will still take a few cycles before the firmware starts to upload, again follow this via the serial connection.

  • It will then probably complain saying it can't find the file (it will be subtly different from C0A81F0F.img)

    • If so, press Ctrl+C on dnsmasq and then:
      cp miwifi_r3600_firmware_5da25_1.0.17.bin /tmp/tftp/<name of file it wants>
  • Restart dnsmasq:
    sudo dnsmasq --no-daemon --listen-address=192.168.31.100 --bind-interfaces --dhcp-range=192.168.31.1,192.168.31.99 --enable-tftp --tftp-root=/tmp/tftp

  • It will take a few goes, but eventually it you should start to see loads of hash tags '#' in the serial console

  • Sometimes it will then fail to verify, just try again by power cycling the router with the reset button pressed

  • Once it takes, I found that the serial console stated the Upgrade was successful, but the light still flashed white, just power cycle the router again

  • Either wait for it to finish booting via the serial console and press 'return/enter'when it finishes displaying all the boot messages, or press 'f' when asked to get a shell prompt if you don't want to wait

  • Then transfer the firmware to the router (it's filesystem will be read-only at them moment, so you must be in the tmp folder)
    cd /tmp
    tftp -g -r factory.ubi 192.168.31.100

  • There will be no progress, but in your dnsmasq command terminal window it will say it uploaded successfully

  • Then apply the firmware
    ubiformat /dev/mtd13 -y -f factory.ubi

  • And make sure it will boot from it
    nvram get flag_last_success ##just to see what it was, you don't need to run this if you don't want to
    nvram get flag_boot_rootfs ##just to see what it was, you don't need to run this if you don't want to
    nvram set flag_last_success=1
    nvram set flag_boot_rootfs=1
    nvram commit

  • Finally you are ready to boot into OpenWRT
    reboot

Also, my diffconfig which adds:

  • LuCI
  • Dashboard
  • The new theme
  • DAWN
  • adblock
  • acme
  • bash
  • Monitoring
  • Dynamic DNS
  • OpenVPN
  • WireShark
  • iperf3
  • nano
  • logratae
  • lsof
  • Quality of Service
  • UPNP Setup
  • PPPoE Setup
  • Shell commands via the Web Interface
  • Full versions of some core utils instead of limited busybox ones

Obviously, edit out the features you don't want, and then save it to your .config file:

CONFIG_TARGET_ipq807x=y
CONFIG_TARGET_ipq807x_generic=y
CONFIG_TARGET_ipq807x_generic_DEVICE_xiaomi_ax3600=y
CONFIG_DEVEL=y
CONFIG_OPENSSL_ENGINE=y
CONFIG_OPENSSL_WITH_ASM=y
CONFIG_OPENSSL_WITH_CHACHA_POLY1305=y
CONFIG_OPENSSL_WITH_CMS=y
CONFIG_OPENSSL_WITH_DEPRECATED=y
CONFIG_OPENSSL_WITH_ERROR_MESSAGES=y
CONFIG_OPENSSL_WITH_PSK=y
CONFIG_OPENSSL_WITH_SRP=y
CONFIG_OPENSSL_WITH_TLS13=y
CONFIG_PACKAGE_TAR_BZIP2=y
CONFIG_PACKAGE_TAR_GZIP=y
CONFIG_PACKAGE_TAR_XZ=y
CONFIG_PACKAGE_TAR_ZSTD=y
CONFIG_PACKAGE_acme=y
CONFIG_PACKAGE_adblock=y
CONFIG_PACKAGE_bash=y
CONFIG_PACKAGE_bzip2=y
CONFIG_PACKAGE_cgi-io=y
CONFIG_PACKAGE_collectd=y
CONFIG_PACKAGE_collectd-mod-cpu=y
CONFIG_PACKAGE_collectd-mod-interface=y
CONFIG_PACKAGE_collectd-mod-iwinfo=y
CONFIG_PACKAGE_collectd-mod-load=y
CONFIG_PACKAGE_collectd-mod-memory=y
CONFIG_PACKAGE_collectd-mod-network=y
CONFIG_PACKAGE_collectd-mod-rrdtool=y
CONFIG_PACKAGE_coreutils=y
CONFIG_PACKAGE_coreutils-sort=y
CONFIG_PACKAGE_dawn=y
CONFIG_PACKAGE_ddns-scripts=y
CONFIG_PACKAGE_ddns-scripts-services=y
CONFIG_PACKAGE_etherwake=y
CONFIG_PACKAGE_grep=y
CONFIG_PACKAGE_iperf3=y
CONFIG_PACKAGE_ipset=y
CONFIG_PACKAGE_iptables-mod-conntrack-extra=y
CONFIG_PACKAGE_iptables-mod-extra=y
CONFIG_PACKAGE_iptables-mod-ipopt=y
CONFIG_PACKAGE_iptables-mod-physdev=y
CONFIG_PACKAGE_kmod=y
CONFIG_PACKAGE_kmod-br-netfilter=y
CONFIG_PACKAGE_kmod-crypto-kpp=y
CONFIG_PACKAGE_kmod-crypto-lib-blake2s=y
CONFIG_PACKAGE_kmod-crypto-lib-chacha20=y
CONFIG_PACKAGE_kmod-crypto-lib-chacha20poly1305=y
CONFIG_PACKAGE_kmod-crypto-lib-curve25519=y
CONFIG_PACKAGE_kmod-crypto-lib-poly1305=y
CONFIG_PACKAGE_kmod-ifb=y
CONFIG_PACKAGE_kmod-ipt-conntrack-extra=y
CONFIG_PACKAGE_kmod-ipt-extra=y
CONFIG_PACKAGE_kmod-ipt-ipopt=y
CONFIG_PACKAGE_kmod-ipt-ipset=y
CONFIG_PACKAGE_kmod-ipt-physdev=y
CONFIG_PACKAGE_kmod-ipt-raw=y
CONFIG_PACKAGE_kmod-nf-conntrack-netlink=y
CONFIG_PACKAGE_kmod-nfnetlink=y
CONFIG_PACKAGE_kmod-qca-nss-drv=y
CONFIG_PACKAGE_kmod-qca-nss-drv-pppoe=y
CONFIG_PACKAGE_kmod-qca-nss-ecm=y
CONFIG_PACKAGE_kmod-sched-connmark=y
CONFIG_PACKAGE_kmod-sched-core=y
CONFIG_PACKAGE_kmod-udptunnel4=y
CONFIG_PACKAGE_kmod-udptunnel6=y
CONFIG_PACKAGE_kmod-wireguard=y
CONFIG_PACKAGE_less=y
CONFIG_PACKAGE_libbz2=y
CONFIG_PACKAGE_libcap=y
CONFIG_PACKAGE_libcap-ng=y
CONFIG_PACKAGE_libgcrypt=y
CONFIG_PACKAGE_libgpg-error=y
CONFIG_PACKAGE_libipset=y
CONFIG_PACKAGE_libiwinfo-lua=y
CONFIG_PACKAGE_libkmod=y
CONFIG_PACKAGE_libltdl=y
CONFIG_PACKAGE_liblua=y
CONFIG_PACKAGE_liblucihttp=y
CONFIG_PACKAGE_liblucihttp-lua=y
CONFIG_PACKAGE_liblzma=y
CONFIG_PACKAGE_libmnl=y
CONFIG_PACKAGE_libncurses=y
CONFIG_PACKAGE_libnetfilter-conntrack=y
CONFIG_PACKAGE_libnfnetlink=y
CONFIG_PACKAGE_libopenssl=y
CONFIG_PACKAGE_libopenssl-conf=y
CONFIG_PACKAGE_libpci=y
CONFIG_PACKAGE_libpcre=y
CONFIG_PACKAGE_libpopt=y
CONFIG_PACKAGE_libreadline=y
CONFIG_PACKAGE_librrd1=y
CONFIG_PACKAGE_librt=y
CONFIG_PACKAGE_libtirpc=y
CONFIG_PACKAGE_libubus-lua=y
CONFIG_PACKAGE_libuuid=y
CONFIG_PACKAGE_libuv=y
CONFIG_PACKAGE_libwebsockets-full=y
CONFIG_PACKAGE_libzstd=y
CONFIG_PACKAGE_logrotate=y
CONFIG_PACKAGE_lsof=y
CONFIG_PACKAGE_lua=y
CONFIG_PACKAGE_luci=y
CONFIG_PACKAGE_luci-app-acme=y
CONFIG_PACKAGE_luci-app-adblock=y
CONFIG_PACKAGE_luci-app-commands=y
CONFIG_PACKAGE_luci-app-dawn=y
CONFIG_PACKAGE_luci-app-ddns=y
CONFIG_PACKAGE_luci-app-firewall=y
CONFIG_PACKAGE_luci-app-ledtrig-rssi=y
CONFIG_PACKAGE_luci-app-ledtrig-switch=y
CONFIG_PACKAGE_luci-app-openvpn=y
CONFIG_PACKAGE_luci-app-opkg=y
CONFIG_PACKAGE_luci-app-qos=y
CONFIG_PACKAGE_luci-app-statistics=y
CONFIG_PACKAGE_luci-app-ttyd=y
CONFIG_PACKAGE_luci-app-upnp=y
CONFIG_PACKAGE_luci-app-vpnbypass=y
CONFIG_PACKAGE_luci-app-watchcat=y
CONFIG_PACKAGE_luci-app-wireguard=y
CONFIG_PACKAGE_luci-app-wol=y
CONFIG_PACKAGE_luci-base=y
CONFIG_PACKAGE_luci-compat=y
CONFIG_PACKAGE_luci-lib-base=y
CONFIG_PACKAGE_luci-lib-ip=y
CONFIG_PACKAGE_luci-lib-ipkg=y
CONFIG_PACKAGE_luci-lib-json=y
CONFIG_PACKAGE_luci-lib-jsonc=y
CONFIG_PACKAGE_luci-lib-nixio=y
CONFIG_PACKAGE_luci-mod-admin-full=y
CONFIG_PACKAGE_luci-mod-dashboard=y
CONFIG_PACKAGE_luci-mod-network=y
CONFIG_PACKAGE_luci-mod-status=y
CONFIG_PACKAGE_luci-mod-system=y
CONFIG_PACKAGE_luci-proto-ipv6=y
CONFIG_PACKAGE_luci-proto-ppp=y
CONFIG_PACKAGE_luci-proto-wireguard=y
CONFIG_PACKAGE_luci-theme-bootstrap=y
CONFIG_PACKAGE_luci-theme-openwrt-2020=y
CONFIG_PACKAGE_miniupnpd=y
CONFIG_PACKAGE_more=y
CONFIG_PACKAGE_moreutils=y
CONFIG_PACKAGE_nano=y
CONFIG_PACKAGE_nss-firmware-ipq8074=y
CONFIG_PACKAGE_openssl-util=y
CONFIG_PACKAGE_pciids=y
CONFIG_PACKAGE_pciutils=y
CONFIG_PACKAGE_perl=y
CONFIG_PACKAGE_perlbase-base=y
CONFIG_PACKAGE_perlbase-bytes=y
CONFIG_PACKAGE_perlbase-class=y
CONFIG_PACKAGE_perlbase-config=y
CONFIG_PACKAGE_perlbase-cwd=y
CONFIG_PACKAGE_perlbase-errno=y
CONFIG_PACKAGE_perlbase-essential=y
CONFIG_PACKAGE_perlbase-fcntl=y
CONFIG_PACKAGE_perlbase-file=y
CONFIG_PACKAGE_perlbase-filehandle=y
CONFIG_PACKAGE_perlbase-getopt=y
CONFIG_PACKAGE_perlbase-i18n=y
CONFIG_PACKAGE_perlbase-integer=y
CONFIG_PACKAGE_perlbase-io=y
CONFIG_PACKAGE_perlbase-ipc=y
CONFIG_PACKAGE_perlbase-list=y
CONFIG_PACKAGE_perlbase-locale=y
CONFIG_PACKAGE_perlbase-params=y
CONFIG_PACKAGE_perlbase-posix=y
CONFIG_PACKAGE_perlbase-re=y
CONFIG_PACKAGE_perlbase-scalar=y
CONFIG_PACKAGE_perlbase-selectsaver=y
CONFIG_PACKAGE_perlbase-selfloader=y
CONFIG_PACKAGE_perlbase-socket=y
CONFIG_PACKAGE_perlbase-symbol=y
CONFIG_PACKAGE_perlbase-text=y
CONFIG_PACKAGE_perlbase-tie=y
CONFIG_PACKAGE_perlbase-unicore=y
CONFIG_PACKAGE_perlbase-utf8=y
CONFIG_PACKAGE_perlbase-xsloader=y
CONFIG_PACKAGE_qos-scripts=y
CONFIG_PACKAGE_rpcd=y
CONFIG_PACKAGE_rpcd-mod-file=y
CONFIG_PACKAGE_rpcd-mod-iwinfo=y
CONFIG_PACKAGE_rpcd-mod-luci=y
CONFIG_PACKAGE_rpcd-mod-rrdns=y
CONFIG_PACKAGE_rrdtool1=y
CONFIG_PACKAGE_rssileds=y
CONFIG_PACKAGE_sed=y
CONFIG_PACKAGE_socat=y
CONFIG_PACKAGE_tar=y
CONFIG_PACKAGE_tc-mod-iptables=y
CONFIG_PACKAGE_tc-tiny=y
CONFIG_PACKAGE_terminfo=y
CONFIG_PACKAGE_tree=y
CONFIG_PACKAGE_ttyd=y
CONFIG_PACKAGE_uhttpd=y
CONFIG_PACKAGE_uhttpd-mod-ubus=y
CONFIG_PACKAGE_umdns=y
CONFIG_PACKAGE_vpnbypass=y
CONFIG_PACKAGE_watchcat=y
CONFIG_PACKAGE_wget-ssl=y
CONFIG_PACKAGE_whereis=y
CONFIG_PACKAGE_wireguard-tools=y
CONFIG_PACKAGE_xz=y
CONFIG_PACKAGE_xz-utils=y
CONFIG_PACKAGE_zlib=y
CONFIG_PERL_NOCOMMENT=y
CONFIG_SRC_TREE_OVERRIDE=y
CONFIG_ZSTD_OPTIMIZE_O3=y

Hope this helps some people out

16 Likes

Nice catch. I have lots of these and I can confirm the pattern (although not for all devices):

2021-06-29T01:31:29+02:00 ax1 dnsmasq-dhcp[5047]: DHCPACK(br-lan) 192.168.1.186 d8:bf:c0:fa:32:43 LoraGW1
2021-06-29T02:36:29+02:00 ax1 hostapd: wlan2: STA d8:bf:c0:fa:32:43 IEEE 802.11: disconnected due to excessive missing ACKs

2021-07-01T08:26:21+02:00 ax2 hostapd: wlan1: EAPOL-4WAY-HS-COMPLETED 52:c5:22:5f:b0:c1
2021-07-01T09:31:21+02:00 ax2 hostapd: wlan1: STA 52:c5:22:5f:b0:c1 IEEE 802.11: disconnected due to excessive missing ACKs

Have now set disassoc_low_ack to 0 and have yet to see if it works

root@ax2:~# cat /etc/config/wireless | egrep 'iface|disass'
config wifi-iface 'default_radio0'
        option disassoc_low_ack '0'
config wifi-iface 'default_radio1'
        option disassoc_low_ack '0'
config wifi-iface 'default_radio2'
        option disassoc_low_ack '0'

That depends on your definition of stable and what features you use. My end user perspective:

  • There seem to be issues with IPV6. I dont use it -> no problem
  • There seem to be issues with disconnects -> could get annoying, but a workaround may help (see my last post).
  • Maybe not highest througput (no offloading in some scenarios?) -> i dont care.
  • Maybe not highest ranges (maybe due to region limits?) -> I dont care. Range is similar to my old devices although the ax3600 antennas seem to suggest they want to provide internet to my whole town.

Other than that: no random reboots or getting stuck or similar things you could expect from a not yet fully supported device. Overall I'm very pleased with it, running 2 devices as LAN (IPV4) connected WLAN range extenders, DHCP and DNS server.

To go to openwrt, you need to downgrade xiaomi firmware, enable ssh access and then install the factory firmware. No serial connection needed, but I'd recomend having a 1.8V usb2serial adapter around, just in case. You need to compile the firmware yourself. More or less like normal openwrt. In short:

git clone https://github.com/robimarko/openwrt robiwrt
cd robiwrt
git checkout AX3600-5.10-restart
./scripts/feeds update -a
./scripts/feeds install -a
make menuconfig
make -j 8
ls -l bin/targets/ipq807x/generic

All I changed in menuconfig:

  • Target System (Qualcomm IPQ807x)
  • Target Profile (Xiaomi AX3600)

At first no luci web interface, but can be installed later with opkg

Hope it helps.

4 Likes

you can add LuCI and other packages in the menuconfig

1 Like

Well, I have same issue. I use AX6, the memory leak too quickly. I'm just using AX6 as AP.

 -----------------------------------------------------
 OpenWrt SNAPSHOT, r17112-6f69bba96d
 -----------------------------------------------------
root@ax6:~# free
              total        used        free      shared  buff/cache   available
Mem:         375808      172740      175548         220       27520      164624
Swap:             0           0           0
root@ax6:~# free
              total        used        free      shared  buff/cache   available
Mem:         375808      277324       70388         220       28096       59752
Swap:             0           0           0
root@ax6:~# uptime
 20:53:39 up 18 min,  load average: 0.00, 0.00, 0.00

Well, yeah. Looks exactly the same.

As much as I know, Robi is working on backporting 5.13 stuff, maybe patches from latest QSDK. If we are lucky, one of them will fix it. If not, then it is really going to be painful to fix this...

1 Like

I'm captured the logread, out of memory too quickly. Hope this can helped.

Summary

Thu Jul 1 22:43:25 2021 kern.info kernel: [ 7677.809138] oom-kill:constraint=CONSTRAINT_NONE,nodemask=(null),cpuset=/,mems_allowed=0,global_oom,task_memcg=/,task=uhttpd,pid=2303,uid=0
Thu Jul 1 22:43:25 2021 kern.err kernel: [ 7677.817552] Out of memory: Killed process 2303 (uhttpd) total-vm:1692kB, anon-rss:288kB, file-rss:4kB, shmem-rss:0kB, UID:0 pgtables:36kB oom_score_adj:0
Thu Jul 1 22:43:25 2021 kern.info kernel: [ 7677.830222] oom_reaper: reaped process 2303 (uhttpd), now anon-rss:0kB, file-rss:0kB, shmem-rss:0kB
Thu Jul 1 22:43:27 2021 kern.warn kernel: [ 7679.036591] netifd invoked oom-killer: gfp_mask=0x100cca(GFP_HIGHUSER_MOVABLE), order=0, oom_score_adj=0
Thu Jul 1 22:43:27 2021 kern.warn kernel: [ 7679.036639] CPU: 0 PID: 2175 Comm: netifd Not tainted 5.10.46 #0
Thu Jul 1 22:43:27 2021 kern.warn kernel: [ 7679.045136] Hardware name: Redmi AX6 (DT)
Thu Jul 1 22:43:27 2021 kern.warn kernel: [ 7679.051122] Call trace:
Thu Jul 1 22:43:27 2021 kern.warn kernel: [ 7679.055034] dump_backtrace+0x0/0x1b0
Thu Jul 1 22:43:27 2021 kern.warn kernel: [ 7679.057286] show_stack+0x18/0x30
Thu Jul 1 22:43:27 2021 kern.warn kernel: [ 7679.061107] dump_stack+0xdc/0x11c
Thu Jul 1 22:43:27 2021 kern.warn kernel: [ 7679.064404] dump_header+0x44/0x194
Thu Jul 1 22:43:27 2021 kern.warn kernel: [ 7679.067707] oom_kill_process+0x1d0/0x1d8
Thu Jul 1 22:43:27 2021 kern.warn kernel: [ 7679.071088] out_of_memory+0x20c/0x320
Thu Jul 1 22:43:27 2021 kern.warn kernel: [ 7679.075257] __alloc_pages_slowpath.constprop.150+0x6c8/0x9b0
Thu Jul 1 22:43:27 2021 kern.warn kernel: [ 7679.078904] __alloc_pages_nodemask+0x1f4/0x238
Thu Jul 1 22:43:27 2021 kern.warn kernel: [ 7679.084719] pagecache_get_page.part.71+0xf8/0x2b8
Thu Jul 1 22:43:27 2021 kern.warn kernel: [ 7679.089059] filemap_fault+0x774/0x978
Thu Jul 1 22:43:27 2021 kern.warn kernel: [ 7679.093922] __do_fault+0x3c/0xf8
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.097649] handle_mm_fault+0x6b4/0xc38
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.101036] do_page_fault+0x1ac/0x3d8
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.105028] do_translation_fault+0x50/0x60
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.108587] do_mem_abort+0x40/0xa0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.112670] el0_da+0x34/0x48
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.116140] el0_sync_handler+0x68/0xb8
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.119266] el0_sync+0x184/0x1c0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.123025] Mem-Info:
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.127532] active_anon:61 inactive_anon:421 isolated_anon:0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.127532] active_file:13 inactive_file:79 isolated_file:0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.127532] unevictable:0 dirty:0 writeback:0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.127532] slab_reclaimable:1848 slab_unreclaimable:11298
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.127532] mapped:48 shmem:55 pagetables:114 bounce:0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.127532] free:3972 free_pcp:30 free_cma:0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.138180] Node 0 active_anon:244kB inactive_anon:1684kB active_file:52kB inactive_file:316kB unevictable:0kB isolated(anon):0kB isolated(file):0kB mapped:192kB dirty:0kB writeback:0kB shmem:220kB writeback_tmp:0kB kernel_stack:1488kB all_unreclaimable? yes
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.160977] DMA free:15504kB min:16384kB low:20480kB high:24576kB reserved_highatomic:0KB active_anon:244kB inactive_anon:1684kB active_file:76kB inactive_file:324kB unevictable:0kB writepending:0kB present:524288kB managed:375808kB mlocked:0kB pagetables:456kB bounce:0kB free_pcp:120kB local_pcp:0kB free_cma:0kB
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.188264] lowmem_reserve[]: 0 0 0 0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.210291] DMA: 3344kB (UME) 1758kB (UME) 10916kB (UME) 8232kB (UME) 1864kB (ME) 7128kB (UME) 3256kB (M) 3512kB (UM) 31024kB (M) 12048kB (M) 04096kB = 16576kB
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.213994] 197 total pagecache pages
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.228974] 0 pages in swap cache
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.232575] Swap cache stats: add 0, delete 0, find 0/0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.235816] Free swap = 0kB
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.240931] Total swap = 0kB
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.244056] 131072 pages RAM
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.246862] 0 pages HighMem/MovableOnly
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.249842] 37120 pages reserved
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7679.253270] Tasks state (memory values in pages):
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7679.256723] [ pid ] uid tgid total_vm rss pgtables_bytes swapents oom_score_adj name
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7679.261372] [ 825] 81 825 310 32 32768 0 0 ubusd
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7679.270017] [ 826] 0 826 205 10 24576 0 0 askfirst
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7679.278152] [ 860] 0 860 237 11 24576 0 0 urngd
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7679.286770] [ 1656] 514 1656 312 35 32768 0 0 logd
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7679.294889] [ 1657] 0 1657 333 25 28672 0 0 logread
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7679.302968] [ 2058] 0 2058 641 42 28672 0 0 hostapd
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7679.311070] [ 2059] 0 2059 623 27 40960 0 0 wpa_supplicant
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7679.319773] [ 2175] 0 2175 453 55 28672 0 0 netifd
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7679.328349] [ 2833] 0 2833 305 14 24576 0 0 ntpd
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7679.336713] [ 3464] 0 3464 254 10 28672 0 0 dropbear
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7679.345242] [ 3525] 0 3525 260 19 32768 0 0 dropbear
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7679.353620] [ 3526] 0 3526 306 16 28672 0 0 ash
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7679.361874] [ 3840] 0 3840 333 24 32768 0 0 logread
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7679.369554] [ 3857] 0 3857 533 49 40960 0 0 rpcd
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7679.377794] oom-kill:constraint=CONSTRAINT_NONE,nodemask=(null),cpuset=/,mems_allowed=0,global_oom,task_memcg=/,task=netifd,pid=2175,uid=0
Thu Jul 1 22:43:28 2021 kern.err kernel: [ 7679.386120] Out of memory: Killed process 2175 (netifd) total-vm:1812kB, anon-rss:220kB, file-rss:0kB, shmem-rss:0kB, UID:0 pgtables:28kB oom_score_adj:0
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7679.398659] oom_reaper: reaped process 2175 (netifd), now anon-rss:0kB, file-rss:0kB, shmem-rss:0kB
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.779768] logd invoked oom-killer: gfp_mask=0x100cca(GFP_HIGHUSER_MOVABLE), order=0, oom_score_adj=0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.779816] CPU: 2 PID: 1656 Comm: logd Not tainted 5.10.46 #0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.787965] Hardware name: Redmi AX6 (DT)
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.793782] Call trace:
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.797864] dump_backtrace+0x0/0x1b0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.800117] show_stack+0x18/0x30
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.803937] dump_stack+0xdc/0x11c
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.807233] dump_header+0x44/0x194
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.810535] oom_kill_process+0x1d0/0x1d8
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.813943] out_of_memory+0x20c/0x320
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.818086] __alloc_pages_slowpath.constprop.150+0x6c8/0x9b0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.821736] __alloc_pages_nodemask+0x1f4/0x238
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.827549] pagecache_get_page.part.71+0xf8/0x2b8
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.831890] filemap_fault+0x774/0x978
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.836752] __do_fault+0x3c/0xf8
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.840479] handle_mm_fault+0x6b4/0xc38
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.843868] do_page_fault+0x1ac/0x3d8
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.847858] do_translation_fault+0x50/0x60
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.851418] do_mem_abort+0x40/0xa0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.855522] el0_ia+0x64/0xd0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.858970] el0_sync_handler+0x78/0xb8
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.862094] el0_sync+0x184/0x1c0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.865793] Mem-Info:
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.869229] active_anon:61 inactive_anon:366 isolated_anon:0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.869229] active_file:3 inactive_file:64 isolated_file:27
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.869229] unevictable:0 dirty:0 writeback:0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.869229] slab_reclaimable:1846 slab_unreclaimable:11297
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.869229] mapped:27 shmem:55 pagetables:107 bounce:0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.869229] free:4154 free_pcp:27 free_cma:0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.879984] Node 0 active_anon:244kB inactive_anon:1464kB active_file:12kB inactive_file:256kB unevictable:0kB isolated(anon):0kB isolated(file):0kB mapped:108kB dirty:0kB writeback:0kB shmem:220kB writeback_tmp:0kB kernel_stack:1472kB all_unreclaimable? yes
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.902834] DMA free:16616kB min:16384kB low:20480kB high:24576kB reserved_highatomic:0KB active_anon:244kB inactive_anon:1464kB active_file:92kB inactive_file:524kB unevictable:0kB writepending:0kB present:524288kB managed:375808kB mlocked:0kB pagetables:428kB bounce:0kB free_pcp:108kB local_pcp:4kB free_cma:0kB
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.930500] lowmem_reserve[]: 0 0 0 0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.952734] DMA: 166
4kB (UME) 1578kB (UME) 12216kB (UME) 8832kB (UME) 1964kB (UME) 8128kB (UME) 3256kB (M) 3512kB (UM) 31024kB (M) 12048kB (M) 04096kB = 16352kB
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.956485] 249 total pagecache pages
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.971586] 0 pages in swap cache
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.975373] Swap cache stats: add 0, delete 0, find 0/0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.978684] Free swap = 0kB
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.983713] Total swap = 0kB
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.986831] 131072 pages RAM
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.989702] 0 pages HighMem/MovableOnly
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7679.992567] 37120 pages reserved
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7679.996127] Tasks state (memory values in pages):
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7679.999601] [ pid ] uid tgid total_vm rss pgtables_bytes swapents oom_score_adj name
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7680.004238] [ 825] 81 825 310 32 32768 0 0 ubusd
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7680.012722] [ 826] 0 826 205 10 24576 0 0 askfirst
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7680.020970] [ 860] 0 860 237 11 24576 0 0 urngd
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7680.029484] [ 1656] 514 1656 312 35 32768 0 0 logd
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7680.037549] [ 1657] 0 1657 333 25 28672 0 0 logread
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7680.045711] [ 2058] 0 2058 641 42 28672 0 0 hostapd
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7680.053782] [ 2059] 0 2059 623 27 40960 0 0 wpa_supplicant
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7680.062118] [ 2833] 0 2833 305 14 24576 0 0 ntpd
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7680.071143] [ 3464] 0 3464 254 10 28672 0 0 dropbear
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7680.079390] [ 3525] 0 3525 260 19 32768 0 0 dropbear
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7680.087817] [ 3526] 0 3526 306 16 28672 0 0 ash
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7680.096231] [ 3840] 0 3840 333 24 32768 0 0 logread
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7680.103957] [ 3857] 0 3857 533 49 40960 0 0 rpcd
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7680.112287] oom-kill:constraint=CONSTRAINT_NONE,nodemask=(null),cpuset=/,mems_allowed=0,global_oom,task_memcg=/,task=rpcd,pid=3857,uid=0
Thu Jul 1 22:43:28 2021 kern.err kernel: [ 7680.120649] Out of memory: Killed process 3857 (rpcd) total-vm:2132kB, anon-rss:196kB, file-rss:0kB, shmem-rss:0kB, UID:0 pgtables:40kB oom_score_adj:0
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7680.133069] oom_reaper: reaped process 3857 (rpcd), now anon-rss:0kB, file-rss:0kB, shmem-rss:0kB
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.754347] procd invoked oom-killer: gfp_mask=0x100cca(GFP_HIGHUSER_MOVABLE), order=0, oom_score_adj=0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.754391] CPU: 2 PID: 1 Comm: procd Not tainted 5.10.46 #0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.762543] Hardware name: Redmi AX6 (DT)
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.768444] Call trace:
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.772356] dump_backtrace+0x0/0x1b0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.774609] show_stack+0x18/0x30
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.778429] dump_stack+0xdc/0x11c
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.781726] dump_header+0x44/0x194
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.785027] oom_kill_process+0x1d0/0x1d8
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.788411] out_of_memory+0x20c/0x320
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.792578] __alloc_pages_slowpath.constprop.150+0x6c8/0x9b0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.796226] __alloc_pages_nodemask+0x1f4/0x238
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.802040] pagecache_get_page.part.71+0xf8/0x2b8
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.806380] filemap_fault+0x774/0x978
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.811243] __do_fault+0x3c/0xf8
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.814972] handle_mm_fault+0x6b4/0xc38
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.818359] do_page_fault+0x1ac/0x3d8
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.822350] do_translation_fault+0x50/0x60
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.825909] do_mem_abort+0x40/0xa0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.829993] el0_da+0x34/0x48
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.833461] el0_sync_handler+0x68/0xb8
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.836587] el0_sync+0x184/0x1c0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.840266] Mem-Info:
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.843720] active_anon:60 inactive_anon:316 isolated_anon:0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.843720] active_file:0 inactive_file:55 isolated_file:0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.843720] unevictable:0 dirty:0 writeback:0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.843720] slab_reclaimable:1838 slab_unreclaimable:11297
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.843720] mapped:20 shmem:55 pagetables:97 bounce:0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.843720] free:4081 free_pcp:0 free_cma:0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.854121] Node 0 active_anon:240kB inactive_anon:1264kB active_file:0kB inactive_file:220kB unevictable:0kB isolated(anon):0kB isolated(file):0kB mapped:80kB dirty:0kB writeback:0kB shmem:220kB writeback_tmp:0kB kernel_stack:1456kB all_unreclaimable? yes
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.877057] DMA free:16300kB min:16384kB low:20480kB high:24576kB reserved_highatomic:0KB active_anon:240kB inactive_anon:1264kB active_file:0kB inactive_file:116kB unevictable:0kB writepending:0kB present:524288kB managed:375808kB mlocked:0kB pagetables:388kB bounce:0kB free_pcp:240kB local_pcp:0kB free_cma:0kB
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.904553] lowmem_reserve[]: 0 0 0 0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.926790] DMA: 3594kB (UME) 1898kB (UME) 12216kB (UME) 9232kB (UME) 1964kB (UME) 7128kB (ME) 4256kB (UM) 2512kB (M) 31024kB (M) 12048kB (M) 0*4096kB = 17124kB
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.930453] 130 total pagecache pages
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.945540] 0 pages in swap cache
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.949266] Swap cache stats: add 0, delete 0, find 0/0
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.952566] Free swap = 0kB
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.957595] Total swap = 0kB
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.960722] 131072 pages RAM
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.963592] 0 pages HighMem/MovableOnly
Thu Jul 1 22:43:28 2021 kern.warn kernel: [ 7680.966444] 37120 pages reserved
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7680.970008] Tasks state (memory values in pages):
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7680.973484] [ pid ] uid tgid total_vm rss pgtables_bytes swapents oom_score_adj name
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7680.978119] [ 825] 81 825 310 32 32768 0 0 ubusd
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7680.986631] [ 826] 0 826 205 10 24576 0 0 askfirst
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7680.994857] [ 860] 0 860 237 11 24576 0 0 urngd
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7681.003377] [ 1656] 514 1656 312 37 32768 0 0 logd
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7681.011448] [ 1657] 0 1657 333 25 28672 0 0 logread
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7681.019601] [ 2058] 0 2058 641 42 28672 0 0 hostapd
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7681.027685] [ 2059] 0 2059 623 27 40960 0 0 wpa_supplicant
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7681.036002] [ 2833] 0 2833 305 14 24576 0 0 ntpd
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7681.045048] [ 3464] 0 3464 254 10 28672 0 0 dropbear
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7681.053278] [ 3525] 0 3525 260 20 32768 0 0 dropbear
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7681.061696] [ 3526] 0 3526 306 16 28672 0 0 ash
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7681.070120] [ 3840] 0 3840 333 24 32768 0 0 logread
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7681.077859] oom-kill:constraint=CONSTRAINT_NONE,nodemask=(null),cpuset=/,mems_allowed=0,global_oom,task_memcg=/,task=hostapd,pid=2058,uid=0
Thu Jul 1 22:43:28 2021 kern.err kernel: [ 7681.086189] Out of memory: Killed process 2058 (hostapd) total-vm:2564kB, anon-rss:168kB, file-rss:0kB, shmem-rss:0kB, UID:0 pgtables:28kB oom_score_adj:0
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7681.098868] oom_reaper: reaped process 2058 (hostapd), now anon-rss:0kB, file-rss:0kB, shmem-rss:0kB
Thu Jul 1 22:43:28 2021 kern.info kernel: [ 7681.185209] br-lan: port 5(wlan0) entered disabled state
Thu Jul 1 22:43:29 2021 kern.info kernel: [ 7682.211865] br-lan: port 4(wlan1) entered disabled state

This is the memory layout for 512 MB devices (from AmadeusGhost).
With this patch: https://source.codeaurora.org/quic/cc-qrdk/oss/system/feeds/wlan-open/tree/mac80211/patches/207-ath11k-Enable-512MB-profile-in-ath11k.patch?h=NHSS.QSDK.11.5.0.5.r1

/* 512 MB Profile */
reserved-memory {
	#address-cells = <2>;
	#size-cells = <2>;
	ranges;

	nss@40000000 {
		no-map;
		reg = <0x0 0x40000000 0x0 0x01000000>;
	};

	uboot@4a600000 {
		no-map;
		reg = <0x0 0x4a600000 0x0 0x00400000>;
	};

	sbl@4aa00000 {
		no-map;
		reg = <0x0 0x4aa00000 0x0 0x00100000>;
	};

	smem_region: smem@4ab00000 {
		no-map;
		reg = <0x0 0x4ab00000 0x0 0x00100000>;
	};

	tz@4ac00000 {
		no-map;
		reg = <0x0 0x4ac00000 0x0 0x00400000>;
	};

	q6_region: wcnss@4b000000 {
		no-map;
		reg = <0x0 0x4b000000 0x0 0x03700000>;
	};

	q6_etr_region: q6_etr_dump@4e700000 {
		no-map;
		reg = <0x0 0x4e700000 0x0 0x100000>;
	};

	wifi_dump@50500000 {
		no-map;
		reg = <0x0 0x50500000 0x0 0x200000>;
	};
};

@robimarko was thinking should we put the required kernel patch in the feeds package?

As far as I know, you cant have kernel patches inside of a package.

i mean having a dir in the feeds repo just as a reference

I dont like that personally, as that needs to be synced with the OpenWrt tree.

1 Like

Anyway can confirm there seems to be a problem in ipv6 ecm db source... can't understand if it's our problem (with patch) or they didn't notice they created a buffer overflow error...

Reverting the commit fix the problem.

5 Likes

Looking in file ipq8071-ax3600.dtsi, i see #include ipq8074.dtsi, but can't see ipq8074.dtsi file in anywhere, is there anything wrong here ?

No.

https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/arch/arm64/boot/dts/qcom/ipq8074.dtsi?h=v5.10

oh, it in build_dir, i'm just search in target/ dir. thanks

1 Like

I'm really pleased with this device running OpenWRT! Thanks to all involved.

Even on a baseline build of robimarko's branch - without adding NSS offload - I'm seeing a genuine 70MB/sec iperf3 from local wireless to far-side wired on an AX3600-AX3600 WDS link through two solid walls. The 4x4 AX link is indicating PHY rates of ~1400 at 18dBm and up to ~2000 at 26dBm. I wasn't expecting high MCS at > 18dBm based on the 5GHz PA specification (https://www.qorvo.com/products/p/QPF4588, via the teardown at https://www.acwifi.net/9478.html)

2x2 2.4GHz 'N' clients also seem to get better PHY rates than they did on my old Archer C7 at the same indicated power levels. I imagine it is a combination of improved RF/analog chipset design, the AX3600 RF PAs and antennae.

One not so good thing is that the ath10k IoT radio0 seems to perform badly at 2.4GHz. I don't just mean the 1x1 spec, but that actual carrier power as seen by a client is maybe 10-20dBm down from what another AP in the same location with same indicated TX power would give. PHY rates suffer at moderate distances, and radio0 is effectively useless as a 2.4GHz AP on both my AX3600s. On a positive note, radio0 does work well at 5GHz. Even 1x1 AC 433mbps is a useful additional channel.

Does the original Xiaomi firmware only run radio0 in 5GHz band? I thought maybe they cost-reduced the hardware, but the teardown shows full separate 2.4GHz/5GHz RF paths out of radio0. Maybe there is a hardware design bug or 5GHz-only antenna?

I saw that the 2.4GHz PA has a enable pin (https://www.nxp.com/docs/en/data-sheet/BGU7224.pdf) which changes the path by about 20dB. I'll check the DTS to see if there are any obvious GPIO candidates...

2 Likes

@dspalu32
the BGU7224 is a pre-amplifier for the receive chain, not a power amplifier for the transmit chain, according to its data sheet (first sentence General Description).

Ah, right you are! I missed the context completely. I was wondering why all references were to dB gain rather than dBm. That's a dead end then.

For the sake of posterity:

I did audit robimarko's branch GPIO DTS vs. the original Xiaomi(?) (Xiaomi AX3600 DTS), and a live state dump from the original Xiaomi (Adding OpenWrt support for Xiaomi AX3600 - #214 by gmzhuo)

  • gpio16: was (2mA, PD), now (8mA, none). Doesn't matter as used for 'qpic' NAND?
  • gpio21: was (8mA), now (2mA). Doesn't matter: net blue LED, presumably via FET
  • gpio22: was (8mA), now (2mA). Doesn't matter: net yellow LED, presumably via FET
  • gpio25: was (PU), now (PD). An orphan input in the MDIO group of the original DTS. I had hoped this might be a hacky tie-high PA enable.
  • gpio34: was (8mA), now 12mA. Doesn't matter: reset button
  • gpio38 - gpio41: was (PU), now (none). Doesn't matter now: SPI controller (unpopulated SPI flash, I think I saw elsewhere? Adding OpenWrt support for Xiaomi AX3600 - #51 by robimarko, Adding OpenWrt support for Xiaomi AX3600 - #157 by juppin)
  • gpio44: was (PU), now (PD). An orphan input in the MDIO group of the original DTS. I had hoped this might be a hacky tie-high PA enable.
  • gpio46 - gpio49: was (function1, none) now (function0, PD). Doesn't matter: f1 = hsuart, presumably some other debug UART. The board UART we use is on gpio23/24
  • gpio51: was (8mA), now (2mA). Doesn't matter: IoT antenna LED, presumably via FET
  • gpio64 - gpio66: was (function1, 6mA) now (function0, 2mA). Sounded promising, but looks like a debug left-over. Named "btcoex" in the original DTS, and f1 is the PTA (Packet Traffic Arbitration) peripheral on the SoC. Presumably this has no context on an AP without BT. ...and wouldn't have applied to the PCI ath10k anyway.
4 Likes

Hm, it could be that they have not limited the channel range properly in the BDF for the IoT radio.
I have seen that before, where they would limit the channels further in SW instead of doing it properly and
then it advertises channels that are outside of the designed amplifier range.