Jump to content

I've been trying to google and learn alot about linux since the past 2 days and am on Pop OS 21.04, although i've reached a wall in a specific spot, my wifi is absolutely garbage compared to windows and there appears to be a patch of sorts to fix that. I dont know how to go about applying it to my system and am hoping someone who does can fill me in on the details and guide me.

 

https://gist.github.com/harrykipper/d1bedb234c4af0692f7ccd33329a02d7

 

Someone commented that the patch worked but i dont even know what mac.c is

https://bbs.archlinux.org/viewtopic.php?pid=1689990#p1689990

Link to comment
https://linustechtips.com/topic/1384672-how-do-i-installapply-this-patch-file/
Share on other sites

Link to post
Share on other sites

34 minutes ago, burdlinux said:

I've been trying to google and learn alot about linux since the past 2 days and am on Pop OS 21.04, although i've reached a wall in a specific spot, my wifi is absolutely garbage compared to windows and there appears to be a patch of sorts to fix that. I dont know how to go about applying it to my system and am hoping someone who does can fill me in on the details and guide me.

 

https://gist.github.com/harrykipper/d1bedb234c4af0692f7ccd33329a02d7

 

Someone commented that the patch worked but i dont even know what mac.c is

https://bbs.archlinux.org/viewtopic.php?pid=1689990#p1689990

That's not something you can really do, its a kernel patch and to apply it you would have to manually rebuild the entire kernel. Plus see below anyway.

 

Heres the file - https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/drivers/net/wireless/ath/ath10k/mac.c?h=v5.15-rc7

Line 3399

 

