Unverified Commit df82849d authored by github-actions[bot]'s avatar github-actions[bot] Committed by GitHub
Browse files

Merge staging-next into staging

parents eb74cb92 10e916e6
Loading
Loading
Loading
Loading
+24 −7
Original line number Diff line number Diff line
@@ -163,8 +163,19 @@ in
      '';
    };

    hardware.nvidia.forceFullCompositionPipeline = lib.mkOption {
      default = false;
      type = types.bool;
      description = ''
        Whether to force-enable the full composition pipeline.
        This sometimes fixes screen tearing issues.
        This has been reported to reduce the performance of some OpenGL applications and may produce issues in WebGL.
        It also drastically increases the time the driver needs to clock down after load.
      '';
    };

    hardware.nvidia.package = lib.mkOption {
      type = lib.types.package;
      type = types.package;
      default = config.boot.kernelPackages.nvidiaPackages.stable;
      defaultText = literalExpression "config.boot.kernelPackages.nvidiaPackages.stable";
      description = ''
@@ -255,13 +266,18 @@ in
        ''
          BusID "${pCfg.nvidiaBusId}"
          ${optionalString syncCfg.allowExternalGpu "Option \"AllowExternalGpus\""}
          ${optionalString cfg.powerManagement.finegrained "Option \"NVreg_DynamicPowerManagement=0x02\""}
        '';
      screenSection =
        ''
          Option "RandRRotation" "on"
          ${optionalString syncCfg.enable "Option \"AllowEmptyInitialConfiguration\""}
        '';
        '' + optionalString syncCfg.enable ''
          Option "AllowEmptyInitialConfiguration"
        '' + optionalString cfg.forceFullCompositionPipeline ''
          Option         "metamodes" "nvidia-auto-select +0+0 {ForceFullCompositionPipeline=On}"
          Option         "AllowIndirectGLXProtocol" "off"
          Option         "TripleBuffer" "on"
        ''
        ;
    };

    services.xserver.serverLayoutSection = optionalString syncCfg.enable ''
@@ -367,7 +383,8 @@ in
          RUN+="${pkgs.runtimeShell} -c 'mknod -m 666 /dev/nvidia%c{3} c 195 %c{3}"
        KERNEL=="nvidia_uvm", RUN+="${pkgs.runtimeShell} -c 'mknod -m 666 /dev/nvidia-uvm c $$(grep nvidia-uvm /proc/devices | cut -d \  -f 1) 0'"
        KERNEL=="nvidia_uvm", RUN+="${pkgs.runtimeShell} -c 'mknod -m 666 /dev/nvidia-uvm-tools c $$(grep nvidia-uvm /proc/devices | cut -d \  -f 1) 1'"
      '' + optionalString cfg.powerManagement.finegrained ''
      '' + optionalString cfg.powerManagement.finegrained (
      optionalString (versionOlder config.boot.kernelPackages.kernel.version "5.5") ''
        # Remove NVIDIA USB xHCI Host Controller devices, if present
        ACTION=="add", SUBSYSTEM=="pci", ATTR{vendor}=="0x10de", ATTR{class}=="0x0c0330", ATTR{remove}="1"

@@ -376,7 +393,7 @@ in

        # Remove NVIDIA Audio devices, if present
        ACTION=="add", SUBSYSTEM=="pci", ATTR{vendor}=="0x10de", ATTR{class}=="0x040300", ATTR{remove}="1"

      '' + ''
        # Enable runtime PM for NVIDIA VGA/3D controller devices on driver bind
        ACTION=="bind", SUBSYSTEM=="pci", ATTR{vendor}=="0x10de", ATTR{class}=="0x030000", TEST=="power/control", ATTR{power/control}="auto"
        ACTION=="bind", SUBSYSTEM=="pci", ATTR{vendor}=="0x10de", ATTR{class}=="0x030200", TEST=="power/control", ATTR{power/control}="auto"
@@ -384,7 +401,7 @@ in
        # Disable runtime PM for NVIDIA VGA/3D controller devices on driver unbind
        ACTION=="unbind", SUBSYSTEM=="pci", ATTR{vendor}=="0x10de", ATTR{class}=="0x030000", TEST=="power/control", ATTR{power/control}="on"
        ACTION=="unbind", SUBSYSTEM=="pci", ATTR{vendor}=="0x10de", ATTR{class}=="0x030200", TEST=="power/control", ATTR{power/control}="on"
      '';
      '');

    boot.extraModprobeConfig = mkIf cfg.powerManagement.finegrained ''
      options nvidia "NVreg_DynamicPowerManagement=0x02"
