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

Update Raspberry Pi packages #156005

Merged
merged 10 commits into from
Feb 24, 2022
Merged

Update Raspberry Pi packages #156005

merged 10 commits into from
Feb 24, 2022

Conversation

zhaofengli
Copy link
Member

Motivation for this change

This supersedes #144649 by @leo60228. Tested by booting an SD image on a Pi Zero 2 W:

let
  pkgs = import ./. {
    system = "aarch64-linux";
    overlays = [
      (final: super: {
        makeModulesClosure = x:
        super.makeModulesClosure (x // { allowMissing = true; });
      })
    ];
  };
  configuration = { pkgs, modulesPath, ... }: {
    imports = [
      (modulesPath + "/installer/sd-card/sd-image-aarch64-installer.nix")
    ];

    boot.kernelPackages = pkgs.linuxPackages_rpi3;
  };
  nixos = pkgs.nixos configuration;
in nixos.config.system.build.sdImage
Things done
  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
  • 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/)
  • 22.05 Release Notes (or backporting 21.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
    • (Release notes changes) Ran nixos/doc/manual/md-to-db.sh to update generated release notes
  • Fits CONTRIBUTING.md.

@github-actions github-actions bot added 6.topic: kernel The Linux kernel 6.topic: nixos Issues or PRs affecting NixOS modules, or package usability issues specific to NixOS 8.has: module (update) This PR changes an existing module in `nixos/` labels Jan 21, 2022
@zhaofengli zhaofengli mentioned this pull request Jan 21, 2022
12 tasks
@ofborg ofborg bot added 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin 10.rebuild-linux: 1-10 labels Jan 21, 2022
@K900
Copy link
Contributor

K900 commented Jan 23, 2022

Possibly a dupe of #154389? Also, it might be worth adding arm_boost=1 to the default config.txt so newer Pis get a free overclock.

@zhaofengli
Copy link
Member Author

Well, this is what happens when things take too long to merge. Either way, the last two commits need to be cherry-picked for Pi Zero 2 W support.

@colemickens
Copy link
Member

Note that for the rpi firmware package, I had to switch the fetcher to fetchurl, disable unpacking to avoid some Darwin sha256 mismatch due to FS+unicode issues that I don't understand well enough to explain. You can steal that from my PR if you want the CI to go green for this PR.

This is effective on the Pi 400 and on newer board revisions of the
Pi 4B. From the official documentation:

> New Raspberry Pi OS images from Bullseye onwards come with
> this setting by default.

<https://www.raspberrypi.com/documentation/computers/config_txt.html>
@zhaofengli
Copy link
Member Author

Should we merge this now?

@colemickens
Copy link
Member

I'm in favor of merging.

@ereslibre
Copy link
Member

I own a Raspberry Pi 4 B and a Raspberry Pi Zero 2 W. I have built an sdcard image for them with this two expressions:

Both generated an zst under sd-image. Flashed them to sdcards and booted in the right machine.

I can confirm both machines booted fine. I have not done more thorough tests, but I plan to use this images from now on.

Let me know if you want me to do any other tests, or if you want me to streamline some nix expression I have pasted here for you to gather more information.

Copy link
Member

@samueldr samueldr left a comment

Choose a reason for hiding this comment

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

Changes look okay.

Approving / Merging on the account of multiple successful reviews.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
6.topic: kernel The Linux kernel 6.topic: nixos Issues or PRs affecting NixOS modules, or package usability issues specific to NixOS 8.has: module (update) This PR changes an existing module in `nixos/` 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin 10.rebuild-linux: 1-10
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants