From 42ec21a27cfab10b45bae466ef5c86593baf957c Mon Sep 17 00:00:00 2001 From: dadada Date: Sun, 25 Oct 2020 19:24:43 +0100 Subject: [PATCH] t14s: init Copied from t495. --- README.md | 1 + flake.nix | 1 + lenovo/thinkpad/t14s/default.nix | 16 ++++++++++++++++ 3 files changed, 18 insertions(+) create mode 100644 lenovo/thinkpad/t14s/default.nix diff --git a/README.md b/README.md index 83b5c1d..8f36405 100644 --- a/README.md +++ b/README.md @@ -100,6 +100,7 @@ See code for all available configurations. | Lenovo ThinkPad L14 (Intel) | ` | | Lenovo ThinkPad L14 (AMD) | ` | | Lenovo ThinkPad P53 | `` | +| Lenovo ThinkPad T14s | `` | | Lenovo ThinkPad T410 | `` | | Lenovo ThinkPad T420 | `` | | Lenovo ThinkPad T430 | `` | diff --git a/flake.nix b/flake.nix index a4d562d..da24084 100644 --- a/flake.nix +++ b/flake.nix @@ -34,6 +34,7 @@ lenovo-thinkpad-l14-intel = import ./lenovo/thinkpad/l14/intel; lenovo-thinkpad-l14-amd = import ./lenovo/thinkpad/l14/amd; lenovo-thinkpad-p53 = import ./lenovo/thinkpad/p53; + lenovo-thinkpad-t14s = import ./lenovo/thinkpad/t14s; lenovo-thinkpad-t410 = import ./lenovo/thinkpad/t410; lenovo-thinkpad-t420 = import ./lenovo/thinkpad/t420; lenovo-thinkpad-t430 = import ./lenovo/thinkpad/t430; diff --git a/lenovo/thinkpad/t14s/default.nix b/lenovo/thinkpad/t14s/default.nix new file mode 100644 index 0000000..64957e6 --- /dev/null +++ b/lenovo/thinkpad/t14s/default.nix @@ -0,0 +1,16 @@ +{ config, lib, pkgs, ... }: + +{ + imports = [ + ../. + ../../../common/cpu/amd + ../../../common/pc/laptop/acpi_call.nix + ]; + + # Force use of the thinkpad_acpi driver for backlight control. + # This allows the backlight save/load systemd service to work. + boot.kernelParams = [ "acpi_backlight=native" ]; + + # see https://github.com/NixOS/nixpkgs/issues/69289 + boot.kernelPackages = lib.mkIf (lib.versionOlder pkgs.linux.version "5.2") pkgs.linuxPackages_latest; +}