summaryrefslogtreecommitdiffstats
path: root/src/core
diff options
context:
space:
mode:
authorLioncash <mathew1800@gmail.com>2019-07-11 19:32:20 +0200
committerLioncash <mathew1800@gmail.com>2019-07-11 19:34:55 +0200
commitf4ae449f733a0939a39d9674ddc152647b924027 (patch)
tree0f98a9600bb1545e9cdca1311bf0c3c03783edda /src/core
parentservice/am: Implement SetAutoSleepDisabled (diff)
downloadyuzu-f4ae449f733a0939a39d9674ddc152647b924027.tar
yuzu-f4ae449f733a0939a39d9674ddc152647b924027.tar.gz
yuzu-f4ae449f733a0939a39d9674ddc152647b924027.tar.bz2
yuzu-f4ae449f733a0939a39d9674ddc152647b924027.tar.lz
yuzu-f4ae449f733a0939a39d9674ddc152647b924027.tar.xz
yuzu-f4ae449f733a0939a39d9674ddc152647b924027.tar.zst
yuzu-f4ae449f733a0939a39d9674ddc152647b924027.zip
Diffstat (limited to 'src/core')
-rw-r--r--src/core/hle/service/am/am.cpp10
-rw-r--r--src/core/hle/service/am/am.h1
2 files changed, 10 insertions, 1 deletions
diff --git a/src/core/hle/service/am/am.cpp b/src/core/hle/service/am/am.cpp
index 3f2f5c7db..a192a1f5f 100644
--- a/src/core/hle/service/am/am.cpp
+++ b/src/core/hle/service/am/am.cpp
@@ -267,7 +267,7 @@ ISelfController::ISelfController(std::shared_ptr<NVFlinger::NVFlinger> nvflinger
{66, nullptr, "GetCurrentIlluminance"},
{67, nullptr, "IsIlluminanceAvailable"},
{68, &ISelfController::SetAutoSleepDisabled, "SetAutoSleepDisabled"},
- {69, nullptr, "IsAutoSleepDisabled"},
+ {69, &ISelfController::IsAutoSleepDisabled, "IsAutoSleepDisabled"},
{70, nullptr, "ReportMultimediaError"},
{71, nullptr, "GetCurrentIlluminanceEx"},
{80, nullptr, "SetWirelessPriorityMode"},
@@ -474,6 +474,14 @@ void ISelfController::SetAutoSleepDisabled(Kernel::HLERequestContext& ctx) {
rb.Push(RESULT_SUCCESS);
}
+void ISelfController::IsAutoSleepDisabled(Kernel::HLERequestContext& ctx) {
+ LOG_DEBUG(Service_AM, "called.");
+
+ IPC::ResponseBuilder rb{ctx, 3};
+ rb.Push(RESULT_SUCCESS);
+ rb.Push(is_auto_sleep_disabled);
+}
+
void ISelfController::GetAccumulatedSuspendedTickValue(Kernel::HLERequestContext& ctx) {
LOG_DEBUG(Service_AM, "called.");
diff --git a/src/core/hle/service/am/am.h b/src/core/hle/service/am/am.h
index 0788e2dc0..6cb582483 100644
--- a/src/core/hle/service/am/am.h
+++ b/src/core/hle/service/am/am.h
@@ -134,6 +134,7 @@ private:
void SetIdleTimeDetectionExtension(Kernel::HLERequestContext& ctx);
void GetIdleTimeDetectionExtension(Kernel::HLERequestContext& ctx);
void SetAutoSleepDisabled(Kernel::HLERequestContext& ctx);
+ void IsAutoSleepDisabled(Kernel::HLERequestContext& ctx);
void GetAccumulatedSuspendedTickValue(Kernel::HLERequestContext& ctx);
void GetAccumulatedSuspendedTickChangedEvent(Kernel::HLERequestContext& ctx);