From b800953d66ad384d54435551ec06e71a88e5c2b0 Mon Sep 17 00:00:00 2001 From: Michael Scire Date: Mon, 8 May 2023 17:51:13 -0700 Subject: [PATCH] ams: recognize 16.0.3('s FS) --- fusee/program/source/fusee_stratosphere.cpp | 14 ++++++++++++++ .../include/stratosphere/hos/hos_types.hpp | 1 + .../include/vapours/ams/ams_api_version.h | 4 ++-- .../include/vapours/ams/ams_target_firmware.h | 4 +++- 4 files changed, 20 insertions(+), 3 deletions(-) diff --git a/fusee/program/source/fusee_stratosphere.cpp b/fusee/program/source/fusee_stratosphere.cpp index ac2475ad8..76775cc66 100644 --- a/fusee/program/source/fusee_stratosphere.cpp +++ b/fusee/program/source/fusee_stratosphere.cpp @@ -162,6 +162,9 @@ namespace ams::nxboot { FsVersion_16_0_0, FsVersion_16_0_0_Exfat, + FsVersion_16_0_3, + FsVersion_16_0_3_Exfat, + FsVersion_Count, }; @@ -239,6 +242,9 @@ namespace ams::nxboot { { 0x56, 0xE8, 0x56, 0x56, 0x6C, 0x38, 0xD8, 0xBE }, /* FsVersion_16_0_0 */ { 0xCF, 0xAB, 0x45, 0x0C, 0x2C, 0x53, 0x9D, 0xA9 }, /* FsVersion_16_0_0_Exfat */ + + { 0x56, 0xE8, 0x56, 0x56, 0x6C, 0x38, 0xD8, 0xBE }, /* FsVersion_16_0_3 */ + { 0xCF, 0xAB, 0x45, 0x0C, 0x2C, 0x53, 0x9D, 0xA9 }, /* FsVersion_16_0_3_Exfat */ }; const InitialProcessBinaryHeader *FindInitialProcessBinary(const pkg2::Package2Header *header, const u8 *data, ams::TargetFirmware target_firmware) { @@ -656,6 +662,14 @@ namespace ams::nxboot { AddPatch(fs_meta, 0x1913B9, NogcPatch0, sizeof(NogcPatch0)); AddPatch(fs_meta, 0x16B950, NogcPatch1, sizeof(NogcPatch1)); break; + case FsVersion_16_0_3: + AddPatch(fs_meta, 0x186729, NogcPatch0, sizeof(NogcPatch0)); + AddPatch(fs_meta, 0x160CC0, NogcPatch1, sizeof(NogcPatch1)); + break; + case FsVersion_16_0_3_Exfat: + AddPatch(fs_meta, 0x191409, NogcPatch0, sizeof(NogcPatch0)); + AddPatch(fs_meta, 0x16B9A0, NogcPatch1, sizeof(NogcPatch1)); + break; default: break; } diff --git a/libraries/libstratosphere/include/stratosphere/hos/hos_types.hpp b/libraries/libstratosphere/include/stratosphere/hos/hos_types.hpp index 0a4b93b32..16b2ba188 100644 --- a/libraries/libstratosphere/include/stratosphere/hos/hos_types.hpp +++ b/libraries/libstratosphere/include/stratosphere/hos/hos_types.hpp @@ -78,6 +78,7 @@ namespace ams::hos { Version_16_0_0 = ::ams::TargetFirmware_16_0_0, Version_16_0_1 = ::ams::TargetFirmware_16_0_1, Version_16_0_2 = ::ams::TargetFirmware_16_0_2, + Version_16_0_3 = ::ams::TargetFirmware_16_0_3, Version_Current = ::ams::TargetFirmware_Current, diff --git a/libraries/libvapours/include/vapours/ams/ams_api_version.h b/libraries/libvapours/include/vapours/ams/ams_api_version.h index 9f1e45e25..0d970b155 100644 --- a/libraries/libvapours/include/vapours/ams/ams_api_version.h +++ b/libraries/libvapours/include/vapours/ams/ams_api_version.h @@ -17,10 +17,10 @@ #define ATMOSPHERE_RELEASE_VERSION_MAJOR 1 #define ATMOSPHERE_RELEASE_VERSION_MINOR 5 -#define ATMOSPHERE_RELEASE_VERSION_MICRO 2 +#define ATMOSPHERE_RELEASE_VERSION_MICRO 3 #define ATMOSPHERE_RELEASE_VERSION ATMOSPHERE_RELEASE_VERSION_MAJOR, ATMOSPHERE_RELEASE_VERSION_MINOR, ATMOSPHERE_RELEASE_VERSION_MICRO #define ATMOSPHERE_SUPPORTED_HOS_VERSION_MAJOR 16 #define ATMOSPHERE_SUPPORTED_HOS_VERSION_MINOR 0 -#define ATMOSPHERE_SUPPORTED_HOS_VERSION_MICRO 2 +#define ATMOSPHERE_SUPPORTED_HOS_VERSION_MICRO 3 diff --git a/libraries/libvapours/include/vapours/ams/ams_target_firmware.h b/libraries/libvapours/include/vapours/ams/ams_target_firmware.h index 51eab86be..5fa6a926f 100644 --- a/libraries/libvapours/include/vapours/ams/ams_target_firmware.h +++ b/libraries/libvapours/include/vapours/ams/ams_target_firmware.h @@ -76,8 +76,9 @@ #define ATMOSPHERE_TARGET_FIRMWARE_16_0_0 ATMOSPHERE_TARGET_FIRMWARE(16, 0, 0) #define ATMOSPHERE_TARGET_FIRMWARE_16_0_1 ATMOSPHERE_TARGET_FIRMWARE(16, 0, 1) #define ATMOSPHERE_TARGET_FIRMWARE_16_0_2 ATMOSPHERE_TARGET_FIRMWARE(16, 0, 2) +#define ATMOSPHERE_TARGET_FIRMWARE_16_0_3 ATMOSPHERE_TARGET_FIRMWARE(16, 0, 3) -#define ATMOSPHERE_TARGET_FIRMWARE_CURRENT ATMOSPHERE_TARGET_FIRMWARE_16_0_2 +#define ATMOSPHERE_TARGET_FIRMWARE_CURRENT ATMOSPHERE_TARGET_FIRMWARE_16_0_3 #define ATMOSPHERE_TARGET_FIRMWARE_MIN ATMOSPHERE_TARGET_FIRMWARE(0, 0, 0) #define ATMOSPHERE_TARGET_FIRMWARE_MAX ATMOSPHERE_TARGET_FIRMWARE_CURRENT @@ -146,6 +147,7 @@ namespace ams { TargetFirmware_16_0_0 = ATMOSPHERE_TARGET_FIRMWARE_16_0_0, TargetFirmware_16_0_1 = ATMOSPHERE_TARGET_FIRMWARE_16_0_1, TargetFirmware_16_0_2 = ATMOSPHERE_TARGET_FIRMWARE_16_0_2, + TargetFirmware_16_0_3 = ATMOSPHERE_TARGET_FIRMWARE_16_0_3, TargetFirmware_Current = ATMOSPHERE_TARGET_FIRMWARE_CURRENT,