mirror of
https://github.com/Atmosphere-NX/Atmosphere.git
synced 2024-11-26 22:02:15 +00:00
Fix wrongly named register in __set_memory_registers, add prototype
This commit is contained in:
parent
c5b0639b8a
commit
64c8612342
2 changed files with 7 additions and 1 deletions
|
@ -1,5 +1,7 @@
|
||||||
/* For some reason GAS doesn't know about it, even with .cpu cortex-a57 */
|
/* For some reason GAS doesn't know about it, even with .cpu cortex-a57 */
|
||||||
#define cpuactlr_el1 s3_1_c15_c2_0
|
#define cpuactlr_el1 s3_1_c15_c2_0
|
||||||
|
#define cpuectlr_el1 s3_1_c15_c2_1
|
||||||
|
|
||||||
.macro RESET_CORE
|
.macro RESET_CORE
|
||||||
mov x0, #(1 << 63)
|
mov x0, #(1 << 63)
|
||||||
msr cpuactlr_el1, x0 /* disable regional clock gating */
|
msr cpuactlr_el1, x0 /* disable regional clock gating */
|
||||||
|
@ -102,7 +104,7 @@ __start_warm:
|
||||||
.global __set_memory_registers
|
.global __set_memory_registers
|
||||||
.type __set_memory_registers, %function
|
.type __set_memory_registers, %function
|
||||||
__set_memory_registers:
|
__set_memory_registers:
|
||||||
msr cpuactlr_el1, x2
|
msr cpuectlr_el1, x2
|
||||||
isb
|
isb
|
||||||
msr scr_el3, x3
|
msr scr_el3, x3
|
||||||
msr ttbr0_el3, x0
|
msr ttbr0_el3, x0
|
||||||
|
|
|
@ -1,7 +1,11 @@
|
||||||
#include "utils.h"
|
#include "utils.h"
|
||||||
#include "memory_map.h"
|
#include "memory_map.h"
|
||||||
|
|
||||||
|
void __set_memory_registers(uintptr_t ttbr0, uintptr_t vbar, uint64_t cpuectlr, uint32_t scr,
|
||||||
|
uint32_t tcr, uint32_t cptr, uint64_t mair, uint32_t sctlr);
|
||||||
|
|
||||||
uintptr_t get_warmboot_crt0_stack_address(void);
|
uintptr_t get_warmboot_crt0_stack_address(void);
|
||||||
|
void set_memory_registers(void);
|
||||||
|
|
||||||
void flush_dcache_all_tzram_pa(void) {
|
void flush_dcache_all_tzram_pa(void) {
|
||||||
/* TODO */
|
/* TODO */
|
||||||
|
|
Loading…
Reference in a new issue