mirror of
https://gitlab.com/asus-linux/asusctl.git
synced 2026-02-06 00:15:04 +01:00
profiles: add mid fan curve support
This commit is contained in:
@@ -660,7 +660,7 @@ fn handle_fan_curve(
|
||||
supported: &PlatformProfileFunctions,
|
||||
cmd: &FanCurveCommand,
|
||||
) -> Result<(), Box<dyn std::error::Error>> {
|
||||
if !supported.fan_curves {
|
||||
if supported.fans.is_empty() {
|
||||
println!("Fan-curves not supported by either this kernel or by the laptop.");
|
||||
println!("This requires kernel 5.17 or the fan curve patch listed in the readme.");
|
||||
return Err(ProfileError::NotSupported.into());
|
||||
@@ -686,8 +686,9 @@ fn handle_fan_curve(
|
||||
}
|
||||
|
||||
if cmd.get_enabled {
|
||||
let res = dbus.proxies().profile().enabled_fan_profiles()?;
|
||||
println!("{:?}", res);
|
||||
// TODO:
|
||||
// let res = dbus.proxies().profile().enabled_fan_profiles()?;
|
||||
// println!("{:?}", res);
|
||||
}
|
||||
|
||||
if cmd.default {
|
||||
|
||||
@@ -34,12 +34,12 @@ pub struct FanCurveCommand {
|
||||
pub mod_profile: Option<Profile>,
|
||||
#[options(
|
||||
meta = "",
|
||||
help = "enable or disable <true/false> fan curve. `mod-profile` required"
|
||||
help = "enable or disable <true/false> fan curve. `mod_profile` required"
|
||||
)]
|
||||
pub enabled: Option<bool>,
|
||||
#[options(
|
||||
meta = "",
|
||||
help = "select fan <cpu/gpu> to modify. `mod-profile` required"
|
||||
help = "select fan <cpu/gpu/mid> to modify. `mod_profile` required"
|
||||
)]
|
||||
pub fan: Option<FanCurvePU>,
|
||||
|
||||
|
||||
Reference in New Issue
Block a user