meso: update for new fatal encoding

This commit is contained in:
Michael Scire 2021-01-31 09:06:54 -08:00
parent 2b5e8b5c65
commit ec655069d0

View file

@ -314,12 +314,12 @@ namespace ams::kern::board::nintendo::nx {
g_secure_applet_memory_used = false; g_secure_applet_memory_used = false;
} }
u64 GetVersionIdentifier() { u32 GetVersionIdentifier() {
u64 value = kern::GetTargetFirmware(); u32 value = 0;
value |= static_cast<u64>(ATMOSPHERE_RELEASE_VERSION_MICRO) << 32; value |= static_cast<u64>(ATMOSPHERE_RELEASE_VERSION_MICRO) << 0;
value |= static_cast<u64>(ATMOSPHERE_RELEASE_VERSION_MINOR) << 40; value |= static_cast<u64>(ATMOSPHERE_RELEASE_VERSION_MINOR) << 8;
value |= static_cast<u64>(ATMOSPHERE_RELEASE_VERSION_MAJOR) << 48; value |= static_cast<u64>(ATMOSPHERE_RELEASE_VERSION_MAJOR) << 16;
value |= static_cast<u64>('M') << 56; value |= static_cast<u64>('M') << 24;
return value; return value;
} }
@ -584,8 +584,8 @@ namespace ams::kern::board::nintendo::nx {
f_ctx->module_base = KMemoryLayout::GetKernelCodeRegionExtents().GetAddress(); f_ctx->module_base = KMemoryLayout::GetKernelCodeRegionExtents().GetAddress();
/* Set afsr1. */ /* Set afsr1. */
f_ctx->afsr0 = 0; f_ctx->afsr0 = GetVersionIdentifier();
f_ctx->afsr1 = GetVersionIdentifier(); f_ctx->afsr1 = static_cast<u32>(kern::GetTargetFirmware());
/* Set efsr/far. */ /* Set efsr/far. */
f_ctx->far = cpu::GetFarEl1(); f_ctx->far = cpu::GetFarEl1();