[PATCH 4/5] drm/vgem: getparam ioctl

Ben Widawsky ben at bwidawsk.net
Mon Feb 20 09:12:38 PST 2012


On Thu, 16 Feb 2012 07:23:52 +0000
Dave Airlie <airlied at gmail.com> wrote:

> On Wed, Feb 15, 2012 at 9:22 PM, Adam Jackson <ajax at redhat.com> wrote:
> > On 2/8/12 6:19 PM, Ben Widawsky wrote:
> >>
> >> Similar to i915, it's nice to be able to query this device uniquely and
> >> get some info
> >>
> >> Signed-off-by: Ben Widawsky<ben at bwidawsk.net>
> >
> >
> > So, this is actually not especially useful as written.  You'd like to be
> > able to use this to find the vgem device node, but since it's a
> > device-specific ioctl it collides with whatever happens to be
> > device-specific ioctl number 2 on whatever device you've opened.  On i915,
> > that's I915_FLIP, and you promptly oops the machine.
> >

Hmm... it doesn't oops my machine.

> 
> We have DRM level caps that we could use for that if necessary.
> 
> I'm not sure we need a getparam for vgem if the only thing it reports
> is VGEM status.

The plan I had for it was to report whether or not prime support exists. But
I'll just call the prime ioctls and see if they fail instead.

> 
> Though yeah what ajax said looking in /sys is the discovery path of choice.

I've done this now, it turned out quite nicely.

> 
> Dave.

Thanks.
~Ben


More information about the dri-devel mailing list