mirror of
https://github.com/Atmosphere-NX/Atmosphere.git
synced 2025-05-18 17:14:28 -04:00
exo2: implement smc cpu off
This commit is contained in:
parent
8a4019151b
commit
8e401f4daa
10 changed files with 272 additions and 6 deletions
|
@ -268,6 +268,25 @@ namespace ams::secmon::smc {
|
|||
return SmcResult::Success;
|
||||
}
|
||||
|
||||
SmcResult SetConfig(SmcArguments &args) {
|
||||
switch (static_cast<ConfigItem>(args.r[1])) {
|
||||
case ConfigItem::IsChargerHiZModeEnabled:
|
||||
/* Configure the HiZ mode. */
|
||||
SetChargerHiZModeEnabled(static_cast<bool>(args.r[3]));
|
||||
break;
|
||||
case ConfigItem::ExosphereNeedsReboot:
|
||||
/* TODO */
|
||||
return SmcResult::NotImplemented;
|
||||
case ConfigItem::ExosphereNeedsShutdown:
|
||||
/* TODO */
|
||||
return SmcResult::NotImplemented;
|
||||
default:
|
||||
return SmcResult::InvalidArgument;
|
||||
}
|
||||
|
||||
return SmcResult::Success;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
SmcResult SmcGetConfigUser(SmcArguments &args) {
|
||||
|
@ -279,8 +298,7 @@ namespace ams::secmon::smc {
|
|||
}
|
||||
|
||||
SmcResult SmcSetConfig(SmcArguments &args) {
|
||||
/* TODO */
|
||||
return SmcResult::NotImplemented;
|
||||
return SetConfig(args);
|
||||
}
|
||||
|
||||
/* This is an atmosphere extension smc. */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue