4 #define ENTRY(X) TEXT X(SB), $0
7 * XXX there's a race in here because we can get an upcall
8 * betwen the spllo() (in xenupcall) and the rti. This will make
9 * handlers stack, which could lead to a blown stack. Probably
10 * not worth fixing (but possibly worth detecting and panicing).
12 * For fun get some popcorn and turn off the lights and read the
13 * linux solution (search for scrit/ecrit).
15 ENTRY(hypervisor_callback)
16 SUBL $8, SP /* space for ecode and trap type */
17 PUSHL DS /* save DS */
19 POPL DS /* fix up DS */
20 PUSHL ES /* save ES */
22 POPL ES /* fix up ES */
24 PUSHL FS /* save the rest of the Ureg struct */
28 PUSHL SP /* Ureg* argument to trap */
37 ADDL $8, SP /* pop error code and trap type */
40 /* Hypervisor uses this for application faults while it executes.*/
41 ENTRY(failsafe_callback)
44 CALL install_safe_pf_handler(SB)
53 CALL install_normal_pf_handler(SB)
58 /* xen traps with varying argument counts */