Netgear R7800 exploration (IPQ8065, QCA9984)

Will push the commits this night to a repo.
Current problem: wired looks like it works (with ifconfig i can see that packets are actually transmitted) but for some reason they don't get received (or the device can't send data to the router). Problem is that no error is reported and I can't really diagnosticate the cause of this.

Tried with both the dsa driver upstream and the normal driver.
I haven't tried wireless network as i think there is something to fix with pcie (and it looks cause some system lock) so I'm trying a very base build.

I'll take a look if you think its far enough along to try on ipq8064; however, adding another device at this point could be unhelpful.

In any event it will take me at least a few weeks to get going.

Thankyou for working on this.

Well you will have a base to work on... will post here the repo

You could try the newly released beta firmware (I think the correct images are the ones with "full" in the name): http://candelatech.com/downloads/ath10k-9984-10-4b/ath10k-fw-beta/

The release notes mention a crash fix: Jan 16, 2020: Fix crash that is probably related to AP rekey problem.

I did try the HTT variant of that beta firmware and the issue was still present. The original ath10k would crash at least once a minute (master). I reverted to 19.07 with the latest ath10k firmware/board files from kvalo and it is unbelievably stable after a few days. Everyone here stopped complaining about wifi. I am gonna run this for now.

1 Like

@hnyman @anon98444528 here the repo https://github.com/Ansuel/openwrt/commits/kernel-5.4

Some kernel flag still needs to be included...
(also funny thing... i accidentally deleted the patch5.4 in the commit stage so i actually had to rework the patchset AGAIN....)

2 Likes

Any thoughts on starting a new thread?

I'm happy to start one but I'd think it be better if it is not device specific (say "ipq806x: kernel 5.4") and a respectable community member (like you or hnyman) is the op.

I suspect the frequent communication like what was done for 4.19 (which I like) would not be appreciated in this thread.

2 Likes

wanted to open with a ready to test pr but since i'm having little time and this problem... will open an help thread ahahah

I'm still complaining about wifi with ct firmware :slight_smile: I do try it once in a while when I'm pinged in the github issues to try new builds. So far I have not found a ct version that works well for me. It also seems there are similar reports to mine in the github issues:
https://github.com/greearb/ath10k-ct/issues
Developing wifi firmware is not easy. Unfortunately there seems to be only 1 developer behind ct (greearb -- I appreciate your efforts, thank you!) but it is very tough when you don't have a variety of hardware to test various interop scenarios.

FWIW, this "old" version works best for me and it still seems to work with hnyman's more recent builds.
https://github.com/kvalo/ath10k-firmware/tree/master/QCA9984/hw1.0/3.10

1 Like
1 Like

@Ansuel , if one was to apply some of your work back to 19.07, would the following two diffs cover the key fixes?

diff --git a/target/linux/ipq806x/files-4.14/arch/arm/boot/dts/qcom-ipq8064.dtsi b/target/linux/ipq806x/files-4.14/arch/arm/boot/dts/qcom-ipq8064.dtsi
index 8387460d27..d850553000 100644
--- a/target/linux/ipq806x/files-4.14/arch/arm/boot/dts/qcom-ipq8064.dtsi
+++ b/target/linux/ipq806x/files-4.14/arch/arm/boot/dts/qcom-ipq8064.dtsi
@@ -50,6 +50,7 @@
                        clock-names = "cpu", "l2";
                        clock-latency = <100000>;
                        cpu-supply = <&smb208_s2b>;
+                       voltage-tolerance = <5>;
                        cooling-min-state = <0>;
                        cooling-max-state = <10>;
                        #cooling-cells = <2>;
diff --git a/target/linux/ipq806x/patches-4.14/0055-cpufreq-dt-Add-L2-frequency-scaling-support.patch b/target/linux/ipq806x/patches-4.14/0055-cpufreq-dt-Add-L2-frequency-scaling-support.patch
index 1c26650b78..f3e79b2178 100644
--- a/target/linux/ipq806x/patches-4.14/0055-cpufreq-dt-Add-L2-frequency-scaling-support.patch
+++ b/target/linux/ipq806x/patches-4.14/0055-cpufreq-dt-Add-L2-frequency-scaling-support.patch
@@ -11,7 +11,7 @@ Signed-off-by: Georgi Djakov <georgi.djakov@linaro.org>
 
 --- a/drivers/cpufreq/cpufreq-dt.c
 +++ b/drivers/cpufreq/cpufreq-dt.c
