mirror of
https://github.com/NixOS/nixos-hardware.git
synced 2026-12-05 07:23:29 +01:00
framework: Add framework-laptop-kmod as default for NixOS >= 24.05
This commit is contained in:
2 files changed
+18
No files matched your search
@@ -2,6 +2,7 @@
|
|||||||
imports = [
|
imports = [
|
||||||
../../../common/pc/laptop
|
../../../common/pc/laptop
|
||||||
../../../common/pc/laptop/ssd
|
../../../common/pc/laptop/ssd
|
||||||
|
../../kmod.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
# Fix TRRS headphones missing a mic
|
# Fix TRRS headphones missing a mic
|
||||||
|
|||||||
@@ -0,0 +1,17 @@
|
|||||||
|
{ config, lib, ... }:
|
||||||
|
{
|
||||||
|
options.hardware.framework.enableKmod = lib.mkEnableOption (lib.mdDoc
|
||||||
|
"Enable the community created Framework kernel module that allows interacting with the embedded controller from sysfs."
|
||||||
|
) // {
|
||||||
|
# Enable by default if on new enough version of NixOS
|
||||||
|
default = (lib.versionAtLeast (lib.versions.majorMinor lib.version) "24.05");
|
||||||
|
};
|
||||||
|
|
||||||
|
config = lib.mkIf config.hardware.framework.enableKmod {
|
||||||
|
boot.extraModulePackages = with config.boot.kernelPackages; [
|
||||||
|
framework-laptop-kmod
|
||||||
|
];
|
||||||
|
# https://github.com/DHowett/framework-laptop-kmod?tab=readme-ov-file#usage
|
||||||
|
boot.kernelModules = [ "cros_ec" "cros_ec_lpcs" ];
|
||||||
|
};
|
||||||
|
}
|
||||||
Reference in new issue
Block a user