2022-12-05 04:01:37 +01:00
|
|
|
{ stdenv, lib, pkgs, firmwareLinuxNonfree, ... }:
|
|
|
|
|
2021-02-06 12:55:27 +01:00
|
|
|
let
|
2023-01-10 03:22:06 +01:00
|
|
|
repos = pkgs.callPackage ../../../common/repos.nix {};
|
2021-08-25 02:06:29 +02:00
|
|
|
killernetworking_firmware = repos.surface-go-ath10k-firmware_backup + "/K1535_Debian";
|
2022-12-05 04:01:37 +01:00
|
|
|
|
|
|
|
in stdenv.mkDerivation {
|
2021-02-06 12:55:27 +01:00
|
|
|
pname = "microsoft-surface-go-firmware-linux-nonfree";
|
2022-02-20 18:23:14 +01:00
|
|
|
inherit (firmwareLinuxNonfree) version;
|
|
|
|
src = firmwareLinuxNonfree;
|
|
|
|
phases = [ "unpackPhase" "installPhase" ];
|
2021-02-06 12:55:27 +01:00
|
|
|
|
2022-02-20 18:23:14 +01:00
|
|
|
installPhase = ''
|
2021-02-07 01:31:26 +01:00
|
|
|
# Install the Surface Go Wifi firmware:
|
2022-02-20 18:23:14 +01:00
|
|
|
cp ${killernetworking_firmware}/board.bin lib/firmware/ath10k/QCA6174/hw2.1/
|
|
|
|
cp ${killernetworking_firmware}/board.bin lib/firmware/ath10k/QCA6174/hw3.0/
|
2021-02-07 03:49:02 +01:00
|
|
|
|
2022-02-20 18:23:14 +01:00
|
|
|
mkdir $out; cp -r ./. $out
|
|
|
|
'';
|
2021-02-07 03:49:46 +01:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Standard binary firmware collection, adjusted with the Surface Go WiFi firmware";
|
|
|
|
platforms = platforms.linux;
|
|
|
|
priority = 5;
|
|
|
|
};
|
2022-02-20 18:23:14 +01:00
|
|
|
}
|