mirror of
https://github.com/NixOS/nixos-hardware
synced 2024-11-01 08:39:41 +01:00
25 lines
769 B
Nix
25 lines
769 B
Nix
{ pkgs, ... }:
|
|
|
|
let
|
|
# This file was obtained from the display while "DDG" mode was enabled.
|
|
chip_edid = pkgs.runCommandNoCC "chip_edid" { } ''
|
|
mkdir -p $out/lib/firmware/edid
|
|
cp ${./16ach6h.bin} $out/lib/firmware/edid/16ach6h.bin
|
|
'';
|
|
in
|
|
{
|
|
hardware.display = {
|
|
edid.packages = [ chip_edid ];
|
|
|
|
outputs = {
|
|
# For some reason, the internal display is sometimes eDP-1, and sometimes it's eDP-2
|
|
"eDP-1".edid = "16ach6h.bin";
|
|
"eDP-2".edid = "16ach6h.bin";
|
|
};
|
|
};
|
|
|
|
|
|
# This fails at the moment, https://github.com/NixOS/nixos-hardware/issues/795
|
|
# Extra refresh rates seem to work regardless
|
|
# boot.initrd.extraFiles."lib/firmware/edid/16ach6h.bin".source = pkgs.runCommandLocal "chip_edid" { } "cp ${./16ach6h.bin} $out";
|
|
}
|