Re: Adding set_blob ioctl to DRM

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Feb 20, 2014 at 11:24:40AM +1000, Dave Airlie wrote:
> > I am working on enabling a Color Enhancement block for primary display
> > for Exynos SoC. I need to
> > set a bunch of parameters like Color Conversion matrix, Contrast
> > Improvement parameters etc ~ 30 parameters from User Space.
> >
> > I am planning to use KDS blob property to receive these parameters.
> > Currently drivers are not allowed to create a blob property inside
> > drm. Neither, user space can set the blob. There is no ioctl provided
> > for same.
> 
> I don't really like the idea of sticking unstructured data into an
> ioctl, for the driver to interpret,
> 
> it opens the door to all kinds of ugly driver hacks, so I think we
> should have writable blobs,
> but with well defined structures inside them, not per-driver ones.
> 
> Per-driver structures will lead to binary userspace drivers that start
> sticking a pll timings blob on the end and require it to set a mode,
> because I know driver developers will abuse any interface in the worst
> way possible.
> 
> Currently the only blob we really have is EDID and its well defined,
> so if we are going to add writable blobs, they need to be well defined
> and as little as possible driver specific, just to avoid driver
> writings doing what driver writers do.

tbh I don't see a use for structured blobs at all and would much more
prefer a pile of properties. With the atomic modeset ioctl proposals
floating around we could then pass in an entire sets of properties, which
is essentially what the blob prop would be doing.

The upshot of going all-in with explicitly named properties is that we can
shovel kms configuration descriptions into different formats. I'm thinking
of shovelling an initial config into DT or something similar as an
example.  For i915 we have some experimental patches which load a DT blob
as a firmware file and use the property values to set things up.

So imo a blob property needs some _really_ good justification. My default
stance is to oppose it ;-)

Cheers, Daniel
-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch
_______________________________________________
dri-devel mailing list
dri-devel@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/dri-devel




[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux