{ config, lib, pkgs, ... }:
{
  options.system.video.nouveau.enable = lib.mkEnableOption "Enable the Nouveau graphics stack";

  config = lib.mkIf config.system.video.nouveau.enable {
    services.xserver.videoDrivers = [ "nouveau" ];
    boot.kernelParams = [ "nouveau.config=NvGspRm=1" ];
  };
}
