Changeset View
Changeset View
Standalone View
Standalone View
head/sys/riscv/riscv/machdep.c
Show First 20 Lines • Show All 420 Lines • ▼ Show 20 Lines | if (!busy) | ||||
cpu_activeclock(); | cpu_activeclock(); | ||||
spinlock_exit(); | spinlock_exit(); | ||||
} | } | ||||
void | void | ||||
cpu_halt(void) | cpu_halt(void) | ||||
{ | { | ||||
panic("cpu_halt"); | intr_disable(); | ||||
for (;;) | |||||
__asm __volatile("wfi"); | |||||
} | } | ||||
/* | /* | ||||
* Flush the D-cache for non-DMA I/O so that the I-cache can | * Flush the D-cache for non-DMA I/O so that the I-cache can | ||||
* be made coherent later. | * be made coherent later. | ||||
*/ | */ | ||||
void | void | ||||
cpu_flush_dcache(void *ptr, size_t len) | cpu_flush_dcache(void *ptr, size_t len) | ||||
▲ Show 20 Lines • Show All 456 Lines • Show Last 20 Lines |