[Intel-gfx] No more read/write ioctls

Eric Anholt eric at anholt.net
Fri Apr 8 19:10:14 CEST 2011


On Wed, 6 Apr 2011 14:38:27 -0700, Ben Widawsky <ben at bwidawsk.net> wrote:
> On Fri, Apr 01, 2011 at 04:54:47PM -0700, Ben Widawsky wrote:
> 
> > So if this isn't okay by everyone, let's get down to the minimum number
> > of changes required to get this accepted so I can move on to the tools,
> > and then get back to the debug stuff.
> > 
> 
> Some discussion on IRC has led to a new proposal (well 2 new proposals,
> but the first one wasn't viable).
> 
> The interface will instead of using ioctls use debugfs. The debugfs file
> will control force wake. There will be a refcount mechanism for number
> of users of the registers in the relevant power-well, and upon opening a
> specific file in debugfs (we could have one per power-well if needed),
> the refcount will get incremented, and decremented at close.
> 
> In other words, for userspace to read/write registers:
> fd = open(/sys/kernel/debug/dri...)
> normal read write mechanism
> close(fd)
> 
> There are two side effects which everyone on IRC seems fine with:
> * root-only read access (the ioctl read was promiscuous)
> * access is only available when debugfs is mounted
> 
> As a result, you should ignore both the gpu-tools patches, as well as
> these kernel patches.

I thought previously we had issues with debugfs nodes which could wedge
the system (out of range mmio reads)?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/intel-gfx/attachments/20110408/74f974e6/attachment.sig>


More information about the Intel-gfx mailing list