boot: Implement DetectBootReason
This commit is contained in:
@@ -23,3 +23,11 @@ HardwareType Boot::GetHardwareType() {
|
||||
}
|
||||
return static_cast<HardwareType>(out_val);
|
||||
}
|
||||
|
||||
bool Boot::IsRecoveryBoot() {
|
||||
u64 val = 0;
|
||||
if (R_FAILED(splGetConfig(SplConfigItem_IsRecoveryBoot, &val))) {
|
||||
std::abort();
|
||||
}
|
||||
return val != 0;
|
||||
}
|
||||
Reference in New Issue
Block a user