Yes, that is possible in theory.
But the trick is since these devices only have NAND that its much harder to recover if you mess something up and there is no UART recovery like Marvell has

Is there a jtag port accessible?
If so I should find my stlink and open my router to see if it works with qca as well...

Its probably available, not sure about the pinout.

You can actually recover using JTAG, you need to enable 2 clocks, configure DRAM and then simply boot U-boot from memory.
QCA has nice Trace32 only scripts for this exact thing, but they are only available as part of QSDK.

Also, to use JTAG you must configure the pins using bootstrap pin so that GPIO0-5 usually go into JTAG mode

Ok would have been too easy...

Hmmm sounds like kind of another proprietary lock-in, nothing just with open ocd...

Today I was in the local electronics shop to see what routers are easily available... Not a single one that looked interesting and had anything like openwrt. The most interesting I saw was netgear rax10 not even a word about it in openwrt page :wink:

how did you manage that? here's completely different story

only have radio1 and 2 turned on. wan over PPPOE, 5.15 branch compiled today

1 Like

It's quite easy to spot the check when you're disassembling their u-boot. Quite easy to find using the various strings and calls to openssl rsa functions, once you punch in the right load address and offset into your disassembler. The legalities of redistributing a patched u-boot image would be a tad murkier. (Although in theory one could just build a binary or shell script to read and patch the paticular offset in that partition. With asserts to stop the more obvious pitfalls like mismatched image.)

Although one would rather just build a whole new image that does not have these kind of limitations. Or just connect uart and use the various read/write commands available in the stock image.

For me it looks similar on my two devices

Nothing special. I am just using it as I always did. Nothing changed on my end (use case and devices are exactly the same), and I was very prone to this OOM issue before. The only difference on my end is that I am using one minor version newer NSS FW (11.4.0.5.6-R instead of 11.4.0.5.5-R), but that is an unlikely reason. Although you can try if you want: link. Wifi version is WLAN.HK.2.5.0.1-01201 (this should be the one by default).

Well in any case if we would start messing with uboot the goal should be a mainline uboot and possibly also ATF, unfortunately this is way above my head. I gave up when I failed miserably while playing with libreelec and the DTS...

I'm having trouble building the 5.15 branch: for some reason mips compile flags get added to the compile command when building qca-ssdk (pulled in by NSS-DP), resulting in errors:

aarch64-openwrt-linux-musl-gcc: error: unrecognized argument in option '-mabi=32'
aarch64-openwrt-linux-musl-gcc: note: valid arguments to '-mabi=' are: ilp32 lp64
aarch64-openwrt-linux-musl-gcc: error: unrecognized command-line option '-G'
aarch64-openwrt-linux-musl-gcc: error: unrecognized command-line option '-mno-abicalls'
aarch64-openwrt-linux-musl-gcc: error: unrecognized command-line option '-mlong-calls'

Full make output: https://pastebin.com/GGpB7Aip

What could be the reason for such strange behavior of the build system?

Whats the nss_package feed hash you are running?

Cause, the only way this can happen is if you didn't update the feeds and are using version before 5.15 support

That's it, needed to update the feeds.

@robimarko - I know you're really digging on the AX9000, so wanted to share some good news on the AX3600...

I upgraded to the k5.15 branch as it was on Thursday. The Netflix issue I described above did not show itself on this version. Interestingly, the 2 Clients that had trouble connecting to Wifi also appear to connect now. (this could be either the Robi updates OR the DAWN fixes that polynomaldivision pushed to master).

All that to say: Either Kernel upgrade, or the removal of the other kmods (qca-nss-ecm and qca-nss-drv-bridge-mgr), seems to have helped in my setup so far.

After about 24 hours uptime with ~15-20 Wifi Clients and ~15 wired clients, I noticed that Robi had rebased (Kernel = 5.15.13 and openwrt just before fw4 becoming default).

I have compiled and installed this version, and will run it over the weekend to see how it goes.
In terms of memory, I see up and down fluctuations but generally between 70-95MB free / 366.82MB.

