spl: refactor for accuracy/move into libstrat

This commit is contained in:
Michael Scire 2021-10-10 12:57:24 -07:00
parent 4758dfa933
commit d8a36e39f2
40 changed files with 1898 additions and 1732 deletions

View file

@ -417,7 +417,7 @@ namespace ams::secmon::smc {
case CipherMode_CbcDecryption: se::DecryptAes128CbcAsync(output_address, slot, input_address, size, iv, sizeof(iv), SecurityEngineDoneHandler); break;
case CipherMode_Ctr: se::ComputeAes128CtrAsync(output_address, slot, input_address, size, iv, sizeof(iv), SecurityEngineDoneHandler); break;
case CipherMode_Cmac:
return SmcResult::NotImplemented;
return SmcResult::NotSupported;
default:
return SmcResult::InvalidArgument;
}
@ -765,8 +765,8 @@ namespace ams::secmon::smc {
const auto which = static_cast<SecureData>(args.r[1]);
/* Validate arguments/conditions. */
SMC_R_UNLESS(fuse::GetPatchVersion() < fuse::PatchVersion_Odnx02A2, NotImplemented);
SMC_R_UNLESS(which < SecureData_Count, NotImplemented);
SMC_R_UNLESS(fuse::GetPatchVersion() < fuse::PatchVersion_Odnx02A2, NotSupported);
SMC_R_UNLESS(which < SecureData_Count, NotSupported);
/* Use a temporary buffer. */
u8 secure_data[AesKeySize];

View file

@ -20,7 +20,7 @@ namespace ams::secmon::smc {
enum class SmcResult : u32 {
Success = 0,
NotImplemented = 1,
NotSupported = 1,
InvalidArgument = 2,
Busy = 3,
NoAsyncOperation = 4,

View file

@ -345,7 +345,7 @@ namespace ams::secmon::smc {
PerformUserShutDown();
}
} else /* if (soc_type == fuse::SocType_Mariko) */ {
return SmcResult::NotImplemented;
return SmcResult::NotSupported;
}
break;
case ConfigItem::ExospherePayloadAddress:
@ -389,7 +389,7 @@ namespace ams::secmon::smc {
/* Validate arguments. */
/* NOTE: In the future, configuration for non-NAND storage may be implemented. */
SMC_R_UNLESS(mmc == EmummcMmc_Nand, NotImplemented);
SMC_R_UNLESS(mmc == EmummcMmc_Nand, NotSupported);
SMC_R_UNLESS(user_offset + 2 * sizeof(EmummcFilePath) <= 4_KB, InvalidArgument);
/* Get the emummc config. */

View file

@ -70,7 +70,7 @@ namespace ams::secmon::smc {
SmcResult SmcWriteAddress(SmcArguments &args) {
/* NOTE: This smc was deprecated in Atmosphère 0.13.0. */
AMS_UNUSED(args);
return SmcResult::NotImplemented;
return SmcResult::NotSupported;
}
}