From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: Jon Smirl <jonsmirl@gmail.com>
Cc: xorg@freedesktop.org, Egbert Eich <eich@freedesktop.org>,
Jon Smirl <jonsmirl@yahoo.com>,
Linux Kernel list <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] VGA arbitration: draft of kernel side
Date: Wed, 09 Mar 2005 14:53:18 +1100 [thread overview]
Message-ID: <1110340398.32557.36.camel@gaston> (raw)
In-Reply-To: <9e47339105030819172eecc324@mail.gmail.com>
On Tue, 2005-03-08 at 22:17 -0500, Jon Smirl wrote:
> How do I do the 'disable all, post, renable last active' sequence in
> this scheme?
You don't do it that way. You vga_get(IO|MEM) the card you want to
POST, do the POST, then vga_put().
Subsequent user will get back ownership when it does vga_get(something)
again.
BTW. I have a draft of the userland API. It will be a /dev entry (so
other OSes can implement the same API, also, it's just doing too much
for sysfs, I debated it with a few kernel folks and we decided it should
be that way) :
* open : open user instance of the arbitrer. by default, it's
* attached to the default VGA device of the system.
*
* close : close user instance, release locks
*
* read : return a string indicating the status of the target.
* an IO state string is of the form {mem,io,mem+io,none},
* mc and ic are respectively mem and io lock counts (for
* debugging/diagnostic only). "decodes" indicate what the
* card currently decodes, "owns" indicates what is currently
* enabled on it, and "locks" indicates what is locked by this
* card.
*
* "<card_ID>:decodes=<io_state>,owns=<io_state>,locks=<io_state> (mc,ic)"
*
* write : write a command to the arbiter. List of commands is:
*
* target <card_ID> : switch target to card <card_ID> (see below)
* lock <io_state> : acquires locks on target ("none" is invalid io_state)
* trylock <io_state> : non-blocking acquire locks on target
* unlock <io_state> : release locks on target
* decodes <io_state> : set the legacy decoding attributes for the card
*
* poll : event if something change on any card (not just the target)
I also added nesting counters (mostly to make things safer, though it could
be useful for scenarios where IRQ stuffs are doing a tryget kind of thing
as described in a previous message).
Ben.
next prev parent reply other threads:[~2005-03-09 3:58 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-03-08 7:11 [PATCH] VGA arbitration: draft of kernel side Benjamin Herrenschmidt
2005-03-08 21:29 ` Kronos
2005-03-08 22:46 ` Benjamin Herrenschmidt
2005-03-09 10:22 ` Pekka Enberg
2005-03-09 20:06 ` Kronos
2005-03-08 22:01 ` Benjamin Herrenschmidt
2005-03-08 23:47 ` Jon Smirl
2005-03-09 0:02 ` Benjamin Herrenschmidt
2005-03-09 3:17 ` Jon Smirl
2005-03-09 3:53 ` Benjamin Herrenschmidt [this message]
2005-03-09 4:35 ` Jon Smirl
2005-03-09 5:37 ` Benjamin Herrenschmidt
2005-03-09 5:58 ` Jon Smirl
2005-03-09 6:00 ` Benjamin Herrenschmidt
2005-03-09 8:04 ` Benjamin Herrenschmidt
2005-03-09 16:57 ` Jesse Barnes
2005-03-09 10:45 ` Pekka Enberg
2005-03-09 22:02 ` Benjamin Herrenschmidt
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1110340398.32557.36.camel@gaston \
--to=benh@kernel.crashing.org \
--cc=eich@freedesktop.org \
--cc=jonsmirl@gmail.com \
--cc=jonsmirl@yahoo.com \
--cc=linux-kernel@vger.kernel.org \
--cc=xorg@freedesktop.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.