Dynalink DL-WRX36 Askey RT5010W IPQ8072A technical discussion

Just to make sure - but I have to run sysupgrade (or flash image to nand some other way?) before setting variables, right? Besides that, which specific variables I have to set?

I probably will order hardware next week, so I can not brick it just yet :grinning: Sorry for probably stupid questions above - although I am not afraid to use serial console (if it's will be necessary to proceed) I just hope to get it done without opening up the case.

If you have serial access, I think the current safest way it to follow the instructions from the commit on @robimarko repo, which supports single-slot for the time being.
That should enable sysupgrade to the same slot until something else is developed and tested.

Opening the case is not hard at all, just 4 screws.
The challenging part is probably the connector.

I have not tested the script from @clayface to support multi-slot and recovery from TFTP (it might miss some scenarios).
I'm not fully sure what are the steps to flash OpenWrt with this approach, and they might change with the "usbinitramfs" I gave as an example on my previous post.

I'm trying to develop something similar, that ideally won't require serial access, but it needs review, changes, and more testing before recommending it.

Oh, it's seems like I missed that @clayface script not only flash OpenWRT but also implement additional features, so for simple loading uImage from flash drive something much simpler should be sufficient?

If loading uImage from flash drive works out, following sequence should flash OpenWRT (and enable sysupgrade for future updates) even without serial access, right? Theoretically speaking, at least.

cat /proc/mtd
ubiformat /dev/mtdXY -y -f /path_to/factory_image
fw_setenv bootcmd "setenv bootargs console=ttyMSM0,115200n8 ubi.mtd=rootfs root=mtd:rootfs rootfstype=squashfs rootwait; ubi part fs; ubi read 0x44000000 kernel; bootm 0x44000000#config@rt5010w-d350-rev0"

(I replaced partition number with XY intentionally.)

Yes, that script has more features.

You also need to set mtdids and mtdparts.
Give me a couple of days to test a method that should install to a single-partition (same as current commit).

Note: I'm also working on multi-partition support with recovery, but that requires more developent.

2 Likes

I wanted to share some simple tests I just run out of curiosity.
Everything looks good.

I have 500/100 Mbits and I'm also running these:
https-dns-proxy
addblock
statistics with additional cpufreq and thermal (5 sec. collection)
htop
There is also one wifi user that I didn't disconnect to run the tests.

Also I enabled this:
image
But not this:


Running speedtest-netperf.sh -H netperf-eu.bufferbloat.net:

root@D1:~# speedtest-netperf.sh -H netperf-eu.bufferbloat.net
2022-12-28 15:20:09 Starting speedtest for 60 seconds per transfer session.
Measure speed to netperf-eu.bufferbloat.net (IPv4) while pinging gstatic.com.
Download and upload sessions are sequential, each with 5 simultaneous streams.
.............................................................
 Download: 484.38 Mbps
  Latency: [in msec, 61 pings, 0.00% packet loss]
      Min:  13.712
    10pct:  14.079
   Median:  14.560
      Avg:  16.239
    90pct:  19.908
      Max:  22.943
 CPU Load: [in % busy (avg +/- std dev) @ avg frequency, 57 samples]
     cpu0:  43.5 +/-  1.7  @ 1410 MHz
     cpu1:  13.8 +/-  2.3  @ 1552 MHz
     cpu2:  13.7 +/-  2.4  @ 1467 MHz
     cpu3:  12.9 +/-  2.8  @ 1509 MHz
 Overhead: [in % used of total CPU available]
  netperf:  11.9
...............................................................
   Upload: 102.52 Mbps
  Latency: [in msec, 62 pings, 0.00% packet loss]
      Min:  13.626
    10pct:  13.843
   Median:  14.877
      Avg:  16.379
    90pct:  20.144
      Max:  21.683
 CPU Load: [in % busy (avg +/- std dev) @ avg frequency, 59 samples]
     cpu0:  10.3 +/-  3.1  @ 1422 MHz
     cpu1:   1.7 +/-  1.2  @ 1538 MHz
     cpu2:   1.4 +/-  1.1  @ 1422 MHz
     cpu3:   2.0 +/-  1.2  @ 1498 MHz
 Overhead: [in % used of total CPU available]
  netperf:   0.9
root@D1:~# ping gstatic.com
PING gstatic.com (142.250.178.163): 56 data bytes
64 bytes from 142.250.178.163: seq=0 ttl=61 time=14.253 ms
64 bytes from 142.250.178.163: seq=1 ttl=61 time=14.657 ms
64 bytes from 142.250.178.163: seq=2 ttl=61 time=14.734 ms
64 bytes from 142.250.178.163: seq=3 ttl=61 time=14.835 ms
64 bytes from 142.250.178.163: seq=4 ttl=61 time=14.676 ms
64 bytes from 142.250.178.163: seq=5 ttl=61 time=14.796 ms
64 bytes from 142.250.178.163: seq=6 ttl=61 time=15.126 ms
^C
--- gstatic.com ping statistics ---
7 packets transmitted, 7 packets received, 0% packet loss
round-trip min/avg/max = 14.253/14.725/15.126 ms
root@D1:~#

Load observed during test:

Max spike observed:

Latency results are specif to my ISP and location, but CPU load is related to my max 500/100 speed and to the router CPU and configuration. Max router freq. is 2.2Ghz, but it was running at 1Ghz with only 2 or 3 occasional spikes at 1.3Ghz and 1.6Ghz.
There's also the load from netperf running inside the router.


fast.com

Max. cpu load and freq. observed during test:




-> How Packet Steering and Software flow offloading affects CPU load (during a 520Mbits speedtest):
image

  • Packet Steering: OFF; Software flow offloading: OFF


    (also 3 spikes to 1.3Ghz)

  • Packet Steering: ON; Software flow offloading: OFF


    (In a few other runs, there was a worst load distribution, with one core upto 70%, but same freq.)

  • Packet Steering: OFF; Software flow offloading: ON


    (In a few other runs, one core went upto 63%, but same freq.)

  • Packet Steering: ON; Software flow offloading: ON

2 Likes

After several tests I was able to come up with a process to install OpenWrt from OEM SSH (without serial access).
I split the instructions into booting initramfs (serial or OEM SSH), and installing from initramfs.

@RussianNeuroMancer, please try it once your device arrives. I tested it with both OEM slots, so it should be safe.

@robimarko, can the instructions on commit "ipq807x: add Dynalink DL-WRX36" from your repo include this instead?
They are just instructions (no code change required).

I still plan to work on multi-partition support, but we can review that part later.

Instructions are:

[rest of the commit message]
...
Notes:
- Serial is completely deactivated in the stock firmware image.
- This commit adds only single partition support, that means
  sysupgrade is upgrading the current rootfs partition.
- Installation can be done by serial connection or
  SSH access on OEM firmware

Installation Instructions:

Most part of the installation is performed from an initramfs image
running OpenWrt, and there are two options to boot it.

Boot initramfs option 1: Using serial connection (3.3V)
1. Stop auto boot to get to U-boot shell
2. Transfer initramfs image to device
   (openwrt-ipq807x-generic-dynalink_dl-wrx36-initramfs-uImage.itb)
   Tested using TFTP and a FAT-formatted USB flash drive.
3. Boot the initramfs image
   # bootm

Boot initramfs option 2: From SSH access on OEM firmware
1. Copy the initramfs image to a FAT-formatted flash drive
   (tested on single-partition drive) and connect it to device USB port.
2. Change boot command so it loads the initramfs image on next boot
   Fallback to OEM firmware is provided.
   # fw_setenv bootcmd 'usb start && fatload usb 0:1 0x44000000 openwrt-ipq807x-generic-dynalink_dl-wrx36-initramfs-uImage.itb && bootm 0x44000000; bootipq'
3. Reboot the device to boot the initramfs
   # reboot

Install OpenWrt from initramfs image:
1. Use SCP (or other way) to transfer OpenWrt factory image
2. Connect to device using SSH (on a LAN port)
3. Check MTD partition table.
   rootfs and rootfs_1 should be mtd18 and mtd20
   depending on current OEM slot.
   # cat /proc/mtd
4. Do a ubiformat to both rootfs partitions:
   # ubiformat /dev/mtd18 -y -f /path_to/factory_image
   # ubiformat /dev/mtd20 -y -f /path_to/factory_image
5. Set U-boot env variable: mtdids
   # fw_setenv mtdids 'nand0=nand0'
6. Get offset of mtd18 to determine current OEM slot
   - If current OEM slot is 1, offset is 16777216  (0x1000000)
   - If current OEM slot is 2, offset is 127926272 (0x7a00000)
   # cat /sys/class/mtd/mtd18/offset
7. Set U-boot env variable: mtdparts
   If current OEM slot is 1, run:
   # fw_setenv mtdparts 'mtdparts=nand0:0x6100000@0x1000000(fs),0x6100000@0x7a00000(fs_1)'
   If current OEM slot is 2, run:
   # fw_setenv mtdparts 'mtdparts=nand0:0x6100000@0x7a00000(fs),0x6100000@0x1000000(fs_1)'
8. Set U-boot env variable: bootcmd
   # fw_setenv bootcmd 'setenv bootargs console=ttyMSM0,115200n8 ubi.mtd=rootfs rootfstype=squashfs rootwait; ubi part fs; ubi read 0x44000000 kernel; bootm 0x44000000#config@rt5010w-d350-rev0'
9. Reboot the device
   # reboot
12 Likes

Sure, it looks like you put in quite a lot of work, so why not add non UART ones as well

I got OpenWrt installed following these instructions (+ following Dynalink DL-WRX36 Askey RT5010W IPQ8074 OpenWrt support - #365 by luaraneda first to enable SSH). Thanks a lot to you, @robimarko, @lmore377 and others who spent time to get it working. Hoping to see it mainline at some point.

1 Like

Finally remembered to replace the Dynalink instructions with yours.

1 Like

@luaraneda
Thank you so much for the ssh (stock firmware) and openwrt install instructions. There were some minor issues I faced that I was able to overcome.

  1. SSH in the stock firmware seems to use some older algorithm. The ssh utility in my Arch Linux x86_64 system initially refused to connect to it.
% pacman -Qi openssh
Name            : openssh
Version         : 9.1p1-3
% pacman -Qi openssl
Name            : openssl
Version         : 3.0.7-4
% ssh -V
OpenSSH_9.1p1, OpenSSL 3.0.7 1 Nov 2022

I had to add the following to ~/.ssh/config to connect to the DL-WRX36.

Host 192.168.216.1
    User admin
    PubkeyAcceptedAlgorithms +ssh-rsa
    HostkeyAlgorithms +ssh-rsa
  1. After loading OpenWrt Initramfs image, I again faced some issue trying to scp the factory.ubi image. SCP man page has the following text "Since OpenSSH 9.0, scp has used the SFTP protocol for transfers by default". I had to pass the "-O" parameter to scp to make it use the older SCP protocol.

scp -O openwrt-ipq807x-generic-dynalink_dl-wrx36-squashfs-factory.ubi root@192.168.1.1:/tmp/

1 Like

@robimarko Thank you for providing the OpenWrt images for DL-WRX36. I followed @luaraneda's instructions and I was able to flash (tag https://github.com/robimarko/openwrt/releases/tag/ipq807x-2022-12-28-2350)

https://github.com/robimarko/openwrt/releases/download/ipq807x-2022-12-28-2350/openwrt-ipq807x-generic-dynalink_dl-wrx36-initramfs-uImage.itb

and then

https://github.com/robimarko/openwrt/releases/download/ipq807x-2022-12-28-2350/openwrt-ipq807x-generic-dynalink_dl-wrx36-squashfs-factory.ubi

Everything seemed to work fine. I later replaced the IPQ8074 firmware in the image with the latest from kvalo's ath11k-firmware github repo

and

and then rebooted. Now, the DL-WRX36 turns ON but neither LAN ports nor WiFI SSID seem to work. WiFi, I can understand, may be the IPQ8074 firmware 2.7.0.1 might have issues. But why do the LAN ports not work?

I am back to using my Belkin RT3200 for now.

Because you replaced the board-2.bin, dont replace it and it will work

1 Like

Will pressing "reset" button for 30 seconds clear the changes (basically resetting back to factory.ubi squashfs) and bring back the DL-WRX36?

I think it should, and guys please stop randomly modifying, replacing stuff etc

Thank you, the reset button worked. I loaded back initramfs image and reflashed (ubiformat) latest factory.ubi from https://github.com/robimarko/openwrt/releases/tag/ipq807x-2023-01-02-1602 . I had to change some of the config files as the network names changed from eth{0,1,2,3,4) to wan, lan{1,2,3,4}.

@robimarko Do you think it is possible for me to do a build from your gibhub files that would work on the Linksys Atlas Max MX8300? Chipset is similar, but this has 6E/6Ghz capability.It has IPQ8072A-000 application processor, three WiFi radio solutions: #QCN5024-007, #QCN5054-007, #QCN9024-001 and power management IC #PMP8074-000-01. Application processor is supported by 1 GB of DDR3 SDRAM in two #D2516ECMDXGJD packages from Kingston and 512 MB of NAND flash memory#FMND4G08S3J-ID manufactured by Fidelix.

Probably, but you are gonna need to port the board.

Hi, how can i upgrade to the newes build?!?

do I have to consider something like with AX3600 or not

Just sysupgrade

1 Like

Is the WiFi 6E radio chipset QCN9024 or QCN9074?
Is QCN9074 supported?