mirror of
https://github.com/ARM-software/arm-trusted-firmware.git
synced 2025-04-23 21:44:15 +00:00
Merge pull request #206 from soby-mathew/sm/reset_cntvoff
Reset CNTVOFF_EL2 register before exit into EL1 on warm boot
This commit is contained in:
commit
d07baec4b5
2 changed files with 5 additions and 0 deletions
|
@ -250,6 +250,9 @@ void cm_prepare_el3_exit(uint32_t security_state)
|
||||||
/* Enable EL1 access to timer */
|
/* Enable EL1 access to timer */
|
||||||
write_cnthctl_el2(EL1PCEN_BIT | EL1PCTEN_BIT);
|
write_cnthctl_el2(EL1PCEN_BIT | EL1PCTEN_BIT);
|
||||||
|
|
||||||
|
/* Reset CNTVOFF_EL2 */
|
||||||
|
write_cntvoff_el2(0);
|
||||||
|
|
||||||
/* Set VPIDR, VMPIDR to match MIDR, MPIDR */
|
/* Set VPIDR, VMPIDR to match MIDR, MPIDR */
|
||||||
write_vpidr_el2(read_midr_el1());
|
write_vpidr_el2(read_midr_el1());
|
||||||
write_vmpidr_el2(read_mpidr_el1());
|
write_vmpidr_el2(read_mpidr_el1());
|
||||||
|
|
|
@ -262,6 +262,8 @@ DEFINE_SYSREG_RW_FUNCS(cnthctl_el2)
|
||||||
|
|
||||||
DEFINE_SYSREG_RW_FUNCS(tpidr_el3)
|
DEFINE_SYSREG_RW_FUNCS(tpidr_el3)
|
||||||
|
|
||||||
|
DEFINE_SYSREG_RW_FUNCS(cntvoff_el2)
|
||||||
|
|
||||||
DEFINE_SYSREG_RW_FUNCS(vpidr_el2)
|
DEFINE_SYSREG_RW_FUNCS(vpidr_el2)
|
||||||
DEFINE_SYSREG_RW_FUNCS(vmpidr_el2)
|
DEFINE_SYSREG_RW_FUNCS(vmpidr_el2)
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue