diff options
Diffstat (limited to 'freebsd-5.3-xen-sparse/i386-xen/include/hypervisor.h')
-rw-r--r-- | freebsd-5.3-xen-sparse/i386-xen/include/hypervisor.h | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/freebsd-5.3-xen-sparse/i386-xen/include/hypervisor.h b/freebsd-5.3-xen-sparse/i386-xen/include/hypervisor.h index b23221bdbd..94c449ded9 100644 --- a/freebsd-5.3-xen-sparse/i386-xen/include/hypervisor.h +++ b/freebsd-5.3-xen-sparse/i386-xen/include/hypervisor.h @@ -22,6 +22,7 @@ extern start_info_t *xen_start_info; * be MACHINE addresses. */ +static inline void HYPERVISOR_crash(void) __dead2; void MULTICALL_flush_page_update_queue(void); @@ -201,6 +202,23 @@ HYPERVISOR_suspend(unsigned long srec) return ret; } + +static inline void +HYPERVISOR_crash(void) +{ + int ret; + unsigned long ign1; + __asm__ __volatile__ ( + TRAP_INSTR + : "=a" (ret), "=b" (ign1) + : "0" (__HYPERVISOR_sched_op), + "1" (SCHEDOP_shutdown | (SHUTDOWN_crash << SCHEDOP_reasonshift)) + : "memory" ); + + for (;;) ; /* eliminate noreturn error */ + +} + static inline long HYPERVISOR_set_timer_op(uint64_t timeout) { |