+2 −0
Original line number Diff line number Diff line
@@ -115,6 +115,8 @@ in stdenv.mkDerivation rec {
    libwebp
    libheif
    python
    # Duplicated here because python.withPackages does not expose the dev output with pkg-config files
    python2.pkgs.pygtk
    libexif
    xorg.libXpm
    glib-networking
+2 −2
Original line number Diff line number Diff line
@@ -2,11 +2,11 @@

stdenv.mkDerivation rec {
  pname = "logseq";
  version = "0.6.9";
  version = "0.7.0";

  src = fetchurl {
    url = "https://github.com/logseq/logseq/releases/download/${version}/logseq-linux-x64-${version}.AppImage";
    sha256 = "sha256-ubhGDx5T1AAJjU6Ka1Pqy5kL8HPa097QhhK5Sp3HWEo=";
    sha256 = "sha256-oXNSd0ZU2ZsMK51tq8iq2sfuLg0ZHaiXhpJpWZkEmeY=";
    name = "${pname}-${version}.AppImage";
  };

+2 −2
Original line number Diff line number Diff line
@@ -2,12 +2,12 @@

mkDerivation rec {
  pname = "chatterino2";
  version = "2.3.4";
  version = "2.3.5";
  src = fetchFromGitHub {
    owner = "Chatterino";
    repo = pname;
    rev = "v${version}";
    sha256 = "sha256-ZmUM56+YNH98J3XE/mWOOIfb0qBld2n4iuHpImbrU4o=";
    sha256 = "sha256-ozfLLoNUN+1SPXbMNbF1V5sdZgPZEA/J3xXzJP9D3uI=";
    fetchSubmodules = true;
  };
  nativeBuildInputs = [ qmake pkg-config wrapQtAppsHook ];
+0 −36
Original line number Diff line number Diff line
{ lib, stdenv, buildGoPackage, trousers, dclxvi, wrapGAppsHook, pkg-config, gtk3, gtkspell3,
  fetchFromGitHub }:

let
  gui = true; # Might be implemented with nixpkgs config.
in
buildGoPackage rec {
  pname = "pond";
  version = "unstable-2015-08-30";

  goPackagePath = "github.com/agl/pond";

  src = fetchFromGitHub {
    owner = "agl";
    repo = "pond";
    rev = "bce6e0dc61803c23699c749e29a83f81da3c41b2";
    sha256 = "sha256-BE7+146E9hz8enrfA+sQhtqgHiSZAtjrW1OOqchbr7Y=";
  };

  goDeps = ./deps.nix;

  nativeBuildInputs = [ pkg-config ];
  buildInputs = [ trousers gtk3 gtkspell3 ]
    ++ lib.optional stdenv.hostPlatform.isx86_64 dclxvi
    ++ lib.optionals gui [ wrapGAppsHook ];
  tags = lib.optionals (!gui) [ "nogui" ];
  excludedPackages = [ "appengine" "bn256cgo" ];
  postPatch = lib.optionalString stdenv.hostPlatform.isx86_64 ''
    grep -r 'bn256' | awk -F: '{print $1}' | xargs sed -i \
      -e "s,golang.org/x/crypto/bn256,github.com/agl/pond/bn256cgo,g" \
      -e "s,bn256\.,bn256cgo.,g"
  '';

  # https://hydra.nixos.org/build/150102618/nixlog/2
  meta.broken = stdenv.isAarch64;
}
Loading