fusee: do PMC reboots, not CAR reboots.

This commit is contained in:
Michael Scire committed 2018-11-30 06:34:20 -08:00
1 parent be5b58d033
commit 33b7e227d4
4 files changed
+2 -22

No files matched your search

+1 -10
View File
@@ -59,21 +59,12 @@ __attribute__((noreturn)) void pmc_reboot(uint32_t scratch0) {
}
}
__attribute__((noreturn)) void car_reboot(void) {
/* Reset the processor. */
car_get_regs()->rst_dev_l |= 1<<2;
while (true) {
/* Wait for reboot. */
}
}
__attribute__((noreturn)) void wait_for_button_and_reboot(void) {
uint32_t button;
while (true) {
button = btn_read();
if (button & BTN_POWER) {
car_reboot();
pmc_reboot(1 << 1);
}
}
}
-1
View File
@@ -121,7 +121,6 @@ void hexdump(const void* data, size_t size, uintptr_t addrbase);
__attribute__((noreturn)) void watchdog_reboot(void);
__attribute__((noreturn)) void pmc_reboot(uint32_t scratch0);
__attribute__((noreturn)) void car_reboot(void);
__attribute__((noreturn)) void wait_for_button_and_reboot(void);
__attribute__((noreturn)) void generic_panic(void);
+1 -10
View File
@@ -58,21 +58,12 @@ __attribute__((noreturn)) void pmc_reboot(uint32_t scratch0) {
}
}
__attribute__((noreturn)) void car_reboot(void) {
/* Reset the processor. */
car_get_regs()->rst_dev_l |= 1<<2;
while (true) {
/* Wait for reboot. */
}
}
__attribute__((noreturn)) void wait_for_button_and_reboot(void) {
uint32_t button;
while (true) {
button = btn_read();
if (button & BTN_POWER) {
car_reboot();
pmc_reboot(1 << 1);
}
}
}
-1
View File
@@ -122,7 +122,6 @@ void hexdump(const void* data, size_t size, uintptr_t addrbase);
__attribute__((noreturn)) void watchdog_reboot(void);
__attribute__((noreturn)) void pmc_reboot(uint32_t scratch0);
__attribute__((noreturn)) void car_reboot(void);
__attribute__((noreturn)) void wait_for_button_and_reboot(void);
void wait_for_button(void);