mirror of
https://github.com/CTCaer/hekate.git
synced 2024-12-01 22:12:06 +00:00
l4t: Clear boot mode if user canceled autoboot
This commit is contained in:
parent
3d05b58856
commit
98555b24f8
3 changed files with 4 additions and 3 deletions
|
@ -384,9 +384,6 @@ void hw_init()
|
||||||
sdram_init();
|
sdram_init();
|
||||||
|
|
||||||
bpmp_mmu_enable();
|
bpmp_mmu_enable();
|
||||||
|
|
||||||
// L4T: Clear flags from PMC_SCRATCH0.
|
|
||||||
PMC(APBDEV_PMC_SCRATCH0) &= ~PMC_SCRATCH0_MODE_PAYLOAD;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void hw_reinit_workaround(bool extra_reconfig, u32 magic)
|
void hw_reinit_workaround(bool extra_reconfig, u32 magic)
|
||||||
|
|
|
@ -37,6 +37,7 @@
|
||||||
#define PMC_SCRATCH0_MODE_PAYLOAD (1 << 29)
|
#define PMC_SCRATCH0_MODE_PAYLOAD (1 << 29)
|
||||||
#define PMC_SCRATCH0_MODE_RCM (1 << 1)
|
#define PMC_SCRATCH0_MODE_RCM (1 << 1)
|
||||||
#define PMC_SCRATCH0_MODE_WARMBOOT (1 << 0)
|
#define PMC_SCRATCH0_MODE_WARMBOOT (1 << 0)
|
||||||
|
#define PMC_SCRATCH0_MODE_CUSTOM_ALL (PMC_SCRATCH0_MODE_RECOVERY | PMC_SCRATCH0_MODE_FASTBOOT | PMC_SCRATCH0_MODE_PAYLOAD)
|
||||||
#define APBDEV_PMC_SCRATCH1 0x54
|
#define APBDEV_PMC_SCRATCH1 0x54
|
||||||
#define APBDEV_PMC_SCRATCH20 0xA0
|
#define APBDEV_PMC_SCRATCH20 0xA0
|
||||||
#define APBDEV_PMC_PWR_DET_VAL 0xE4
|
#define APBDEV_PMC_PWR_DET_VAL 0xE4
|
||||||
|
|
|
@ -1080,6 +1080,9 @@ out:
|
||||||
b_cfg.boot_cfg &= BOOT_CFG_SEPT_RUN;
|
b_cfg.boot_cfg &= BOOT_CFG_SEPT_RUN;
|
||||||
h_cfg.emummc_force_disable = false;
|
h_cfg.emummc_force_disable = false;
|
||||||
|
|
||||||
|
// L4T: Clear custom boot mode flags from PMC_SCRATCH0.
|
||||||
|
PMC(APBDEV_PMC_SCRATCH0) &= ~PMC_SCRATCH0_MODE_CUSTOM_ALL;
|
||||||
|
|
||||||
nyx_load_run();
|
nyx_load_run();
|
||||||
|
|
||||||
sd_end();
|
sd_end();
|
||||||
|
|
Loading…
Reference in a new issue