Merge pull request #107637 from drewrisinger/dr-pr-update-raspberrypi

raspberrypi: update firmware, linux, tools to latest (~2020-12-01)
This commit is contained in:
Florian Klink 2020-12-27 18:54:20 +01:00 committed by GitHub
commit dcbe3b4779
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
9 changed files with 68 additions and 84 deletions

View File

@ -1,25 +1,40 @@
{ stdenv, cmake, fetchFromGitHub }:
{ stdenv
, fetchFromGitHub
, fetchpatch
, cmake
, pkg-config
}:
stdenv.mkDerivation rec {
name = "libraspberrypi";
version = "2020-05-28";
pname = "libraspberrypi";
version = "unstable-2020-11-30";
src = fetchFromGitHub {
owner = "raspberrypi";
repo = "userland";
rev = "f97b1af1b3e653f9da2c1a3643479bfd469e3b74";
sha256 = "1r7n05rv96hqjq0rn0qzchmfqs0j7vh3p8jalgh66s6l0vms5mwy";
rev = "093b30bbc2fd083d68cc3ee07e6e555c6e592d11";
sha256 = "0n2psqyxlsic9cc5s8h65g0blblw3xws4czhpbbgjm58px3822d7";
};
cmakeFlags = if (stdenv.targetPlatform.system == "aarch64-linux")
then "-DARM64=ON"
else "-DARM64=OFF";
preConfigure = ''cmakeFlags="$cmakeFlags -DVMCS_INSTALL_PREFIX=$out"'';
nativeBuildInputs = [ cmake ];
patches = [
(fetchpatch {
# https://github.com/raspberrypi/userland/pull/670
url = "https://github.com/raspberrypi/userland/pull/670/commits/37cb44f314ab1209fe2a0a2449ef78893b1e5f62.patch";
sha256 = "1fbrbkpc4cc010ji8z4ll63g17n6jl67kdy62m74bhlxn72gg9rw";
})
];
nativeBuildInputs = [ cmake pkg-config ];
cmakeFlags = [
(if (stdenv.hostPlatform.isAarch64) then "-DARM64=ON" else "-DARM64=OFF")
"-DVMCS_INSTALL_PREFIX=$out"
];
meta = with stdenv.lib; {
description = "Userland libraries for interfacing with Raspberry Pi hardware";
description = "Userland tools & libraries for interfacing with Raspberry Pi hardware";
homepage = "https://github.com/raspberrypi/userland";
license = licenses.bsd3;
platforms = [ "armv6l-linux" "armv7l-linux" "aarch64-linux" ];
maintainers = with maintainers; [ tkerber ];
platforms = [ "armv6l-linux" "armv7l-linux" "aarch64-linux" "x86_64-linux" ];
maintainers = with maintainers; [ dezgeg tavyc tkerber ];
};
}

View File

