mirror of
https://github.com/Atmosphere-NX/Atmosphere.git
synced 2025-05-27 21:24:11 -04:00
sm: add HasService/HasMitm, refactor into sts::
This commit is contained in:
parent
3ccbb34c62
commit
9217e4c5f9
15 changed files with 69 additions and 118 deletions
|
@ -22,6 +22,7 @@
|
|||
#include <switch.h>
|
||||
#include <atmosphere.h>
|
||||
#include <stratosphere.hpp>
|
||||
#include <stratosphere/sm/sm_manager_api.hpp>
|
||||
|
||||
#include "pm_boot_mode.hpp"
|
||||
#include "pm_info.hpp"
|
||||
|
@ -99,18 +100,14 @@ void __appInit(void) {
|
|||
|
||||
DoWithSmSession([&]() {
|
||||
R_ASSERT(fsprInitialize());
|
||||
R_ASSERT(smManagerInitialize());
|
||||
|
||||
/* This works around a bug with process permissions on < 4.0.0. */
|
||||
RegisterPrivilegedProcessesWithFs();
|
||||
|
||||
/* Use AMS manager extension to tell SM that FS has been worked around. */
|
||||
{
|
||||
R_ASSERT(smManagerAmsInitialize());
|
||||
smManagerAmsEndInitialDefers();
|
||||
smManagerAmsExit();
|
||||
}
|
||||
R_ASSERT(sts::sm::manager::EndInitialDefers());
|
||||
|
||||
R_ASSERT(smManagerInitialize());
|
||||
R_ASSERT(lrInitialize());
|
||||
R_ASSERT(ldrPmInitialize());
|
||||
R_ASSERT(splInitialize());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue