summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/core/hle/service/am/service/application_functions.cpp45
-rw-r--r--src/core/hle/service/am/service/application_functions.h13
-rw-r--r--src/core/hle/service/sm/sm.cpp2
3 files changed, 53 insertions, 7 deletions
diff --git a/src/core/hle/service/am/service/application_functions.cpp b/src/core/hle/service/am/service/application_functions.cpp
index 30c2715a6..70b8df409 100644
--- a/src/core/hle/service/am/service/application_functions.cpp
+++ b/src/core/hle/service/am/service/application_functions.cpp
@@ -72,17 +72,17 @@ IApplicationFunctions::IApplicationFunctions(Core::System& system_, std::shared_
{121, D<&IApplicationFunctions::ClearUserChannel>, "ClearUserChannel"},
{122, D<&IApplicationFunctions::UnpopToUserChannel>, "UnpopToUserChannel"},
{123, D<&IApplicationFunctions::GetPreviousProgramIndex>, "GetPreviousProgramIndex"},
- {124, nullptr, "EnableApplicationAllThreadDumpOnCrash"},
+ {124, D<&IApplicationFunctions::EnableApplicationAllThreadDumpOnCrash>, "EnableApplicationAllThreadDumpOnCrash"},
{130, D<&IApplicationFunctions::GetGpuErrorDetectedSystemEvent>, "GetGpuErrorDetectedSystemEvent"},
- {131, nullptr, "SetDelayTimeToAbortOnGpuError"},
+ {131, D<&IApplicationFunctions::SetDelayTimeToAbortOnGpuError>, "SetDelayTimeToAbortOnGpuError"},
{140, D<&IApplicationFunctions::GetFriendInvitationStorageChannelEvent>, "GetFriendInvitationStorageChannelEvent"},
{141, D<&IApplicationFunctions::TryPopFromFriendInvitationStorageChannel>, "TryPopFromFriendInvitationStorageChannel"},
{150, D<&IApplicationFunctions::GetNotificationStorageChannelEvent>, "GetNotificationStorageChannelEvent"},
- {151, nullptr, "TryPopFromNotificationStorageChannel"},
+ {151, D<&IApplicationFunctions::TryPopFromNotificationStorageChannel>, "TryPopFromNotificationStorageChannel"},
{160, D<&IApplicationFunctions::GetHealthWarningDisappearedSystemEvent>, "GetHealthWarningDisappearedSystemEvent"},
- {170, nullptr, "SetHdcpAuthenticationActivated"},
- {180, nullptr, "GetLaunchRequiredVersion"},
- {181, nullptr, "UpgradeLaunchRequiredVersion"},
+ {170, D<&IApplicationFunctions::SetHdcpAuthenticationActivated>, "SetHdcpAuthenticationActivated"},
+ {180, D<&IApplicationFunctions::GetLaunchRequiredVersion>, "GetLaunchRequiredVersion"},
+ {181, D<&IApplicationFunctions::UpgradeLaunchRequiredVersion>, "UpgradeLaunchRequiredVersion"},
{190, nullptr, "SendServerMaintenanceOverlayNotification"},
{200, nullptr, "GetLastApplicationExitReason"},
{500, nullptr, "StartContinuousRecordingFlushForDebug"},
@@ -500,4 +500,37 @@ Result IApplicationFunctions::PrepareForJit() {
R_SUCCEED();
}
+Result IApplicationFunctions::EnableApplicationAllThreadDumpOnCrash() {
+ LOG_WARNING(Service_AM, "(STUBBED) called");
+ return ResultSuccess;
+}
+
+Result IApplicationFunctions::SetDelayTimeToAbortOnGpuError(u64 delay_time_ns) {
+ LOG_WARNING(Service_AM, "(STUBBED) called, delay_time_ns={}", delay_time_ns);
+ return ResultSuccess;
+}
+
+Result IApplicationFunctions::TryPopFromNotificationStorageChannel(Out<bool> out_success,
+ OutBuffer<BufferAttr_HipcMapAlias> out_buffer) {
+ LOG_WARNING(Service_AM, "(STUBBED) called");
+ *out_success = false;
+ return ResultSuccess;
+}
+
+Result IApplicationFunctions::SetHdcpAuthenticationActivated(bool activated) {
+ LOG_WARNING(Service_AM, "(STUBBED) called, activated={}", activated);
+ return ResultSuccess;
+}
+
+Result IApplicationFunctions::GetLaunchRequiredVersion(Out<LaunchRequiredVersion> out_version) {
+ LOG_WARNING(Service_AM, "(STUBBED) called");
+ *out_version = {}; // Zero-initialize the struct
+ return ResultSuccess;
+}
+
+Result IApplicationFunctions::UpgradeLaunchRequiredVersion(const LaunchRequiredVersion& version) {
+ LOG_WARNING(Service_AM, "(STUBBED) called");
+ return ResultSuccess;
+}
+
} // namespace Service::AM
diff --git a/src/core/hle/service/am/service/application_functions.h b/src/core/hle/service/am/service/application_functions.h
index 10025a152..85bf8640d 100644
--- a/src/core/hle/service/am/service/application_functions.h
+++ b/src/core/hle/service/am/service/application_functions.h
@@ -21,6 +21,12 @@ namespace Service::AM {
struct Applet;
class IStorage;
+struct LaunchRequiredVersion {
+ u32 version;
+ INSERT_PADDING_WORDS(3); // Padding for IPC alignment
+};
+static_assert(sizeof(LaunchRequiredVersion) == 0x10);
+
class IApplicationFunctions final : public ServiceFramework<IApplicationFunctions> {
public:
explicit IApplicationFunctions(Core::System& system_, std::shared_ptr<Applet> applet);
@@ -77,6 +83,13 @@ private:
Result GetNotificationStorageChannelEvent(OutCopyHandle<Kernel::KReadableEvent> out_event);
Result GetHealthWarningDisappearedSystemEvent(OutCopyHandle<Kernel::KReadableEvent> out_event);
Result PrepareForJit();
+ Result EnableApplicationAllThreadDumpOnCrash();
+ Result SetDelayTimeToAbortOnGpuError(u64 delay_time_ns);
+ Result TryPopFromNotificationStorageChannel(Out<bool> out_success,
+ OutBuffer<BufferAttr_HipcMapAlias> out_buffer);
+ Result SetHdcpAuthenticationActivated(bool activated);
+ Result GetLaunchRequiredVersion(Out<LaunchRequiredVersion> out_version);
+ Result UpgradeLaunchRequiredVersion(const LaunchRequiredVersion& version);
const std::shared_ptr<Applet> m_applet;
};
diff --git a/src/core/hle/service/sm/sm.cpp b/src/core/hle/service/sm/sm.cpp
index 14e0a03c8..8a92d9146 100644
--- a/src/core/hle/service/sm/sm.cpp
+++ b/src/core/hle/service/sm/sm.cpp
@@ -22,7 +22,7 @@ constexpr Result ResultInvalidClient(ErrorModule::SM, 2);
constexpr Result ResultAlreadyRegistered(ErrorModule::SM, 4);
constexpr Result ResultInvalidServiceName(ErrorModule::SM, 6);
constexpr Result ResultNotRegistered(ErrorModule::SM, 7);
-constexpr Result ResultNotAllowed(ErrorModule::SM, 1);
+[[maybe_unused]] constexpr Result ResultNotAllowed(ErrorModule::SM, 1);
ServiceManager::ServiceManager(Kernel::KernelCore& kernel_) : kernel{kernel_} {
controller_interface = std::make_unique<Controller>(kernel.System());