Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rtl8852au: init at 70bdde2 #279702

Merged
merged 2 commits into from
Apr 23, 2024
Merged

rtl8852au: init at 70bdde2 #279702

merged 2 commits into from
Apr 23, 2024

Conversation

lonyelon
Copy link
Contributor

@lonyelon lonyelon commented Jan 8, 2024

Description of changes

Add the RTL8852AU driver for some devices that require it, like my WiFi antenna. Source at https://github.com/lwfinger/rtl8852au.

Things done

  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)
    • sandbox = relaxed
    • sandbox = true
  • Tested, as applicable:
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • 24.05 Release Notes (or backporting 23.05 and 23.11 Release notes)
    • (Package updates) Added a release notes entry if the change is major or breaking
    • (Module updates) Added a release notes entry if the change is significant
    • (Module addition) Added a release notes entry if adding a new NixOS module
  • Fits CONTRIBUTING.md.

Add a 👍 reaction to pull requests you find important.

@rjpcasalino
Copy link
Contributor

rjpcasalino commented Mar 11, 2024

this works well. I modified it to fetch the 8852bu https://github.com/lwfinger/rtl8852bu and that worked too! many thanks.

Copy link
Contributor

@rjpcasalino rjpcasalino left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this can be merged? I wonder if the author could add 8852bu as well since like I've said I've copied this for such a purpose and saw success locally

Copy link
Member

@Aleksanaa Aleksanaa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You have to add rtl8821au = callPackage ../os-specific/linux/rtl8821au { }; in pkgs/top-level/linux-kernels.nix, otherwise it won't get added (unlike what by-name does)

@nixos-discourse
Copy link

This pull request has been mentioned on NixOS Discourse. There might be relevant details there:

https://discourse.nixos.org/t/prs-ready-for-review/3032/3622

@rjpcasalino
Copy link
Contributor

rjpcasalino commented Mar 13, 2024

this probably is a matter of compiling the driver (in)correctly but I get SAE unsupported: rtl8852bu needs CMD_EXTERNAL_AUTH for SAE when I attempt to connect to a hidden network with iwctl ; I am using WPA3 but this might be a problem just with iwd https://lore.kernel.org/all/214422a4-25bc-4676-8a4a-8bf8d67c7ab9@gmail.com/T/ I can confirm that rtl8852bu is working at least :) - one does not need to use useDHCP for the interface - iwd will handle it

@lonyelon
Copy link
Contributor Author

lonyelon commented Mar 30, 2024

All changes done! sorry for the long wait, I was off the internet!

I'll look into adding the 8852bu next, as many of you confirm it works. @rjpcasalino can I count on you testing my next PR with your antenna? I have no way of doing it (aside from just compiling).

@kirillrdy
Copy link
Member

@lonyelon can you change order of commits. otherwise first commit is referencing an attribute that doesn't exist

@lonyelon
Copy link
Contributor Author

@lonyelon can you change order of commits. otherwise first commit is referencing an attribute that doesn't exist

Done! <3

I had not even thought about that lol

@lonyelon
Copy link
Contributor Author

lonyelon commented Apr 1, 2024

I changed every '--replace' with '--replace-fail' as asked by @kirillrdy. I also detected an unnecessary replace thanks to it.
All is fixed now.

@rjpcasalino
Copy link
Contributor

@lonyelon yes! Would love to test. I was seeing strange issues I'm trying to see if they are related to 8852bu but haven't isolated it yet so would be happy to further test.

@lonyelon lonyelon requested a review from kirillrdy April 2, 2024 05:43
Copy link
Member

@kirillrdy kirillrdy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Result of nixpkgs-review pr 279702 run on x86_64-linux 1

12 packages failed to build:
  • linuxKernel.packages.linux_4_19.rtl8852au
  • linuxPackages_4_19_hardened.rtl8852au (linuxKernel.packages.linux_4_19_hardened.rtl8852au)
  • linuxPackages_5_10_hardened.rtl8852au (linuxKernel.packages.linux_5_10_hardened.rtl8852au)
  • linuxPackages_5_15_hardened.rtl8852au (linuxKernel.packages.linux_5_15_hardened.rtl8852au)
  • linuxPackages_5_4_hardened.rtl8852au (linuxKernel.packages.linux_5_4_hardened.rtl8852au)
  • linuxPackages_6_1_hardened.rtl8852au (linuxKernel.packages.linux_6_1_hardened.rtl8852au)
  • linuxPackages_hardened.rtl8852au (linuxPackages_6_6_hardened.rtl8852au)
  • linuxPackages_6_7_hardened.rtl8852au (linuxKernel.packages.linux_6_7_hardened.rtl8852au)
  • linuxPackages_latest.rtl8852au (linuxKernel.packages.linux_6_8.rtl8852au)
  • linuxPackages_latest-libre.rtl8852au (linuxKernel.packages.linux_latest_libre.rtl8852au)
  • linuxPackages_lqx.rtl8852au (linuxKernel.packages.linux_lqx.rtl8852au)
  • linuxPackages_zen.rtl8852au (linuxKernel.packages.linux_zen.rtl8852au)
