Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 17 Sep 2000 03:33:17 -0400
From:      Jonathan Chen <jon@spock.org>
To:        freebsd-hackers@freebsd.org
Subject:   VM86 interrupt calls from userland
Message-ID:  <20000917033317.A41735@spock.org>

next in thread | raw e-mail | index | archive | help
Is there a way to make VM86 interrupt calls from userland?  The reason I'm
asking is that in order to get my video card (Savage/IX) working in X
properly, I need to make a couple of VESA int10 calls (or somehow obtain
the programming specs for the card and do this the right way).  Anyway,
what I have tried is using the syscons ioctl()'s, which doesn't work here.  
Right now what I've done is modified src/sys/i386/i386/vm86.c to enable the
VM86_INTCALL bit (and added a check for uid), and just called i386_vm86
from userland.  This seems to work fine, but I want to know

1) Is there already some standard way to do this that I missed?  The man
   page for i386_vm86 mentions sigreturn(), but I'm not sure if that will
   do what I want, plus I don't know how to use it anyway...
2) There was probably a reason the VM86_INTCALL stuff was #if'ed out... but
   I looked around the lists and cvs logs to see if one was mentioned and
   found none.  This seems to work and I don't see how anything bad could
   come from this -- is it possible that this be enabled by default?
3) Or would the whole problem be solved more correctly by extending the
   ioctl by adding something like FBIO_SETMODE_ONLY where syscons would
   only switch the mode and not bother setting up the renderer or emulator?

Thanks for any pointers...

-- 
    (o_ 1-2-1-2-1-2-1-2-1-2-1-2-1-2-1-2-1-2-1-2-1-2-1-2-1-2-1-2-1-2 _o)
 \\\_\            Jonathan Chen              jon@spock.org           /_///
 <____)  No electrons were harmed during production of this message (____>
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20000917033317.A41735>