Colin Davidson wrote:
> Only one OS could access a card at a time. We could control this via the PCI
> spoofing, causing Plex86 to abort if the required resources were already in
> use, or we could just trust the user (Trust the user? Sucker...)
PCI spoofing in general would be a Good Thing, but we certianly can't
consider it the primary display driver --
it'd make plex86 rather useless on a single-headed system. As to access
control, I think the best case would be
to simply make the card non-responsive (is there a well-defined way for
a card to reject an access?) if it was
in use by the host -- that way, you could switch ownership under control
of the host OS, without having to make
any assumptions of the guest, and without killing it summeraly. (If it
can't stand to have the card yanked from
under it, there isn't much we can do about it.)
It'd be very useful, for example, to flip ownership of a sound card,
say, around like this -- when you want the
host to have it, load the kernel module. Otherwise, unload it. Keep
the drivers loaded on the guest -- they
should just error out when the card doesn't respond.
We could even do PCI-hotswap from the guest's point of view, but is that
widely supported?
>
> I have to admit that I have a gut-level bad feel about this option. Its
> inelligant, inefficient and using someone else's driver without using their
> hardware is more than a little dubious in my view (I write device drivers
> for a living, mind). There is also the legal issue. Still, it is an option
> that should be considered. On older cards, the manufacturer may simply not
> care anymore.
I'd tend to agree with you on the gut feelings here. If we emulate
another card, it shouldn't be a card
so much as a standard -- like VGA or 8512/A (or whatever the hell the
designator was), or some common
SVGA subset. I assume you write windows display drivers -- would you
like to help us with this project?
>
> Ideally, we would have a solution everywhere, but let's face it, windows is
> the real problem. Most everywhere else will be X/OpenGL or something similar
> based and the drivers should be pretty similar. The real performance issue
> is probably Windows games, so we only really need to do real meaty work
> three times (Win9x, Win2k - can't run games on earlier NT versions - and
> everything else. Note that NT and 9x have different Display Driver Models
> that don't have a lot in common).
Well, I wouldn't be quite that... limited. For example, there are
probably a fair number of people for whom OS/2
or DOS-based games would be a Good Thing. I'd say VESA support (pretty
simple, IIRC), and win* support
would get a fair number of people. (I'm assuming that VESA and win9x
would come first -- do we even
run 2k?