diff options
| author | 2022-02-16 18:42:49 -0700 | |
|---|---|---|
| committer | 2022-02-16 18:42:49 -0700 | |
| commit | 027ff7847ca47669561f990cbb2f3c27b1e65be9 (patch) | |
| tree | a5c8f68b6c6db306324906f6b8794f01f0eb75b3 /src | |
| parent | Merge pull request #7899 from Kelebek1/test (diff) | |
| parent | service/mnpp: Stub mnpp_app (diff) | |
| download | yuzu-027ff7847ca47669561f990cbb2f3c27b1e65be9.tar.gz yuzu-027ff7847ca47669561f990cbb2f3c27b1e65be9.tar.xz yuzu-027ff7847ca47669561f990cbb2f3c27b1e65be9.zip | |
Merge pull request #7878 from german77/mnpp
service/mnpp: Stub mnpp_app
Diffstat (limited to '')
| -rw-r--r-- | src/common/logging/filter.cpp | 1 | ||||
| -rw-r--r-- | src/common/logging/types.h | 1 | ||||
| -rw-r--r-- | src/core/CMakeLists.txt | 2 | ||||
| -rw-r--r-- | src/core/hle/service/mnpp/mnpp_app.cpp | 45 | ||||
| -rw-r--r-- | src/core/hle/service/mnpp/mnpp_app.h | 20 | ||||
| -rw-r--r-- | src/core/hle/service/service.cpp | 2 |
6 files changed, 71 insertions, 0 deletions
diff --git a/src/common/logging/filter.cpp b/src/common/logging/filter.cpp index b898a652c..4afc1369a 100644 --- a/src/common/logging/filter.cpp +++ b/src/common/logging/filter.cpp | |||
| @@ -108,6 +108,7 @@ bool ParseFilterRule(Filter& instance, Iterator begin, Iterator end) { | |||
| 108 | SUB(Service, Migration) \ | 108 | SUB(Service, Migration) \ |
| 109 | SUB(Service, Mii) \ | 109 | SUB(Service, Mii) \ |
| 110 | SUB(Service, MM) \ | 110 | SUB(Service, MM) \ |
| 111 | SUB(Service, MNPP) \ | ||
| 111 | SUB(Service, NCM) \ | 112 | SUB(Service, NCM) \ |
| 112 | SUB(Service, NFC) \ | 113 | SUB(Service, NFC) \ |
| 113 | SUB(Service, NFP) \ | 114 | SUB(Service, NFP) \ |
diff --git a/src/common/logging/types.h b/src/common/logging/types.h index 9ed0c7ad6..2b6e4daa7 100644 --- a/src/common/logging/types.h +++ b/src/common/logging/types.h | |||
| @@ -76,6 +76,7 @@ enum class Class : u8 { | |||
| 76 | Service_Migration, ///< The migration service | 76 | Service_Migration, ///< The migration service |
| 77 | Service_Mii, ///< The Mii service | 77 | Service_Mii, ///< The Mii service |
| 78 | Service_MM, ///< The MM (Multimedia) service | 78 | Service_MM, ///< The MM (Multimedia) service |
| 79 | Service_MNPP, ///< The MNPP service | ||
| 79 | Service_NCM, ///< The NCM service | 80 | Service_NCM, ///< The NCM service |
| 80 | Service_NFC, ///< The NFC (Near-field communication) service | 81 | Service_NFC, ///< The NFC (Near-field communication) service |
| 81 | Service_NFP, ///< The NFP service | 82 | Service_NFP, ///< The NFP service |
diff --git a/src/core/CMakeLists.txt b/src/core/CMakeLists.txt index 6e8d11919..0c10cd019 100644 --- a/src/core/CMakeLists.txt +++ b/src/core/CMakeLists.txt | |||
| @@ -467,6 +467,8 @@ add_library(core STATIC | |||
| 467 | hle/service/mii/types.h | 467 | hle/service/mii/types.h |
| 468 | hle/service/mm/mm_u.cpp | 468 | hle/service/mm/mm_u.cpp |
| 469 | hle/service/mm/mm_u.h | 469 | hle/service/mm/mm_u.h |
| 470 | hle/service/mnpp/mnpp_app.cpp | ||
| 471 | hle/service/mnpp/mnpp_app.h | ||
| 470 | hle/service/ncm/ncm.cpp | 472 | hle/service/ncm/ncm.cpp |
| 471 | hle/service/ncm/ncm.h | 473 | hle/service/ncm/ncm.h |
| 472 | hle/service/nfc/nfc.cpp | 474 | hle/service/nfc/nfc.cpp |
diff --git a/src/core/hle/service/mnpp/mnpp_app.cpp b/src/core/hle/service/mnpp/mnpp_app.cpp new file mode 100644 index 000000000..53497612f --- /dev/null +++ b/src/core/hle/service/mnpp/mnpp_app.cpp | |||
| @@ -0,0 +1,45 @@ | |||
| 1 | // Copyright 2022 yuzu emulator team | ||
| 2 | // Licensed under GPLv2 or any later version | ||
| 3 | // Refer to the license.txt file included. | ||
| 4 | |||
| 5 | #include "common/logging/log.h" | ||
| 6 | #include "core/hle/ipc_helpers.h" | ||
| 7 | #include "core/hle/service/mnpp/mnpp_app.h" | ||
| 8 | #include "core/hle/service/sm/sm.h" | ||
| 9 | |||
| 10 | namespace Service::MNPP { | ||
| 11 | |||
| 12 | class MNPP_APP final : public ServiceFramework<MNPP_APP> { | ||
| 13 | public: | ||
| 14 | explicit MNPP_APP(Core::System& system_) : ServiceFramework{system_, "mnpp:app"} { | ||
| 15 | // clang-format off | ||
| 16 | static const FunctionInfo functions[] = { | ||
| 17 | {0, &MNPP_APP::Unknown0, "unknown0"}, | ||
| 18 | {1, &MNPP_APP::Unknown1, "unknown1"}, | ||
| 19 | }; | ||
| 20 | // clang-format on | ||
| 21 | |||
| 22 | RegisterHandlers(functions); | ||
| 23 | } | ||
| 24 | |||
| 25 | private: | ||
| 26 | void Unknown0(Kernel::HLERequestContext& ctx) { | ||
| 27 | LOG_WARNING(Service_MNPP, "(STUBBED) called"); | ||
| 28 | |||
| 29 | IPC::ResponseBuilder rb{ctx, 2}; | ||
| 30 | rb.Push(ResultSuccess); | ||
| 31 | } | ||
| 32 | |||
| 33 | void Unknown1(Kernel::HLERequestContext& ctx) { | ||
| 34 | LOG_WARNING(Service_MNPP, "(STUBBED) called"); | ||
| 35 | |||
| 36 | IPC::ResponseBuilder rb{ctx, 2}; | ||
| 37 | rb.Push(ResultSuccess); | ||
| 38 | } | ||
| 39 | }; | ||
| 40 | |||
| 41 | void InstallInterfaces(SM::ServiceManager& service_manager, Core::System& system) { | ||
| 42 | std::make_shared<MNPP_APP>(system)->InstallAsService(service_manager); | ||
| 43 | } | ||
| 44 | |||
| 45 | } // namespace Service::MNPP | ||
diff --git a/src/core/hle/service/mnpp/mnpp_app.h b/src/core/hle/service/mnpp/mnpp_app.h new file mode 100644 index 000000000..6bf20b494 --- /dev/null +++ b/src/core/hle/service/mnpp/mnpp_app.h | |||
| @@ -0,0 +1,20 @@ | |||
| 1 | // Copyright 2022 yuzu emulator team | ||
| 2 | // Licensed under GPLv2 or any later version | ||
| 3 | // Refer to the license.txt file included. | ||
| 4 | |||
| 5 | #pragma once | ||
| 6 | |||
| 7 | namespace Core { | ||
| 8 | class System; | ||
| 9 | } | ||
| 10 | |||
| 11 | namespace Service::SM { | ||
| 12 | class ServiceManager; | ||
| 13 | } | ||
| 14 | |||
| 15 | namespace Service::MNPP { | ||
| 16 | |||
| 17 | /// Registers all MNPP services with the specified service manager. | ||
| 18 | void InstallInterfaces(SM::ServiceManager& service_manager, Core::System& system); | ||
| 19 | |||
| 20 | } // namespace Service::MNPP | ||
diff --git a/src/core/hle/service/service.cpp b/src/core/hle/service/service.cpp index f54e6fe56..eb1138313 100644 --- a/src/core/hle/service/service.cpp +++ b/src/core/hle/service/service.cpp | |||
| @@ -39,6 +39,7 @@ | |||
| 39 | #include "core/hle/service/mig/mig.h" | 39 | #include "core/hle/service/mig/mig.h" |
| 40 | #include "core/hle/service/mii/mii.h" | 40 | #include "core/hle/service/mii/mii.h" |
| 41 | #include "core/hle/service/mm/mm_u.h" | 41 | #include "core/hle/service/mm/mm_u.h" |
| 42 | #include "core/hle/service/mnpp/mnpp_app.h" | ||
| 42 | #include "core/hle/service/ncm/ncm.h" | 43 | #include "core/hle/service/ncm/ncm.h" |
| 43 | #include "core/hle/service/nfc/nfc.h" | 44 | #include "core/hle/service/nfc/nfc.h" |
| 44 | #include "core/hle/service/nfp/nfp.h" | 45 | #include "core/hle/service/nfp/nfp.h" |
| @@ -265,6 +266,7 @@ Services::Services(std::shared_ptr<SM::ServiceManager>& sm, Core::System& system | |||
| 265 | Migration::InstallInterfaces(*sm, system); | 266 | Migration::InstallInterfaces(*sm, system); |
| 266 | Mii::InstallInterfaces(*sm, system); | 267 | Mii::InstallInterfaces(*sm, system); |
| 267 | MM::InstallInterfaces(*sm, system); | 268 | MM::InstallInterfaces(*sm, system); |
| 269 | MNPP::InstallInterfaces(*sm, system); | ||
| 268 | NCM::InstallInterfaces(*sm, system); | 270 | NCM::InstallInterfaces(*sm, system); |
| 269 | NFC::InstallInterfaces(*sm, system); | 271 | NFC::InstallInterfaces(*sm, system); |
| 270 | NFP::InstallInterfaces(*sm, system); | 272 | NFP::InstallInterfaces(*sm, system); |