diff options
author | Norbert Preining | 2024-03-03 22:39:54 +0900 |
---|---|---|
committer | Norbert Preining | 2024-03-03 22:40:20 +0900 |
commit | fe93e57b8e14ae07a385326bfd59ba0830d6b108 (patch) | |
tree | fccb578787acd9be1e05433e0e7c2643fb2ca4c8 /90-intel-lpmd.rules | |
parent | 4ded794405aab4932022e4487f1469cbc2c109c5 (diff) | |
download | aur-intel-lpmd.tar.gz |
Add udev rules for stopping on power
Diffstat (limited to '90-intel-lpmd.rules')
-rw-r--r-- | 90-intel-lpmd.rules | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/90-intel-lpmd.rules b/90-intel-lpmd.rules new file mode 100644 index 000000000000..2c6e5f8f60ed --- /dev/null +++ b/90-intel-lpmd.rules @@ -0,0 +1,6 @@ +# Turn off intel_lpmd when running on power, +# and set to auto when running on battery. +# Rules thanks to +# https://github.com/intel/intel-lpmd/issues/24#issuecomment-1973348960 +ACTION=="change", SUBSYSTEM=="power_supply", KERNEL!="hidpp_battery*", ATTR{type}=="Mains", ATTR{online}=="0", RUN+="/usr/bin/intel_lpmd_control AUTO" +ACTION=="change", SUBSYSTEM=="power_supply", KERNEL!="hidpp_battery*", ATTR{type}=="Mains", ATTR{online}=="1", RUN+="/usr/bin/intel_lpmd_control OFF" |