os_kernel_lab/labcodes/lab7/user/badsegment.c
2013-09-17 22:21:48 +08:00

12 lines
200 B
C

#include <stdio.h>
#include <ulib.h>
/* try to load the kernel's TSS selector into the DS register */
int
main(void) {
asm volatile("movw $0x28,%ax; movw %ax,%ds");
panic("FAIL: T.T\n");
}