Move watchdog reset higher
This commit is contained in:
parent
1b5dc21552
commit
a3aff2083a
@ -81,6 +81,10 @@ void pmc_event(struct Pmc * pmc) {
|
||||
state = PMC_STATE_ACPI_WRITE;
|
||||
break;
|
||||
case 0xEC:
|
||||
printf_tiny("RESET\n");
|
||||
// Attempt to trigger watchdog reset
|
||||
ETWCFG |= (1 << 5);
|
||||
EWDKEYR = 0;
|
||||
// Clear processor caches
|
||||
__asm__("mov 0xf7, #1");
|
||||
__asm__("nop");
|
||||
@ -90,9 +94,6 @@ void pmc_event(struct Pmc * pmc) {
|
||||
__asm__("nop");
|
||||
__asm__("mov 0xf7, #1");
|
||||
__asm__("nop");
|
||||
// Attempt to trigger watchdog reset
|
||||
ETWCFG |= (1 << 5);
|
||||
EWDKEYR = 0;
|
||||
// Exit scratch ROM by going through trampoline
|
||||
__asm__("ljmp 0x1000");
|
||||
break;
|
||||
|
@ -81,6 +81,10 @@ void pmc_event(struct Pmc * pmc) {
|
||||
state = PMC_STATE_ACPI_WRITE;
|
||||
break;
|
||||
case 0xEC:
|
||||
printf_tiny("RESET\n");
|
||||
// Attempt to trigger watchdog reset
|
||||
ETWCFG |= (1 << 5);
|
||||
EWDKEYR = 0;
|
||||
// Clear processor caches
|
||||
__asm__("mov 0xf7, #1");
|
||||
__asm__("nop");
|
||||
@ -90,9 +94,6 @@ void pmc_event(struct Pmc * pmc) {
|
||||
__asm__("nop");
|
||||
__asm__("mov 0xf7, #1");
|
||||
__asm__("nop");
|
||||
// Attempt to trigger watchdog reset
|
||||
ETWCFG |= (1 << 5);
|
||||
EWDKEYR = 0;
|
||||
// Exit scratch ROM by going through trampoline
|
||||
__asm__("ljmp 0x1000");
|
||||
break;
|
||||
|
@ -81,6 +81,10 @@ void pmc_event(struct Pmc * pmc) {
|
||||
state = PMC_STATE_ACPI_WRITE;
|
||||
break;
|
||||
case 0xEC:
|
||||
printf_tiny("RESET\n");
|
||||
// Attempt to trigger watchdog reset
|
||||
ETWCFG |= (1 << 5);
|
||||
EWDKEYR = 0;
|
||||
// Clear processor caches
|
||||
__asm__("mov 0xf7, #1");
|
||||
__asm__("nop");
|
||||
@ -90,9 +94,6 @@ void pmc_event(struct Pmc * pmc) {
|
||||
__asm__("nop");
|
||||
__asm__("mov 0xf7, #1");
|
||||
__asm__("nop");
|
||||
// Attempt to trigger watchdog reset
|
||||
ETWCFG |= (1 << 5);
|
||||
EWDKEYR = 0;
|
||||
// Exit scratch ROM by going through trampoline
|
||||
__asm__("ljmp 0x1000");
|
||||
break;
|
||||
|
Loading…
x
Reference in New Issue
Block a user