1
1
mirror of https://github.com/NixOS/mobile-nixos.git synced 2024-12-15 11:03:37 +03:00
mobile-nixos/modules/hardware-qualcomm.nix
Samuel Dionne-Riel a1430b3ab8 quirks: qualcomm.msm-fb-refresher -> fb-refresher
It has been found that it may be useful on non-Qualcomm platforms.
2020-06-28 23:54:14 -04:00

81 lines
2.0 KiB
Nix
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

{ config, lib, pkgs, ... }:
with lib;
let
cfg = config.mobile.hardware.socs;
in
{
options.mobile = {
hardware.socs.qualcomm-apq8064-1aa.enable = mkOption {
type = types.bool;
default = false;
description = "enable when SOC is APQ80641AA";
};
hardware.socs.qualcomm-msm8953.enable = mkOption {
type = types.bool;
default = false;
description = "enable when SOC is msm8953";
};
hardware.socs.qualcomm-msm8939.enable = mkOption {
type = types.bool;
default = false;
description = "enable when SOC is msm8939";
};
hardware.socs.qualcomm-msm8996.enable = mkOption {
type = types.bool;
default = false;
description = "enable when SOC is msm8996";
};
hardware.socs.qualcomm-msm8998.enable = mkOption {
type = types.bool;
default = false;
description = "enable when SOC is msm8998";
};
hardware.socs.qualcomm-sdm660.enable = mkOption {
type = types.bool;
default = false;
description = "enable when SOC is SDM660";
};
};
config = mkMerge [
{
mobile = mkIf cfg.qualcomm-msm8939.enable {
system.system = "aarch64-linux";
quirks.fb-refresher.enable = true;
};
}
{
mobile = mkIf cfg.qualcomm-msm8953.enable {
system.system = "aarch64-linux";
quirks.fb-refresher.enable = true;
};
}
{
mobile = mkIf cfg.qualcomm-msm8996.enable {
system.system = "aarch64-linux";
quirks.fb-refresher.enable = true;
};
}
{
mobile = mkIf cfg.qualcomm-msm8998.enable {
system.system = "aarch64-linux";
quirks.fb-refresher.enable = true;
};
}
{
mobile = mkIf cfg.qualcomm-sdm660.enable {
system.system = "aarch64-linux";
quirks.fb-refresher.enable = true;
};
}
{
mobile = mkIf cfg.qualcomm-apq8064-1aa.enable {
system.system = "armv7l-linux";
quirks.fb-refresher.enable = true;
};
}
];
}