[Intel-gfx] [PATCH v8 6/6] drm/i915: expose rcs topology through query uAPI
Chris Wilson
chris at chris-wilson.co.uk
Thu Jan 18 13:04:53 UTC 2018
Quoting Tvrtko Ursulin (2018-01-18 12:46:55)
>
> On 17/01/2018 15:39, Lionel Landwerlin wrote:
> > +
> > + if (query_item->length == 0)
> > + return total_length;
> > +
> > + if (query_item->length < total_length)
> > + return -EINVAL;
>
> Did we talk about whether this check should be != or < yet? != would
> sound safer to me, or you want to allow extending the queries in the
> future and keeping the same id?
This is me, because I like read(buf, len) style behaviour that lets me
pass in a preallocated buffer that should be big enough without having
to worry and do a 2-pass approach to find out the length of the buffer
to allocate first. '!=' style I have found much more painful to handle in
userspace.
-Chris
More information about the Intel-gfx
mailing list