9 packages built:
  • linuxKernel.packages.linux_5_10.rtl8852au
  • linuxKernel.packages.linux_5_15.rtl8852au
  • linuxKernel.packages.linux_5_4.rtl8852au
  • linuxKernel.packages.linux_6_1.rtl8852au
  • linuxPackages.rtl8852au (linuxKernel.packages.linux_6_6.rtl8852au)
  • linuxKernel.packages.linux_6_7.rtl8852au
  • linuxPackages-libre.rtl8852au (linuxKernel.packages.linux_libre.rtl8852au)
  • linuxPackages_xanmod.rtl8852au (linuxKernel.packages.linux_xanmod.rtl8852au)
  • linuxPackages_xanmod_latest.rtl8852au (linuxKernel.packages.linux_xanmod_latest.rtl8852au ,linuxPackages_xanmod_stable.rtl8852au)

@lonyelon
Copy link
Contributor Author

lonyelon commented Apr 2, 2024

Result of nixpkgs-review pr 279702 run on x86_64-linux 1
12 packages failed to build:
9 packages built:

This will expose me as a nixpgks novice but... Why is it failing on those kernels?

@kirillrdy
Copy link
Member

Result of nixpkgs-review pr 279702 run on x86_64-linux 1
12 packages failed to build:
9 packages built:

This will expose me as a nixpgks novice but... Why is it failing on those kernels?

this will not necessarily block this PR, just indication of current situation

I'll have a look at failures, although i am not a kernel expert either :-) and I don't have hardware to test this with

@lonyelon
Copy link
Contributor Author

lonyelon commented Apr 2, 2024

I can test the zen, libre and hardened kernels no problem. I have an old thinkpad where I can plug the antenna and check. It just feels weird that it fails on those and not in the default one.

@rjpcasalino
Copy link
Contributor

rjpcasalino commented Apr 19, 2024

any luck with further testing? I found out my motherboard was dying so that was my issue but I've got a new one now so I can go ahead and help out testing - my rendition of 8852bu is working fine

@kirillrdy kirillrdy changed the title Add rtl8852au driver rtl8852au: init at 70bdde2 Apr 22, 2024
@kirillrdy kirillrdy requested a review from K900 April 22, 2024 08:36
@kirillrdy
Copy link
Member

kirillrdy commented Apr 22, 2024

@K900 asking for review, as I don't have much experience in the nixpkgs kernels area

otherwise, I don't see reasons not to merge it

@lonyelon
Copy link
Contributor Author

lonyelon commented Apr 22, 2024

any luck with further testing? I found out my motherboard was dying so that was my issue but I've got a new one now so I can go ahead and help out testing - my rendition of 8852bu is working fine

I have been using this driver for months now without any issue so idk, but more eyes are always better.

As for the 8852bu, I guess once this one is given the OK and merged I'll make that PR.

@K900
Copy link
Contributor

K900 commented Apr 22, 2024

Do we really have to? This hardware seems to be supported by rtw89 in latest kernels.

@lonyelon
Copy link
Contributor Author

Do we really have to? This hardware seems to be supported by rtw89 in latest kernels.

Latest as in 6.8? In 6.6 I've had no luck.

@K900
Copy link
Contributor

K900 commented Apr 22, 2024

Please try 6.8.

@rjpcasalino
Copy link
Contributor

rjpcasalino commented Apr 22, 2024

is 8852bu also supported in 6.8? I am guessing yes. I think we can close this but many thanks @lonyelon regardless

@K900
Copy link
Contributor

K900 commented Apr 22, 2024

I think everything 885x is actually the same chip.

@rjpcasalino
Copy link
Contributor

tried 6.8 and testing but doesn't seem to see the usb adapter anymore but perhaps I have a misconfiguration somewhere

@K900
Copy link
Contributor

K900 commented Apr 23, 2024

Oh I see, the U variants are USB, which is not supported in mainline yet. I guess we have to deal with this for a bit longer then...

@K900 K900 merged commit 6a45695 into NixOS:master Apr 23, 2024
22 checks passed
@lonyelon
Copy link
Contributor Author

Thanks everyone. I'll now start working on the RTL8852BU PR here: #306247.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

9 participants