mirror of
https://github.com/NixOS/nixos-hardware.git
synced 2025-11-03 16:57:14 +08:00
Add support for System76 hardware, specifically the Darter Pro 6.
This relies on new `system76`, `system76-acpi`, and `system76-io` packages in `linuxPackages` in Nixpkgs.
This commit is contained in:
27
system76/darp6/default.nix
Normal file
27
system76/darp6/default.nix
Normal file
@@ -0,0 +1,27 @@
|
||||
# Hardware profile for the Darter Pro 6 laptop by System76.
|
||||
#
|
||||
# https://system76.com/laptops/darter
|
||||
|
||||
{ config, ... }:
|
||||
let
|
||||
# darp6 needs system76-acpi-dkms, not system76-dkms:
|
||||
#
|
||||
# [1] https://github.com/pop-os/system76-dkms/issues/39
|
||||
# jackpot51> system76-acpi-dkms is the correct driver to use on the darp6
|
||||
#
|
||||
# system76-io-dkms also appears to be loaded on darp6 with Pop!_OS, and
|
||||
# system76-dkms does not, and in fact refuses to load.
|
||||
packages = with config.boot.kernelPackages; [ system76-acpi system76-io ];
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
../../common/pc/laptop
|
||||
../../common/pc/laptop/ssd
|
||||
];
|
||||
|
||||
boot.extraModulePackages = packages;
|
||||
|
||||
# system76_acpi automatically loads on darp6, but system76_io does not.
|
||||
# Explicitly list all modules to be loaded, for consistency.
|
||||
boot.kernelModules = map (drv: drv.moduleName) packages;
|
||||
}
|
||||
22
system76/default.nix
Normal file
22
system76/default.nix
Normal file
@@ -0,0 +1,22 @@
|
||||
# Implementation of support for general System76 hardware.
|
||||
#
|
||||
# https://system76.com/
|
||||
|
||||
{ config, ... }:
|
||||
let
|
||||
# Try loading all system76 modules. The ones not relevant to specific
|
||||
# hardware won't be loaded.
|
||||
packages = with config.boot.kernelPackages; [ system76 system76-acpi system76-io ];
|
||||
in
|
||||
{
|
||||
imports = [ ../common/pc ];
|
||||
|
||||
# This seems to be required for system76-driver.
|
||||
boot.kernelParams = [ "ec_sys.write_support=1" ];
|
||||
|
||||
boot.extraModulePackages = packages;
|
||||
|
||||
# Explicitly attempt to load all available system76 modules. Some do
|
||||
# (system76-acpi), some don't (system76-io).
|
||||
boot.kernelModules = map (drv: drv.moduleName) packages;
|
||||
}
|
||||
Reference in New Issue
Block a user