-@@ -49,11 +49,41 @@ static int set_target(struct cpufreq_pol
+@@ -49,11 +49,42 @@ static int set_target(struct cpufreq_pol
        struct private_data *priv = policy->driver_data;
        int ret;
        unsigned long target_freq = policy->freq_table[index].frequency * 1000;
@@ -43,6 +43,7 @@ Signed-off-by: Georgi Djakov <georgi.djakov@linaro.org>
 +                      l2_freq = clk_get_rate(l2_clk);
 +
 +                      if (l2_freq != new_l2_freq) {
++                              ret = clk_set_rate(l2_clk, policy->l2_rate[0]);
 +                              /* scale l2 with the core */
 +                              ret = clk_set_rate(l2_clk, new_l2_freq);
 +                      }

1 Like

yes they should.

1 Like

update: Been running super stable with uptime over 9 days since. I'll probably try the CT (with/without HTT) drivers now and then, but for me the non CT drivers are rock solid.

1 Like

New ct firmware lede.015 is out
https://www.candelatech.com/downloads/ath10k-9984-10-4b/

Change log:

*  Jan 16, 2020:  Fix crash that is probably related to AP rekey problem.
*  Jan 27, 2020:  Fix rate-ctrl problem that broke xbox communication in some cases.
                    Big thanks to Neil Aspinall for prompt and persistent bisecting!
1 Like

hello,
how can i use this with @hnyman recent builds, that are reported to crash with non-ct drivers?
thanks :slight_smile:

firmware-5.bin_10.4-3.9.0.2-00070 is working great as well. And it kind of matches the one that is used in the non-ct package, which is firmware-5.bin_10.4-3.9.0.2-00046.

In case anybody would like to have a quick way of switching between firmwares:

case "$1" in
        ct)
		wget https://www.candelatech.com/downloads/ath10k-9984-10-4b/ath10k-fw-beta/firmware-5-ct-full-htt-mgt-community.bin
		[ -f /lib/firmware/ath10k/QCA9984/hw1.0/firmware-5.bin ] && mv firmware-5-ct-full-htt-mgt-community.bin /lib/firmware/ath10k/QCA9984/hw1.0/firmware-5.bin
		[ -f /lib/firmware/ath10k/QCA9984/hw1.0/ct-firmware-5.bin ] && mv firmware-5-ct-full-htt-mgt-community.bin
 /lib/firmware/ath10k/QCA9984/hw1.0/ct-firmware-5.bin
            ;;
         
        old)
		wget https://github.com/kvalo/ath10k-firmware/raw/master/QCA9984/hw1.0/3.10/firmware-5.bin_10.4-3.10-00047
		[ -f /lib/firmware/ath10k/QCA9984/hw1.0/firmware-5.bin ] && mv firmware-5.bin_10.4-3.10-00047 /lib/firmware/ath10k/QCA9984/hw1.0/firmware-5.bin
		[ -f /lib/firmware/ath10k/QCA9984/hw1.0/ct-firmware-5.bin ] && mv firmware-5.bin_10.4-3.10-00047 /lib/firmware/ath10k/QCA9984/hw1.0/ct-firmware-5.bin
            ;;
         
        org)
		wget https://github.com/kvalo/ath10k-firmware/raw/master/QCA9984/hw1.0/3.9.0.2/firmware-5.bin_10.4-3.9.0.2-00046
		[ -f /lib/firmware/ath10k/QCA9984/hw1.0/firmware-5.bin ] && mv firmware-5.bin_10.4-3.9.0.2-00046 /lib/firmware/ath10k/QCA9984/hw1.0/firmware-5.bin
		[ -f /lib/firmware/ath10k/QCA9984/hw1.0/ct-firmware-5.bin ] && mv firmware-5.bin_10.4-3.9.0.2-00046 /lib/firmware/ath10k/QCA9984/hw1.0/ct-firmware-5.bin
            ;;
                  
        new)
		wget https://github.com/kvalo/ath10k-firmware/raw/master/QCA9984/hw1.0/3.9.0.2/firmware-5.bin_10.4-3.9.0.2-00070
		[ -f /lib/firmware/ath10k/QCA9984/hw1.0/firmware-5.bin ] && mv firmware-5.bin_10.4-3.9.0.2-00070 /lib/firmware/ath10k/QCA9984/hw1.0/firmware-5.bin
		[ -f /lib/firmware/ath10k/QCA9984/hw1.0/ct-firmware-5.bin ] && mv firmware-5.bin_10.4-3.9.0.2-00070 /lib/firmware/ath10k/QCA9984/hw1.0/ct-firmware-5.bin
            ;;
                       
        *)
            echo $"Usage: $0 {ct|old|new|org}"
            exit 1
 
esac

CT firmware is with HTT-MGT feature but if not required could be swapped with standard version.

4 Likes

I just had my first reboot with the non-ct driver. After about 2 weeks. Argh! Why god why :smiley:

While not great, if it reboots and recovers and doesn't happen very often, it should be fine. The problems I had in the past is that it just hard froze, the only way to revive it was to pull the power. That's a problem when you are not around and "smart" devices depend on it (e.g. sprinklers, alarm, cameras, ...)

You have many different devices on wifi or perhaps much traffic going on from a specific device? I only have IPhones/IPads, one D-Link extender, a smart scale and a Chromecast (which I don¨t use very often). No issues whatsoever for me.