mirror of
https://git.suyu.dev/suyu/suyu.git
synced 2024-11-28 06:16:23 -05:00
5219424226
This was based on Switchbrew page: https://switchbrew.org/wiki/Migration_services
40 lines
1.2 KiB
C++
40 lines
1.2 KiB
C++
// Copyright 2018 yuzu emulator team
|
|
// Licensed under GPLv2 or any later version
|
|
// Refer to the license.txt file included.
|
|
|
|
#include <memory>
|
|
|
|
#include "core/hle/service/mig/mig.h"
|
|
#include "core/hle/service/service.h"
|
|
#include "core/hle/service/sm/sm.h"
|
|
|
|
namespace Service::Migration {
|
|
|
|
class MIG_USR final : public ServiceFramework<MIG_USR> {
|
|
public:
|
|
explicit MIG_USR() : ServiceFramework{"mig:usr"} {
|
|
// clang-format off
|
|
static const FunctionInfo functions[] = {
|
|
{10, nullptr, "TryGetLastMigrationInfo"},
|
|
{100, nullptr, "CreateServer"},
|
|
{101, nullptr, "ResumeServer"},
|
|
{200, nullptr, "CreateClient"},
|
|
{201, nullptr, "ResumeClient"},
|
|
{1001, nullptr, "Unknown1001"},
|
|
{1010, nullptr, "Unknown1010"},
|
|
{1100, nullptr, "Unknown1100"},
|
|
{1101, nullptr, "Unknown1101"},
|
|
{1200, nullptr, "Unknown1200"},
|
|
{1201, nullptr, "Unknown1201"}
|
|
};
|
|
// clang-format on
|
|
|
|
RegisterHandlers(functions);
|
|
}
|
|
};
|
|
|
|
void InstallInterfaces(SM::ServiceManager& sm) {
|
|
std::make_shared<MIG_USR>()->InstallAsService(sm);
|
|
}
|
|
|
|
} // namespace Service::Migration
|