2026-09-25 16:26:18

Signed-off-by: lizzie <lizzie@eden-emu.dev>
This commit is contained in:
lizzie
2026-09-25 16:26:18 +00:00
committed by crueter
parent 0f6a782cfa
commit caaabb503d
17 changed files with 351 additions and 385 deletions
+87 -88
View File
@@ -277,7 +277,8 @@ public:
class IOAuthProcedureForExternalNsa final : public ServiceFramework<IOAuthProcedureForExternalNsa> { class IOAuthProcedureForExternalNsa final : public ServiceFramework<IOAuthProcedureForExternalNsa> {
public: public:
explicit IOAuthProcedureForExternalNsa(Core::System& system_, Common::UUID) explicit IOAuthProcedureForExternalNsa(Core::System& system_, Common::UUID)
: ServiceFramework{system_, "IOAuthProcedureForExternalNsa"} {} : ServiceFramework{system_, "IOAuthProcedureForExternalNsa"}
{}
FunctionInfoBase const* FindRequest(u32 key) override { FunctionInfoBase const* FindRequest(u32 key) override {
return HandlerTableGenerateWithFind(key, return HandlerTableGenerateWithFind(key,
@@ -295,11 +296,11 @@ public:
} }
}; };
class IOAuthProcedureForNintendoAccountLinkage final class IOAuthProcedureForNintendoAccountLinkage final : public ServiceFramework<IOAuthProcedureForNintendoAccountLinkage> {
: public ServiceFramework<IOAuthProcedureForNintendoAccountLinkage> {
public: public:
explicit IOAuthProcedureForNintendoAccountLinkage(Core::System& system_, Common::UUID) explicit IOAuthProcedureForNintendoAccountLinkage(Core::System& system_, Common::UUID)
: ServiceFramework{system_, "IOAuthProcedureForNintendoAccountLinkage"} {} : ServiceFramework{system_, "IOAuthProcedureForNintendoAccountLinkage"}
{}
FunctionInfoBase const* FindRequest(u32 key) override { FunctionInfoBase const* FindRequest(u32 key) override {
return HandlerTableGenerateWithFind(key, return HandlerTableGenerateWithFind(key,
@@ -315,7 +316,7 @@ public:
FunctionInfo{210, nullptr, "IsProfileAvailable"}, // 17.0.0+ FunctionInfo{210, nullptr, "IsProfileAvailable"}, // 17.0.0+
FunctionInfo{220, nullptr, "RegisterUserAsyncWithoutProfile"}, // 17.0.0+ FunctionInfo{220, nullptr, "RegisterUserAsyncWithoutProfile"}, // 17.0.0+
FunctionInfo{221, nullptr, "RegisterUserWithProfileAsync"}, // 17.0.0+ FunctionInfo{221, nullptr, "RegisterUserWithProfileAsync"}, // 17.0.0+
FunctionInfo{230, nullptr, "RegisterUserWithLargeImageProfileAsync"}, // 18.0.0+ FunctionInfo{230, nullptr, "RegisterUserWithLargeImageProfileAsync"} // 18.0.0+
); );
} }
}; };
@@ -630,7 +631,7 @@ public:
FunctionInfo{14, nullptr, "GetNickname"}, FunctionInfo{14, nullptr, "GetNickname"},
FunctionInfo{15, nullptr, "GetProfileImage"}, FunctionInfo{15, nullptr, "GetProfileImage"},
FunctionInfo{16, nullptr, "GetProfileLargeImage"}, // 18.0.0+ FunctionInfo{16, nullptr, "GetProfileLargeImage"}, // 18.0.0+
FunctionInfo{21, nullptr, "LoadIdTokenCache"}, // 3.0.0+ FunctionInfo{21, nullptr, "LoadIdTokenCache"} // 3.0.0+
); );
} }
}; };
@@ -1222,11 +1223,9 @@ public:
FunctionInfo{0, nullptr, "EnsureCacheAsync"}, FunctionInfo{0, nullptr, "EnsureCacheAsync"},
FunctionInfo{1, nullptr, "LoadCache"}, FunctionInfo{1, nullptr, "LoadCache"},
FunctionInfo{2, nullptr, "GetDeviceAccountId"}, FunctionInfo{2, nullptr, "GetDeviceAccountId"},
FunctionInfo{50, nullptr, "RegisterNotificationTokenAsync"}, // 1.0.0 - 6.2.0 FunctionInfo{50, nullptr, "RegisterNotificationTokenAsync"}, // 1.0.0 - 6.2.0
FunctionInfo{51, nullptr, "UnregisterNotificationTokenAsync"}, // 1.0.0 - 6.2.0 FunctionInfo{51, nullptr, "UnregisterNotificationTokenAsync"} // 1.0.0 - 6.2.0
}; );
// clang-format on
RegisterHandlers(functions);
} }
~ACC_AA() override = default; ~ACC_AA() override = default;
}; };
@@ -1427,83 +1426,83 @@ public:
FunctionInfoBase const* FindRequest(u32 key) override { FunctionInfoBase const* FindRequest(u32 key) override {
return HandlerTableGenerateWithFind(key, return HandlerTableGenerateWithFind(key,
{ 0, nullptr, "GetUserCount"}, FunctionInfo{ 0, nullptr, "GetUserCount"},
{ 1, nullptr, "GetUserExistence"}, FunctionInfo{ 1, nullptr, "GetUserExistence"},
{ 2, nullptr, "ListAllUsers"}, FunctionInfo{ 2, nullptr, "ListAllUsers"},
{ 3, nullptr, "ListOpenUsers"}, FunctionInfo{ 3, nullptr, "ListOpenUsers"},
{ 4, nullptr, "GetLastOpenedUser"}, FunctionInfo{ 4, nullptr, "GetLastOpenedUser"},
{ 5, nullptr, "GetProfile"}, FunctionInfo{ 5, nullptr, "GetProfile"},
{ 6, nullptr, "GetProfileDigest"}, FunctionInfo{ 6, nullptr, "GetProfileDigest"},
{ 50, nullptr, "IsUserRegistrationRequestPermitted"}, FunctionInfo{ 50, nullptr, "IsUserRegistrationRequestPermitted"},
{ 51, nullptr, "TrySelectUserWithoutInteractionDeprecated"}, FunctionInfo{ 51, nullptr, "TrySelectUserWithoutInteractionDeprecated"},
{ 52, nullptr, "TrySelectUserWithoutInteraction"}, FunctionInfo{ 52, nullptr, "TrySelectUserWithoutInteraction"},
{ 99, nullptr, "DebugActivateOpenContextRetention"}, FunctionInfo{ 99, nullptr, "DebugActivateOpenContextRetention"},
{ 100, nullptr, "GetUserRegistrationNotifier"}, FunctionInfo{ 100, nullptr, "GetUserRegistrationNotifier"},
{ 101, nullptr, "GetUserStateChangeNotifier"}, FunctionInfo{ 101, nullptr, "GetUserStateChangeNotifier"},
{ 102, nullptr, "GetBaasAccountManagerForSystemService"}, FunctionInfo{ 102, nullptr, "GetBaasAccountManagerForSystemService"},
{ 103, nullptr, "GetBaasUserAvailabilityChangeNotifier"}, FunctionInfo{ 103, nullptr, "GetBaasUserAvailabilityChangeNotifier"},
{ 104, nullptr, "GetProfileUpdateNotifier"}, FunctionInfo{ 104, nullptr, "GetProfileUpdateNotifier"},
{ 105, nullptr, "CheckNetworkServiceAvailabilityAsync"}, FunctionInfo{ 105, nullptr, "CheckNetworkServiceAvailabilityAsync"},
{ 106, nullptr, "GetProfileSyncNotifier"}, FunctionInfo{ 106, nullptr, "GetProfileSyncNotifier"},
{ 110, nullptr, "StoreSaveDataThumbnail"}, FunctionInfo{ 110, nullptr, "StoreSaveDataThumbnail"},
{ 111, nullptr, "ClearSaveDataThumbnail"}, FunctionInfo{ 111, nullptr, "ClearSaveDataThumbnail"},
{ 112, nullptr, "LoadSaveDataThumbnail"}, FunctionInfo{ 112, nullptr, "LoadSaveDataThumbnail"},
{ 113, nullptr, "GetSaveDataThumbnailExistence"}, FunctionInfo{ 113, nullptr, "GetSaveDataThumbnailExistence"},
{ 120, nullptr, "ListOpenUsersInApplication"}, FunctionInfo{ 120, nullptr, "ListOpenUsersInApplication"},
{ 130, nullptr, "ActivateOpenContextRetention"}, FunctionInfo{ 130, nullptr, "ActivateOpenContextRetention"},
{ 140, nullptr, "ListQualifiedUsers"}, FunctionInfo{ 140, nullptr, "ListQualifiedUsers"},
{ 151, nullptr, "EnsureSignedDeviceIdentifierCacheForNintendoAccountAsync"}, FunctionInfo{ 151, nullptr, "EnsureSignedDeviceIdentifierCacheForNintendoAccountAsync"},
{ 152, nullptr, "LoadSignedDeviceIdentifierCacheForNintendoAccount"}, FunctionInfo{ 152, nullptr, "LoadSignedDeviceIdentifierCacheForNintendoAccount"},
{ 170, nullptr, "GetNasOp2MembershipStateChangeNotifier"}, FunctionInfo{ 170, nullptr, "GetNasOp2MembershipStateChangeNotifier"},
{ 191, nullptr, "UpdateNotificationReceiverInfo"}, FunctionInfo{ 191, nullptr, "UpdateNotificationReceiverInfo"},
{ 200, nullptr, "BeginUserRegistration"}, FunctionInfo{ 200, nullptr, "BeginUserRegistration"},
{ 201, nullptr, "CompleteUserRegistration"}, FunctionInfo{ 201, nullptr, "CompleteUserRegistration"},
{ 202, nullptr, "CancelUserRegistration"}, FunctionInfo{ 202, nullptr, "CancelUserRegistration"},
{ 203, nullptr, "DeleteUser"}, FunctionInfo{ 203, nullptr, "DeleteUser"},
{ 204, nullptr, "SetUserPosition"}, FunctionInfo{ 204, nullptr, "SetUserPosition"},
{ 205, nullptr, "GetProfileEditor"}, FunctionInfo{ 205, nullptr, "GetProfileEditor"},
{ 206, nullptr, "CompleteUserRegistrationForcibly"}, FunctionInfo{ 206, nullptr, "CompleteUserRegistrationForcibly"},
{ 210, nullptr, "CreateFloatingRegistrationRequest"}, FunctionInfo{ 210, nullptr, "CreateFloatingRegistrationRequest"},
{ 211, nullptr, "CreateProcedureToRegisterUserWithNintendoAccount"}, FunctionInfo{ 211, nullptr, "CreateProcedureToRegisterUserWithNintendoAccount"},
{ 212, nullptr, "ResumeProcedureToRegisterUserWithNintendoAccount"}, FunctionInfo{ 212, nullptr, "ResumeProcedureToRegisterUserWithNintendoAccount"},
{ 213, nullptr, "CreateProcedureToCreateUserWithNintendoAccount"}, FunctionInfo{ 213, nullptr, "CreateProcedureToCreateUserWithNintendoAccount"},
{ 214, nullptr, "ResumeProcedureToCreateUserWithNintendoAccount"}, FunctionInfo{ 214, nullptr, "ResumeProcedureToCreateUserWithNintendoAccount"},
{ 215, nullptr, "ResumeProcedureToCreateUserWithNintendoAccountAfterApplyResponse"}, FunctionInfo{ 215, nullptr, "ResumeProcedureToCreateUserWithNintendoAccountAfterApplyResponse"},
{ 230, nullptr, "AuthenticateServiceAsync"}, FunctionInfo{ 230, nullptr, "AuthenticateServiceAsync"},
{ 250, nullptr, "GetBaasAccountAdministrator"}, FunctionInfo{ 250, nullptr, "GetBaasAccountAdministrator"},
{ 251, nullptr, "SynchronizeNetworkServiceAccountsSnapshotAsync"}, FunctionInfo{ 251, nullptr, "SynchronizeNetworkServiceAccountsSnapshotAsync"},
{ 290, nullptr, "ProxyProcedureForGuestLoginWithNintendoAccount"}, FunctionInfo{ 290, nullptr, "ProxyProcedureForGuestLoginWithNintendoAccount"},
{ 291, nullptr, "ProxyProcedureForFloatingRegistrationWithNintendoAccount"}, FunctionInfo{ 291, nullptr, "ProxyProcedureForFloatingRegistrationWithNintendoAccount"},
{ 292, nullptr, "ProxyProcedureForDeviceMigrationAuthenticatingOperatingUser"}, FunctionInfo{ 292, nullptr, "ProxyProcedureForDeviceMigrationAuthenticatingOperatingUser"},
{ 293, nullptr, "ProxyProcedureForDeviceMigrationDownload"}, FunctionInfo{ 293, nullptr, "ProxyProcedureForDeviceMigrationDownload"},
{ 299, nullptr, "SuspendBackgroundDaemon"}, FunctionInfo{ 299, nullptr, "SuspendBackgroundDaemon"},
{ 350, nullptr, "CreateDeviceMigrationUserExportRequest"}, FunctionInfo{ 350, nullptr, "CreateDeviceMigrationUserExportRequest"},
{ 351, nullptr, "UploadNasCredential"}, FunctionInfo{ 351, nullptr, "UploadNasCredential"},
{ 352, nullptr, "CreateDeviceMigrationUserImportRequest"}, FunctionInfo{ 352, nullptr, "CreateDeviceMigrationUserImportRequest"},
{ 353, nullptr, "DeleteUserMigrationSaveData"}, FunctionInfo{ 353, nullptr, "DeleteUserMigrationSaveData"},
{ 400, nullptr, "SetPinCode"}, FunctionInfo{ 400, nullptr, "SetPinCode"},
{ 401, nullptr, "GetPinCodeLength"}, FunctionInfo{ 401, nullptr, "GetPinCodeLength"},
{ 402, nullptr, "GetPinCode"}, FunctionInfo{ 402, nullptr, "GetPinCode"},
{ 403, nullptr, "GetPinCodeParity"}, FunctionInfo{ 403, nullptr, "GetPinCodeParity"},
{ 404, nullptr, "VerifyPinCode"}, FunctionInfo{ 404, nullptr, "VerifyPinCode"},
{ 405, nullptr, "IsPinCodeVerificationForbidden"}, FunctionInfo{ 405, nullptr, "IsPinCodeVerificationForbidden"},
{ 410, nullptr, "GetPinCodeErrorCount"}, FunctionInfo{ 410, nullptr, "GetPinCodeErrorCount"},
{ 411, nullptr, "ResetPinCodeErrorCount"}, FunctionInfo{ 411, nullptr, "ResetPinCodeErrorCount"},
{ 412, nullptr, "IncrementPinCodeErrorCount"}, FunctionInfo{ 412, nullptr, "IncrementPinCodeErrorCount"},
{ 413, nullptr, "SetPinCodeErrorCount"}, FunctionInfo{ 413, nullptr, "SetPinCodeErrorCount"},
{ 420, nullptr, "SetStartPenaltyTime"}, FunctionInfo{ 420, nullptr, "SetStartPenaltyTime"},
{ 421, nullptr, "GetStartPenaltyTime"}, FunctionInfo{ 421, nullptr, "GetStartPenaltyTime"},
{ 900, nullptr, "SetUserUnqualifiedForDebug"}, FunctionInfo{ 900, nullptr, "SetUserUnqualifiedForDebug"},
{ 901, nullptr, "UnsetUserUnqualifiedForDebug"}, FunctionInfo{ 901, nullptr, "UnsetUserUnqualifiedForDebug"},
{ 902, nullptr, "ListUsersUnqualifiedForDebug"}, FunctionInfo{ 902, nullptr, "ListUsersUnqualifiedForDebug"},
{ 910, nullptr, "RefreshFirmwareSettingsForDebug"}, FunctionInfo{ 910, nullptr, "RefreshFirmwareSettingsForDebug"},
{ 997, nullptr, "DebugInvalidateTokenCacheForUser"}, FunctionInfo{ 997, nullptr, "DebugInvalidateTokenCacheForUser"},
{ 998, nullptr, "DebugSetUserStateClose"}, FunctionInfo{ 998, nullptr, "DebugSetUserStateClose"},
{ 999, nullptr, "DebugSetUserStateOpen"}, FunctionInfo{ 999, nullptr, "DebugSetUserStateOpen"},
{ 1000, nullptr, "CreateIAccountEntityServiceForApplication"}, FunctionInfo{ 1000, nullptr, "CreateIAccountEntityServiceForApplication"},
{ 1100, nullptr, "CreateIUserStateManager"}, FunctionInfo{ 1100, nullptr, "CreateIUserStateManager"},
{ 10050, nullptr, "IsUserRegistrationRequestPermittedForAccountPolicy"}, FunctionInfo{ 10050, nullptr, "IsUserRegistrationRequestPermittedForAccountPolicy"},
{ 10105, nullptr, "CheckNetworkServiceAvailabilityAsyncForAccountPolicy"} FunctionInfo{ 10105, nullptr, "CheckNetworkServiceAvailabilityAsyncForAccountPolicy"}
); );
} }
}; };
+5 -6
View File
@@ -20,7 +20,10 @@ namespace Service::BtDrv {
class IBluetoothUser final : public ServiceFramework<IBluetoothUser> { class IBluetoothUser final : public ServiceFramework<IBluetoothUser> {
public: public:
explicit IBluetoothUser(Core::System& system_) explicit IBluetoothUser(Core::System& system_)
: ServiceFramework{system_, "bt"}, service_context{system_, "bt"} {} : ServiceFramework{system_, "bt"}
, service_context{system_, "bt"} {
register_event = service_context.CreateEvent("BT:RegisterEvent");
}
FunctionInfoBase const* FindRequest(u32 key) override { FunctionInfoBase const* FindRequest(u32 key) override {
return HandlerTableGenerateWithFind(key, return HandlerTableGenerateWithFind(key,
@@ -34,11 +37,7 @@ public:
FunctionInfo{7, nullptr, "LeSendIndication"}, FunctionInfo{7, nullptr, "LeSendIndication"},
FunctionInfo{8, nullptr, "GetLeEventInfo"}, FunctionInfo{8, nullptr, "GetLeEventInfo"},
FunctionInfo{9, C<&IBluetoothUser::RegisterBleEvent>, "RegisterBleEvent"} FunctionInfo{9, C<&IBluetoothUser::RegisterBleEvent>, "RegisterBleEvent"}
}; );
// clang-format on
RegisterHandlers(functions);
register_event = service_context.CreateEvent("BT:RegisterEvent");
} }
~IBluetoothUser() override { ~IBluetoothUser() override {
+1 -1
View File
@@ -107,7 +107,7 @@ public:
FunctionInfo{114, nullptr, "IsFirstAudioControlConnection"}, //14.0.0+ FunctionInfo{114, nullptr, "IsFirstAudioControlConnection"}, //14.0.0+
FunctionInfo{115, nullptr, "GetShortenedDeviceCondition"}, //14.0.0+ FunctionInfo{115, nullptr, "GetShortenedDeviceCondition"}, //14.0.0+
FunctionInfo{116, nullptr, "SetAudioSinkVolume"}, //15.0.0+ FunctionInfo{116, nullptr, "SetAudioSinkVolume"}, //15.0.0+
FunctionInfo{117, nullptr, "GetAudioSinkVolume"}, //15.0.0+ FunctionInfo{117, nullptr, "GetAudioSinkVolume"} //15.0.0+
); );
} }
}; };
+5 -7
View File
@@ -18,7 +18,10 @@ constexpr Result ERROR_INVALID_RIGHTS_ID{ErrorModule::ETicket, 3};
class ETicket final : public ServiceFramework<ETicket> { class ETicket final : public ServiceFramework<ETicket> {
public: public:
explicit ETicket(Core::System& system_) : ServiceFramework{system_, "es"} {} explicit ETicket(Core::System& system_) : ServiceFramework{system_, "es"} {
keys.PopulateTickets();
keys.SynthesizeTickets();
}
FunctionInfoBase const* FindRequest(u32 key) override { FunctionInfoBase const* FindRequest(u32 key) override {
return HandlerTableGenerateWithFind(key, return HandlerTableGenerateWithFind(key,
@@ -116,12 +119,7 @@ public:
FunctionInfo{2601, nullptr, "Unknown2601"}, FunctionInfo{2601, nullptr, "Unknown2601"},
FunctionInfo{3001, nullptr, "Unknown3001"}, FunctionInfo{3001, nullptr, "Unknown3001"},
FunctionInfo{3002, nullptr, "Unknown3002"} FunctionInfo{3002, nullptr, "Unknown3002"}
}; );
// clang-format on
RegisterHandlers(functions);
keys.PopulateTickets();
keys.SynthesizeTickets();
} }
private: private:
+19 -23
View File
@@ -21,7 +21,9 @@ namespace Service::Friend {
class IFriendService final : public ServiceFramework<IFriendService> { class IFriendService final : public ServiceFramework<IFriendService> {
public: public:
explicit IFriendService(Core::System& system_) explicit IFriendService(Core::System& system_)
: ServiceFramework{system_, "IFriendService"}, service_context{system, "IFriendService"} {} : ServiceFramework{system_, "IFriendService"}, service_context{system, "IFriendService"} {
completion_event = service_context.CreateEvent("IFriendService:CompletionEvent");
}
FunctionInfoBase const* FindRequest(u32 key) override { FunctionInfoBase const* FindRequest(u32 key) override {
return HandlerTableGenerateWithFind(key, return HandlerTableGenerateWithFind(key,
@@ -137,12 +139,7 @@ public:
FunctionInfo{40100, nullptr, "DeleteFriendListCache"}, FunctionInfo{40100, nullptr, "DeleteFriendListCache"},
FunctionInfo{40400, nullptr, "DeleteBlockedUserListCache"}, FunctionInfo{40400, nullptr, "DeleteBlockedUserListCache"},
FunctionInfo{49900, nullptr, "DeleteNetworkServiceAccountCache"} FunctionInfo{49900, nullptr, "DeleteNetworkServiceAccountCache"}
}; );
// clang-format on
RegisterHandlers(functions);
completion_event = service_context.CreateEvent("IFriendService:CompletionEvent");
} }
~IFriendService() override { ~IFriendService() override {
@@ -376,20 +373,17 @@ private:
class INotificationService final : public ServiceFramework<INotificationService> { class INotificationService final : public ServiceFramework<INotificationService> {
public: public:
explicit INotificationService(Core::System& system_, Common::UUID uuid_) explicit INotificationService(Core::System& system_, Common::UUID uuid_)
: ServiceFramework{system_, "INotificationService"}, uuid{uuid_}, : ServiceFramework{system_, "INotificationService"}, uuid{uuid_}
service_context{system_, "INotificationService"} {} , service_context{system_, "INotificationService"} {
notification_event = service_context.CreateEvent("INotificationService:NotifyEvent");
}
FunctionInfoBase const* FindRequest(u32 key) override { FunctionInfoBase const* FindRequest(u32 key) override {
return HandlerTableGenerateWithFind(key, return HandlerTableGenerateWithFind(key,
FunctionInfo{0, &INotificationService::GetEvent, "GetEvent"}, FunctionInfo{0, &INotificationService::GetEvent, "GetEvent"},
FunctionInfo{1, &INotificationService::Clear, "Clear"}, FunctionInfo{1, &INotificationService::Clear, "Clear"},
FunctionInfo{2, &INotificationService::Pop, "Pop"} FunctionInfo{2, &INotificationService::Pop, "Pop"}
}; );
// clang-format on
RegisterHandlers(functions);
notification_event = service_context.CreateEvent("INotificationService:NotifyEvent");
} }
~INotificationService() override { ~INotificationService() override {
@@ -503,12 +497,13 @@ class IServiceForApplication final : public ServiceFramework<IServiceForApplicat
public: public:
explicit IServiceForApplication(Core::System& system_) explicit IServiceForApplication(Core::System& system_)
: ServiceFramework{system_, "nd:app"} : ServiceFramework{system_, "nd:app"}
{ {}
static const FunctionInfo functions[] = {
FunctionInfoBase const* FindRequest(u32 key) override {
return HandlerTableGenerateWithFind(key,
FunctionInfo{0, nullptr, "GetReceivableNeighborInfoCountMax"}, FunctionInfo{0, nullptr, "GetReceivableNeighborInfoCountMax"},
FunctionInfo{10, nullptr, "IsNeighborDetectionEnabled"} FunctionInfo{10, nullptr, "IsNeighborDetectionEnabled"}
}; );
RegisterHandlers(functions);
} }
}; };
@@ -516,8 +511,10 @@ class IServiceForSystem final : public ServiceFramework<IServiceForSystem> {
public: public:
explicit IServiceForSystem(Core::System& system_) explicit IServiceForSystem(Core::System& system_)
: ServiceFramework{system_, "nd:sys"} : ServiceFramework{system_, "nd:sys"}
{ {}
static const FunctionInfo functions[] = {
FunctionInfoBase const* FindRequest(u32 key) override {
return HandlerTableGenerateWithFind(key,
FunctionInfo{0, nullptr, "GetReceivableNeighborInfoCountMax"}, FunctionInfo{0, nullptr, "GetReceivableNeighborInfoCountMax"},
FunctionInfo{10, nullptr, "IsNeighborDetectionEnabled"}, FunctionInfo{10, nullptr, "IsNeighborDetectionEnabled"},
FunctionInfo{200, nullptr, "SetSystemData"}, FunctionInfo{200, nullptr, "SetSystemData"},
@@ -555,8 +552,7 @@ public:
FunctionInfo{310, nullptr, "SetApplicationDataForDebug"}, FunctionInfo{310, nullptr, "SetApplicationDataForDebug"},
FunctionInfo{400, nullptr, "GetNetworkUserId"}, FunctionInfo{400, nullptr, "GetNetworkUserId"},
FunctionInfo{401, nullptr, "DeleteNetworkUserId"} FunctionInfo{401, nullptr, "DeleteNetworkUserId"}
}; );
RegisterHandlers(functions);
} }
}; };
+5 -9
View File
@@ -178,19 +178,15 @@ class INotificationSystemEventAccessor final
: public ServiceFramework<INotificationSystemEventAccessor> { : public ServiceFramework<INotificationSystemEventAccessor> {
public: public:
explicit INotificationSystemEventAccessor(Core::System& system_) explicit INotificationSystemEventAccessor(Core::System& system_)
: ServiceFramework{system_, "INotificationSystemEventAccessor"}, : ServiceFramework{system_, "INotificationSystemEventAccessor"}
service_context{system_, "INotificationSystemEventAccessor"} {} , service_context{system_, "INotificationSystemEventAccessor"} {
notification_event = service_context.CreateEvent("INotificationSystemEventAccessor:NotificationEvent");
}
FunctionInfoBase const* FindRequest(u32 key) override { FunctionInfoBase const* FindRequest(u32 key) override {
return HandlerTableGenerateWithFind(key, return HandlerTableGenerateWithFind(key,
FunctionInfo{0, D<&INotificationSystemEventAccessor::GetSystemEvent>, "GetSystemEvent"} FunctionInfo{0, D<&INotificationSystemEventAccessor::GetSystemEvent>, "GetSystemEvent"}
}; );
// clang-format on
RegisterHandlers(functions);
notification_event =
service_context.CreateEvent("INotificationSystemEventAccessor:NotificationEvent");
} }
~INotificationSystemEventAccessor() { ~INotificationSystemEventAccessor() {
+9 -13
View File
@@ -37,19 +37,6 @@ public:
, user_ro{std::move(user_ro_)} , user_ro{std::move(user_ro_)}
, context{process_->GetMemory()} , context{process_->GetMemory()}
{ {
FunctionInfoBase const* FindRequest(u32 key) override {
return HandlerTableGenerateWithFind(key,
FunctionInfo{0, C<&IJitEnvironment::GenerateCode>, "GenerateCode"},
FunctionInfo{1, C<&IJitEnvironment::Control>, "Control"},
FunctionInfo{1000, C<&IJitEnvironment::LoadPlugin>, "LoadPlugin"},
FunctionInfo{1001, C<&IJitEnvironment::GetCodeAddress>, "GetCodeAddress"}
};
// clang-format on
RegisterHandlers(functions);
// Identity map user code range into sysmodule context // Identity map user code range into sysmodule context
configuration.user_rx_memory.size = user_rx.GetSize(); configuration.user_rx_memory.size = user_rx.GetSize();
configuration.user_rx_memory.offset = user_rx.GetAddress(); configuration.user_rx_memory.offset = user_rx.GetAddress();
@@ -60,6 +47,15 @@ public:
configuration.sys_ro_memory = configuration.user_ro_memory; configuration.sys_ro_memory = configuration.user_ro_memory;
} }
FunctionInfoBase const* FindRequest(u32 key) override {
return HandlerTableGenerateWithFind(key,
FunctionInfo{0, C<&IJitEnvironment::GenerateCode>, "GenerateCode"},
FunctionInfo{1, C<&IJitEnvironment::Control>, "Control"},
FunctionInfo{1000, C<&IJitEnvironment::LoadPlugin>, "LoadPlugin"},
FunctionInfo{1001, C<&IJitEnvironment::GetCodeAddress>, "GetCodeAddress"}
);
}
~IJitEnvironment() { ~IJitEnvironment() {
user_rx.Finalize(system.Kernel()); user_rx.Finalize(system.Kernel());
user_ro.Finalize(system.Kernel()); user_ro.Finalize(system.Kernel());
+1 -1
View File
@@ -53,7 +53,7 @@ public:
FunctionInfo{2300, nullptr, "Unknown2300"}, //20.0.0+ FunctionInfo{2300, nullptr, "Unknown2300"}, //20.0.0+
FunctionInfo{2310, nullptr, "Unknown2310"}, //20.0.0+ FunctionInfo{2310, nullptr, "Unknown2310"}, //20.0.0+
FunctionInfo{2400, nullptr, "Unknown2400"}, //20.0.0+ FunctionInfo{2400, nullptr, "Unknown2400"}, //20.0.0+
FunctionInfo{2420, nullptr, "Unknown2420"}, //20.0.0+ FunctionInfo{2420, nullptr, "Unknown2420"} //20.0.0+
); );
} }
}; };
+8 -12
View File
@@ -24,10 +24,13 @@ namespace Service::Mii {
class IDatabaseService final : public ServiceFramework<IDatabaseService> { class IDatabaseService final : public ServiceFramework<IDatabaseService> {
public: public:
explicit IDatabaseService(Core::System& system_, std::shared_ptr<MiiManager> mii_manager, explicit IDatabaseService(Core::System& system_, std::shared_ptr<MiiManager> mii_manager, bool is_system_)
bool is_system_) : ServiceFramework{system_, "IDatabaseService"}
: ServiceFramework{system_, "IDatabaseService"}, manager{mii_manager}, is_system{ , manager{mii_manager}
is_system_} {} , is_system{is_system_} {
m_set_sys = system.ServiceManager().GetService<Service::Set::ISystemSettingsServer>("set:sys", true);
manager->Initialize(metadata);
}
FunctionInfoBase const* FindRequest(u32 key) override { FunctionInfoBase const* FindRequest(u32 key) override {
return HandlerTableGenerateWithFind(key, return HandlerTableGenerateWithFind(key,
@@ -58,14 +61,7 @@ public:
FunctionInfo{24, D<&IDatabaseService::ConvertCoreDataToCharInfo>, "ConvertCoreDataToCharInfo"}, FunctionInfo{24, D<&IDatabaseService::ConvertCoreDataToCharInfo>, "ConvertCoreDataToCharInfo"},
FunctionInfo{25, D<&IDatabaseService::ConvertCharInfoToCoreData>, "ConvertCharInfoToCoreData"}, FunctionInfo{25, D<&IDatabaseService::ConvertCharInfoToCoreData>, "ConvertCharInfoToCoreData"},
FunctionInfo{26, D<&IDatabaseService::Append>, "Append"} FunctionInfo{26, D<&IDatabaseService::Append>, "Append"}
}; );
// clang-format on
RegisterHandlers(functions);
m_set_sys = system.ServiceManager().GetService<Service::Set::ISystemSettingsServer>(
"set:sys", true);
manager->Initialize(metadata);
} }
private: private:
+72 -75
View File
@@ -18,69 +18,67 @@ namespace Service::NFC {
class IUser final : public NfcInterface { class IUser final : public NfcInterface {
public: public:
explicit IUser(Core::System& system_) : NfcInterface(system_, "NFC::IUser", BackendType::Nfc) {} explicit IUser(Core::System& system_) : NfcInterface(system_, "NFC::IUser", BackendType::Nfc) {
static const FunctionInfoTyped<IUser> functions[] = {
FunctionInfoBase const* FindRequest(u32 key) override { {0, &NfcInterface::Initialize, "InitializeOld"},
return HandlerTableGenerateWithFind(key, {1, &NfcInterface::Finalize, "FinalizeOld"},
FunctionInfo{0, &NfcInterface::Initialize, "InitializeOld"}, {2, &NfcInterface::GetState, "GetStateOld"},
FunctionInfo{1, &NfcInterface::Finalize, "FinalizeOld"}, {3, &NfcInterface::IsNfcEnabled, "IsNfcEnabledOld"},
FunctionInfo{2, &NfcInterface::GetState, "GetStateOld"}, {400, &NfcInterface::Initialize, "Initialize"},
FunctionInfo{3, &NfcInterface::IsNfcEnabled, "IsNfcEnabledOld"}, {401, &NfcInterface::Finalize, "Finalize"},
FunctionInfo{400, &NfcInterface::Initialize, "Initialize"}, {402, &NfcInterface::GetState, "GetState"},
FunctionInfo{401, &NfcInterface::Finalize, "Finalize"}, {403, &NfcInterface::IsNfcEnabled, "IsNfcEnabled"},
FunctionInfo{402, &NfcInterface::GetState, "GetState"}, {404, &NfcInterface::ListDevices, "ListDevices"},
FunctionInfo{403, &NfcInterface::IsNfcEnabled, "IsNfcEnabled"}, {405, &NfcInterface::GetDeviceState, "GetDeviceState"},
FunctionInfo{404, &NfcInterface::ListDevices, "ListDevices"}, {406, &NfcInterface::GetNpadId, "GetNpadId"},
FunctionInfo{405, &NfcInterface::GetDeviceState, "GetDeviceState"}, {407, &NfcInterface::AttachAvailabilityChangeEvent, "AttachAvailabilityChangeEvent"},
FunctionInfo{406, &NfcInterface::GetNpadId, "GetNpadId"}, {408, &NfcInterface::StartDetection, "StartDetection"},
FunctionInfo{407, &NfcInterface::AttachAvailabilityChangeEvent, "AttachAvailabilityChangeEvent"}, {409, &NfcInterface::StopDetection, "StopDetection"},
FunctionInfo{408, &NfcInterface::StartDetection, "StartDetection"}, {410, &NfcInterface::GetTagInfo, "GetTagInfo"},
FunctionInfo{409, &NfcInterface::StopDetection, "StopDetection"}, {411, &NfcInterface::AttachActivateEvent, "AttachActivateEvent"},
FunctionInfo{410, &NfcInterface::GetTagInfo, "GetTagInfo"}, {412, &NfcInterface::AttachDeactivateEvent, "AttachDeactivateEvent"},
FunctionInfo{411, &NfcInterface::AttachActivateEvent, "AttachActivateEvent"}, {1000, &NfcInterface::ReadMifare, "ReadMifare"},
FunctionInfo{412, &NfcInterface::AttachDeactivateEvent, "AttachDeactivateEvent"}, {1001, &NfcInterface::WriteMifare ,"WriteMifare"},
FunctionInfo{1000, &NfcInterface::ReadMifare, "ReadMifare"}, {1300, &NfcInterface::SendCommandByPassThrough, "SendCommandByPassThrough"},
FunctionInfo{1001, &NfcInterface::WriteMifare ,"WriteMifare"}, {1301, nullptr, "KeepPassThroughSession"},
FunctionInfo{1300, &NfcInterface::SendCommandByPassThrough, "SendCommandByPassThrough"}, {1302, nullptr, "ReleasePassThroughSession"}
FunctionInfo{1301, nullptr, "KeepPassThroughSession"}, };
FunctionInfo{1302, nullptr, "ReleasePassThroughSession"} RegisterHandlers(functions);
);
} }
}; };
class ISystem final : public NfcInterface { class ISystem final : public NfcInterface {
public: public:
explicit ISystem(Core::System& system_) explicit ISystem(Core::System& system_)
: NfcInterface{system_, "NFC::ISystem", BackendType::Nfc} {} : NfcInterface{system_, "NFC::ISystem", BackendType::Nfc} {
static const FunctionInfoTyped<ISystem> functions[] = {
FunctionInfoBase const* FindRequest(u32 key) override { {0, &NfcInterface::Initialize, "InitializeOld"},
return HandlerTableGenerateWithFind(key, {1, &NfcInterface::Finalize, "FinalizeOld"},
FunctionInfo{0, &NfcInterface::Initialize, "InitializeOld"}, {2, &NfcInterface::GetState, "GetStateOld"},
FunctionInfo{1, &NfcInterface::Finalize, "FinalizeOld"}, {3, &NfcInterface::IsNfcEnabled, "IsNfcEnabledOld"},
FunctionInfo{2, &NfcInterface::GetState, "GetStateOld"}, {100, &NfcInterface::SetNfcEnabled, "SetNfcEnabledOld"},
FunctionInfo{3, &NfcInterface::IsNfcEnabled, "IsNfcEnabledOld"}, {400, &NfcInterface::Initialize, "Initialize"},
FunctionInfo{100, &NfcInterface::SetNfcEnabled, "SetNfcEnabledOld"}, {401, &NfcInterface::Finalize, "Finalize"},
FunctionInfo{400, &NfcInterface::Initialize, "Initialize"}, {402, &NfcInterface::GetState, "GetState"},
FunctionInfo{401, &NfcInterface::Finalize, "Finalize"}, {403, &NfcInterface::IsNfcEnabled, "IsNfcEnabled"},
FunctionInfo{402, &NfcInterface::GetState, "GetState"}, {404, &NfcInterface::ListDevices, "ListDevices"},
FunctionInfo{403, &NfcInterface::IsNfcEnabled, "IsNfcEnabled"}, {405, &NfcInterface::GetDeviceState, "GetDeviceState"},
FunctionInfo{404, &NfcInterface::ListDevices, "ListDevices"}, {406, &NfcInterface::GetNpadId, "GetNpadId"},
FunctionInfo{405, &NfcInterface::GetDeviceState, "GetDeviceState"}, {407, &NfcInterface::AttachAvailabilityChangeEvent, "AttachAvailabilityChangeEvent"},
FunctionInfo{406, &NfcInterface::GetNpadId, "GetNpadId"}, {408, &NfcInterface::StartDetection, "StartDetection"},
FunctionInfo{407, &NfcInterface::AttachAvailabilityChangeEvent, "AttachAvailabilityChangeEvent"}, {409, &NfcInterface::StopDetection, "StopDetection"},
FunctionInfo{408, &NfcInterface::StartDetection, "StartDetection"}, {410, &NfcInterface::GetTagInfo, "GetTagInfo"},
FunctionInfo{409, &NfcInterface::StopDetection, "StopDetection"}, {411, &NfcInterface::AttachActivateEvent, "AttachActivateEvent"},
FunctionInfo{410, &NfcInterface::GetTagInfo, "GetTagInfo"}, {412, &NfcInterface::AttachDeactivateEvent, "AttachDeactivateEvent"},
FunctionInfo{411, &NfcInterface::AttachActivateEvent, "AttachActivateEvent"}, {500, &NfcInterface::SetNfcEnabled, "SetNfcEnabled"},
FunctionInfo{412, &NfcInterface::AttachDeactivateEvent, "AttachDeactivateEvent"}, {510, nullptr, "OutputTestWave"},
FunctionInfo{500, &NfcInterface::SetNfcEnabled, "SetNfcEnabled"}, {1000, &NfcInterface::ReadMifare, "ReadMifare"},
FunctionInfo{510, nullptr, "OutputTestWave"}, {1001, &NfcInterface::WriteMifare, "WriteMifare"},
FunctionInfo{1000, &NfcInterface::ReadMifare, "ReadMifare"}, {1300, &NfcInterface::SendCommandByPassThrough, "SendCommandByPassThrough"},
FunctionInfo{1001, &NfcInterface::WriteMifare, "WriteMifare"}, {1301, nullptr, "KeepPassThroughSession"},
FunctionInfo{1300, &NfcInterface::SendCommandByPassThrough, "SendCommandByPassThrough"}, {1302, nullptr, "ReleasePassThroughSession"}
FunctionInfo{1301, nullptr, "KeepPassThroughSession"}, };
FunctionInfo{1302, nullptr, "ReleasePassThroughSession"} RegisterHandlers(functions);
);
} }
}; };
@@ -89,25 +87,24 @@ public:
using MFInterface = NfcInterface; using MFInterface = NfcInterface;
class MFIUser final : public MFInterface { class MFIUser final : public MFInterface {
public: public:
explicit MFIUser(Core::System& system_) explicit MFIUser(Core::System& system_) : MFInterface{system_, "NFC::MFInterface", BackendType::Mifare} {
: MFInterface{system_, "NFC::MFInterface", BackendType::Mifare} {
// clang-format off
static const FunctionInfoTyped<MFIUser> functions[] = { static const FunctionInfoTyped<MFIUser> functions[] = {
FunctionInfo{0, &MFIUser::Initialize, "Initialize"}, {0, &MFIUser::Initialize, "Initialize"},
FunctionInfo{1, &MFIUser::Finalize, "Finalize"}, {1, &MFIUser::Finalize, "Finalize"},
FunctionInfo{2, &MFIUser::ListDevices, "ListDevices"}, {2, &MFIUser::ListDevices, "ListDevices"},
FunctionInfo{3, &MFIUser::StartDetection, "StartDetection"}, {3, &MFIUser::StartDetection, "StartDetection"},
FunctionInfo{4, &MFIUser::StopDetection, "StopDetection"}, {4, &MFIUser::StopDetection, "StopDetection"},
FunctionInfo{5, &MFIUser::ReadMifare, "Read"}, {5, &MFIUser::ReadMifare, "Read"},
FunctionInfo{6, &MFIUser::WriteMifare, "Write"}, {6, &MFIUser::WriteMifare, "Write"},
FunctionInfo{7, &MFIUser::GetTagInfo, "GetTagInfo"}, {7, &MFIUser::GetTagInfo, "GetTagInfo"},
FunctionInfo{8, &MFIUser::AttachActivateEvent, "GetActivateEventHandle"}, {8, &MFIUser::AttachActivateEvent, "GetActivateEventHandle"},
FunctionInfo{9, &MFIUser::AttachDeactivateEvent, "GetDeactivateEventHandle"}, {9, &MFIUser::AttachDeactivateEvent, "GetDeactivateEventHandle"},
FunctionInfo{10, &MFIUser::GetState, "GetState"}, {10, &MFIUser::GetState, "GetState"},
FunctionInfo{11, &MFIUser::GetDeviceState, "GetDeviceState"}, {11, &MFIUser::GetDeviceState, "GetDeviceState"},
FunctionInfo{12, &MFIUser::GetNpadId, "GetNpadId"}, {12, &MFIUser::GetNpadId, "GetNpadId"},
FunctionInfo{13, &MFIUser::AttachAvailabilityChangeEvent, "GetAvailabilityChangeEventHandle"} {13, &MFIUser::AttachAvailabilityChangeEvent, "GetAvailabilityChangeEventHandle"}
); };
RegisterHandlers(functions);
} }
}; };
+100 -100
View File
@@ -15,121 +15,121 @@ namespace Service::NFP {
class IUser final : public Interface { class IUser final : public Interface {
public: public:
explicit IUser(Core::System& system_) : Interface(system_, "NFP:IUser") { explicit IUser(Core::System& system_) : Interface(system_, "NFP:IUser") {
// clang-format off
static const FunctionInfoTyped<IUser> functions[] = { static const FunctionInfoTyped<IUser> functions[] = {
FunctionInfo{0, &IUser::Initialize, "Initialize"}, {0, &IUser::Initialize, "Initialize"},
FunctionInfo{1, &IUser::Finalize, "Finalize"}, {1, &IUser::Finalize, "Finalize"},
FunctionInfo{2, &IUser::ListDevices, "ListDevices"}, {2, &IUser::ListDevices, "ListDevices"},
FunctionInfo{3, &IUser::StartDetection, "StartDetection"}, {3, &IUser::StartDetection, "StartDetection"},
FunctionInfo{4, &IUser::StopDetection, "StopDetection"}, {4, &IUser::StopDetection, "StopDetection"},
FunctionInfo{5, &IUser::Mount, "Mount"}, {5, &IUser::Mount, "Mount"},
FunctionInfo{6, &IUser::Unmount, "Unmount"}, {6, &IUser::Unmount, "Unmount"},
FunctionInfo{7, &IUser::OpenApplicationArea, "OpenApplicationArea"}, {7, &IUser::OpenApplicationArea, "OpenApplicationArea"},
FunctionInfo{8, &IUser::GetApplicationArea, "GetApplicationArea"}, {8, &IUser::GetApplicationArea, "GetApplicationArea"},
FunctionInfo{9, &IUser::SetApplicationArea, "SetApplicationArea"}, {9, &IUser::SetApplicationArea, "SetApplicationArea"},
FunctionInfo{10, &IUser::Flush, "Flush"}, {10, &IUser::Flush, "Flush"},
FunctionInfo{11, &IUser::Restore, "Restore"}, {11, &IUser::Restore, "Restore"},
FunctionInfo{12, &IUser::CreateApplicationArea, "CreateApplicationArea"}, {12, &IUser::CreateApplicationArea, "CreateApplicationArea"},
FunctionInfo{13, &IUser::GetTagInfo, "GetTagInfo"}, {13, &IUser::GetTagInfo, "GetTagInfo"},
FunctionInfo{14, &IUser::GetRegisterInfo, "GetRegisterInfo"}, {14, &IUser::GetRegisterInfo, "GetRegisterInfo"},
FunctionInfo{15, &IUser::GetCommonInfo, "GetCommonInfo"}, {15, &IUser::GetCommonInfo, "GetCommonInfo"},
FunctionInfo{16, &IUser::GetModelInfo, "GetModelInfo"}, {16, &IUser::GetModelInfo, "GetModelInfo"},
FunctionInfo{17, &IUser::AttachActivateEvent, "AttachActivateEvent"}, {17, &IUser::AttachActivateEvent, "AttachActivateEvent"},
FunctionInfo{18, &IUser::AttachDeactivateEvent, "AttachDeactivateEvent"}, {18, &IUser::AttachDeactivateEvent, "AttachDeactivateEvent"},
FunctionInfo{19, &IUser::GetState, "GetState"}, {19, &IUser::GetState, "GetState"},
FunctionInfo{20, &IUser::GetDeviceState, "GetDeviceState"}, {20, &IUser::GetDeviceState, "GetDeviceState"},
FunctionInfo{21, &IUser::GetNpadId, "GetNpadId"}, {21, &IUser::GetNpadId, "GetNpadId"},
FunctionInfo{22, &IUser::GetApplicationAreaSize, "GetApplicationAreaSize"}, {22, &IUser::GetApplicationAreaSize, "GetApplicationAreaSize"},
FunctionInfo{23, &IUser::AttachAvailabilityChangeEvent, "AttachAvailabilityChangeEvent"}, {23, &IUser::AttachAvailabilityChangeEvent, "AttachAvailabilityChangeEvent"},
FunctionInfo{24, &IUser::RecreateApplicationArea, "RecreateApplicationArea"}, {24, &IUser::RecreateApplicationArea, "RecreateApplicationArea"},
FunctionInfo{25, &IUser::StartDetection, "StartDetectionWithFilter"} {25, &IUser::StartDetection, "StartDetectionWithFilter"}
); };
RegisterHandlers(functions);
} }
}; };
class ISystem final : public Interface { class ISystem final : public Interface {
public: public:
explicit ISystem(Core::System& system_) : Interface(system_, "NFP:ISystem") { explicit ISystem(Core::System& system_) : Interface(system_, "NFP:ISystem") {
// clang-format off
static const FunctionInfoTyped<ISystem> functions[] = { static const FunctionInfoTyped<ISystem> functions[] = {
FunctionInfo{0, &ISystem::InitializeSystem, "InitializeSystem"}, {0, &ISystem::InitializeSystem, "InitializeSystem"},
FunctionInfo{1, &ISystem::FinalizeSystem, "FinalizeSystem"}, {1, &ISystem::FinalizeSystem, "FinalizeSystem"},
FunctionInfo{2, &ISystem::ListDevices, "ListDevices"}, {2, &ISystem::ListDevices, "ListDevices"},
FunctionInfo{3, &ISystem::StartDetection, "StartDetection"}, {3, &ISystem::StartDetection, "StartDetection"},
FunctionInfo{4, &ISystem::StopDetection, "StopDetection"}, {4, &ISystem::StopDetection, "StopDetection"},
FunctionInfo{5, &ISystem::Mount, "Mount"}, {5, &ISystem::Mount, "Mount"},
FunctionInfo{6, &ISystem::Unmount, "Unmount"}, {6, &ISystem::Unmount, "Unmount"},
FunctionInfo{10, &ISystem::Flush, "Flush"}, {10, &ISystem::Flush, "Flush"},
FunctionInfo{11, &ISystem::Restore, "Restore"}, {11, &ISystem::Restore, "Restore"},
FunctionInfo{12, &ISystem::CreateApplicationArea, "CreateApplicationArea"}, {12, &ISystem::CreateApplicationArea, "CreateApplicationArea"},
FunctionInfo{13, &ISystem::GetTagInfo, "GetTagInfo"}, {13, &ISystem::GetTagInfo, "GetTagInfo"},
FunctionInfo{14, &ISystem::GetRegisterInfo, "GetRegisterInfo"}, {14, &ISystem::GetRegisterInfo, "GetRegisterInfo"},
FunctionInfo{15, &ISystem::GetCommonInfo, "GetCommonInfo"}, {15, &ISystem::GetCommonInfo, "GetCommonInfo"},
FunctionInfo{16, &ISystem::GetModelInfo, "GetModelInfo"}, {16, &ISystem::GetModelInfo, "GetModelInfo"},
FunctionInfo{17, &ISystem::AttachActivateEvent, "AttachActivateEvent"}, {17, &ISystem::AttachActivateEvent, "AttachActivateEvent"},
FunctionInfo{18, &ISystem::AttachDeactivateEvent, "AttachDeactivateEvent"}, {18, &ISystem::AttachDeactivateEvent, "AttachDeactivateEvent"},
FunctionInfo{19, &ISystem::GetState, "GetState"}, {19, &ISystem::GetState, "GetState"},
FunctionInfo{20, &ISystem::GetDeviceState, "GetDeviceState"}, {20, &ISystem::GetDeviceState, "GetDeviceState"},
FunctionInfo{21, &ISystem::GetNpadId, "GetNpadId"}, {21, &ISystem::GetNpadId, "GetNpadId"},
FunctionInfo{23, &ISystem::AttachAvailabilityChangeEvent, "AttachAvailabilityChangeEvent"}, {23, &ISystem::AttachAvailabilityChangeEvent, "AttachAvailabilityChangeEvent"},
FunctionInfo{25, &ISystem::StartDetection, "StartDetectionWithFilter"}, {25, &ISystem::StartDetection, "StartDetectionWithFilter"},
FunctionInfo{100, &ISystem::Format, "Format"}, {100, &ISystem::Format, "Format"},
FunctionInfo{101, &ISystem::GetAdminInfo, "GetAdminInfo"}, {101, &ISystem::GetAdminInfo, "GetAdminInfo"},
FunctionInfo{102, &ISystem::GetRegisterInfoPrivate, "GetRegisterInfoPrivate"}, {102, &ISystem::GetRegisterInfoPrivate, "GetRegisterInfoPrivate"},
FunctionInfo{103, &ISystem::SetRegisterInfoPrivate, "SetRegisterInfoPrivate"}, {103, &ISystem::SetRegisterInfoPrivate, "SetRegisterInfoPrivate"},
FunctionInfo{104, &ISystem::DeleteRegisterInfo, "DeleteRegisterInfo"}, {104, &ISystem::DeleteRegisterInfo, "DeleteRegisterInfo"},
FunctionInfo{105, &ISystem::DeleteApplicationArea, "DeleteApplicationArea"}, {105, &ISystem::DeleteApplicationArea, "DeleteApplicationArea"},
FunctionInfo{106, &ISystem::ExistsApplicationArea, "ExistsApplicationArea"} {106, &ISystem::ExistsApplicationArea, "ExistsApplicationArea"}
); };
RegisterHandlers(functions);
} }
}; };
class IDebug final : public Interface { class IDebug final : public Interface {
public: public:
explicit IDebug(Core::System& system_) : Interface(system_, "NFP:IDebug") { explicit IDebug(Core::System& system_) : Interface(system_, "NFP:IDebug") {
// clang-format off
static const FunctionInfoTyped<IDebug> functions[] = { static const FunctionInfoTyped<IDebug> functions[] = {
FunctionInfo{0, &IDebug::InitializeDebug, "InitializeDebug"}, {0, &IDebug::InitializeDebug, "InitializeDebug"},
FunctionInfo{1, &IDebug::FinalizeDebug, "FinalizeDebug"}, {1, &IDebug::FinalizeDebug, "FinalizeDebug"},
FunctionInfo{2, &IDebug::ListDevices, "ListDevices"}, {2, &IDebug::ListDevices, "ListDevices"},
FunctionInfo{3, &IDebug::StartDetection, "StartDetection"}, {3, &IDebug::StartDetection, "StartDetection"},
FunctionInfo{4, &IDebug::StopDetection, "StopDetection"}, {4, &IDebug::StopDetection, "StopDetection"},
FunctionInfo{5, &IDebug::Mount, "Mount"}, {5, &IDebug::Mount, "Mount"},
FunctionInfo{6, &IDebug::Unmount, "Unmount"}, {6, &IDebug::Unmount, "Unmount"},
FunctionInfo{7, &IDebug::OpenApplicationArea, "OpenApplicationArea"}, {7, &IDebug::OpenApplicationArea, "OpenApplicationArea"},
FunctionInfo{8, &IDebug::GetApplicationArea, "GetApplicationArea"}, {8, &IDebug::GetApplicationArea, "GetApplicationArea"},
FunctionInfo{9, &IDebug::SetApplicationArea, "SetApplicationArea"}, {9, &IDebug::SetApplicationArea, "SetApplicationArea"},
FunctionInfo{10, &IDebug::Flush, "Flush"}, {10, &IDebug::Flush, "Flush"},
FunctionInfo{11, &IDebug::Restore, "Restore"}, {11, &IDebug::Restore, "Restore"},
FunctionInfo{12, &IDebug::CreateApplicationArea, "CreateApplicationArea"}, {12, &IDebug::CreateApplicationArea, "CreateApplicationArea"},
FunctionInfo{13, &IDebug::GetTagInfo, "GetTagInfo"}, {13, &IDebug::GetTagInfo, "GetTagInfo"},
FunctionInfo{14, &IDebug::GetRegisterInfo, "GetRegisterInfo"}, {14, &IDebug::GetRegisterInfo, "GetRegisterInfo"},
FunctionInfo{15, &IDebug::GetCommonInfo, "GetCommonInfo"}, {15, &IDebug::GetCommonInfo, "GetCommonInfo"},
FunctionInfo{16, &IDebug::GetModelInfo, "GetModelInfo"}, {16, &IDebug::GetModelInfo, "GetModelInfo"},
FunctionInfo{17, &IDebug::AttachActivateEvent, "AttachActivateEvent"}, {17, &IDebug::AttachActivateEvent, "AttachActivateEvent"},
FunctionInfo{18, &IDebug::AttachDeactivateEvent, "AttachDeactivateEvent"}, {18, &IDebug::AttachDeactivateEvent, "AttachDeactivateEvent"},
FunctionInfo{19, &IDebug::GetState, "GetState"}, {19, &IDebug::GetState, "GetState"},
FunctionInfo{20, &IDebug::GetDeviceState, "GetDeviceState"}, {20, &IDebug::GetDeviceState, "GetDeviceState"},
FunctionInfo{21, &IDebug::GetNpadId, "GetNpadId"}, {21, &IDebug::GetNpadId, "GetNpadId"},
FunctionInfo{22, &IDebug::GetApplicationAreaSize, "GetApplicationAreaSize"}, {22, &IDebug::GetApplicationAreaSize, "GetApplicationAreaSize"},
FunctionInfo{23, &IDebug::AttachAvailabilityChangeEvent, "AttachAvailabilityChangeEvent"}, {23, &IDebug::AttachAvailabilityChangeEvent, "AttachAvailabilityChangeEvent"},
FunctionInfo{24, &IDebug::RecreateApplicationArea, "RecreateApplicationArea"}, {24, &IDebug::RecreateApplicationArea, "RecreateApplicationArea"},
FunctionInfo{25, &IDebug::StartDetection, "StartDetectionWithFilter"}, {25, &IDebug::StartDetection, "StartDetectionWithFilter"},
FunctionInfo{100, &IDebug::Format, "Format"}, {100, &IDebug::Format, "Format"},
FunctionInfo{101, &IDebug::GetAdminInfo, "GetAdminInfo"}, {101, &IDebug::GetAdminInfo, "GetAdminInfo"},
FunctionInfo{102, &IDebug::GetRegisterInfoPrivate, "GetRegisterInfoPrivate"}, {102, &IDebug::GetRegisterInfoPrivate, "GetRegisterInfoPrivate"},
FunctionInfo{103, &IDebug::SetRegisterInfoPrivate, "SetRegisterInfoPrivate"}, {103, &IDebug::SetRegisterInfoPrivate, "SetRegisterInfoPrivate"},
FunctionInfo{104, &IDebug::DeleteRegisterInfo, "DeleteRegisterInfo"}, {104, &IDebug::DeleteRegisterInfo, "DeleteRegisterInfo"},
FunctionInfo{105, &IDebug::DeleteApplicationArea, "DeleteApplicationArea"}, {105, &IDebug::DeleteApplicationArea, "DeleteApplicationArea"},
FunctionInfo{106, &IDebug::ExistsApplicationArea, "ExistsApplicationArea"}, {106, &IDebug::ExistsApplicationArea, "ExistsApplicationArea"},
FunctionInfo{200, &IDebug::GetAll, "GetAll"}, {200, &IDebug::GetAll, "GetAll"},
FunctionInfo{201, &IDebug::SetAll, "SetAll"}, {201, &IDebug::SetAll, "SetAll"},
FunctionInfo{202, &IDebug::FlushDebug, "FlushDebug"}, {202, &IDebug::FlushDebug, "FlushDebug"},
FunctionInfo{203, &IDebug::BreakTag, "BreakTag"}, {203, &IDebug::BreakTag, "BreakTag"},
FunctionInfo{204, &IDebug::ReadBackupData, "ReadBackupData"}, {204, &IDebug::ReadBackupData, "ReadBackupData"},
FunctionInfo{205, &IDebug::WriteBackupData, "WriteBackupData"}, {205, &IDebug::WriteBackupData, "WriteBackupData"},
FunctionInfo{206, &IDebug::WriteNtf, "WriteNtf"} {206, &IDebug::WriteNtf, "WriteNtf"}
); };
RegisterHandlers(functions);
} }
}; };
+4 -4
View File
@@ -154,8 +154,8 @@ public:
FunctionInfoBase const* FindRequest(u32 key) override { FunctionInfoBase const* FindRequest(u32 key) override {
return HandlerTableGenerateWithFind(key, return HandlerTableGenerateWithFind(key,
{0 , nullptr, "Match"}, FunctionInfo{0, nullptr, "Match"},
{1 , nullptr, "Filter"}, FunctionInfo{1, nullptr, "Filter"},
FunctionInfo{100, nullptr, "ConfigureAutoUpdateSetting"}, FunctionInfo{100, nullptr, "ConfigureAutoUpdateSetting"},
FunctionInfo{101, nullptr, "RequestResourceUpdateCheck"}, FunctionInfo{101, nullptr, "RequestResourceUpdateCheck"},
FunctionInfo{110, nullptr, "Reload"}, FunctionInfo{110, nullptr, "Reload"},
@@ -212,7 +212,7 @@ public:
FunctionInfoBase const* FindRequest(u32 key) override { FunctionInfoBase const* FindRequest(u32 key) override {
return HandlerTableGenerateWithFind(key, return HandlerTableGenerateWithFind(key,
{0 , D<&IUserService::Cmd0>, "Cmd0"} FunctionInfo{0, D<&IUserService::Cmd0>, "Cmd0"}
); );
} }
Result Cmd0(u32 unk0, OutInterface<IUserShimScopedObject> out_interface) { Result Cmd0(u32 unk0, OutInterface<IUserShimScopedObject> out_interface) {
@@ -257,7 +257,7 @@ public:
FunctionInfoBase const* FindRequest(u32 key) override { FunctionInfoBase const* FindRequest(u32 key) override {
return HandlerTableGenerateWithFind(key, return HandlerTableGenerateWithFind(key,
{0 , D<&ISystemService::Cmd0>, "Cmd0"} FunctionInfo{0, D<&ISystemService::Cmd0>, "Cmd0"}
); );
} }
Result Cmd0(OutInterface<ISystemShimScopedObject> out_interface) { Result Cmd0(OutInterface<ISystemShimScopedObject> out_interface) {
+6 -9
View File
@@ -24,8 +24,10 @@ namespace Service::NIM {
class IShopServiceAsync final : public ServiceFramework<IShopServiceAsync> { class IShopServiceAsync final : public ServiceFramework<IShopServiceAsync> {
public: public:
explicit IShopServiceAsync(Core::System& system_) explicit IShopServiceAsync(Core::System& system_)
: ServiceFramework{system_, "IShopServiceAsync"}, : ServiceFramework{system_, "IShopServiceAsync"}
service_context{system_, "IShopServiceAsync"} {} , service_context{system_, "IShopServiceAsync"} {
completion_event = service_context.CreateEvent("IShopServiceAsync:Completion");
}
FunctionInfoBase const* FindRequest(u32 key) override { FunctionInfoBase const* FindRequest(u32 key) override {
return HandlerTableGenerateWithFind(key, return HandlerTableGenerateWithFind(key,
@@ -35,12 +37,7 @@ public:
FunctionInfo{3, D<&IShopServiceAsync::GetErrorCode>, "GetErrorCode"}, FunctionInfo{3, D<&IShopServiceAsync::GetErrorCode>, "GetErrorCode"},
FunctionInfo{4, D<&IShopServiceAsync::Request>, "Request"}, FunctionInfo{4, D<&IShopServiceAsync::Request>, "Request"},
FunctionInfo{5, D<&IShopServiceAsync::Prepare>, "Prepare"} FunctionInfo{5, D<&IShopServiceAsync::Prepare>, "Prepare"}
}; );
// clang-format on
RegisterHandlers(functions);
completion_event = service_context.CreateEvent("IShopServiceAsync:Completion");
} }
~IShopServiceAsync() override { ~IShopServiceAsync() override {
@@ -409,7 +406,7 @@ public:
FunctionInfo{2050, nullptr, "Unknown2050"}, //20.0.0+ FunctionInfo{2050, nullptr, "Unknown2050"}, //20.0.0+
FunctionInfo{2051, nullptr, "Unknown2051"}, //20.0.0+ FunctionInfo{2051, nullptr, "Unknown2051"}, //20.0.0+
FunctionInfo{3000, nullptr, "RequestLatestApplicationIcon"}, //17.0.0+ FunctionInfo{3000, nullptr, "RequestLatestApplicationIcon"}, //17.0.0+
FunctionInfo{3001, nullptr, "RequestDownloadIdbeLatestIconFile"}, //17.0.0+ FunctionInfo{3001, nullptr, "RequestDownloadIdbeLatestIconFile"} //17.0.0+
); );
} }
}; };
+1 -1
View File
@@ -88,7 +88,7 @@ public:
FunctionInfo{303, nullptr, "GetNotificationHistories"}, // 18.0.0+ FunctionInfo{303, nullptr, "GetNotificationHistories"}, // 18.0.0+
FunctionInfo{304, nullptr, "GetPersistentConnectionSummary"}, // 18.0.0+ FunctionInfo{304, nullptr, "GetPersistentConnectionSummary"}, // 18.0.0+
FunctionInfo{305, nullptr, "GetDigitalTwinSummary"}, // 18.0.0+ FunctionInfo{305, nullptr, "GetDigitalTwinSummary"}, // 18.0.0+
FunctionInfo{306, nullptr, "GetDigitalTwinValue"}, // 18.0.0+ FunctionInfo{306, nullptr, "GetDigitalTwinValue"} // 18.0.0+
); );
} }
+14 -16
View File
@@ -23,22 +23,20 @@ public:
FunctionInfoBase const* FindRequest(u32 key) override { FunctionInfoBase const* FindRequest(u32 key) override {
return HandlerTableGenerateWithFind(key, return HandlerTableGenerateWithFind(key,
{ 0, nullptr, "NotifyAppletEvent" }, FunctionInfo{ 0, nullptr, "NotifyAppletEvent" },
{ 2, nullptr, "NotifyOperationModeChangeEvent" }, FunctionInfo{ 2, nullptr, "NotifyOperationModeChangeEvent" },
{ 3, nullptr, "NotifyPowerStateChangeEvent" }, FunctionInfo{ 3, nullptr, "NotifyPowerStateChangeEvent" },
{ 4, nullptr, "NotifyClearAllEvent" }, FunctionInfo{ 4, nullptr, "NotifyClearAllEvent" },
{ 5, nullptr, "NotifyEventForDebug" }, FunctionInfo{ 5, nullptr, "NotifyEventForDebug" },
{ 6, nullptr, "SuspendUserAccountEventService" }, FunctionInfo{ 6, nullptr, "SuspendUserAccountEventService" },
{ 7, nullptr, "ResumeUserAccountEventService" }, FunctionInfo{ 7, nullptr, "ResumeUserAccountEventService" },
{ 8, nullptr, "NotifyLibraryAppletEvent" }, FunctionInfo{ 8, nullptr, "NotifyLibraryAppletEvent" },
{ 9, nullptr, "Cmd9" }, FunctionInfo{ 9, nullptr, "Cmd9" },
{ 20, nullptr, "Cmd20" }, FunctionInfo{ 20, nullptr, "Cmd20" },
{ 30, nullptr, "Cmd30" }, FunctionInfo{ 30, nullptr, "Cmd30" },
{ 100, nullptr, "Cmd100" }, FunctionInfo{ 100, nullptr, "Cmd100" },
{ 101, nullptr, "Cmd101" }, FunctionInfo{ 101, nullptr, "Cmd101" }
}; );
// clang-format on
RegisterHandlers(functions);
} }
}; };
+5 -7
View File
@@ -21,7 +21,10 @@ namespace Service::PTM {
class IPsmSession final : public ServiceFramework<IPsmSession> { class IPsmSession final : public ServiceFramework<IPsmSession> {
public: public:
explicit IPsmSession(Core::System& system_) explicit IPsmSession(Core::System& system_)
: ServiceFramework{system_, "IPsmSession"}, service_context{system_, "IPsmSession"} {} : ServiceFramework{system_, "IPsmSession"}
, service_context{system_, "IPsmSession"} {
state_change_event = service_context.CreateEvent("IPsmSession::state_change_event");
}
FunctionInfoBase const* FindRequest(u32 key) override { FunctionInfoBase const* FindRequest(u32 key) override {
return HandlerTableGenerateWithFind(key, return HandlerTableGenerateWithFind(key,
@@ -30,12 +33,7 @@ public:
FunctionInfo{2, &IPsmSession::SetChargerTypeChangeEventEnabled, "SetChargerTypeChangeEventEnabled"}, FunctionInfo{2, &IPsmSession::SetChargerTypeChangeEventEnabled, "SetChargerTypeChangeEventEnabled"},
FunctionInfo{3, &IPsmSession::SetPowerSupplyChangeEventEnabled, "SetPowerSupplyChangeEventEnabled"}, FunctionInfo{3, &IPsmSession::SetPowerSupplyChangeEventEnabled, "SetPowerSupplyChangeEventEnabled"},
FunctionInfo{4, &IPsmSession::SetBatteryVoltageStateChangeEventEnabled, "SetBatteryVoltageStateChangeEventEnabled"} FunctionInfo{4, &IPsmSession::SetBatteryVoltageStateChangeEventEnabled, "SetBatteryVoltageStateChangeEventEnabled"}
}; );
// clang-format on
RegisterHandlers(functions);
state_change_event = service_context.CreateEvent("IPsmSession::state_change_event");
} }
~IPsmSession() override { ~IPsmSession() override {
+9 -13
View File
@@ -74,11 +74,14 @@ struct SslContextSharedData {
class ISslConnection final : public ServiceFramework<ISslConnection> { class ISslConnection final : public ServiceFramework<ISslConnection> {
public: public:
explicit ISslConnection(Core::System& system_in, SslVersion ssl_version_in, explicit ISslConnection(Core::System& system_in, SslVersion ssl_version_in, std::shared_ptr<SslContextSharedData>& shared_data_in, std::unique_ptr<SSLConnectionBackend>&& backend_in)
std::shared_ptr<SslContextSharedData>& shared_data_in, : ServiceFramework{system_in, "ISslConnection"}
std::unique_ptr<SSLConnectionBackend>&& backend_in) , ssl_version{ssl_version_in}
: ServiceFramework{system_in, "ISslConnection"}, ssl_version{ssl_version_in}, , shared_data{shared_data_in}
shared_data{shared_data_in}, backend{std::move(backend_in)} {} , backend{std::move(backend_in)} {
backend->SetVerifyOption(verify_option);
shared_data->connection_count++;
}
FunctionInfoBase const* FindRequest(u32 key) override { FunctionInfoBase const* FindRequest(u32 key) override {
return HandlerTableGenerateWithFind(key, return HandlerTableGenerateWithFind(key,
@@ -118,14 +121,7 @@ public:
FunctionInfo{33, nullptr, "ExportKeyingMaterial"}, FunctionInfo{33, nullptr, "ExportKeyingMaterial"},
FunctionInfo{34, nullptr, "SetIoTimeout"}, FunctionInfo{34, nullptr, "SetIoTimeout"},
FunctionInfo{35, nullptr, "GetIoTimeout"} FunctionInfo{35, nullptr, "GetIoTimeout"}
}; );
// clang-format on
RegisterHandlers(functions);
backend->SetVerifyOption(verify_option);
shared_data->connection_count++;
} }
~ISslConnection() { ~ISslConnection() {