Compare commits
33 Commits
1.4.0-rele
...
pc_testing
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
34acb80635 | ||
|
|
99fc16bfd0 | ||
|
|
3c07819cd2 | ||
|
|
1313427b5d | ||
|
|
13b63af15e | ||
|
|
76910e8954 | ||
|
|
09a44fa680 | ||
|
|
244a396b16 | ||
|
|
6e6b86eabc | ||
|
|
82620f95a3 | ||
|
|
b7ed9c58bb | ||
|
|
46f2d34f25 | ||
|
|
f58eca5f7b | ||
|
|
6cf31486e1 | ||
|
|
d6dbfd356d | ||
|
|
d76e678da2 | ||
|
|
1d0c9ae71a | ||
|
|
502a89e1e3 | ||
|
|
f8409680c2 | ||
|
|
22f30e4e51 | ||
|
|
6c4960d5a9 | ||
|
|
242577f90d | ||
|
|
fd02c9bd22 | ||
|
|
753434ff2d | ||
|
|
f817178081 | ||
|
|
87764613f2 | ||
|
|
5c5789eadf | ||
|
|
a3ba767fba | ||
|
|
100bead52b | ||
|
|
a4895a1e79 | ||
|
|
453e70bc6f | ||
|
|
ddf80b29f2 | ||
|
|
01c939f774 |
@@ -75,33 +75,33 @@ dist-no-debug: package3 $(CURRENT_DIRECTORY)/$(ATMOSPHERE_OUT_DIR)
|
||||
cp -r config_templates/kip_patches $(DIST_DIR)/atmosphere/kip_patches
|
||||
cp -r config_templates/hbl_html $(DIST_DIR)/atmosphere/hbl_html
|
||||
mkdir -p $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/0100000000000008
|
||||
mkdir -p $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/010000000000000d
|
||||
mkdir -p $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/010000000000000D
|
||||
mkdir -p $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/0100000000000017
|
||||
mkdir -p $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/010000000000002b
|
||||
mkdir -p $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/010000000000002B
|
||||
mkdir -p $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/0100000000000032
|
||||
mkdir -p $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/0100000000000034
|
||||
mkdir -p $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/0100000000000036
|
||||
mkdir -p $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/0100000000000037
|
||||
mkdir -p $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/010000000000003c
|
||||
mkdir -p $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/010000000000003C
|
||||
mkdir -p $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/0100000000000042
|
||||
mkdir -p $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/0100000000000420
|
||||
mkdir -p $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/010000000000b240
|
||||
mkdir -p $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/010000000000d609
|
||||
mkdir -p $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/010000000000d623
|
||||
mkdir -p $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/010000000000B240
|
||||
mkdir -p $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/010000000000D609
|
||||
mkdir -p $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/010000000000D623
|
||||
cp stratosphere/boot2/$(ATMOSPHERE_OUT_DIR)/boot2.nsp $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/0100000000000008/exefs.nsp
|
||||
cp stratosphere/dmnt/$(ATMOSPHERE_OUT_DIR)/dmnt.nsp $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/010000000000000d/exefs.nsp
|
||||
cp stratosphere/dmnt/$(ATMOSPHERE_OUT_DIR)/dmnt.nsp $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/010000000000000D/exefs.nsp
|
||||
cp stratosphere/cs/$(ATMOSPHERE_OUT_DIR)/cs.nsp $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/0100000000000017/exefs.nsp
|
||||
cp stratosphere/erpt/$(ATMOSPHERE_OUT_DIR)/erpt.nsp $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/010000000000002b/exefs.nsp
|
||||
cp stratosphere/erpt/$(ATMOSPHERE_OUT_DIR)/erpt.nsp $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/010000000000002B/exefs.nsp
|
||||
cp stratosphere/eclct.stub/$(ATMOSPHERE_OUT_DIR)/eclct.stub.nsp $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/0100000000000032/exefs.nsp
|
||||
cp stratosphere/fatal/$(ATMOSPHERE_OUT_DIR)/fatal.nsp $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/0100000000000034/exefs.nsp
|
||||
cp stratosphere/creport/$(ATMOSPHERE_OUT_DIR)/creport.nsp $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/0100000000000036/exefs.nsp
|
||||
cp stratosphere/ro/$(ATMOSPHERE_OUT_DIR)/ro.nsp $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/0100000000000037/exefs.nsp
|
||||
cp stratosphere/jpegdec/$(ATMOSPHERE_OUT_DIR)/jpegdec.nsp $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/010000000000003c/exefs.nsp
|
||||
cp stratosphere/jpegdec/$(ATMOSPHERE_OUT_DIR)/jpegdec.nsp $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/010000000000003C/exefs.nsp
|
||||
cp stratosphere/pgl/$(ATMOSPHERE_OUT_DIR)/pgl.nsp $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/0100000000000042/exefs.nsp
|
||||
cp stratosphere/LogManager/$(ATMOSPHERE_OUT_DIR)/LogManager.nsp $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/0100000000000420/exefs.nsp
|
||||
cp stratosphere/htc/$(ATMOSPHERE_OUT_DIR)/htc.nsp $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/010000000000b240/exefs.nsp
|
||||
cp stratosphere/dmnt.gen2/$(ATMOSPHERE_OUT_DIR)/dmnt.gen2.nsp $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/010000000000d609/exefs.nsp
|
||||
cp stratosphere/TioServer/$(ATMOSPHERE_OUT_DIR)/TioServer.nsp $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/010000000000d623/exefs.nsp
|
||||
cp stratosphere/htc/$(ATMOSPHERE_OUT_DIR)/htc.nsp $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/010000000000B240/exefs.nsp
|
||||
cp stratosphere/dmnt.gen2/$(ATMOSPHERE_OUT_DIR)/dmnt.gen2.nsp $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/010000000000D609/exefs.nsp
|
||||
cp stratosphere/TioServer/$(ATMOSPHERE_OUT_DIR)/TioServer.nsp $(DIST_DIR)/stratosphere_romfs/atmosphere/contents/010000000000D623/exefs.nsp
|
||||
@build_romfs $(DIST_DIR)/stratosphere_romfs $(DIST_DIR)/atmosphere/stratosphere.romfs
|
||||
rm -r $(DIST_DIR)/stratosphere_romfs
|
||||
cp troposphere/reboot_to_payload/reboot_to_payload.nro $(DIST_DIR)/switch/reboot_to_payload.nro
|
||||
|
||||
@@ -17,9 +17,6 @@
|
||||
; Note that this setting does nothing when log manager is not enabled/sd card logging is not enabled.
|
||||
; sd_card_log_output_directory = str!atmosphere/binlogs
|
||||
; Atmosphere custom settings
|
||||
[erpt]
|
||||
; Control whether erpt reports should always be preserved, instead of automatically cleaning periodically.
|
||||
; disable_automatic_report_cleanup = u8!0x0
|
||||
[atmosphere]
|
||||
; Reboot from fatal automatically after some number of milliseconds.
|
||||
; If field is not present or 0, fatal will wait indefinitely for user input.
|
||||
|
||||
@@ -1,53 +1,4 @@
|
||||
# Changelog
|
||||
## 1.4.0
|
||||
+ Support was added for 15.0.0.
|
||||
+ `mesosphère` was updated to reflect the latest official kernel behavior.
|
||||
+ `ncm` was updated to reflect the latest official kernel behavior.
|
||||
+ A number of minor issues were fixed and improvements were made, including:
|
||||
+ The capacity limit on registered add-on contents was fixed in NCM to reflect the increase that occurred in 12.0.0.
|
||||
+ An off-by-one was fixed in mesosphere when computing the new value for an address arbiter signaled with ModifyByWaitingCountIfEqual.
|
||||
+ dmnt.gen2's gdbstub now sanitizes thread names to prevent invalid characters from breaking gdb.
|
||||
+ dmnt.gen2's gdbstub now reports the architecture tag correctly when attached to 32-bit processes.
|
||||
+ Support for program-specific html manual content overrides was added for non-hbl takeover context.
|
||||
+ A bug was fixed in how emummc constructed the alternate Nintendo directory path.
|
||||
+ Previously, this was using `/*/Nintendo/Nintendo` instead of `/*/Nintendo`.
|
||||
+ Code was added to automatically move the old folders to the new ones when booting into emummc.
|
||||
+ A bug was fixed in boot that caused an incorrectly low input voltage limit to be set.
|
||||
+ General system stability improvements to enhance the user's experience.
|
||||
## 1.3.2
|
||||
+ Support was improved for 14.0.0+.
|
||||
+ `loader` was updated to reflect the latest official behaviors.
|
||||
+ `ro` was updated to reflect the latest official behaviors.
|
||||
+ A number of minor issues were fixed and improvements were made, including:
|
||||
+ A memory leak was fixed in filesystem path management; this could cause a crash when launching games ~100 times, or when deleting/re-downloading games.
|
||||
+ A bug was fixed that could cause threads to not see a newly signaled semaphore.
|
||||
+ A number of minor inaccuracies were fixed in the updated FileSystem APIs.
|
||||
+ General system stability improvements to enhance the user's experience.
|
||||
## 1.3.1
|
||||
+ Support was added for 14.1.0.
|
||||
+ A number of minor under the hood improvements to accuracy were made to better reflect latest official system module behavior, particularly around FS apis.
|
||||
+ General system stability improvements to enhance the user's experience.
|
||||
## 1.3.0
|
||||
+ Support was added for 14.0.0.
|
||||
+ `mesosphère` was updated to reflect the latest official kernel behavior.
|
||||
+ `erpt` was updated to reflect the latest official behaviors.
|
||||
+ `pm` was updated to reflect the latest official behaviors.
|
||||
+ `fatal` was updated to reflect the latest official behaviors.
|
||||
+ A mechanism for automatically cleaning up `erpt_reports` was added.
|
||||
+ When booting, if the console has more than 1000 reports inside `/atmosphere/erpt_reports`, the folder will be cleaned to empty.
|
||||
+ This behavior can be disabled by setting `erpt!disable_automatic_report_cleanup` = u8!0x1 in system_settings.ini.
|
||||
+ Atmosphère's build system was re-written, and now allows globally building for various builds/configs.
|
||||
+ All boards now automatically support release/debugging/auditing targets; it is now possible to build a full debugging/auditing build of atmosphère for the first time.
|
||||
+ Support was added for compiling libstratosphère to run on PC.
|
||||
+ The currently implemented/tested targets are Windows (x64), Linux (x64, arm64), macOS (x64, arm64).
|
||||
+ If you are a developer interested in adding support for another target, please reach out to `SciresM#0524` on discord.
|
||||
+ This is intended to finally allow sanely testing Atmosphère's code, by allowing most of it to run on a PC (with access to a debugger) instead of on game console hardware.
|
||||
+ In addition, this will allow making PC tools which reuse code written for Atmosphère directly..
|
||||
+ **Please Note**: This has no relation to interacting with official software on PC whatsoever. This really allows for making tests and self-contained atmosphère-based command-line tools; the Atmosphère project continues to have zero interest in attempting to run official software of any kind.
|
||||
+ In the course of adding this support (and working on tooling using it), a number of fairly major revisions were made to stratosphere (particularly surrounding filesystem code).
|
||||
+ **Please Note**: A number of changes made for this (and ones necessary in the process of adding support for 14.0.0) are api-breaking.
|
||||
+ If you're a developer and any of this caused your code to break, please feel free to contact `SciresM#0524` for help updating your program.
|
||||
+ General system stability improvements to enhance the user's experience.
|
||||
## 1.2.6
|
||||
+ Support was added for 13.2.1.
|
||||
+ A number of minor issues were fixed and improvements were made, including:
|
||||
@@ -188,7 +139,7 @@
|
||||
+ Many, many other minor changes, please talk to SciresM#0524 or read the relevant commits if you want to know more.
|
||||
+ A number of minor issues were fixed, including:
|
||||
+ Mesosphere's handling of SVC permissions on thread pin/unpin was updated to reflect official kernel behavior.
|
||||
+ util::CountTrailingZeros() was fixed to calculate the correct value when used at compile-time.
|
||||
+ util::CountTrailingZeroes() was fixed to calculate the correct value when used at compile-time.
|
||||
+ General system stability improvements to enhance the user's experience.
|
||||
## 1.1.1
|
||||
+ A bug was fixed which caused some memory to leak when launching a game with mods enabled, eventually causing a crash after enough game launches without rebooting.
|
||||
|
||||
6
emummc/.gitrepo
vendored
6
emummc/.gitrepo
vendored
@@ -4,9 +4,9 @@
|
||||
; git-subrepo command. See https://github.com/git-commands/git-subrepo#readme
|
||||
;
|
||||
[subrepo]
|
||||
remote = https://github.com/m4xw/emummc
|
||||
remote = https://github.com/m4xw/emuMMC
|
||||
branch = develop
|
||||
commit = 4714b2df9eaf68fb85516b35f7f4265ab0413825
|
||||
parent = 99f6a96845b6097d50f5059eea9245d27876f26a
|
||||
commit = a9d56959460fc794ce2cb6405402c25a3e89c47f
|
||||
parent = ff719641396c635b735873fb2b020c910f768a04
|
||||
method = merge
|
||||
cmdver = 0.4.1
|
||||
|
||||
2
emummc/README.md
vendored
2
emummc/README.md
vendored
@@ -2,7 +2,7 @@
|
||||
*A SDMMC driver replacement for Nintendo's Filesystem Services, by **m4xw***
|
||||
|
||||
### Supported Horizon Versions
|
||||
**1.0.0 - 15.0.0**
|
||||
**1.0.0 - 13.1.0**
|
||||
|
||||
## Features
|
||||
* Arbitrary SDMMC backend selection
|
||||
|
||||
16
emummc/source/FS/FS_offsets.c
vendored
16
emummc/source/FS/FS_offsets.c
vendored
@@ -59,10 +59,6 @@
|
||||
#include "offsets/1300_exfat.h"
|
||||
#include "offsets/1310.h"
|
||||
#include "offsets/1310_exfat.h"
|
||||
#include "offsets/1400.h"
|
||||
#include "offsets/1400_exfat.h"
|
||||
#include "offsets/1500.h"
|
||||
#include "offsets/1500_exfat.h"
|
||||
#include "../utils/fatal.h"
|
||||
|
||||
#define GET_OFFSET_STRUCT_NAME(vers) g_offsets##vers
|
||||
@@ -133,10 +129,6 @@ DEFINE_OFFSET_STRUCT(_1300);
|
||||
DEFINE_OFFSET_STRUCT(_1300_EXFAT);
|
||||
DEFINE_OFFSET_STRUCT(_1310);
|
||||
DEFINE_OFFSET_STRUCT(_1310_EXFAT);
|
||||
DEFINE_OFFSET_STRUCT(_1400);
|
||||
DEFINE_OFFSET_STRUCT(_1400_EXFAT);
|
||||
DEFINE_OFFSET_STRUCT(_1500);
|
||||
DEFINE_OFFSET_STRUCT(_1500_EXFAT);
|
||||
|
||||
const fs_offsets_t *get_fs_offsets(enum FS_VER version) {
|
||||
switch (version) {
|
||||
@@ -226,14 +218,6 @@ const fs_offsets_t *get_fs_offsets(enum FS_VER version) {
|
||||
return &(GET_OFFSET_STRUCT_NAME(_1310));
|
||||
case FS_VER_13_1_0_EXFAT:
|
||||
return &(GET_OFFSET_STRUCT_NAME(_1310_EXFAT));
|
||||
case FS_VER_14_0_0:
|
||||
return &(GET_OFFSET_STRUCT_NAME(_1400));
|
||||
case FS_VER_14_0_0_EXFAT:
|
||||
return &(GET_OFFSET_STRUCT_NAME(_1400_EXFAT));
|
||||
case FS_VER_15_0_0:
|
||||
return &(GET_OFFSET_STRUCT_NAME(_1500));
|
||||
case FS_VER_15_0_0_EXFAT:
|
||||
return &(GET_OFFSET_STRUCT_NAME(_1500_EXFAT));
|
||||
default:
|
||||
fatal_abort(Fatal_UnknownVersion);
|
||||
}
|
||||
|
||||
6
emummc/source/FS/FS_versions.h
vendored
6
emummc/source/FS/FS_versions.h
vendored
@@ -86,12 +86,6 @@ enum FS_VER
|
||||
FS_VER_13_1_0,
|
||||
FS_VER_13_1_0_EXFAT,
|
||||
|
||||
FS_VER_14_0_0,
|
||||
FS_VER_14_0_0_EXFAT,
|
||||
|
||||
FS_VER_15_0_0,
|
||||
FS_VER_15_0_0_EXFAT,
|
||||
|
||||
FS_VER_MAX,
|
||||
};
|
||||
|
||||
|
||||
59
emummc/source/FS/offsets/1400.h
vendored
59
emummc/source/FS/offsets/1400.h
vendored
@@ -1,59 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2019 m4xw <m4x@m4xw.net>
|
||||
* Copyright (c) 2019 Atmosphere-NX
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it
|
||||
* under the terms and conditions of the GNU General Public License,
|
||||
* version 2, as published by the Free Software Foundation.
|
||||
*
|
||||
* This program is distributed in the hope it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
|
||||
* more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#ifndef __FS_1400_H__
|
||||
#define __FS_1400_H__
|
||||
|
||||
// Accessor vtable getters
|
||||
#define FS_OFFSET_1400_SDMMC_ACCESSOR_GC 0x189F50
|
||||
#define FS_OFFSET_1400_SDMMC_ACCESSOR_SD 0x18BD60
|
||||
#define FS_OFFSET_1400_SDMMC_ACCESSOR_NAND 0x18A480
|
||||
|
||||
// Hooks
|
||||
#define FS_OFFSET_1400_SDMMC_WRAPPER_READ 0x185AF0
|
||||
#define FS_OFFSET_1400_SDMMC_WRAPPER_WRITE 0x185B50
|
||||
#define FS_OFFSET_1400_RTLD 0x282B8
|
||||
#define FS_OFFSET_1400_RTLD_DESTINATION ((uintptr_t)(INT64_C(-0x3C)))
|
||||
|
||||
#define FS_OFFSET_1400_CLKRST_SET_MIN_V_CLK_RATE 0x1A5D90
|
||||
|
||||
// Misc funcs
|
||||
#define FS_OFFSET_1400_LOCK_MUTEX 0x17E9F0
|
||||
#define FS_OFFSET_1400_UNLOCK_MUTEX 0x17EA40
|
||||
|
||||
#define FS_OFFSET_1400_SDMMC_WRAPPER_CONTROLLER_OPEN 0x185AA0
|
||||
#define FS_OFFSET_1400_SDMMC_WRAPPER_CONTROLLER_CLOSE 0x185AD0
|
||||
|
||||
// Misc Data
|
||||
#define FS_OFFSET_1400_SD_MUTEX 0xF2E3F0
|
||||
#define FS_OFFSET_1400_NAND_MUTEX 0xF292F8
|
||||
#define FS_OFFSET_1400_ACTIVE_PARTITION 0xF29338
|
||||
#define FS_OFFSET_1400_SDMMC_DAS_HANDLE 0xDFE9C8
|
||||
|
||||
// NOPs
|
||||
#define FS_OFFSET_1400_SD_DAS_INIT 0x27004
|
||||
|
||||
// Nintendo Paths
|
||||
#define FS_OFFSET_1400_NINTENDO_PATHS \
|
||||
{ \
|
||||
{.opcode_reg = 3, .adrp_offset = 0x0006D9C0, .add_rel_offset = 0x00000004}, \
|
||||
{.opcode_reg = 3, .adrp_offset = 0x0007AC24, .add_rel_offset = 0x00000004}, \
|
||||
{.opcode_reg = 4, .adrp_offset = 0x000813E8, .add_rel_offset = 0x00000004}, \
|
||||
{.opcode_reg = 4, .adrp_offset = 0x0009387C, .add_rel_offset = 0x00000004}, \
|
||||
{.opcode_reg = 0, .adrp_offset = 0, .add_rel_offset = 0}, \
|
||||
}
|
||||
|
||||
#endif // __FS_1400_H__
|
||||
59
emummc/source/FS/offsets/1400_exfat.h
vendored
59
emummc/source/FS/offsets/1400_exfat.h
vendored
@@ -1,59 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2019 m4xw <m4x@m4xw.net>
|
||||
* Copyright (c) 2019 Atmosphere-NX
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it
|
||||
* under the terms and conditions of the GNU General Public License,
|
||||
* version 2, as published by the Free Software Foundation.
|
||||
*
|
||||
* This program is distributed in the hope it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
|
||||
* more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#ifndef __FS_1400_EXFAT_H__
|
||||
#define __FS_1400_EXFAT_H__
|
||||
|
||||
// Accessor vtable getters
|
||||
#define FS_OFFSET_1400_EXFAT_SDMMC_ACCESSOR_GC 0x1952D0
|
||||
#define FS_OFFSET_1400_EXFAT_SDMMC_ACCESSOR_SD 0x1970E0
|
||||
#define FS_OFFSET_1400_EXFAT_SDMMC_ACCESSOR_NAND 0x195800
|
||||
|
||||
// Hooks
|
||||
#define FS_OFFSET_1400_EXFAT_SDMMC_WRAPPER_READ 0x190E70
|
||||
#define FS_OFFSET_1400_EXFAT_SDMMC_WRAPPER_WRITE 0x190ED0
|
||||
#define FS_OFFSET_1400_EXFAT_RTLD 0x282B8
|
||||
#define FS_OFFSET_1400_EXFAT_RTLD_DESTINATION ((uintptr_t)(INT64_C(-0x3C)))
|
||||
|
||||
#define FS_OFFSET_1400_EXFAT_CLKRST_SET_MIN_V_CLK_RATE 0x1B1110
|
||||
|
||||
// Misc funcs
|
||||
#define FS_OFFSET_1400_EXFAT_LOCK_MUTEX 0x189D70
|
||||
#define FS_OFFSET_1400_EXFAT_UNLOCK_MUTEX 0x189DC0
|
||||
|
||||
#define FS_OFFSET_1400_EXFAT_SDMMC_WRAPPER_CONTROLLER_OPEN 0x190E20
|
||||
#define FS_OFFSET_1400_EXFAT_SDMMC_WRAPPER_CONTROLLER_CLOSE 0x190E50
|
||||
|
||||
// Misc Data
|
||||
#define FS_OFFSET_1400_EXFAT_SD_MUTEX 0x10123F0
|
||||
#define FS_OFFSET_1400_EXFAT_NAND_MUTEX 0x100D2F8
|
||||
#define FS_OFFSET_1400_EXFAT_ACTIVE_PARTITION 0x100D338
|
||||
#define FS_OFFSET_1400_EXFAT_SDMMC_DAS_HANDLE 0xE0B9C8
|
||||
|
||||
// NOPs
|
||||
#define FS_OFFSET_1400_EXFAT_SD_DAS_INIT 0x27004
|
||||
|
||||
// Nintendo Paths
|
||||
#define FS_OFFSET_1400_EXFAT_NINTENDO_PATHS \
|
||||
{ \
|
||||
{.opcode_reg = 3, .adrp_offset = 0x0006D9C0, .add_rel_offset = 0x00000004}, \
|
||||
{.opcode_reg = 3, .adrp_offset = 0x0007AC24, .add_rel_offset = 0x00000004}, \
|
||||
{.opcode_reg = 4, .adrp_offset = 0x000813E8, .add_rel_offset = 0x00000004}, \
|
||||
{.opcode_reg = 4, .adrp_offset = 0x0009387C, .add_rel_offset = 0x00000004}, \
|
||||
{.opcode_reg = 0, .adrp_offset = 0, .add_rel_offset = 0}, \
|
||||
}
|
||||
|
||||
#endif // __FS_1400_EXFAT_H__
|
||||
59
emummc/source/FS/offsets/1500.h
vendored
59
emummc/source/FS/offsets/1500.h
vendored
@@ -1,59 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2019 m4xw <m4x@m4xw.net>
|
||||
* Copyright (c) 2019 Atmosphere-NX
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it
|
||||
* under the terms and conditions of the GNU General Public License,
|
||||
* version 2, as published by the Free Software Foundation.
|
||||
*
|
||||
* This program is distributed in the hope it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
|
||||
* more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#ifndef __FS_1500_H__
|
||||
#define __FS_1500_H__
|
||||
|
||||
// Accessor vtable getters
|
||||
#define FS_OFFSET_1500_SDMMC_ACCESSOR_GC 0x183E20
|
||||
#define FS_OFFSET_1500_SDMMC_ACCESSOR_SD 0x185AA0
|
||||
#define FS_OFFSET_1500_SDMMC_ACCESSOR_NAND 0x1842E0
|
||||
|
||||
// Hooks
|
||||
#define FS_OFFSET_1500_SDMMC_WRAPPER_READ 0x17FCF0
|
||||
#define FS_OFFSET_1500_SDMMC_WRAPPER_WRITE 0x17FD50
|
||||
#define FS_OFFSET_1500_RTLD 0x26518
|
||||
#define FS_OFFSET_1500_RTLD_DESTINATION ((uintptr_t)(INT64_C(-0x3C)))
|
||||
|
||||
#define FS_OFFSET_1500_CLKRST_SET_MIN_V_CLK_RATE 0x1A0870
|
||||
|
||||
// Misc funcs
|
||||
#define FS_OFFSET_1500_LOCK_MUTEX 0x1791A0
|
||||
#define FS_OFFSET_1500_UNLOCK_MUTEX 0x1791F0
|
||||
|
||||
#define FS_OFFSET_1500_SDMMC_WRAPPER_CONTROLLER_OPEN 0x17FCB0
|
||||
#define FS_OFFSET_1500_SDMMC_WRAPPER_CONTROLLER_CLOSE 0x17FCD0
|
||||
|
||||
// Misc Data
|
||||
#define FS_OFFSET_1500_SD_MUTEX 0xFF33F0
|
||||
#define FS_OFFSET_1500_NAND_MUTEX 0xFEE2E8
|
||||
#define FS_OFFSET_1500_ACTIVE_PARTITION 0xFEE328
|
||||
#define FS_OFFSET_1500_SDMMC_DAS_HANDLE 0xFD38D8
|
||||
|
||||
// NOPs
|
||||
#define FS_OFFSET_1500_SD_DAS_INIT 0x25454
|
||||
|
||||
// Nintendo Paths
|
||||
#define FS_OFFSET_1500_NINTENDO_PATHS \
|
||||
{ \
|
||||
{.opcode_reg = 3, .adrp_offset = 0x00063050, .add_rel_offset = 0x00000004}, \
|
||||
{.opcode_reg = 3, .adrp_offset = 0x0006FDE8, .add_rel_offset = 0x00000004}, \
|
||||
{.opcode_reg = 4, .adrp_offset = 0x000768D4, .add_rel_offset = 0x00000004}, \
|
||||
{.opcode_reg = 4, .adrp_offset = 0x00089364, .add_rel_offset = 0x00000004}, \
|
||||
{.opcode_reg = 0, .adrp_offset = 0, .add_rel_offset = 0}, \
|
||||
}
|
||||
|
||||
#endif // __FS_1500_H__
|
||||
59
emummc/source/FS/offsets/1500_exfat.h
vendored
59
emummc/source/FS/offsets/1500_exfat.h
vendored
@@ -1,59 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 2019 m4xw <m4x@m4xw.net>
|
||||
* Copyright (c) 2019 Atmosphere-NX
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it
|
||||
* under the terms and conditions of the GNU General Public License,
|
||||
* version 2, as published by the Free Software Foundation.
|
||||
*
|
||||
* This program is distributed in the hope it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
|
||||
* more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#ifndef __FS_1500_EXFAT_H__
|
||||
#define __FS_1500_EXFAT_H__
|
||||
|
||||
// Accessor vtable getters
|
||||
#define FS_OFFSET_1500_EXFAT_SDMMC_ACCESSOR_GC 0x18EDB0
|
||||
#define FS_OFFSET_1500_EXFAT_SDMMC_ACCESSOR_SD 0x190A30
|
||||
#define FS_OFFSET_1500_EXFAT_SDMMC_ACCESSOR_NAND 0x18F270
|
||||
|
||||
// Hooks
|
||||
#define FS_OFFSET_1500_EXFAT_SDMMC_WRAPPER_READ 0x18AC80
|
||||
#define FS_OFFSET_1500_EXFAT_SDMMC_WRAPPER_WRITE 0x18ACE0
|
||||
#define FS_OFFSET_1500_EXFAT_RTLD 0x26518
|
||||
#define FS_OFFSET_1500_EXFAT_RTLD_DESTINATION ((uintptr_t)(INT64_C(-0x3C)))
|
||||
|
||||
#define FS_OFFSET_1500_EXFAT_CLKRST_SET_MIN_V_CLK_RATE 0x1AB800
|
||||
|
||||
// Misc funcs
|
||||
#define FS_OFFSET_1500_EXFAT_LOCK_MUTEX 0x184130
|
||||
#define FS_OFFSET_1500_EXFAT_UNLOCK_MUTEX 0x184180
|
||||
|
||||
#define FS_OFFSET_1500_EXFAT_SDMMC_WRAPPER_CONTROLLER_OPEN 0x18AC40
|
||||
#define FS_OFFSET_1500_EXFAT_SDMMC_WRAPPER_CONTROLLER_CLOSE 0x18AC60
|
||||
|
||||
// Misc Data
|
||||
#define FS_OFFSET_1500_EXFAT_SD_MUTEX 0x10053F0
|
||||
#define FS_OFFSET_1500_EXFAT_NAND_MUTEX 0x10002E8
|
||||
#define FS_OFFSET_1500_EXFAT_ACTIVE_PARTITION 0x1000328
|
||||
#define FS_OFFSET_1500_EXFAT_SDMMC_DAS_HANDLE 0xFE08D8
|
||||
|
||||
// NOPs
|
||||
#define FS_OFFSET_1500_EXFAT_SD_DAS_INIT 0x25454
|
||||
|
||||
// Nintendo Paths
|
||||
#define FS_OFFSET_1500_EXFAT_NINTENDO_PATHS \
|
||||
{ \
|
||||
{.opcode_reg = 3, .adrp_offset = 0x00063050, .add_rel_offset = 0x00000004}, \
|
||||
{.opcode_reg = 3, .adrp_offset = 0x0006FDE8, .add_rel_offset = 0x00000004}, \
|
||||
{.opcode_reg = 4, .adrp_offset = 0x000768D4, .add_rel_offset = 0x00000004}, \
|
||||
{.opcode_reg = 4, .adrp_offset = 0x00089364, .add_rel_offset = 0x00000004}, \
|
||||
{.opcode_reg = 0, .adrp_offset = 0, .add_rel_offset = 0}, \
|
||||
}
|
||||
|
||||
#endif // __FS_1500_EXFAT_H__
|
||||
28
emummc/source/nx/cache.s
vendored
28
emummc/source/nx/cache.s
vendored
@@ -27,10 +27,6 @@ CODE_BEGIN armDCacheFlush
|
||||
bic x8, x0, x10
|
||||
mov x10, x1
|
||||
|
||||
mov w1, #1
|
||||
mrs x0, tpidrro_el0
|
||||
strb w1, [x0, #0x104]
|
||||
|
||||
armDCacheFlush_L0:
|
||||
dc civac, x8
|
||||
add x8, x8, x9
|
||||
@@ -38,9 +34,6 @@ armDCacheFlush_L0:
|
||||
bcc armDCacheFlush_L0
|
||||
|
||||
dsb sy
|
||||
|
||||
strb wzr, [x0, #0x104]
|
||||
|
||||
ret
|
||||
CODE_END
|
||||
|
||||
@@ -55,10 +48,6 @@ CODE_BEGIN armDCacheClean
|
||||
bic x8, x0, x10
|
||||
mov x10, x1
|
||||
|
||||
mov w1, #1
|
||||
mrs x0, tpidrro_el0
|
||||
strb w1, [x0, #0x104]
|
||||
|
||||
armDCacheClean_L0:
|
||||
dc cvac, x8
|
||||
add x8, x8, x9
|
||||
@@ -66,9 +55,6 @@ armDCacheClean_L0:
|
||||
bcc armDCacheClean_L0
|
||||
|
||||
dsb sy
|
||||
|
||||
strb wzr, [x0, #0x104]
|
||||
|
||||
ret
|
||||
CODE_END
|
||||
|
||||
@@ -82,10 +68,6 @@ CODE_BEGIN armICacheInvalidate
|
||||
bic x8, x0, x10
|
||||
mov x10, x1
|
||||
|
||||
mov w1, #1
|
||||
mrs x0, tpidrro_el0
|
||||
strb w1, [x0, #0x104]
|
||||
|
||||
armICacheInvalidate_L0:
|
||||
ic ivau, x8
|
||||
add x8, x8, x9
|
||||
@@ -93,9 +75,6 @@ armICacheInvalidate_L0:
|
||||
bcc armICacheInvalidate_L0
|
||||
|
||||
dsb sy
|
||||
|
||||
strb wzr, [x0, #0x104]
|
||||
|
||||
ret
|
||||
CODE_END
|
||||
|
||||
@@ -110,10 +89,6 @@ CODE_BEGIN armDCacheZero
|
||||
bic x8, x0, x10
|
||||
mov x10, x1
|
||||
|
||||
mov w1, #1
|
||||
mrs x0, tpidrro_el0
|
||||
strb w1, [x0, #0x104]
|
||||
|
||||
armDCacheZero_L0:
|
||||
dc zva, x8
|
||||
add x8, x8, x9
|
||||
@@ -121,8 +96,5 @@ armDCacheZero_L0:
|
||||
bcc armDCacheZero_L0
|
||||
|
||||
dsb sy
|
||||
|
||||
strb wzr, [x0, #0x104]
|
||||
|
||||
ret
|
||||
CODE_END
|
||||
|
||||
@@ -62,7 +62,7 @@ namespace ams::secmon::fatal {
|
||||
/* Write the context to the file. */
|
||||
R_TRY(fs::WriteFile(file, 0, ctx, sizeof(*ctx), fs::WriteOption::Flush));
|
||||
|
||||
R_SUCCEED();
|
||||
return ResultSuccess();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -48,11 +48,11 @@ namespace ams::secmon::fatal {
|
||||
//sdmmc::Deactivate(Port);
|
||||
R_TRY(sdmmc::Activate(Port));
|
||||
|
||||
R_SUCCEED();
|
||||
return ResultSuccess();
|
||||
}
|
||||
|
||||
Result CheckSdCardConnection(sdmmc::SpeedMode *out_sm, sdmmc::BusWidth *out_bw) {
|
||||
R_RETURN(sdmmc::CheckSdCardConnection(out_sm, out_bw, Port));
|
||||
return sdmmc::CheckSdCardConnection(out_sm, out_bw, Port);
|
||||
}
|
||||
|
||||
Result ReadSdCard(void *dst, size_t size, size_t sector_index, size_t sector_count) {
|
||||
@@ -78,7 +78,7 @@ namespace ams::secmon::fatal {
|
||||
sector_count -= cur_sectors;
|
||||
}
|
||||
|
||||
R_SUCCEED();
|
||||
return ResultSuccess();
|
||||
}
|
||||
|
||||
Result WriteSdCard(size_t sector_index, size_t sector_count, const void *src, size_t size) {
|
||||
@@ -104,7 +104,7 @@ namespace ams::secmon::fatal {
|
||||
sector_count -= cur_sectors;
|
||||
}
|
||||
|
||||
R_SUCCEED();
|
||||
return ResultSuccess();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -34,45 +34,45 @@ namespace ams::fs {
|
||||
Result TranslateFatFsError(FRESULT res) {
|
||||
switch (res) {
|
||||
case FR_OK:
|
||||
R_SUCCEED();
|
||||
return ResultSuccess();
|
||||
case FR_DISK_ERR:
|
||||
R_THROW(fs::ResultMmcAccessFailed());
|
||||
return fs::ResultMmcAccessFailed();
|
||||
case FR_INT_ERR:
|
||||
R_THROW(fs::ResultPreconditionViolation());
|
||||
return fs::ResultPreconditionViolation();
|
||||
case FR_NOT_READY:
|
||||
R_THROW(fs::ResultMmcAccessFailed());
|
||||
return fs::ResultMmcAccessFailed();
|
||||
case FR_NO_FILE:
|
||||
R_THROW(fs::ResultPathNotFound());
|
||||
return fs::ResultPathNotFound();
|
||||
case FR_NO_PATH:
|
||||
R_THROW(fs::ResultPathNotFound());
|
||||
return fs::ResultPathNotFound();
|
||||
case FR_INVALID_NAME:
|
||||
R_THROW(fs::ResultInvalidPath());
|
||||
return fs::ResultInvalidPath();
|
||||
case FR_DENIED:
|
||||
R_THROW(fs::ResultPermissionDenied());
|
||||
return fs::ResultPermissionDenied();
|
||||
case FR_EXIST:
|
||||
R_THROW(fs::ResultPathAlreadyExists());
|
||||
return fs::ResultPathAlreadyExists();
|
||||
case FR_INVALID_OBJECT:
|
||||
R_THROW(fs::ResultInvalidArgument());
|
||||
return fs::ResultInvalidArgument();
|
||||
case FR_WRITE_PROTECTED:
|
||||
R_THROW(fs::ResultWriteNotPermitted());
|
||||
return fs::ResultWriteNotPermitted();
|
||||
case FR_INVALID_DRIVE:
|
||||
R_THROW(fs::ResultInvalidMountName());
|
||||
return fs::ResultInvalidMountName();
|
||||
case FR_NOT_ENABLED:
|
||||
R_THROW(fs::ResultInvalidMountName()); /* BAD/TODO */
|
||||
return fs::ResultInvalidMountName(); /* BAD/TODO */
|
||||
case FR_NO_FILESYSTEM:
|
||||
R_THROW(fs::ResultInvalidMountName()); /* BAD/TODO */
|
||||
return fs::ResultInvalidMountName(); /* BAD/TODO */
|
||||
case FR_TIMEOUT:
|
||||
R_THROW(fs::ResultTargetLocked()); /* BAD/TODO */
|
||||
return fs::ResultTargetLocked(); /* BAD/TODO */
|
||||
case FR_LOCKED:
|
||||
R_THROW(fs::ResultTargetLocked());
|
||||
return fs::ResultTargetLocked();
|
||||
case FR_NOT_ENOUGH_CORE:
|
||||
R_THROW(fs::ResultPreconditionViolation()); /* BAD/TODO */
|
||||
return fs::ResultPreconditionViolation(); /* BAD/TODO */
|
||||
case FR_TOO_MANY_OPEN_FILES:
|
||||
R_THROW(fs::ResultPreconditionViolation()); /* BAD/TODO */
|
||||
return fs::ResultPreconditionViolation(); /* BAD/TODO */
|
||||
case FR_INVALID_PARAMETER:
|
||||
R_THROW(fs::ResultInvalidArgument());
|
||||
return fs::ResultInvalidArgument();
|
||||
default:
|
||||
R_THROW(fs::ResultInternal());
|
||||
return fs::ResultInternal();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -125,11 +125,11 @@ namespace ams::fs {
|
||||
/* Expand the file. */
|
||||
R_TRY(TranslateFatFsError(f_expand(std::addressof(fp), size, 1)));
|
||||
|
||||
R_SUCCEED();
|
||||
return ResultSuccess();
|
||||
}
|
||||
|
||||
Result CreateDirectory(const char *path) {
|
||||
R_RETURN(TranslateFatFsError(f_mkdir(path)));
|
||||
return TranslateFatFsError(f_mkdir(path));
|
||||
}
|
||||
|
||||
Result OpenFile(FileHandle *out_file, const char *path, int mode) {
|
||||
@@ -144,10 +144,10 @@ namespace ams::fs {
|
||||
out_file->_handle = fp;
|
||||
g_files_opened[i] = true;
|
||||
g_open_modes[i] = mode;
|
||||
R_SUCCEED();
|
||||
return ResultSuccess();
|
||||
}
|
||||
}
|
||||
R_THROW(fs::ResultOpenCountLimit());
|
||||
return fs::ResultOpenCountLimit();
|
||||
}
|
||||
|
||||
Result ReadFile(FileHandle handle, s64 offset, void *buffer, size_t size, const fs::ReadOption &option) {
|
||||
@@ -164,11 +164,11 @@ namespace ams::fs {
|
||||
/* Check that we read the correct amount. */
|
||||
R_UNLESS(br == size, fs::ResultOutOfRange());
|
||||
|
||||
R_SUCCEED();
|
||||
return ResultSuccess();
|
||||
}
|
||||
|
||||
Result ReadFile(FileHandle handle, s64 offset, void *buffer, size_t size) {
|
||||
R_RETURN(ReadFile(handle, offset, buffer, size, fs::ReadOption::None));
|
||||
return ReadFile(handle, offset, buffer, size, fs::ReadOption::None);
|
||||
}
|
||||
|
||||
Result ReadFile(size_t *out, FileHandle handle, s64 offset, void *buffer, size_t size, const fs::ReadOption &option) {
|
||||
@@ -185,21 +185,21 @@ namespace ams::fs {
|
||||
/* Set the output size. */
|
||||
*out = br;
|
||||
|
||||
R_SUCCEED();
|
||||
return ResultSuccess();
|
||||
}
|
||||
|
||||
Result ReadFile(size_t *out, FileHandle handle, s64 offset, void *buffer, size_t size) {
|
||||
R_RETURN(ReadFile(out, handle, offset, buffer, size, fs::ReadOption::None));
|
||||
return ReadFile(out, handle, offset, buffer, size, fs::ReadOption::None);
|
||||
}
|
||||
|
||||
Result GetFileSize(s64 *out, FileHandle handle) {
|
||||
FIL *fp = GetInternalFile(handle);
|
||||
*out = f_size(fp);
|
||||
R_SUCCEED();
|
||||
return ResultSuccess();
|
||||
}
|
||||
|
||||
Result FlushFile(FileHandle handle) {
|
||||
R_RETURN(TranslateFatFsError(f_sync(GetInternalFile(handle))));
|
||||
return TranslateFatFsError(f_sync(GetInternalFile(handle)));
|
||||
}
|
||||
|
||||
Result WriteFile(FileHandle handle, s64 offset, const void *buffer, size_t size, const fs::WriteOption &option) {
|
||||
@@ -218,7 +218,7 @@ namespace ams::fs {
|
||||
R_TRY(FlushFile(handle));
|
||||
}
|
||||
|
||||
R_SUCCEED();
|
||||
return ResultSuccess();
|
||||
}
|
||||
|
||||
Result SetFileSize(FileHandle handle, s64 size) {
|
||||
@@ -242,7 +242,7 @@ namespace ams::fs {
|
||||
/* Check that our expansion succeeded. */
|
||||
AMS_ASSERT(f_size(fp) == static_cast<FSIZE_t>(size));
|
||||
|
||||
R_SUCCEED();
|
||||
return ResultSuccess();
|
||||
}
|
||||
|
||||
int GetFileOpenMode(FileHandle handle) {
|
||||
|
||||
@@ -85,10 +85,10 @@ _ZN3ams6secmon4boot15VolatileKeyDataE:
|
||||
/* We can get away with only including latest because exosphere supports newer-than-expected master key in engine. */
|
||||
/* TODO: Update on next change of keys. */
|
||||
/* Mariko Development Master Kek Source. */
|
||||
.byte 0x18, 0xA5, 0x6F, 0xEF, 0x72, 0x11, 0x62, 0xC5, 0x1A, 0x14, 0xF1, 0x8C, 0x21, 0x83, 0x27, 0xB7
|
||||
.byte 0x4D, 0x5A, 0xB2, 0xC9, 0xE9, 0xE4, 0x4E, 0xA4, 0xD3, 0xBF, 0x94, 0x12, 0x36, 0x30, 0xD0, 0x7F
|
||||
|
||||
/* Mariko Production Master Kek Source. */
|
||||
.byte 0xEC, 0x61, 0xBC, 0x82, 0x1E, 0x0F, 0x5A, 0xC3, 0x2B, 0x64, 0x3F, 0x9D, 0xD6, 0x19, 0x22, 0x2D
|
||||
.byte 0x52, 0x71, 0x9B, 0xDF, 0xA7, 0x8B, 0x61, 0xD8, 0xD5, 0x85, 0x11, 0xE4, 0x8E, 0x4F, 0x74, 0xC6
|
||||
|
||||
/* Development Master Key Vectors. */
|
||||
.byte 0x46, 0x22, 0xB4, 0x51, 0x9A, 0x7E, 0xA7, 0x7F, 0x62, 0xA1, 0x1F, 0x8F, 0xC5, 0x3A, 0xDB, 0xFE /* Zeroes encrypted with Master Key 00. */
|
||||
@@ -104,8 +104,6 @@ _ZN3ams6secmon4boot15VolatileKeyDataE:
|
||||
.byte 0x6C, 0x2E, 0xCD, 0xB3, 0x34, 0x61, 0x77, 0xF5, 0xF9, 0xB1, 0xDD, 0x61, 0x98, 0x19, 0x3E, 0xD4 /* Master key 09 encrypted with Master key 0A. */
|
||||
.byte 0x21, 0x88, 0x6B, 0x10, 0x9E, 0x83, 0xD6, 0x52, 0xAB, 0x08, 0xDB, 0x6D, 0x39, 0xFF, 0x1C, 0x9C /* Master key 0A encrypted with Master key 0B. */
|
||||
.byte 0x8A, 0xCE, 0xC4, 0x7F, 0xBE, 0x08, 0x61, 0x88, 0xD3, 0x73, 0x64, 0x51, 0xE2, 0xB6, 0x53, 0x15 /* Master key 0B encrypted with Master key 0C. */
|
||||
.byte 0x08, 0xE0, 0xF4, 0xBE, 0xAA, 0x6E, 0x5A, 0xC3, 0xA6, 0xBC, 0xFE, 0xB9, 0xE2, 0xA3, 0x24, 0x12 /* Master key 0C encrypted with Master key 0D. */
|
||||
.byte 0xD6, 0x80, 0x98, 0xC0, 0xFA, 0xC7, 0x13, 0xCB, 0x93, 0xD2, 0x0B, 0x82, 0x4C, 0xA1, 0x7B, 0x8D /* Master key 0D encrypted with Master key 0E. */
|
||||
|
||||
/* Production Master Key Vectors. */
|
||||
.byte 0x0C, 0xF0, 0x59, 0xAC, 0x85, 0xF6, 0x26, 0x65, 0xE1, 0xE9, 0x19, 0x55, 0xE6, 0xF2, 0x67, 0x3D /* Zeroes encrypted with Master Key 00. */
|
||||
@@ -121,8 +119,6 @@ _ZN3ams6secmon4boot15VolatileKeyDataE:
|
||||
.byte 0xB8, 0x96, 0x9E, 0x4A, 0x00, 0x0D, 0xD6, 0x28, 0xB3, 0xD1, 0xDB, 0x68, 0x5F, 0xFB, 0xE1, 0x2A /* Master key 09 encrypted with Master key 0A. */
|
||||
.byte 0xC1, 0x8D, 0x16, 0xBB, 0x2A, 0xE4, 0x1D, 0xD4, 0xC2, 0xC1, 0xB6, 0x40, 0x94, 0x35, 0x63, 0x98 /* Master key 0A encrypted with Master key 0B. */
|
||||
.byte 0xA3, 0x24, 0x65, 0x75, 0xEA, 0xCC, 0x6E, 0x8D, 0xFB, 0x5A, 0x16, 0x50, 0x74, 0xD2, 0x15, 0x06 /* Master key 0B encrypted with Master key 0C. */
|
||||
.byte 0x83, 0x67, 0xAF, 0x01, 0xCF, 0x93, 0xA1, 0xAB, 0x80, 0x45, 0xF7, 0x3F, 0x72, 0xFD, 0x3B, 0x38 /* Master key 0C encrypted with Master key 0D. */
|
||||
.byte 0xB1, 0x81, 0xA6, 0x0D, 0x72, 0xC7, 0xEE, 0x15, 0x21, 0xF3, 0xC0, 0xB5, 0x6B, 0x61, 0x6D, 0xE7 /* Master key 0D encrypted with Master key 0E. */
|
||||
|
||||
/* Device Master Key Source Sources. */
|
||||
.byte 0x8B, 0x4E, 0x1C, 0x22, 0x42, 0x07, 0xC8, 0x73, 0x56, 0x94, 0x08, 0x8B, 0xCC, 0x47, 0x0F, 0x5D /* 4.0.0 Device Master Key Source Source. */
|
||||
@@ -135,8 +131,6 @@ _ZN3ams6secmon4boot15VolatileKeyDataE:
|
||||
.byte 0x14, 0xB8, 0x74, 0x12, 0xCB, 0xBD, 0x0B, 0x8F, 0x20, 0xFB, 0x30, 0xDA, 0x27, 0xE4, 0x58, 0x94 /* 9.1.0 Device Master Key Source Source. */
|
||||
.byte 0xAA, 0xFD, 0xBC, 0xBB, 0x25, 0xC3, 0xA4, 0xEF, 0xE3, 0xEE, 0x58, 0x53, 0xB7, 0xF8, 0xDD, 0xD6 /* 12.1.0 Device Master Key Source Source. */
|
||||
.byte 0xE4, 0xF3, 0x45, 0x6F, 0x18, 0xA1, 0x89, 0xF8, 0xDA, 0x4C, 0x64, 0x75, 0x68, 0xE6, 0xBD, 0x4F /* 13.0.0 Device Master Key Source Source. */
|
||||
.byte 0x5B, 0x94, 0x63, 0xF7, 0xAD, 0x96, 0x1B, 0xA6, 0x23, 0x30, 0x06, 0x4D, 0x01, 0xE4, 0xCE, 0x1D /* 14.0.0 Device Master Key Source Source. */
|
||||
.byte 0x5E, 0xC9, 0xC5, 0x0A, 0xD0, 0x5F, 0x8B, 0x7B, 0xA7, 0x39, 0xEA, 0xBC, 0x60, 0x0F, 0x74, 0xE6 /* 15.0.0 Device Master Key Source Source. */
|
||||
|
||||
/* Development Device Master Kek Sources. */
|
||||
.byte 0xD6, 0xBD, 0x9F, 0xC6, 0x18, 0x09, 0xE1, 0x96, 0x20, 0x39, 0x60, 0xD2, 0x89, 0x83, 0x31, 0x34 /* 4.0.0 Device Master Kek Source. */
|
||||
@@ -149,8 +143,6 @@ _ZN3ams6secmon4boot15VolatileKeyDataE:
|
||||
.byte 0x9D, 0xB1, 0xAE, 0xCB, 0xF6, 0xF6, 0xE3, 0xFE, 0xAB, 0x6F, 0xCB, 0xAF, 0x38, 0x03, 0xFC, 0x7B /* 9.1.0 Device Master Kek Source. */
|
||||
.byte 0xC4, 0xBB, 0xF3, 0x9F, 0xA3, 0xAA, 0x00, 0x99, 0x7C, 0x97, 0xAD, 0x91, 0x8F, 0xE8, 0x45, 0xCB /* 12.1.0 Device Master Kek Source. */
|
||||
.byte 0x20, 0x20, 0xAA, 0xFB, 0x89, 0xC2, 0xF0, 0x70, 0xB5, 0xE0, 0xA3, 0x11, 0x8A, 0x29, 0x8D, 0x0F /* 13.0.0 Device Master Kek Source. */
|
||||
.byte 0xCE, 0x14, 0x74, 0x66, 0x98, 0xA8, 0x6D, 0x7D, 0xBD, 0x54, 0x91, 0x68, 0x5F, 0x1D, 0x0E, 0xEA /* 14.0.0 Device Master Kek Source. */
|
||||
.byte 0xAE, 0x05, 0x48, 0x65, 0xAB, 0x17, 0x9D, 0x3D, 0x51, 0xB7, 0x56, 0xBD, 0x9B, 0x0B, 0x5B, 0x6E /* 15.0.0 Device Master Kek Source. */
|
||||
|
||||
/* Production Device Master Kek Sources. */
|
||||
.byte 0x88, 0x62, 0x34, 0x6E, 0xFA, 0xF7, 0xD8, 0x3F, 0xE1, 0x30, 0x39, 0x50, 0xF0, 0xB7, 0x5D, 0x5D /* 4.0.0 Device Master Kek Source. */
|
||||
@@ -163,5 +155,3 @@ _ZN3ams6secmon4boot15VolatileKeyDataE:
|
||||
.byte 0xCE, 0xFE, 0x41, 0x0F, 0x46, 0x9A, 0x30, 0xD6, 0xF2, 0xE9, 0x0C, 0x6B, 0xB7, 0x15, 0x91, 0x36 /* 9.1.0 Device Master Kek Source. */
|
||||
.byte 0xC2, 0x65, 0x34, 0x6E, 0xC7, 0xC6, 0x5D, 0x97, 0x3E, 0x34, 0x5C, 0x6B, 0xB3, 0x7E, 0xC6, 0xE3 /* 12.1.0 Device Master Kek Source. */
|
||||
.byte 0x77, 0x52, 0x92, 0xF0, 0xAA, 0xE3, 0xFB, 0xE0, 0x60, 0x16, 0xB3, 0x78, 0x68, 0x53, 0xF7, 0xA8 /* 13.0.0 Device Master Kek Source. */
|
||||
.byte 0x67, 0xD5, 0xD6, 0x0C, 0x08, 0xF5, 0xA3, 0x11, 0xBD, 0x6D, 0x5A, 0xEB, 0x96, 0x24, 0xB0, 0xD2 /* 14.0.0 Device Master Kek Source. */
|
||||
.byte 0x7C, 0x30, 0xED, 0x8B, 0x39, 0x25, 0x2C, 0x08, 0x8F, 0x48, 0xDC, 0x28, 0xE6, 0x1A, 0x6B, 0x49 /* 15.0.0 Device Master Kek Source. */
|
||||
|
||||
@@ -94,7 +94,7 @@ namespace ams::secmon::boot {
|
||||
}
|
||||
|
||||
/* Check that the key generation is one that we can use. */
|
||||
static_assert(pkg1::KeyGeneration_Count == 15);
|
||||
static_assert(pkg1::KeyGeneration_Count == 13);
|
||||
if (key_generation >= pkg1::KeyGeneration_Count) {
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -365,9 +365,9 @@ namespace ams::secmon {
|
||||
reg::Write(MC + MC_SECURITY_CARVEOUT4_CFG0, carveout_config);
|
||||
|
||||
/* Configure carveout 5. */
|
||||
reg::Write(MC + MC_SECURITY_CARVEOUT5_BOM, g_kernel_carveouts[1].address >> 0);
|
||||
reg::Write(MC + MC_SECURITY_CARVEOUT5_BOM_HI, g_kernel_carveouts[1].address >> 32);
|
||||
reg::Write(MC + MC_SECURITY_CARVEOUT5_SIZE_128KB, g_kernel_carveouts[1].size / 128_KB);
|
||||
reg::Write(MC + MC_SECURITY_CARVEOUT5_BOM, g_kernel_carveouts[0].address >> 0);
|
||||
reg::Write(MC + MC_SECURITY_CARVEOUT5_BOM_HI, g_kernel_carveouts[0].address >> 32);
|
||||
reg::Write(MC + MC_SECURITY_CARVEOUT5_SIZE_128KB, g_kernel_carveouts[0].size / 128_KB);
|
||||
reg::Write(MC + MC_SECURITY_CARVEOUT5_CLIENT_ACCESS0, ClientAccess0);
|
||||
reg::Write(MC + MC_SECURITY_CARVEOUT5_CLIENT_ACCESS1, ClientAccess1);
|
||||
reg::Write(MC + MC_SECURITY_CARVEOUT5_CLIENT_ACCESS2, client_access_2);
|
||||
|
||||
@@ -52,7 +52,7 @@ namespace ams::secmon::smc {
|
||||
[fuse::DramId_IcosaSamsung6GB] = pkg1::MemorySize_6GB,
|
||||
[fuse::DramId_HoagHynix1y4GB] = pkg1::MemorySize_4GB,
|
||||
[fuse::DramId_AulaHynix1y4GB] = pkg1::MemorySize_4GB,
|
||||
[fuse::DramId_Deprecated7] = pkg1::MemorySize_4GB,
|
||||
[fuse::DramId_IowaX1X2Samsung4GB] = pkg1::MemorySize_4GB,
|
||||
[fuse::DramId_IowaSansung4GB] = pkg1::MemorySize_4GB,
|
||||
[fuse::DramId_IowaSamsung8GB] = pkg1::MemorySize_8GB,
|
||||
[fuse::DramId_IowaHynix4GB] = pkg1::MemorySize_4GB,
|
||||
@@ -61,25 +61,19 @@ namespace ams::secmon::smc {
|
||||
[fuse::DramId_HoagSamsung8GB] = pkg1::MemorySize_8GB,
|
||||
[fuse::DramId_HoagHynix4GB] = pkg1::MemorySize_4GB,
|
||||
[fuse::DramId_HoagMicron4GB] = pkg1::MemorySize_4GB,
|
||||
[fuse::DramId_Deprecated16] = pkg1::MemorySize_4GB,
|
||||
[fuse::DramId_IowaSamsung4GBY] = pkg1::MemorySize_4GB,
|
||||
[fuse::DramId_IowaSamsung1y4GBX] = pkg1::MemorySize_4GB,
|
||||
[fuse::DramId_IowaSamsung1y8GBX] = pkg1::MemorySize_8GB,
|
||||
[fuse::DramId_HoagSamsung1y4GBX] = pkg1::MemorySize_4GB,
|
||||
[fuse::DramId_IowaSamsung1z4GB] = pkg1::MemorySize_4GB,
|
||||
[fuse::DramId_HoagSamsung1z4GB] = pkg1::MemorySize_4GB,
|
||||
[fuse::DramId_AulaSamsung1z4GB] = pkg1::MemorySize_4GB,
|
||||
[fuse::DramId_IowaSamsung1y4GBY] = pkg1::MemorySize_4GB,
|
||||
[fuse::DramId_IowaSamsung1y8GBY] = pkg1::MemorySize_8GB,
|
||||
[fuse::DramId_AulaSamsung1y4GB] = pkg1::MemorySize_4GB,
|
||||
[fuse::DramId_HoagSamsung1y8GBX] = pkg1::MemorySize_8GB,
|
||||
[fuse::DramId_AulaSamsung1y4GBX] = pkg1::MemorySize_4GB,
|
||||
[fuse::DramId_IowaMicron1y4GB] = pkg1::MemorySize_4GB,
|
||||
[fuse::DramId_HoagMicron1y4GB] = pkg1::MemorySize_4GB,
|
||||
[fuse::DramId_AulaMicron1y4GB] = pkg1::MemorySize_4GB,
|
||||
[fuse::DramId_AulaSamsung1y8GBX] = pkg1::MemorySize_8GB,
|
||||
[fuse::DramId_IowaX1X2Samsung4GB] = pkg1::MemorySize_4GB,
|
||||
[fuse::DramId_HoagX1X2Samsung4GB] = pkg1::MemorySize_4GB,
|
||||
[fuse::DramId_AulaX1X2Samsung4GB] = pkg1::MemorySize_4GB,
|
||||
[fuse::DramId_IowaSamsung4GBY] = pkg1::MemorySize_4GB,
|
||||
[fuse::DramId_HoagSamsung4GBY] = pkg1::MemorySize_4GB,
|
||||
[fuse::DramId_AulaSamsung4GBY] = pkg1::MemorySize_4GB,
|
||||
};
|
||||
|
||||
constexpr const pkg1::MemoryMode MemoryModes[] = {
|
||||
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user