@ -1,16 +1,14 @@
{ stdenv, fetchFromGitHub, libusb1 }:
let
version = "2020-05-11";
name = "rpiboot-unstable-${version}";
in stdenv.mkDerivation {
inherit name;
stdenv.mkDerivation {
pname = "rpiboot";
version = "unstable-2020-10-20";
src = fetchFromGitHub {
owner = "raspberrypi";
repo = "usbboot";
rev = "c650cd747c1d0597487dcf319bf95b5ba775d78b";
sha256 = "17kapny79dh05vfmrniqdvz6xhpwnqnw0511ycfx4qcjh4krxh8n";
rev = "d3760e119385a179765f43a50a8e051a44127c25";
sha256 = "0vygzh2h27xplqp1x4isj6kgrgmvmvc1mr3ghmsi98kzp91w772r";
};
nativeBuildInputs = [ libusb1 ];
@ -26,11 +24,11 @@ in stdenv.mkDerivation {
cp -r msd $out/share/rpiboot
'';
meta = {
meta = with stdenv.lib; {
homepage = "https://github.com/raspberrypi/usbboot";
description = "Utility to boot a Raspberry Pi CM/CM3/Zero over USB";
maintainers = [ stdenv.lib.maintainers.cartr ];
license = stdenv.lib.licenses.asl20;
platforms = stdenv.lib.platforms.unix;
license = licenses.asl20;
maintainers = with maintainers; [ cartr ];
platforms = [ "aarch64-linux" "armv7l-linux" "armv6l-linux" "x86_64-linux" ];
};
}

View File

@ -2,22 +2,22 @@
stdenv.mkDerivation {
pname = "raspberrypi-wireless-firmware";
version = "2019-08-16";
version = "2020-12-01";
srcs = [
(fetchFromGitHub {
name = "bluez-firmware";
owner = "RPi-Distro";
repo = "bluez-firmware";
rev = "96eefffcccc725425fd83be5e0704a5c32b79e54";
sha256 = "05h57gcxhb2c84h99cyxxx4mzi6kd5fm8pjqkz3nq5vs3nv8cqhr";
rev = "1e4ee0c05bae10002124b56c0e44bb9ac6581ddc";
sha256 = "10n6ibr3ra71f4hlvbpy8csjlgrapawxrr6jmijn470vkcqcpq27";
})
(fetchFromGitHub {
name = "firmware-nonfree";
owner = "RPi-Distro";
repo = "firmware-nonfree";
rev = "130cb86fa30cafbd575d38865fa546350d4c5f9c";
sha256 = "0jmhgbpldzz8n8lncpzwfl5ym8zgss05y952rfpwcf9v5c7vgabx";
rev = "b66ab26cebff689d0d3257f56912b9bb03c20567";
sha256 = "0cffgsp0w7vv7ylpymdddx0bl9dx3pl7snlh30p4rr9srmn8869f";
})
];
@ -41,10 +41,10 @@ stdenv.mkDerivation {
outputHashMode = "recursive";
outputHashAlgo = "sha256";
outputHash = "1r4alf1fbj6vkkf54d0anm47ymb6gn2ykl4a2hhd34b0hnf1dnhn";
outputHash = "17k9y499kjc4zv7ivnsfrgfibwj0ldr3sqdgia4dackbr70jfg2h";
meta = with stdenv.lib; {
description = "Firmware for builtin Wifi/Bluetooth devices in the Raspberry Pi 3 and Zero W";
description = "Firmware for builtin Wifi/Bluetooth devices in the Raspberry Pi 3+ and Zero W";
homepage = "https://github.com/RPi-Distro/firmware-nonfree";
license = licenses.unfreeRedistributableFirmware;
platforms = platforms.linux;

View File

@ -1,14 +1,15 @@
{ stdenv, fetchFromGitHub }:
{ stdenvNoCC, fetchFromGitHub }:
stdenv.mkDerivation rec {
stdenvNoCC.mkDerivation rec {
# NOTE: this should be updated with linux_rpi
pname = "raspberrypi-firmware";
version = "1.20201022";
version = "1.20201201";
src = fetchFromGitHub {
owner = "raspberrypi";
repo = "firmware";
rev = version;
sha256 = "0j5m50cmmr11m3h8kk89j1pqkdqr7mzdzg04ayiqvfhvy32qqlg8";
sha256 = "09yha3k72yqx29rwnv2j2zm73lzc4jgmcbmcc6yrl1i07x84lx3n";
};
installPhase = ''
@ -16,9 +17,11 @@ stdenv.mkDerivation rec {
cp -R boot/* $out/share/raspberrypi/boot
'';
dontConfigure = true;
dontBuild = true;
dontFixup = true;
meta = with stdenv.lib; {
meta = with stdenvNoCC.lib; {
description = "Firmware for the Raspberry Pi board";
homepage = "https://github.com/raspberrypi/firmware";
license = licenses.unfreeRedistributableFirmware; # See https://github.com/raspberrypi/firmware/blob/master/boot/LICENCE.broadcom

View File

@ -1,37 +0,0 @@
{ stdenv, fetchFromGitHub, fetchpatch, cmake, pkgconfig }:
stdenv.mkDerivation {
pname = "raspberrypi-tools";
version = "2020-05-28";
src = fetchFromGitHub {
owner = "raspberrypi";
repo = "userland";
rev = "f97b1af1b3e653f9da2c1a3643479bfd469e3b74";
sha256 = "1r7n05rv96hqjq0rn0qzchmfqs0j7vh3p8jalgh66s6l0vms5mwy";
};
nativeBuildInputs = [ cmake pkgconfig ];
patches = [
(fetchpatch {
# https://github.com/raspberrypi/userland/pull/670
url = "https://github.com/raspberrypi/userland/pull/670/commits/37cb44f314ab1209fe2a0a2449ef78893b1e5f62.patch";
sha256 = "1fbrbkpc4cc010ji8z4ll63g17n6jl67kdy62m74bhlxn72gg9rw";
})
];
preConfigure = ''
cmakeFlagsArray+=("-DVMCS_INSTALL_PREFIX=$out")
'' + stdenv.lib.optionalString stdenv.isAarch64 ''
cmakeFlagsArray+=("-DARM64=1")
'';
meta = with stdenv.lib; {
description = "Userland tools for the Raspberry Pi board";
homepage = "https://github.com/raspberrypi/userland";
license = licenses.bsd3;
platforms = [ "x86_64-linux" "armv6l-linux" "armv7l-linux" "aarch64-linux" ];
maintainers = with maintainers; [ dezgeg tavyc ];
};
}

View File

@ -1,8 +1,9 @@
{ stdenv, lib, buildPackages, fetchFromGitHub, perl, buildLinux, rpiVersion, ... } @ args:
let
modDirVersion = "4.19.118";
tag = "1.20200601";
# NOTE: raspberrypifw & raspberryPiWirelessFirmware should be updated with this
modDirVersion = "5.4.79";
tag = "1.20201201";
in
lib.overrideDerivation (buildLinux (args // {
version = "${modDirVersion}-${tag}";
@ -12,7 +13,7 @@ lib.overrideDerivation (buildLinux (args // {
owner = "raspberrypi";
repo = "linux";
rev = "raspberrypi-kernel_${tag}-1";
sha256 = "11jzsmnd1qry2ir9vmsv0nfdzjpgkn5yab5ylxcz406plc073anp";
sha256 = "093p5kh5f27djkhbcw371w079lhhihvg3s4by3wzsd40di4fcgn9";
};
defconfig = {
@ -22,6 +23,11 @@ lib.overrideDerivation (buildLinux (args // {
"4" = "bcm2711_defconfig";
}.${toString rpiVersion};
extraConfig = ''
# ../drivers/pci/controller/pcie-altera.c:679:8: error: too few arguments to function 'devm_of_pci_get_host_bridge_resources'
PCIE_ALTERA n
'';
features = {
efiBootStub = false;
} // (args.features or {});

View File

@ -1,15 +1,15 @@
{ stdenvNoCC, lib, fetchFromGitHub, makeWrapper
, python3, binutils-unwrapped, findutils, kmod, pciutils, raspberrypi-tools
, python3, binutils-unwrapped, findutils, kmod, pciutils, libraspberrypi
}:
stdenvNoCC.mkDerivation {
pname = "raspberrypi-eeprom";
version = "unstable-2020-10-05";
version = "2020-12-11";
src = fetchFromGitHub {
owner = "raspberrypi";
repo = "rpi-eeprom";
rev = "718820bcebd21d4a619fa262d9b9cf3acbf110f8";
sha256 = "1277jsiyv34dqpandva8kxy1s0y5ql344pl9gk84avzp1mqjnv4g";
rev = "54a9796abbee59067bff9da6b90c1014178f2c21";
sha256 = "0yp7bn444n6yisp4hiblrm00rrvrf213amzb4sh96mlb5nhxspqk";
};
buildInputs = [ python3 ];
@ -35,7 +35,7 @@ stdenvNoCC.mkDerivation {
patchShebangs $out/bin
wrapProgram $out/bin/rpi-eeprom-update \
--set FIRMWARE_ROOT $out/share/rpi-eeprom \
${lib.optionalString stdenvNoCC.isAarch64 "--set VCMAILBOX ${raspberrypi-tools}/bin/vcmailbox"} \
${lib.optionalString stdenvNoCC.isAarch64 "--set VCMAILBOX ${libraspberrypi}/bin/vcmailbox"} \
--prefix PATH : "${lib.makeBinPath ([
binutils-unwrapped
findutils
@ -43,7 +43,7 @@ stdenvNoCC.mkDerivation {
pciutils
(placeholder "out")
] ++ lib.optionals stdenvNoCC.isAarch64 [
raspberrypi-tools
libraspberrypi
])}"
'';

View File

@ -500,6 +500,7 @@ mapAliases ({
qtcurve = libsForQt5.qtcurve; # added 2020-11-07
qtpfsgui = throw "qtpfsgui is now luminanceHDR"; # added 2019-06-26
quaternion-git = throw "quaternion-git has been removed in favor of the stable version 'quaternion'"; # added 2020-04-09
raspberrypi-tools = throw "raspberrypi-tools has been removed in favor of identical 'libraspberrypi'"; # added 2020-12-24
rdf4store = throw "rdf4store has been removed from nixpkgs."; # added 2019-12-21
rdiff_backup = rdiff-backup; # added 2014-11-23
rdmd = dtools; # added 2017-08-19

View File

@ -19166,8 +19166,6 @@ in
raspberrypi-eeprom = callPackage ../os-specific/linux/raspberrypi-eeprom {};
raspberrypi-tools = callPackage ../os-specific/linux/firmware/raspberrypi/tools.nix {};
regionset = callPackage ../os-specific/linux/regionset { };
rfkill_udev = callPackage ../os-specific/linux/rfkill/udev.nix { };