Page 1 of 1

is this correct for setting v86 mode

Posted: Tue Jul 08, 2008 7:34 am
by asdfgh
.global _v86
_v86:
pushfw
pop %eax
or $1<<17,%eax
push %eax
popfw
ret

at\t syntax

Re: is this correct for setting v86 mode

Posted: Tue Jul 08, 2008 9:36 am
by AJ
No - you need to set up a task and switch to that. v86 mode always runs in ring 3, therefore you need some method (system call, scheduler interrupt) to get back to protected mode again too.

Cheers,
Adam