If anyone is interested, my build packages are below. QoS is built in, but it's not turned on.

                echo 'CONFIG_TARGET_ipq807x=y' > .config
                echo 'CONFIG_TARGET_ipq807x_generic=y' >> .config
                echo 'CONFIG_TARGET_ipq807x_generic_DEVICE_xiaomi_ax3600=y' >> .config
                echo 'CONFIG_HAS_SUBTARGETS=y' >> .config
                echo 'CONFIG_TARGET_BOARD="ipq807x"' >> .config
                echo 'CONFIG_TARGET_SUBTARGET="generic"' >> .config
                echo 'CONFIG_TARGET_PROFILE="DEVICE_xiaomi_ax3600"' >> .config
                echo 'CONFIG_TARGET_ARCH_PACKAGES="aarch64_cortex-a53"' >> .config
                echo 'CONFIG_DEFAULT_TARGET_OPTIMIZATION="-Os -pipe -mcpu=cortex-a53"' >> .config
                echo 'CONFIG_TARGET_ROOTFS_INITRAMFS=y' >> .config
                echo 'CONFIG_TARGET_INITRAMFS_COMPRESSION_ZSTD=y' >> .config
                echo 'CONFIG_TARGET_ROOTFS_SQUASHFS=y' >> .config
                echo 'CONFIG_TARGET_SQUASHFS_BLOCK_SIZE=256' >> .config
                echo 'CONFIG_TARGET_UBIFS_FREE_SPACE_FIXUP=y' >> .config
                echo 'CONFIG_TARGET_OPTIMIZATION="-Os -pipe -mcpu=cortex-a53"' >> .config
                echo 'CONFIG_TARGET_SUFFIX="musl"' >> .config
                echo "CONFIG_PACKAGE_nss-firmware-ipq8074=y" >> .config
                echo "CONFIG_PACKAGE_kmod-qca-nss-dp=y" >> .config

                echo "CONFIG_PACKAGE_announce=y" >> .config
                echo "CONFIG_PACKAGE_arp-scan=y" >> .config
                echo "CONFIG_PACKAGE_bind-host=y" >> .config
                echo "CONFIG_PACKAGE_ca-certificates=y" >> .config                
                echo "CONFIG_PACKAGE_ca-bundle=y" >> .config
                echo "CONFIG_PACKAGE_dawn=y" >> .config
                echo "CONFIG_PACKAGE_ddns-scripts=y" >> .config
                echo "CONFIG_PACKAGE_ddns-scripts-cloudflare=y" >> .config
                echo "CONFIG_PACKAGE_ddns-scripts-services=y" >> .config
                echo "CONFIG_PACKAGE_findutils-xargs=y" >> .config
                echo "CONFIG_PACKAGE_fping=y" >> .config
                echo "CONFIG_PACKAGE_gawk=y" >> .config
                echo "CONFIG_PACKAGE_iputils-arping=y" >> .config
                echo "CONFIG_PACKAGE_irqbalance=y" >> .config
                echo "CONFIG_PACKAGE_iwinfo=y" >> .config
                echo "CONFIG_PACKAGE_less-wide=y" >> .config
                echo "CONFIG_PACKAGE_lldpd=y" >> .config
                echo "CONFIG_PACKAGE_miniupnpd=y" >> .config
                echo "CONFIG_PACKAGE_openvpn-wolfssl=y" >> .config
                echo "CONFIG_PACKAGE_procd-seccomp=y" >> .config
                echo "CONFIG_PACKAGE_qos-scripts=y" >> .config
                echo "CONFIG_PACKAGE_umdns=y" >> .config
                echo "CONFIG_PACKAGE_wget=y" >> .config
                echo "CONFIG_PACKAGE_wpad-wolfssl=y" >> .config

                echo "CONFIG_PACKAGE_luci=y" >> .config
                echo "CONFIG_PACKAGE_luci-base=y" >> .config
                echo "CONFIG_PACKAGE_luci-compat=y" >> .config
                echo "CONFIG_PACKAGE_luci-theme-openwrt-2020=y" >> .config
                echo "CONFIG_PACKAGE_luci-app-nlbwmon=y" >> .config
                echo "CONFIG_PACKAGE_luci-app-dawn=y" >> .config
                echo "CONFIG_PACKAGE_luci-app-ddns=y" >> .config
                echo "CONFIG_PACKAGE_luci-app-firewall=y" >> .config
                echo "CONFIG_PACKAGE_luci-app-openvpn=y" >> .config
                echo "CONFIG_PACKAGE_luci-app-qos=y" >> .config
                echo "CONFIG_PACKAGE_luci-app-upnp=y" >> .config
                echo "CONFIG_PACKAGE_luci-mod-dashboard=y" >> .config
                echo "CONFIG_PACKAGE_less=n" >> .config
                echo "CONFIG_PACKAGE_wpad-mini=n" >> .config
                echo "CONFIG_PACKAGE_wpad-basic-wolfssl=n" >> .config

Will update as it progresses.
Cheers!

5 Likes

I have spent some more time banging my head and just trying to figure out what was SSDK not doing correctly, and it just doesn't make any sense.

So, I am really out of ideas how to debug this POS

2 Likes

Is there a way to get some stably running no memory leaks openwrt on the POS without any of the QCA crap? Meaning whatever creates troubles (offloading etc. maybe even ath11k?) gets disabled for now to have a stable basis for later experiments?

For a product that now has more than 5000 posts for a year, with multiple problems, which costs more than 130 euros and still no stable solution I wonder if this is really interesting

If you can't decide based on more than 5000 posts, that tells a tale. :slight_smile:

3 Likes

I bought one of my ax3600 for 66eur in amazon.es around black friday and the other for 83 eur (current price now). Couldn't find this HW specs for this price in any other device.

Excuse me if my words have no sense but I just trying to help. So why u-boot does not init the clocks only with 5.15 but it does with 5.10? This is not possible.

Can we confirm that AX9000 with 5.10 booting from NAND works correctly?

If u-boot init the clocks with 5.10 booting from NAND, u-boot would do the same when using 5.15 or whatever kernel version.

Or maybe there is some hidden dependency of nss-dp (ssdk) with other nss packages that only has problem in these cases? (AX9000, CAX1800(like @kirdes reported) booting from nand).

U-boot is not supposed to init the clocks for ethernet at all when booting from NAND, and it doesn't.

Its the SSDK that behaves differently when booting from initramfs or when manually booting with already initialized clocks and when booting from NAND.

1 Like