[Mesa-dev] [PATCH 00/13] implement EGL_EXT_image_dma_buf_import_modifiers

Rob Clark robdclark at gmail.com
Tue Nov 15 16:58:16 UTC 2016


On Tue, Nov 15, 2016 at 11:44 AM, Marek Olšák <maraeo at gmail.com> wrote:
>
> Hi,
>
> Is the modifier just a driver-specific description of the tiling
> layout and compression?
>
> What makes you think that 8 bytes is enough to describe that? What if
> I need 9 bytes just to program the display hardware?
>
> Drivers importing DMABUFs still have to invoke the texture tiling
> calculator to get all necessary parameters for rendering (not just
> display), which may even be 128 bytes per plane.

fwiw, this maps 1:1 to addfb2 ioctl, and just brings egl to parity with kms.

Maybe the addfb2 approach wasn't the best idea compared to some of the
ideas proposed for hypothetical "liballoc" for being ultra-generic.
OTOH perhaps you can just treat it like an enum?  I mean maybe the set
of tiled formats that you would actually exchange with another device
is less than 2^^72.  It seems reasonable to restrict the possible
tiled formats supported by this extension to only things that can be
exchanged with i965..

BR,
-R

>
> Marek
>
>
> On Tue, Nov 15, 2016 at 3:24 PM, Varad Gautam <varadgautam at gmail.com> wrote:
> > Hello,
> >
> > This series implements EGL_EXT_image_dma_buf_import_modifiers [1] which makes
> > it possible to pass drm fourcc modifiers to EGL when importing dmabufs.
> >
> > [1] https://www.khronos.org/registry/egl/extensions/EXT/EGL_EXT_image_dma_buf_import_modifiers.txt
> >
> > Pekka Paalanen (5):
> >   egl: return error for unknown EGLImage attributes
> >   egl: introduce DMA_BUF_MAX_PLANES
> >   egl/main: add support for fourth plane tokens
> >   dri: support DRIimage creation from dmabufs with modifiers
> >   egl_dri2: add support for using modifier attributes in
> >     eglCreateImageKHR
> >
> > Varad Gautam (8):
> >   egl: update eglext.h
> >   st/dri: implement DRIimage creation from dmabufs with modifiers
> >   egl: implement eglQueryDmaBufFormatsEXT
> >   dri: add queryDmaBufModifiers to DRIimage
> >   gallium: introduce format modifier querying
> >   st/dri: support format modifier queries
> >   egl: implement eglQueryDmaBufModifiersEXT
> >   egl: advertise EGL_EXT_image_dma_buf_import_modifiers
> >
> >  include/EGL/eglext.h                             |  60 ++++++-
> >  include/GL/internal/dri_interface.h              |  31 +++-
> >  src/egl/drivers/dri2/egl_dri2.c                  | 209 +++++++++++++++++++++--
> >  src/egl/main/eglapi.c                            |  41 +++++
> >  src/egl/main/eglapi.h                            |   9 +
> >  src/egl/main/egldisplay.h                        |   1 +
> >  src/egl/main/eglimage.c                          |  63 ++++++-
> >  src/egl/main/eglimage.h                          |  10 +-
> >  src/gallium/docs/source/screen.rst               |   2 +
> >  src/gallium/drivers/freedreno/freedreno_screen.c |   1 +
> >  src/gallium/drivers/i915/i915_screen.c           |   1 +
> >  src/gallium/drivers/ilo/ilo_screen.c             |   1 +
> >  src/gallium/drivers/llvmpipe/lp_screen.c         |   1 +
> >  src/gallium/drivers/nouveau/nv30/nv30_screen.c   |   1 +
> >  src/gallium/drivers/nouveau/nv50/nv50_screen.c   |   1 +
> >  src/gallium/drivers/nouveau/nvc0/nvc0_screen.c   |   1 +
> >  src/gallium/drivers/r300/r300_screen.c           |   1 +
> >  src/gallium/drivers/r600/r600_pipe.c             |   1 +
> >  src/gallium/drivers/radeonsi/si_pipe.c           |   1 +
> >  src/gallium/drivers/softpipe/sp_screen.c         |   1 +
> >  src/gallium/drivers/svga/svga_screen.c           |   1 +
> >  src/gallium/drivers/swr/swr_screen.cpp           |   1 +
> >  src/gallium/drivers/vc4/vc4_screen.c             |   1 +
> >  src/gallium/drivers/virgl/virgl_screen.c         |   1 +
> >  src/gallium/include/pipe/p_defines.h             |   1 +
> >  src/gallium/include/pipe/p_screen.h              |   7 +
> >  src/gallium/include/state_tracker/drm_driver.h   |   2 +
> >  src/gallium/state_trackers/dri/dri2.c            |  63 ++++++-
> >  28 files changed, 487 insertions(+), 27 deletions(-)
> >
> > --
> > 2.6.2
> >
> > _______________________________________________
> > mesa-dev mailing list
> > mesa-dev at lists.freedesktop.org
> > https://lists.freedesktop.org/mailman/listinfo/mesa-dev
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev


More information about the mesa-dev mailing list