From what I can see and my (very limited) understanding of C it seems like the entire section of the driver has been rewritten since this patch was suggested (the line thats suggested to be altered doesn't exist at all anymore), chances are this patch won't work on anything more modern than a 2019 kernel.

Main Rig:-

Ryzen 7 3800X | Asus ROG Strix X570-F Gaming | 16GB Team Group Dark Pro 3600Mhz | Corsair MP600 1TB PCIe Gen 4 | Sapphire 5700 XT Pulse | Corsair H115i Platinum | WD Black 1TB | WD Green 4TB | EVGA SuperNOVA G3 650W | Asus TUF GT501 | Samsung C27HG70 1440p 144hz HDR FreeSync 2 | Ubuntu 20.04.2 LTS |

 

Server:-

Intel NUC running Server 2019 + Synology DSM218+ with 2 x 4TB Toshiba NAS Ready HDDs (RAID0)

Link to post
Share on other sites

27 minutes ago, Master Disaster said:

That's not something you can really do, its a kernel patch and to apply it you would have to manually rebuild the entire kernel. Plus see below anyway.

 

Heres the file - https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/drivers/net/wireless/ath/ath10k/mac.c?h=v5.15-rc7

Line 3399

 

From what I can see and my (very limited) understanding of C it seems like the entire section of the driver has been rewritten since this patch was suggested (the line thats suggested to be altered doesn't exist at all anymore), chances are this patch won't work on anything more modern than a 2019 kernel.

 

Damn, would you happen know what could be done in order to fix wifi speeds? On any version of Windows its around 90-100Mbps but on Pop OS or Ubuntu its very inconsistent and around 100kbps-3mbps and its obviously very slow while browsing or very laggy while gaming.

Link to post
Share on other sites

7 minutes ago, burdlinux said:

 

Damn, would you happen know what could be done in order to fix wifi speeds? On any version of Windows its around 90-100Mbps but on Pop OS or Ubuntu its very inconsistent and around 100kbps-3mbps and its obviously very slow while browsing or very laggy while gaming.

Let's take a step back... do you even have the same wifi hardware as the one that patch is supposed to improve support for?

Don't ask to ask, just ask... please 🤨

sudo chmod -R 000 /*

Link to post
Share on other sites

1 hour ago, burdlinux said:

Yea it is afaik.

Maybe you need to update the firmware https://wireless.wiki.kernel.org/en/users/Drivers/ath10k/firmware#update_firmware

Don't ask to ask, just ask... please 🤨

sudo chmod -R 000 /*

Link to post
Share on other sites

4 minutes ago, burdlinux said:

Its more confusing though

I think what's probably happened here is...

 

You ran nautilus as yourself with temporary admin privilages

You used nautilus to copy the file

While copying nautilus set you as the owner of the file

Now you have a system file with the wrong owner

 

Open terminal and do

 

ls -la /lib/firmware/ath10k/QCA988X/hw2.0

 

then take a screenshot of the output and post it.

Main Rig:-

Ryzen 7 3800X | Asus ROG Strix X570-F Gaming | 16GB Team Group Dark Pro 3600Mhz | Corsair MP600 1TB PCIe Gen 4 | Sapphire 5700 XT Pulse | Corsair H115i Platinum | WD Black 1TB | WD Green 4TB | EVGA SuperNOVA G3 650W | Asus TUF GT501 | Samsung C27HG70 1440p 144hz HDR FreeSync 2 | Ubuntu 20.04.2 LTS |

 

Server:-

Intel NUC running Server 2019 + Synology DSM218+ with 2 x 4TB Toshiba NAS Ready HDDs (RAID0)

Link to post
Share on other sites

14 minutes ago, burdlinux said:

Yea i already did all of it, no change. I used the latest from 28days back.

double check that the system is actually using that version https://wireless.wiki.kernel.org/en/users/drivers/ath10k/debug#firmware_version

Don't ask to ask, just ask... please 🤨

sudo chmod -R 000 /*

Link to post
Share on other sites

11 minutes ago, Master Disaster said:

I think what's probably happened here is...

 

You ran nautilus as yourself with temporary admin privilages

You used nautilus to copy the file

While copying nautilus set you as the owner of the file

Now you have a system file with the wrong owner

 

Open terminal and do

 

ls -la /lib/firmware/ath10k/QCA988X/hw2.0

 

then take a screenshot of the output and post it.

Im using QCA6174 and i think it should be hw3.0

Link to post
Share on other sites

4 minutes ago, burdlinux said:

Im using QCA6174 and i think it should be hw3.0

If you think so, I just copied the example from the link 🙂

Main Rig:-

Ryzen 7 3800X | Asus ROG Strix X570-F Gaming | 16GB Team Group Dark Pro 3600Mhz | Corsair MP600 1TB PCIe Gen 4 | Sapphire 5700 XT Pulse | Corsair H115i Platinum | WD Black 1TB | WD Green 4TB | EVGA SuperNOVA G3 650W | Asus TUF GT501 | Samsung C27HG70 1440p 144hz HDR FreeSync 2 | Ubuntu 20.04.2 LTS |

 

Server:-

Intel NUC running Server 2019 + Synology DSM218+ with 2 x 4TB Toshiba NAS Ready HDDs (RAID0)

Link to post
Share on other sites

27 minutes ago, burdlinux said:

seems to be

image.thumb.png.ebc37bd56339764d99d71d8a4730ec48.png

firmware ver 4.4.1-00288

 

Matches the latest firmware from the git repo, either your transfer worked or you already had the latest build.

Main Rig:-

Ryzen 7 3800X | Asus ROG Strix X570-F Gaming | 16GB Team Group Dark Pro 3600Mhz | Corsair MP600 1TB PCIe Gen 4 | Sapphire 5700 XT Pulse | Corsair H115i Platinum | WD Black 1TB | WD Green 4TB | EVGA SuperNOVA G3 650W | Asus TUF GT501 | Samsung C27HG70 1440p 144hz HDR FreeSync 2 | Ubuntu 20.04.2 LTS |

 

Server:-

Intel NUC running Server 2019 + Synology DSM218+ with 2 x 4TB Toshiba NAS Ready HDDs (RAID0)

Link to post
Share on other sites

2 minutes ago, Master Disaster said:

firmware ver 4.4.1-00288

 

Matches the latest firmware from the git repo, either your transfer worked or you already had the latest build.

The transfer worked probably, the older file was a few kbs smaller

Link to post
Share on other sites

1 hour ago, burdlinux said:

seems to be

image.thumb.png.ebc37bd56339764d99d71d8a4730ec48.png

All right, let's take a look at that patch again...

6 hours ago, Master Disaster said:

From what I can see and my (very limited) understanding of C it seems like the entire section of the driver has been rewritten since this patch was suggested (the line thats suggested to be altered doesn't exist at all anymore)

It does exist with slight alterations on line 3705 as mentioned by the comment on the patch's gist:

	const struct ieee80211_hdr *hdr = (void *)skb->data;
	const struct ath10k_skb_cb *skb_cb = ATH10K_SKB_CB(skb);
	__le16 fc = hdr->frame_control;

	if (!vif || vif->type == NL80211_IFTYPE_MONITOR)
		return ATH10K_HW_TXRX_RAW;

and you can try applying the same workaround (no need for the patch tool, it's just one line):

	const struct ieee80211_hdr *hdr = (void *)skb->data;
	const struct ath10k_skb_cb *skb_cb = ATH10K_SKB_CB(skb);
	__le16 fc = hdr->frame_control;

	skb_orphan(skb);

	if (!vif || vif->type == NL80211_IFTYPE_MONITOR)
		return ATH10K_HW_TXRX_RAW;

The only problem is that afterwards you still need to compile your own kernel, which isn't trivial for a beginner. Don't be discouraged though, here's a step by step guide: https://kernelnewbies.org/KernelBuild

Don't ask to ask, just ask... please 🤨

sudo chmod -R 000 /*

Link to post
Share on other sites

9 minutes ago, Sauron said:

 

The only problem is that afterwards you still need to compile your own kernel, which isn't trivial for a beginner. Don't be discouraged though, here's a step by step guide: https://kernelnewbies.org/KernelBuild

Thanks, i will look into it, i dont think i will build one, but its great to learn.

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×