33 "custom_doublefault_handler:"
67 [cs32]
"i" (__USER_CS32),
91 xtf_success(
"Success: #DF DPL was checked correctly\n");
95 xtf_failure(
"Fail: Userspace managed to invoke #DF\n");
99 xtf_error(
"Error: Unexpected fault %#x\n", fault);
#define _ASM_XEN_FEP
Xen Forced Emulation Prefix.
bool ex_record_fault_eax(struct cpu_regs *regs, const struct extable_entry *ex)
Record the current fault in %eax.
void test_main(void)
To be implemented by each test, as its entry point.
const char test_title[]
The title of the test.
#define EXINFO_SYM(exc, ec)
unsigned int exinfo_t
Packed exception and error code information.
int xtf_set_idte(unsigned int vector, const struct xtf_idte *idte)
Set up an IDT Entry, in a guest agnostic way.
#define _ASM_EXTABLE_HANDLER(fault, fixup, handler)
Create an exception table entry with custom handler.
static unsigned long exec_user(unsigned long(*fn)(void))
#define STR(x)
Stringise an expression, expanding preprocessor tokens.
#define _u(v)
Express an arbitrary value v as unsigned long.
void xtf_failure(const char *fmt,...)
Report a test failure.
void xtf_error(const char *fmt,...)
Report a test error.
void xtf_success(const char *fmt,...)
Report test success.
A guest agnostic represention of IDT information.
#define EXC_EC_SYM(exc,...)
Create an exception selector based error code using mnemonics, with implicit X86_EC_IDT.
bool test_needs_fep
Boolean indicating whether the test is entirely predicated on the available of the Force Emulation Pr...
static unsigned long compat_userspace(void)
static const struct xtf_idte idte
void custom_doublefault_handler(void)