1
0
Fork 0
mirror of https://github.com/CTCaer/hekate.git synced 2024-12-22 16:12:03 +00:00

hekate/nyx: utilize bdk global header

This commit is contained in:
CTCaer 2022-01-16 00:04:34 +02:00
parent a5cd962f99
commit 5894062b93
55 changed files with 97 additions and 389 deletions

View file

@ -17,19 +17,11 @@
#include <string.h>
#include <stdlib.h>
#include <bdk.h>
#include "config.h"
#include <utils/ini.h>
#include <gfx_utils.h>
#include "gfx/tui.h"
#include <libs/fatfs/ff.h>
#include <soc/fuse.h>
#include <soc/hw_init.h>
#include <soc/t210.h>
#include <storage/nx_sd.h>
#include <storage/sdmmc.h>
#include <utils/btn.h>
#include <utils/list.h>
#include <utils/util.h>
extern hekate_config h_cfg;

View file

@ -17,8 +17,9 @@
#ifndef _CONFIG_H_
#define _CONFIG_H_
#include <bdk.h>
#include "hos/hos.h"
#include <utils/types.h>
typedef struct _hekate_config
{

View file

@ -19,20 +19,13 @@
#include <string.h>
#include <stdlib.h>
#include <bdk.h>
#include "fe_emmc_tools.h"
#include <memory_map.h>
#include "../config.h"
#include <gfx_utils.h>
#include "../gfx/tui.h"
#include <libs/fatfs/ff.h>
#include <mem/heap.h>
#include <sec/se.h>
#include <sec/se_t210.h>
#include "../storage/nx_emmc.h"
#include <storage/nx_sd.h>
#include <storage/sdmmc.h>
#include <utils/btn.h>
#include <utils/util.h>
#define NUM_SECTORS_PER_ITER 8192 // 4MB Cache.
#define OUT_FILENAME_SZ 128

View file

@ -18,28 +18,14 @@
#include <string.h>
#include <bdk.h>
#include "fe_info.h"
#include "../config.h"
#include <gfx_utils.h>
#include "../hos/hos.h"
#include "../hos/pkg1.h"
#include <libs/fatfs/ff.h>
#include <mem/heap.h>
#include <mem/smmu.h>
#include <power/bq24193.h>
#include <power/max17050.h>
#include <sec/se_t210.h>
#include <sec/tsec.h>
#include <soc/fuse.h>
#include <soc/i2c.h>
#include <soc/kfuse.h>
#include <soc/t210.h>
#include <storage/mmc.h>
#include "../storage/nx_emmc.h"
#include <storage/nx_sd.h>
#include <storage/sdmmc.h>
#include <utils/btn.h>
#include <utils/util.h>
extern hekate_config h_cfg;
extern void emmcsn_path_impl(char *path, char *sub_dir, char *filename, sdmmc_storage_t *storage);

View file

@ -19,24 +19,16 @@
#include <string.h>
#include <stdlib.h>
#include <bdk.h>
#include "fe_tools.h"
#include "../config.h"
#include <gfx_utils.h>
#include "../gfx/tui.h"
#include "../hos/hos.h"
#include "../hos/pkg1.h"
#include "../hos/pkg2.h"
#include <libs/fatfs/ff.h>
#include <mem/heap.h>
#include <power/max7762x.h>
#include <sec/se.h>
#include <sec/se_t210.h>
#include "../storage/nx_emmc.h"
#include <storage/nx_sd.h>
#include <storage/sdmmc.h>
#include <soc/fuse.h>
#include <utils/btn.h>
#include <utils/util.h>
extern boot_cfg_t b_cfg;
extern hekate_config h_cfg;

View file

@ -19,7 +19,7 @@
#ifndef _GFX_H_
#define _GFX_H_
#include <utils/types.h>
#include <bdk.h>
#define EPRINTF(text) gfx_printf("%k"text"%k\n", 0xFFFF0000, 0xFFCCCCCC)
#define EPRINTFARGS(text, args...) gfx_printf("%k"text"%k\n", 0xFFFF0000, args, 0xFFCCCCCC)

View file

@ -15,12 +15,10 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include <display/di.h>
#include <bdk.h>
#include "tui.h"
#include "../config.h"
#include <power/max17050.h>
#include <utils/btn.h>
#include <utils/util.h>
extern hekate_config h_cfg;

View file

@ -18,8 +18,7 @@
#ifndef _TUI_H_
#define _TUI_H_
#include <utils/types.h>
#include <gfx_utils.h>
#include <bdk.h>
#define MENT_END 0
#define MENT_HANDLER 1

View file

@ -18,15 +18,15 @@
#include <string.h>
#include <bdk.h>
#include "fss.h"
#include "hos.h"
#include "../config.h"
#include <libs/fatfs/ff.h>
#include <mem/heap.h>
#include "../storage/emummc.h"
#include <storage/nx_sd.h>
#include <gfx_utils.h>
//#define DPRINTF(...) gfx_printf(__VA_ARGS__)
#define DPRINTF(...)
extern hekate_config h_cfg;

View file

@ -20,32 +20,14 @@
#include <string.h>
#include <bdk.h>
#include "hos.h"
#include "hos_config.h"
#include "secmon_exo.h"
#include "../config.h"
#include <display/di.h>
#include <gfx_utils.h>
#include <mem/heap.h>
#include <mem/mc.h>
#include <mem/minerva.h>
#include <mem/smmu.h>
#include <sec/se.h>
#include <sec/se_t210.h>
#include <sec/tsec.h>
#include <soc/bpmp.h>
#include <soc/ccplex.h>
#include <soc/clock.h>
#include <soc/fuse.h>
#include <soc/pmc.h>
#include <soc/t210.h>
#include "../storage/emummc.h"
#include <storage/mbr_gpt.h>
#include "../storage/nx_emmc.h"
#include <storage/nx_sd.h>
#include <storage/sdmmc.h>
#include <utils/btn.h>
#include <utils/util.h>
extern hekate_config h_cfg;

View file

@ -18,12 +18,10 @@
#ifndef _HOS_H_
#define _HOS_H_
#include <bdk.h>
#include "pkg1.h"
#include "pkg2.h"
#include <sec/se_t210.h>
#include <utils/types.h>
#include <utils/ini.h>
#include <sec/tsec.h>
#include <assert.h>

View file

@ -17,15 +17,12 @@
#include <string.h>
#include <bdk.h>
#include "hos.h"
#include "hos_config.h"
#include "fss.h"
#include <libs/fatfs/ff.h>
#include <mem/heap.h>
#include <storage/nx_sd.h>
#include <utils/dirlist.h>
#include <gfx_utils.h>
//#define DPRINTF(...) gfx_printf(__VA_ARGS__)
#define DPRINTF(...)

View file

@ -20,19 +20,12 @@
#include <string.h>
#include <stdlib.h>
#include <bdk.h>
#include "hos.h"
#include "pkg1.h"
#include "../config.h"
#include <gfx_utils.h>
#include <libs/compr/lz4.h>
#include <mem/heap.h>
#include <soc/fuse.h>
#include <sec/se.h>
#include <soc/pmc.h>
#include <soc/t210.h>
#include <storage/nx_sd.h>
#include <utils/aarch64_util.h>
#include <utils/util.h>
extern hekate_config h_cfg;

View file

@ -17,7 +17,7 @@
#ifndef _PKG1_H_
#define _PKG1_H_
#include <utils/types.h>
#include <bdk.h>
#define PKG1_MAGIC 0x31314B50

View file

@ -17,6 +17,8 @@
#include <string.h>
#include <bdk.h>
#include "hos.h"
#include "pkg2.h"
#include "pkg2_ini_kippatch.h"
@ -24,14 +26,7 @@
#include "../config.h"
#include <libs/compr/blz.h>
#include <libs/fatfs/ff.h>
#include <mem/heap.h>
#include <sec/se.h>
#include <sec/se_t210.h>
#include "../storage/emummc.h"
#include <storage/nx_sd.h>
#include <utils/aarch64_util.h>
#include <gfx_utils.h>
extern hekate_config h_cfg;
extern const u8 package2_keyseed[];
@ -41,7 +36,6 @@ u32 pkg2_newkern_ini1_start;
u32 pkg2_newkern_ini1_end;
#ifdef KIP1_PATCH_DEBUG
#include <utils/util.h>
#define DPRINTF(...) gfx_printf(__VA_ARGS__)
#define DEBUG_PRINTING
#else

View file

@ -18,8 +18,7 @@
#ifndef _PKG2_H_
#define _PKG2_H_
#include <utils/types.h>
#include <utils/list.h>
#include <bdk.h>
#define PKG2_MAGIC 0x31324B50
#define PKG2_SEC_BASE 0x80000000

View file

@ -1,9 +1,10 @@
#include <string.h>
#include <stdlib.h>
#include <bdk.h>
#include "pkg2_ini_kippatch.h"
#include <libs/fatfs/ff.h>
#include <mem/heap.h>
#define KPS(x) ((u32)(x) << 29)

View file

@ -17,8 +17,7 @@
#ifndef _INIPATCH_H_
#define _INIPATCH_H_
#include <utils/types.h>
#include <utils/list.h>
#include <bdk.h>
typedef struct _ini_patchset_t
{

View file

@ -18,20 +18,13 @@
#include <string.h>
#include <stdlib.h>
#include <bdk.h>
#include "hos.h"
#include "../config.h"
#include <display/di.h>
#include <gfx_utils.h>
#include <libs/fatfs/ff.h>
#include <mem/heap.h>
#include <soc/fuse.h>
#include "../storage/emummc.h"
#include "../storage/nx_emmc.h"
#include <storage/nx_sd.h>
#include <storage/sdmmc.h>
#include <utils/btn.h>
#include <utils/util.h>
#include <utils/types.h>
extern hekate_config h_cfg;

View file

@ -17,7 +17,7 @@
#ifndef _SECMON_EXO_H_
#define _SECMON_EXO_H_
#include <utils/types.h>
#include <bdk.h>
void config_exosphere(launch_ctxt_t *ctxt, u32 warmboot_base);
void secmon_exo_check_panic();

View file

@ -9,10 +9,9 @@
#include <string.h>
#include <bdk.h>
#include <libs/fatfs/diskio.h> /* FatFs lower layer API */
#include <memory_map.h>
#include <storage/nx_sd.h>
#include <storage/sdmmc.h>
/*-----------------------------------------------------------------------*/
/* Get Drive Status */

View file

@ -4,11 +4,7 @@
/* (C) CTCaer, 2018 */
/*------------------------------------------------------------------------*/
#include <libs/fatfs/ff.h>
#include <mem/heap.h>
#include <bdk.h>
#if FF_USE_LFN == 3 /* Dynamic memory allocation */

View file

@ -19,11 +19,9 @@
#include <string.h>
#include <stdlib.h>
#include <memory_map.h>
#include <bdk.h>
#include "config.h"
#include <display/di.h>
#include <gfx_utils.h>
#include "gfx/logos.h"
#include "gfx/tui.h"
#include "hos/hos.h"
@ -31,29 +29,8 @@
#include <ianos/ianos.h>
#include <libs/compr/blz.h>
#include <libs/fatfs/ff.h>
#include <mem/heap.h>
#include <mem/minerva.h>
#include <mem/sdram.h>
#include <power/bq24193.h>
#include <power/max17050.h>
#include <power/max77620.h>
#include <power/max7762x.h>
#include <rtc/max77620-rtc.h>
#include <soc/bpmp.h>
#include <soc/fuse.h>
#include <soc/hw_init.h>
#include <soc/i2c.h>
#include <soc/pmc.h>
#include <soc/t210.h>
#include <soc/uart.h>
#include "storage/emummc.h"
#include "storage/nx_emmc.h"
#include <storage/nx_sd.h>
#include <storage/sdmmc.h>
#include <utils/btn.h>
#include <utils/dirlist.h>
#include <utils/list.h>
#include <utils/util.h>
#include "frontend/fe_emmc_tools.h"
#include "frontend/fe_tools.h"

View file

@ -17,17 +17,12 @@
#include <string.h>
#include <stdlib.h>
#include <bdk.h>
#include "emummc.h"
#include <storage/sdmmc.h>
#include "../config.h"
#include <utils/ini.h>
#include <gfx_utils.h>
#include <libs/fatfs/ff.h>
#include <mem/heap.h>
#include "../storage/nx_emmc.h"
#include <storage/nx_sd.h>
#include <utils/list.h>
#include <utils/types.h>
extern hekate_config h_cfg;
emummc_cfg_t emu_cfg = { 0 };

View file

@ -17,8 +17,7 @@
#ifndef EMUMMC_H
#define EMUMMC_H
#include <storage/sdmmc.h>
#include <utils/types.h>
#include <bdk.h>
typedef enum
{

View file

@ -17,12 +17,10 @@
#include <string.h>
#include <bdk.h>
#include "nx_emmc.h"
#include "emummc.h"
#include <mem/heap.h>
#include <soc/fuse.h>
#include <storage/mbr_gpt.h>
#include <utils/list.h>
sdmmc_t emmc_sdmmc;
sdmmc_storage_t emmc_storage;

View file

@ -18,10 +18,9 @@
#ifndef _NX_EMMC_H_
#define _NX_EMMC_H_
#include <storage/sdmmc.h>
#include <bdk.h>
#include <libs/fatfs/ff.h>
#include <utils/types.h>
#include <utils/list.h>
#define NX_GPT_FIRST_LBA 1
#define NX_GPT_NUM_BLOCKS 33

View file

@ -15,12 +15,9 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include <storage/nx_sd.h>
#include <storage/sdmmc.h>
#include <storage/sdmmc_driver.h>
#include <gfx_utils.h>
#include <bdk.h>
#include <libs/fatfs/ff.h>
#include <mem/heap.h>
static bool sd_mounted = false;
static u16 sd_errors[3] = { 0 }; // Init and Read/Write errors.

View file

@ -17,18 +17,10 @@
#include <string.h>
#include <stdlib.h>
#include <bdk.h>
#include "config.h"
#include <utils/ini.h>
#include <gfx_utils.h>
#include <libs/fatfs/ff.h>
#include <soc/fuse.h>
#include <soc/hw_init.h>
#include <soc/t210.h>
#include <storage/nx_sd.h>
#include <storage/sdmmc.h>
#include <utils/btn.h>
#include <utils/list.h>
#include <utils/util.h>
extern hekate_config h_cfg;
extern nyx_config n_cfg;

View file

@ -17,8 +17,9 @@
#ifndef _CONFIG_H_
#define _CONFIG_H_
#include <bdk.h>
#include "hos/hos.h"
#include <utils/types.h>
typedef struct _hekate_config
{

View file

@ -21,22 +21,14 @@
#include <string.h>
#include <stdlib.h>
#include <bdk.h>
#include "gui.h"
#include "fe_emmc_tools.h"
#include "fe_emummc_tools.h"
#include <memory_map.h>
#include "../config.h"
#include <libs/fatfs/ff.h>
#include <mem/heap.h>
#include <sec/se.h>
#include <sec/se_t210.h>
#include <storage/mbr_gpt.h>
#include "../storage/nx_emmc.h"
#include <storage/nx_sd.h>
#include <storage/sdmmc.h>
#include <utils/btn.h>
#include <utils/sprintf.h>
#include <utils/util.h>
#define NUM_SECTORS_PER_ITER 8192 // 4MB Cache.
#define OUT_FILENAME_SZ 128

View file

@ -21,22 +21,15 @@
#include <string.h>
#include <stdlib.h>
#include <bdk.h>
#include "gui.h"
#include "fe_emummc_tools.h"
#include "../config.h"
#include <utils/ini.h>
#include <libs/fatfs/diskio.h>
#include <libs/fatfs/ff.h>
#include <mem/heap.h>
#include <sec/se.h>
#include <storage/mbr_gpt.h>
#include "../storage/nx_emmc.h"
#include "../storage/nx_emmc_bis.h"
#include <storage/nx_sd.h>
#include <storage/sdmmc.h>
#include <utils/btn.h>
#include <utils/sprintf.h>
#include <utils/util.h>
#define OUT_FILENAME_SZ 128
#define NAND_PATROL_SECTOR 0xC20

View file

@ -16,6 +16,8 @@
#include <stdlib.h>
#include <bdk.h>
#include "gui.h"
#include "gui_emummc_tools.h"
#include "gui_tools.h"
@ -26,30 +28,7 @@
#include "../gfx/logos-gui.h"
#include "../config.h"
#include <utils/ini.h>
#include <display/di.h>
#include <gfx_utils.h>
#include <input/joycon.h>
#include <input/touch.h>
#include <libs/fatfs/ff.h>
#include <mem/heap.h>
#include <mem/minerva.h>
#include <power/bq24193.h>
#include <power/max17050.h>
#include <power/regulator_5v.h>
#include <rtc/max77620-rtc.h>
#include <soc/bpmp.h>
#include <soc/fuse.h>
#include <soc/hw_init.h>
#include <soc/t210.h>
#include <storage/nx_sd.h>
#include <storage/sdmmc.h>
#include <thermal/fan.h>
#include <thermal/tmp451.h>
#include <utils/dirlist.h>
#include <utils/sprintf.h>
#include <utils/types.h>
#include <utils/util.h>
extern hekate_config h_cfg;
extern nyx_config n_cfg;

View file

@ -16,6 +16,8 @@
#include <stdlib.h>
#include <bdk.h>
#include "gui.h"
#include "gui_emmc_tools.h"
#include "gui_tools.h"
@ -25,13 +27,6 @@
#include "../hos/pkg2.h"
#include "../hos/hos.h"
#include <libs/fatfs/ff.h>
#include <mem/heap.h>
#include <sec/se.h>
#include <soc/fuse.h>
#include <storage/nx_sd.h>
#include <storage/sdmmc.h>
#include <utils/sprintf.h>
#include <utils/util.h>
extern boot_cfg_t b_cfg;
extern hekate_config h_cfg;

View file

@ -16,21 +16,13 @@
#include <stdlib.h>
#include <bdk.h>
#include "gui.h"
#include "fe_emummc_tools.h"
#include "gui_tools_partition_manager.h"
#include <memory_map.h>
#include <utils/ini.h>
#include <libs/fatfs/ff.h>
#include <mem/heap.h>
#include <storage/mbr_gpt.h>
#include "../storage/nx_emmc_bis.h"
#include <storage/nx_sd.h>
#include <storage/sdmmc.h>
#include <utils/dirlist.h>
#include <utils/list.h>
#include <utils/sprintf.h>
#include <utils/types.h>
extern char *emmcsn_path_impl(char *path, char *sub_dir, char *filename, sdmmc_storage_t *storage);

View file

@ -16,36 +16,14 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include <bdk.h>
#include "gui.h"
#include <display/di.h>
#include "../config.h"
#include "../hos/hos.h"
#include "../hos/pkg1.h"
#include <libs/fatfs/ff.h>
#include <input/touch.h>
#include <mem/emc.h>
#include <mem/heap.h>
#include <mem/sdram.h>
#include <mem/smmu.h>
#include <power/bm92t36.h>
#include <power/bq24193.h>
#include <power/max17050.h>
#include <power/max77620.h>
#include <power/max7762x.h>
#include <power/max77812.h>
#include <sec/se.h>
#include <sec/tsec.h>
#include <soc/fuse.h>
#include <soc/kfuse.h>
#include <soc/i2c.h>
#include <soc/t210.h>
#include <storage/mmc.h>
#include "../storage/nx_emmc_bis.h"
#include <storage/nx_sd.h>
#include <storage/sdmmc.h>
#include <utils/btn.h>
#include <utils/sprintf.h>
#include <utils/util.h>
#define SECTORS_TO_MIB_COEFF 11

View file

@ -16,18 +16,11 @@
#include <stdlib.h>
#include <bdk.h>
#include "gui.h"
#include "../config.h"
#include <utils/ini.h>
#include <display/di.h>
#include <input/joycon.h>
#include <libs/lvgl/lvgl.h>
#include <mem/heap.h>
#include <rtc/max77620-rtc.h>
#include <storage/nx_sd.h>
#include <utils/list.h>
#include <utils/sprintf.h>
#include <utils/types.h>
extern hekate_config h_cfg;
extern nyx_config n_cfg;

View file

@ -17,33 +17,19 @@
#include <stdlib.h>
#include <bdk.h>
#include "gui.h"
#include "gui_tools.h"
#include "gui_tools_partition_manager.h"
#include "gui_emmc_tools.h"
#include "fe_emummc_tools.h"
#include <memory_map.h>
#include "../config.h"
#include <display/di.h>
#include "../hos/pkg1.h"
#include "../hos/pkg2.h"
#include "../hos/hos.h"
#include <input/touch.h>
#include <libs/fatfs/ff.h>
#include <mem/heap.h>
#include <mem/minerva.h>
#include <sec/se.h>
#include <soc/bpmp.h>
#include <soc/fuse.h>
#include <soc/hw_init.h>
#include <soc/t210.h>
#include "../storage/nx_emmc.h"
#include <storage/nx_sd.h>
#include <storage/sdmmc.h>
#include <usb/usbd.h>
#include <utils/btn.h>
#include <utils/sprintf.h>
#include <utils/util.h>
extern volatile boot_cfg_t *b_cfg;
extern hekate_config h_cfg;

View file

@ -16,24 +16,14 @@
#include <stdlib.h>
#include <bdk.h>
#include "gui.h"
#include "gui_tools.h"
#include "gui_tools_partition_manager.h"
#include <libs/fatfs/diskio.h>
#include <libs/lvgl/lvgl.h>
#include <mem/heap.h>
#include <sec/se.h>
#include <soc/hw_init.h>
#include <soc/pmc.h>
#include <soc/t210.h>
#include <storage/mbr_gpt.h>
#include "../storage/nx_emmc.h"
#include <storage/nx_sd.h>
#include <storage/ramdisk.h>
#include <storage/sdmmc.h>
#include <utils/btn.h>
#include <utils/sprintf.h>
#include <utils/util.h>
extern volatile boot_cfg_t *b_cfg;
extern volatile nyx_storage_t *nyx_str;

View file

@ -19,7 +19,7 @@
#ifndef _GFX_H_
#define _GFX_H_
#include <utils/types.h>
#include <bdk.h>
#define EPRINTF(text) gfx_printf("%k"text"%k\n", 0xFFFF0000, 0xFFCCCCCC)
#define EPRINTFARGS(text, args...) gfx_printf("%k"text"%k\n", 0xFFFF0000, args, 0xFFCCCCCC)

View file

@ -1,11 +1,10 @@
#ifndef _LOGOS_GUI_H_
#define _LOGOS_GUI_H_
#include <memory_map.h>
#include <bdk.h>
#include <libs/lv_conf.h>
#include <libs/lvgl/lv_draw/lv_draw_img.h>
#include <utils/types.h>
#define HEKATE_LOGO

View file

@ -20,25 +20,11 @@
#include <string.h>
#include <bdk.h>
#include "hos.h"
#include "../config.h"
#include <display/di.h>
#include <gfx_utils.h>
#include <mem/heap.h>
#include <mem/mc.h>
#include <mem/smmu.h>
#include <sec/se.h>
#include <sec/se_t210.h>
#include <sec/tsec.h>
#include <soc/bpmp.h>
#include <soc/fuse.h>
#include <soc/pmc.h>
#include <soc/t210.h>
#include <storage/mbr_gpt.h>
#include "../storage/nx_emmc.h"
#include <storage/nx_sd.h>
#include <storage/sdmmc.h>
#include <utils/util.h>
extern hekate_config h_cfg;

View file

@ -18,12 +18,10 @@
#ifndef _HOS_H_
#define _HOS_H_
#include <bdk.h>
#include "pkg1.h"
#include "pkg2.h"
#include <sec/se_t210.h>
#include <utils/types.h>
#include <utils/ini.h>
#include <sec/tsec.h>
#include <assert.h>

View file

@ -19,13 +19,11 @@
#include <string.h>
#include <bdk.h>
#include "hos.h"
#include "pkg1.h"
#include "../config.h"
#include <gfx_utils.h>
#include <mem/heap.h>
#include <sec/se.h>
#include <utils/aarch64_util.h>
extern hekate_config h_cfg;

View file

@ -17,7 +17,7 @@
#ifndef _PKG1_H_
#define _PKG1_H_
#include <utils/types.h>
#include <bdk.h>
#define PKG1_MAGIC 0x31314B50

View file

@ -17,18 +17,15 @@
#include <string.h>
#include <bdk.h>
#include "pkg2.h"
#include "hos.h"
#include "../config.h"
#include <libs/fatfs/ff.h>
#include <mem/heap.h>
#include <sec/se.h>
#include <sec/se_t210.h>
#include <libs/compr/blz.h>
#include <gfx_utils.h>
extern hekate_config h_cfg;
extern const u8 package2_keyseed[];
@ -36,8 +33,7 @@ u32 pkg2_newkern_ini1_val;
u32 pkg2_newkern_ini1_start;
u32 pkg2_newkern_ini1_end;
/*#include <utils/util.h>
#define DPRINTF(...) gfx_printf(__VA_ARGS__)
/*#define DPRINTF(...) gfx_printf(__VA_ARGS__)
#define DEBUG_PRINTING*/
#define DPRINTF(...)

View file

@ -18,8 +18,7 @@
#ifndef _PKG2_H_
#define _PKG2_H_
#include <utils/types.h>
#include <utils/list.h>
#include <bdk.h>
#define PKG2_MAGIC 0x31324B50
#define PKG2_SEC_BASE 0x80000000

View file

@ -9,12 +9,10 @@
#include <string.h>
#include <bdk.h>
#include <libs/fatfs/diskio.h> /* FatFs lower layer API */
#include <memory_map.h>
#include "../../storage/nx_emmc_bis.h"
#include <storage/nx_sd.h>
#include <storage/ramdisk.h>
#include <storage/sdmmc.h>
static u32 sd_rsvd_sectors = 0;
static u32 ramdisk_sectors = 0;

View file

@ -4,11 +4,10 @@
/* (C) CTCaer, 2018 */
/*------------------------------------------------------------------------*/
#include <bdk.h>
#include <libs/fatfs/ff.h>
#include "../../config.h"
#include <mem/heap.h>
#include <rtc/max77620-rtc.h>
extern nyx_config n_cfg;

View file

@ -19,36 +19,14 @@
#include <string.h>
#include <stdlib.h>
#include <memory_map.h>
#include <bdk.h>
#include "config.h"
#include <display/di.h>
#include <gfx_utils.h>
#include "hos/hos.h"
#include "storage/nx_emmc.h"
#include <ianos/ianos.h>
#include <libs/compr/blz.h>
#include <libs/fatfs/ff.h>
#include <mem/heap.h>
#include <mem/minerva.h>
#include <mem/sdram.h>
#include <power/max77620.h>
#include <soc/clock.h>
#include <soc/bpmp.h>
#include <soc/fuse.h>
#include <soc/gpio.h>
#include <soc/hw_init.h>
#include <soc/i2c.h>
#include <soc/pinmux.h>
#include <soc/pmc.h>
#include <soc/t210.h>
#include <soc/uart.h>
#include "storage/nx_emmc.h"
#include <storage/nx_sd.h>
#include <storage/sdmmc.h>
#include <utils/btn.h>
#include <utils/dirlist.h>
#include <utils/list.h>
#include <utils/util.h>
#include "frontend/fe_emmc_tools.h"
#include "frontend/gui.h"

View file

@ -17,11 +17,9 @@
#include <string.h>
#include <bdk.h>
#include "nx_emmc.h"
#include <mem/heap.h>
#include <soc/fuse.h>
#include <storage/mbr_gpt.h>
#include <utils/list.h>
sdmmc_t emmc_sdmmc;
sdmmc_storage_t emmc_storage;

View file

@ -18,10 +18,9 @@
#ifndef _NX_EMMC_H_
#define _NX_EMMC_H_
#include <storage/sdmmc.h>
#include <bdk.h>
#include <libs/fatfs/ff.h>
#include <utils/types.h>
#include <utils/list.h>
#define NX_GPT_FIRST_LBA 1
#define NX_GPT_NUM_BLOCKS 33

View file

@ -19,15 +19,9 @@
#include <string.h>
#include <memory_map.h>
#include <bdk.h>
#include <mem/heap.h>
#include <sec/se.h>
#include <sec/se_t210.h>
#include "../storage/nx_emmc.h"
#include <storage/nx_sd.h>
#include <storage/sdmmc.h>
#include <utils/types.h>
#define BIS_CLUSTER_SECTORS 32
#define BIS_CLUSTER_SIZE 16384

View file

@ -18,8 +18,9 @@
#ifndef NX_EMMC_BIS_H
#define NX_EMMC_BIS_H
#include <bdk.h>
#include "../storage/nx_emmc.h"
#include <storage/sdmmc.h>
typedef struct _nx_emmc_cal0_spk_t
{

View file

@ -15,12 +15,9 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include <storage/nx_sd.h>
#include <storage/sdmmc.h>
#include <storage/sdmmc_driver.h>
#include <gfx_utils.h>
#include <bdk.h>
#include <libs/fatfs/ff.h>
#include <mem/heap.h>
static bool sd_mounted = false;
static bool sd_init_done = false;