hle: kernel: Migrate KSharedMemory to KAutoObject.

This commit is contained in:
bunnei
2021-04-03 23:22:07 -07:00
parent 7ccbdd4d8d
commit 086db71e94
16 changed files with 128 additions and 114 deletions

View File

@ -37,10 +37,6 @@ IRS::IRS(Core::System& system_) : ServiceFramework{system_, "irs"} {
// clang-format on
RegisterHandlers(functions);
auto& kernel = system.Kernel();
shared_mem = SharedFrom(&kernel.GetIrsSharedMem());
}
void IRS::ActivateIrsensor(Kernel::HLERequestContext& ctx) {
@ -62,7 +58,7 @@ void IRS::GetIrsensorSharedMemoryHandle(Kernel::HLERequestContext& ctx) {
IPC::ResponseBuilder rb{ctx, 2, 1};
rb.Push(RESULT_SUCCESS);
rb.PushCopyObjects(shared_mem.get());
rb.PushCopyObjects(&system.Kernel().GetIrsSharedMem());
}
void IRS::StopImageProcessor(Kernel::HLERequestContext& ctx) {