diff --git a/exosphere/Makefile b/exosphere/Makefile index 8017acd..00aca38 100644 --- a/exosphere/Makefile +++ b/exosphere/Makefile @@ -14,11 +14,13 @@ @printf LENY >> exosphere.bin @echo "Built exosphere.bin..." -program.lz4: - $(MAKE) -C program +program.lz4: build_program @cp program/program.lz4 program.lz4 @cp program/boot_code.lz4 boot_code.lz4 +build_program: + $(MAKE) -C program + warmboot.bin: $(MAKE) -C warmboot @cp warmboot/warmboot.bin warmboot.bin @@ -40,4 +42,4 @@ boot_code-clean: @rm -f boot_code.lz4 -.PHONY: all clean $(CLEAN_TARGETS) +.PHONY: all clean build_program $(CLEAN_TARGETS) diff --git a/exosphere/program/source/smc/secmon_smc_aes.cpp b/exosphere/program/source/smc/secmon_smc_aes.cpp index 7dabf7d..60912e7 100644 --- a/exosphere/program/source/smc/secmon_smc_aes.cpp +++ b/exosphere/program/source/smc/secmon_smc_aes.cpp @@ -572,7 +572,7 @@ const u8 * const seal_key_source = SealKeySources[seal_key_type]; /* Decrypt the data. */ - if (!DecryptDeviceUniqueData(work_buffer, data_size, nullptr, seal_key_source, se::AesBlockSize, access_key, sizeof(access_key), key_source, sizeof(key_source), work_buffer, data_size, enforce_device_unique)) { + if (!DecryptDeviceUniqueData(work_buffer, data_size, nullptr, seal_key_source, se::AesBlockSize, access_key, se::AesBlockSize, key_source, se::AesBlockSize, work_buffer, data_size, enforce_device_unique)) { return SmcResult::InvalidArgument; } diff --git a/fusee/fusee-secondary/src/nxboot.c b/fusee/fusee-secondary/src/nxboot.c index 45a0bca..6a87a34 100644 --- a/fusee/fusee-secondary/src/nxboot.c +++ b/fusee/fusee-secondary/src/nxboot.c @@ -954,11 +954,7 @@ print(SCREEN_LOG_LEVEL_INFO, u8"[NXBOOT] Reading Exosphère...\n"); /* Select the right address for Exosphère. */ - if (MAILBOX_EXOSPHERE_CONFIGURATION->target_firmware < ATMOSPHERE_TARGET_FIRMWARE_4_0_0) { - exosphere_memaddr = (void *)0x4002D000; - } else { - exosphere_memaddr = (void *)0x40030000; - } + exosphere_memaddr = (void *)0x40030000; /* Copy Exosphère to a good location or read it directly to it. */ if (loader_ctx->exosphere_path[0] != '\0') { diff --git a/fusee/fusee-secondary/src/nxboot.h b/fusee/fusee-secondary/src/nxboot.h index 8c640e2..8d007b1 100644 --- a/fusee/fusee-secondary/src/nxboot.h +++ b/fusee/fusee-secondary/src/nxboot.h @@ -35,7 +35,7 @@ #define MAILBOX_NX_BOOTLOADER_BASE_100_620 0x40002E00 #define MAILBOX_NX_BOOTLOADER_BASE_700 0x40000000 -#define MAILBOX_NX_BOOTLOADER_BASE(targetfw) ((targetfw >= ATMOSPHERE_TARGET_FIRMWARE_7_0_0) ? (MAILBOX_NX_BOOTLOADER_BASE_700) : (MAILBOX_NX_BOOTLOADER_BASE_100_620)) +#define MAILBOX_NX_BOOTLOADER_BASE(targetfw) (MAILBOX_NX_BOOTLOADER_BASE_700) #define MAKE_MAILBOX_NX_BOOTLOADER_REG(targetfw, n) MAKE_REG32(MAILBOX_NX_BOOTLOADER_BASE(targetfw) + n) #define MAILBOX_NX_BOOTLOADER_BOOT_REASON_BASE(targetfw) (MAILBOX_NX_BOOTLOADER_BASE(targetfw) + 0x10)