Re: [PATCH] drm/fourcc: add LINEAR modifiers with an exact pitch alignment

2024-12-16 Thread Lucas Stach
Am Montag, dem 16.12.2024 um 10:27 +0100 schrieb Michel Dänzer: > On 2024-12-15 21:53, Marek Olšák wrote: > > The comment explains the problem with DRM_FORMAT_MOD_LINEAR. > >     > > Signed-off-by: Marek Olšák > > > > > > diff --git a/include/uapi/drm/drm_fourcc.h b/in

Re: Does gbm_bo_map() implicitly synchronise?

2024-06-25 Thread Lucas Stach
Am Dienstag, dem 25.06.2024 um 09:56 +0200 schrieb Michel Dänzer: > On 2024-06-24 21:08, James Jones wrote: > > FWIW, the NVIDIA binary driver's implementation of gbm_bo_map/unmap() > > > > 1) Don't do any synchronization against in-flight work. The assumption is > > that if the content is going

Re: NXP i.MX8MM GPU performances

2024-05-08 Thread Lucas Stach
Hi João Paulo, Am Dienstag, dem 07.05.2024 um 15:17 -0300 schrieb João Paulo Gonçalves: > Hello all, > > I did run some benchmark on i.MX8MM GPU and I have some concerns on the > differences between mainline Linux/etnaviv/Mesa and the proprietary > NXP/Vivante > solution. > > The tests were exe

Re: Possible Performance Regression with Mesa

2024-04-25 Thread Lucas Stach
Am Donnerstag, dem 25.04.2024 um 07:56 -0300 schrieb Joao Paulo Silva Goncalves: > > > On Thu, Apr 25, 2024 at 5:58 AM Lucas Stach wrote: > > > Etnaviv added some resource tracking to fix issues with a number of > > use-cases, which did add some CPU overhead and might c

Re: Possible Performance Regression with Mesa

2024-04-25 Thread Lucas Stach
Hi Joao Paulo, Am Mittwoch, dem 24.04.2024 um 19:31 -0300 schrieb Joao Paulo Silva Goncalves: > Hello all, > > We might have encountered a performance regression after upgrading from Mesa > 2022.0.3 to 2024.0.2. During our automated hardware tests using LAVA, we > noticed > a lower score on glma

Re: wayland: wrong tiling with wl_drm on Vivante GC2000

2023-03-31 Thread Lucas Stach
Hi Christian, Am Donnerstag, dem 30.03.2023 um 19:54 + schrieb Christian Gudrian: > Hi, Daniel! > > Thanks for your reply. > > > You need to force QtWayland to use the wp-linux-dmabuf-v1 platform > > integration for the compositor. > > Yes. I've did that before and that indeed solves the ti

Re: [Mesa-dev] Enabling Mesa video frontends on top of D3D12 gallium driver

2021-11-22 Thread Lucas Stach
Am Montag, dem 22.11.2021 um 13:01 +0100 schrieb Christian König: > Hi guys, > > Am 22.11.21 um 06:49 schrieb Dave Airlie: > > On Thu, 18 Nov 2021 at 18:45, Sil Vilerino > > wrote: > > > Hello mesa-dev community, > > > > > > > > > > > > We are starting to work on adding support for D3D12 Video

Re: [Mesa-dev] [RFC] Linux Graphics Next: Explicit fences everywhere and no BO fences - initial proposal

2021-04-27 Thread Lucas Stach
Hi, Am Dienstag, dem 27.04.2021 um 09:26 -0400 schrieb Marek Olšák: > Ok. So that would only make the following use cases broken for now: > - amd render -> external gpu > - amd video encode -> network device FWIW, "only" breaking amd render -> external gpu will make us pretty unhappy, as we have

Re: [Mesa-dev] Etnaviv: eglCreateWindowSurface fails with glmark2

2020-09-21 Thread Lucas Stach
Hi Fabio, On Mo, 2020-09-21 at 09:41 -0300, Fabio Estevam wrote: > Hi, > > I am trying to run glmark2 and I am getting the following error on an > imx6qp-sabresd with kernel 5.8.4: > > # glmark2-es2-drm -d > Debug: Using Udev to detect the right DRM node to use > Debug: Looking for the main GPU

Re: [Mesa-dev] Plumbing explicit synchronization through the Linux ecosystem

2020-03-17 Thread Lucas Stach
Am Dienstag, den 17.03.2020, 10:59 -0700 schrieb Jacob Lifshay: > On Tue, Mar 17, 2020 at 10:21 AM Lucas Stach wrote: > > Am Dienstag, den 17.03.2020, 10:12 -0700 schrieb Jacob Lifshay: > > > One related issue with explicit sync using sync_file is that combined > > > CP

Re: [Mesa-dev] Plumbing explicit synchronization through the Linux ecosystem

2020-03-17 Thread Lucas Stach
Am Dienstag, den 17.03.2020, 11:33 -0400 schrieb Nicolas Dufresne: > Le lundi 16 mars 2020 à 23:15 +0200, Laurent Pinchart a écrit : > > Hi Jason, > > > > On Mon, Mar 16, 2020 at 10:06:07AM -0500, Jason Ekstrand wrote: > > > On Mon, Mar 16, 2020 at 5:20 AM Laurent Pinchart wrote: > > > > On Wed, M

Re: [Mesa-dev] Plumbing explicit synchronization through the Linux ecosystem

2020-03-17 Thread Lucas Stach
Am Dienstag, den 17.03.2020, 10:12 -0700 schrieb Jacob Lifshay: > One related issue with explicit sync using sync_file is that combined > CPUs/GPUs (the CPU cores *are* the GPU cores) that do all the > rendering in userspace (like llvmpipe but for Vulkan and with extra > instructions for GPU tasks)

Re: [Mesa-dev] [Intel-gfx] gitlab.fd.o financial situation and impact on services

2020-02-28 Thread Lucas Stach
On Fr, 2020-02-28 at 10:47 +0100, Daniel Vetter wrote: > On Fri, Feb 28, 2020 at 10:29 AM Erik Faye-Lund > wrote: > > On Fri, 2020-02-28 at 13:37 +1000, Dave Airlie wrote: > > > On Fri, 28 Feb 2020 at 07:27, Daniel Vetter > > > wrote: > > > > Hi all, > > > > > > > > You might have read the short

Re: [Mesa-dev] Mesa 19.2.0 release plan

2019-07-31 Thread Lucas Stach
Hi Emil, Am Mittwoch, den 31.07.2019, 09:37 +0100 schrieb Emil Velikov: > Hi all, > > Here is the tentative release plan for 19.2.0. > > As many of you are well aware, it's time to the next branch point. > The calendar is already updated, so these are the tentative dates: > >  Aug 06 2019 - Fea

Re: [Mesa-dev] [PATCH] gbm: add gbm_{bo, surface}_create_with_modifiers2

2019-06-27 Thread Lucas Stach
Hi Daniel, et. al, Am Dienstag, den 25.06.2019, 16:27 +0100 schrieb Daniel Stone: > Hi, > > > On Tue, 25 Jun 2019 at 16:07, Jason Ekstrand wrote: > > > > On Tue, Jun 25, 2019 at 4:04 AM Daniel Stone > > > > wrote: > > > > > > On Tue, 25 Jun 2019 at 07:26, Simon Ser wrote: > > > > > I noticed

[Mesa-dev] [PATCH] etnaviv: fix some pm query issues

2019-05-31 Thread Lucas Stach
The offsets to read the query results were off-by-one, which causes the counters to report bogus increasing values. Also the counter result is u32, so we need to initialize the query type to reflect that. Signed-off-by: Lucas Stach --- This only fixes the obvious issues. I still believe there

[Mesa-dev] [PATCH libdrm] etnaviv: drop etna_bo_from_handle symbol

2019-05-29 Thread Lucas Stach
There is no implementation and also no users, so there is no point in keeping it in the API. Signed-off-by: Lucas Stach --- etnaviv/etnaviv-symbol-check | 1 - etnaviv/etnaviv_drmif.h | 2 -- 2 files changed, 3 deletions(-) diff --git a/etnaviv/etnaviv-symbol-check b/etnaviv/etnaviv

Re: [Mesa-dev] [PATCH] etnaviv: rs: choose clear format based on block size

2019-05-27 Thread Lucas Stach
Am Sonntag, den 26.05.2019, 21:06 +0200 schrieb Christian Gmeiner: > Fixes following piglit and does not introduce any regressions. >   spec@ext_packed_depth_stencil@fbo-depth-gl_depth24_stencil8-blit > > Signed-off-by: Christian Gmeiner Reviewed-by: Lucas Stach > --- >  s

Re: [Mesa-dev] [PATCH] etnaviv: fill missing offset in etna_resource_get_handle

2019-05-03 Thread Lucas Stach
Am Freitag, den 03.05.2019, 12:05 +0200 schrieb Philipp Zabel: > Without this gbm_bo_get_offset() can return 0 where it shouldn't. Reviewed-by: Lucas Stach > --- >  src/gallium/drivers/etnaviv/etnaviv_resource.c | 1 + >  1 file changed, 1 insertion(+) > > diff --gi

Re: [Mesa-dev] [PATCH 4/8] etnaviv: add 2D GPU YUV->RGB blitter

2019-04-26 Thread Lucas Stach
Am Freitag, den 26.04.2019, 08:24 +0200 schrieb Christian Gmeiner: > Am Fr., 12. Apr. 2019 um 19:38 Uhr schrieb Lucas Stach > : > > > > This adds a blit path using the 2D GPU for a linear YUV to tiled RGB > > blit. This allows to implement importing of planar YUV texture

Re: [Mesa-dev] [PATCH 0/6] Add support for NV12

2019-04-26 Thread Lucas Stach
Am Freitag, den 26.04.2019, 09:41 +0200 schrieb Christian Gmeiner: > Hi Lucas > > > > > Am Mittwoch, den 24.04.2019, 08:36 +0200 schrieb Christian Gmeiner: > > > This patch series goes a complete different route then the one from > > > Lucas Stach. I am using

Re: [Mesa-dev] [PATCH 0/6] Add support for NV12

2019-04-25 Thread Lucas Stach
Hi Christian, Am Mittwoch, den 24.04.2019, 08:36 +0200 schrieb Christian Gmeiner: > This patch series goes a complete different route then the one from > Lucas Stach. I am using the integrated YUV tiler instead of using > the 2D core for format conversion. I am reusing some patches fro

Re: [Mesa-dev] [PATCH 1/6] st/dri: allow to create image for formats that only support SV or RT binding

2019-04-15 Thread Lucas Stach
Hi Michel, Am Montag, den 15.04.2019, 12:04 +0200 schrieb Michel Dänzer: > On 2019-04-12 7:33 p.m., Lucas Stach wrote: > > Unconditionally requesting both bindings can lead to premature > > failure to create a valid image. > > > > > > Signed-off-by: Luca

Re: [Mesa-dev] [PATCH 2/8] etnaviv: clear out next pointer when allocating resource

2019-04-15 Thread Lucas Stach
Am Montag, den 15.04.2019, 12:20 +0200 schrieb Philipp Zabel: > On Fri, 2019-04-12 at 19:38 +0200, Lucas Stach wrote: > > We copy the template resource content into the newly allocated resource. > > If the template derived from a planar resource this leads to a non reference >

[Mesa-dev] [PATCH 1/8] etnaviv: create optional 2d pipe in screen

2019-04-12 Thread Lucas Stach
The 2D pipe is useful to implement fast planar and interleaved YUV buffer imports. Not all systems have a 2D capable core, so this is strictly optional. Signed-off-by: Lucas Stach --- src/gallium/drivers/etnaviv/etnaviv_context.c | 6 ++ src/gallium/drivers/etnaviv/etnaviv_context.h | 1

[Mesa-dev] [PATCH 7/8] etnaviv: improve PIPE_BIND_LINEAR handling

2019-04-12 Thread Lucas Stach
isn't used for rendering. Signed-off-by: Lucas Stach --- src/gallium/drivers/etnaviv/etnaviv_resource.c | 8 1 file changed, 8 insertions(+) diff --git a/src/gallium/drivers/etnaviv/etnaviv_resource.c b/src/gallium/drivers/etnaviv/etnaviv_resource.c index f405b880a6c0..650c8e7eb7

[Mesa-dev] [PATCH 2/8] etnaviv: clear out next pointer when allocating resource

2019-04-12 Thread Lucas Stach
We copy the template resource content into the newly allocated resource. If the template derived from a planar resource this leads to a non reference counted copy of the next resource pointer. Make sure to clear this out when allocating a new resource. Signed-off-by: Lucas Stach --- src/gallium

[Mesa-dev] [PATCH 6/8] etnaviv: use filter blit for 2D YUV import on old GC320

2019-04-12 Thread Lucas Stach
ngine on the 3D core. Not the most efficient path, but at least gives us the same level of functionality as on the newer GC320 cores and looks the same to the application. Signed-off-by: Lucas Stach --- src/gallium/drivers/etnaviv/etnaviv_2d.c | 198 --- 1 file changed, 180 in

[Mesa-dev] [PATCH 8/8] etnaviv: handle YUV textures with the 2D GPU

2019-04-12 Thread Lucas Stach
This allows color space conversion and tiling in a single step, as well as handling multi-planar formats like NV12, which are really useful when dealing with hardware video decoders. Signed-off-by: Lucas Stach --- .../drivers/etnaviv/etnaviv_clear_blit.c | 2 +- src/gallium/drivers

[Mesa-dev] [PATCH 3/8] etnaviv: remember data offset into BO

2019-04-12 Thread Lucas Stach
Imported resources might not start at offset 0 into the buffer object. Make sure to remember the offset that is provided with the handle on import. Signed-off-by: Lucas Stach --- src/gallium/drivers/etnaviv/etnaviv_resource.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/gallium

[Mesa-dev] [PATCH 4/8] etnaviv: add 2D GPU YUV->RGB blitter

2019-04-12 Thread Lucas Stach
This adds a blit path using the 2D GPU for a linear YUV to tiled RGB blit. This allows to implement importing of planar YUV textures with a single copy. Signed-off-by: Lucas Stach --- src/gallium/drivers/etnaviv/Makefile.sources |2 + src/gallium/drivers/etnaviv/etnaviv_2d.c | 164

[Mesa-dev] [PATCH 5/8] etnaviv: export etna_submit_rs_state

2019-04-12 Thread Lucas Stach
The new 2D YUV blit needs this in some cases, so make it available. Signed-off-by: Lucas Stach --- src/gallium/drivers/etnaviv/etnaviv_rs.c | 2 +- src/gallium/drivers/etnaviv/etnaviv_rs.h | 4 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/gallium/drivers/etnaviv

[Mesa-dev] [PATCH 3/6] st/dri: fix dri2_from_planar for multiplanar images

2019-04-12 Thread Lucas Stach
From: Philipp Zabel Fix the gbm_dri_bo_get_handle_for_plane use case by allowing plane > 0 in dri2_from_planar for images with multiple planes in separate chained texture resources. Signed-off-by: Philipp Zabel --- src/gallium/state_trackers/dri/dri2.c | 12 +++- 1 file changed, 11 ins

[Mesa-dev] [PATCH 5/6] st/dri: don't re-write plane format if supported by driver

2019-04-12 Thread Lucas Stach
If the driver supports multi-planar formats natively we don't want to re-write the format of the planes on import. Split this out in a separate function for clarity. Signed-off-by: Lucas Stach --- src/gallium/state_trackers/dri/dri2.c | 32 ++- 1 file change

[Mesa-dev] [PATCH 6/6] st/mesa: skip any extra handling of YUV textures if driver supports them

2019-04-12 Thread Lucas Stach
If the driver provides native support for YUV textures we can skip adding additional samplers and re-writing the shaders. Signed-off-by: Lucas Stach --- src/mesa/state_tracker/st_atom_sampler.c | 6 ++ src/mesa/state_tracker/st_atom_texture.c | 6 ++ src/mesa/state_tracker

[Mesa-dev] [PATCH 4/6] st/dri: handle emulated YUV texture sampling in query_dma_buf_modifiers

2019-04-12 Thread Lucas Stach
mport formats, without the need to take a special code path for the emulated OES_external texture handling. Signed-off-by: Lucas Stach --- src/gallium/state_trackers/dri/dri2.c | 17 ++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/src/gallium/state_trackers/dri/dri2

[Mesa-dev] [PATCH 2/6] st/dri: fix dri2_query_image for multiplanar images

2019-04-12 Thread Lucas Stach
From: Philipp Zabel Images with multiple planes in separate chained texture resources should report the correct number of planes. Signed-off-by: Philipp Zabel --- src/gallium/state_trackers/dri/dri2.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/gallium/state_tr

[Mesa-dev] [PATCH 1/6] st/dri: allow to create image for formats that only support SV or RT binding

2019-04-12 Thread Lucas Stach
Unconditionally requesting both bindings can lead to premature failure to create a valid image. Signed-off-by: Lucas Stach --- src/gallium/state_trackers/dri/dri2.c | 13 +++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/src/gallium/state_trackers/dri/dri2.c b/src

Re: [Mesa-dev] [PATCH v2] gallium: ddebug: Add missing fence related wrappers

2019-04-03 Thread Lucas Stach
> sync=0xed9ef7c0) at ../src/egl/main/eglapi.c:2107 >   #4  0xbd29ca90 in  () >   #5  0xbd401000 in  () > > Signed-off-by: Guido Günther Reviewed-by: Lucas Stach > > --- > Changes from v1: > - Drop duplicate dd_context_flush() as notic

Re: [Mesa-dev] [PATCH] gallium: ddebug: Add missing fence related wrappers

2019-04-03 Thread Lucas Stach
Hi Guido, Am Montag, den 01.04.2019, 14:19 +0200 schrieb Guido Günther: > Without that `GALLIUM_DDEBUG=always kmscube -A` would segfault like > >   #0  0x in  () >   #1  0xa72a3c54 in dri2_get_fence_fd (_screen=0xed4f2090, > _fence=0xed9ef880) at ../src/gallium/st

Re: [Mesa-dev] [PATCH] etnaviv: shrink struct etna_3d_state

2019-03-27 Thread Lucas Stach
Am Mittwoch, den 27.03.2019, 14:58 +0100 schrieb Christian Gmeiner: > Drop struct members which are only written to but never read from. > > Signed-off-by: Christian Gmeiner Reviewed-by: Lucas Stach > --- >  src/gallium/drivers/etnaviv/etnaviv_emit.c | 17 -

[Mesa-dev] [PATCH] etnaviv: only try to construct scanout resource when on KMS winsys

2019-03-27 Thread Lucas Stach
Trying to construct a scanout capable buffer will only ever work when when we are on top of a KMS winsys, as the render node isn't capable of allocating contiguous buffers. Tested-by: Marius Vlad Signed-off-by: Lucas Stach --- src/gallium/drivers/etnaviv/etnaviv_resource.c | 2 +- 1

[Mesa-dev] [PATCH 2/2] etnaviv: flush all pending contexts when accessing a resource with the CPU

2019-03-27 Thread Lucas Stach
resource usage tracking across different pipe_context's) Signed-off-by: Lucas Stach --- src/gallium/drivers/etnaviv/etnaviv_transfer.c | 10 -- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/gallium/drivers/etnaviv/etnaviv_transfer.c b/src/gallium/drivers/et

[Mesa-dev] [PATCH 1/2] etnaviv: don't flush own context when updating resource use

2019-03-27 Thread Lucas Stach
tracking across different pipe_context's) Signed-off-by: Lucas Stach --- src/gallium/drivers/etnaviv/etnaviv_resource.c | 11 ++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/gallium/drivers/etnaviv/etnaviv_resource.c b/src/gallium/drivers/etnaviv/etnaviv_resou

Re: [Mesa-dev] [PATCH v3 3/4] etnaviv: hook-up etc2 patching

2019-02-27 Thread Lucas Stach
- drop minor optimization regarding rsc->layout == ETNA_LAYOUT_LINEAR > - better documentation why DRM_ETNA_PREP_WRITE is needed > > Signed-off-by: Christian Gmeiner Reviewed-by: Lucas Stach > --- > .../drivers/etnaviv/etnaviv_resource.c| 3 + > ..

Re: [Mesa-dev] [PATCH v2 4/4] etnaviv: enable ETC2 texture compression support for HALTI0 GPUs

2019-02-27 Thread Lucas Stach
Am Dienstag, den 26.02.2019, 19:15 +0100 schrieb Christian Gmeiner: > Signed-off-by: Christian Gmeiner Reviewed-by: Lucas Stach > --- >  src/gallium/drivers/etnaviv/etnaviv_screen.c | 12 +--- >  1 file changed, 1 insertion(+), 11 deletions(-) > > diff --git a/s

Re: [Mesa-dev] [PATCH v2 1/4] etnaviv: implement ETC2 block patching for HALTI0

2019-02-27 Thread Lucas Stach
ds_patching(const struct pipe_resource *prsc) > +{ > +   const struct etna_screen *screen = etna_screen(prsc->screen); > + > +   if (!util_format_is_etc(prsc->format)) > +  return false; > + > +   if (prsc->format == PIPE_FORMAT_ETC1_RGB8) > +  retu

Re: [Mesa-dev] [PATCH v2 3/4] etnaviv: hook-up etc2 patching

2019-02-27 Thread Lucas Stach
Am Dienstag, den 26.02.2019, 19:15 +0100 schrieb Christian Gmeiner: > Changes v1 -> v2: >  - Avoid the GPU sampling from the resource that gets mutated by the the >    transfer map by setting DRM_ETNA_PREP_WRITE. > > > Signed-off-by: Christian Gmeiner > --- >  .../drivers/etnaviv/etnaviv_resource

Re: [Mesa-dev] [PATCH] etnaviv: blt: mark used src resource as read from

2019-02-22 Thread Lucas Stach
Am Freitag, den 22.02.2019, 11:10 +0100 schrieb Christian Gmeiner: > Signed-off-by: Christian Gmeiner Reviewed-by: Lucas Stach > --- > src/gallium/drivers/etnaviv/etnaviv_blt.c | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/src/gallium/drivers/etnaviv/etn

Re: [Mesa-dev] etnaviv: rs: mark used src resource as read from

2019-02-22 Thread Lucas Stach
Am Freitag, den 22.02.2019, 11:02 +0100 schrieb Christian Gmeiner: > Signed-off-by: Christian Gmeiner Reviewed-by: Lucas Stach > --- > src/gallium/drivers/etnaviv/etnaviv_rs.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/src/gallium/drivers/etnaviv/etnaviv_rs.

Re: [Mesa-dev] [PATCH 3/4] etnaviv: hook-up etc2 patching

2019-02-22 Thread Lucas Stach
Am Freitag, den 22.02.2019, 10:18 +0100 schrieb Christian Gmeiner: > Signed-off-by: Christian Gmeiner AFAICS this is directly operating on the mapped buffer, right? As ETC is stored as a linear, we won't get a temporary resource for the transfer, but map the GPU resource directly. So this will f

Re: [Mesa-dev] [PATCH 2/4] etnaviv: keep track of mapped bo address

2019-02-22 Thread Lucas Stach
Am Freitag, den 22.02.2019, 10:18 +0100 schrieb Christian Gmeiner: > Saves us from calling etna_bo_map(..) and saves us from doing the > same offset calcs for map() and unmap() operations. > > Signed-off-by: Christian Gmeiner Reviewed-by: Lucas Stach > --- > src/galli

Re: [Mesa-dev] [PATCH 4/4] etnaviv: hook up linear texture sampling support

2019-01-25 Thread Lucas Stach
atures1, LINEAR_TEXTURE_SUPPORT)) > +  return true; In order to avoid this sitting on the ML for too long while mostly looking good: how would you feel about squashing this last hunk into the previous patch and dropping the other parts of this patch for now? This wa

Re: [Mesa-dev] [PATCH 4/4] etnaviv: hook up linear texture sampling support

2019-01-24 Thread Lucas Stach
Am Donnerstag, den 24.01.2019, 07:46 +0100 schrieb Christian Gmeiner: > Am Mo., 21. Jan. 2019 um 10:10 Uhr schrieb Lucas Stach > : > > > > Am Montag, den 21.01.2019, 07:50 +0100 schrieb Christian Gmeiner: > > > If the GPU supports linear sampling, linear addressing

Re: [Mesa-dev] [PATCH 1/4] etnaviv: extend etna_resource with an addressing mode

2019-01-24 Thread Lucas Stach
Am Donnerstag, den 24.01.2019, 07:31 +0100 schrieb Christian Gmeiner: > Hi Lucas > > Am Mo., 21. Jan. 2019 um 10:03 Uhr schrieb Lucas Stach > : > > > > Hi Christian, > > > > first of all, thanks for figuring this out. This is really nice > > to fin

Re: [Mesa-dev] [PATCH 4/4] etnaviv: hook up linear texture sampling support

2019-01-21 Thread Lucas Stach
Am Montag, den 21.01.2019, 07:50 +0100 schrieb Christian Gmeiner: > If the GPU supports linear sampling, linear addressing mode > will be used as default. > > > Signed-off-by: Christian Gmeiner > --- >  src/gallium/drivers/etnaviv/etnaviv_resource.c | 10 +++--- >  src/gallium/drivers/etnaviv/

Re: [Mesa-dev] [PATCH 1/4] etnaviv: extend etna_resource with an addressing mode

2019-01-21 Thread Lucas Stach
Hi Christian, first of all, thanks for figuring this out. This is really nice to finally know how it works. Am Montag, den 21.01.2019, 07:49 +0100 schrieb Christian Gmeiner: > Defines how sampler (and pixel pipes) needs to access the data > represented with a resource. The used default is mode is

Re: [Mesa-dev] Double free error on etnaviv driver.

2019-01-18 Thread Lucas Stach
Hi Sergey, Am Donnerstag, den 17.01.2019, 18:14 +0300 schrieb Nazarov Sergey: > Hi, Lucas! > Here is result of execution standard Qt5 example application mainwindow > built under custom buildroot with gcc-4.9.4, mesa3d-17.3.6. > But we had the same error with latest buildroot and latest supported

Re: [Mesa-dev] Double free error on etnaviv driver.

2019-01-17 Thread Lucas Stach
Hi Sergey, Am Mittwoch, den 16.01.2019, 13:34 +0300 schrieb Nazarov Sergey: > Hello! > I use mesa+etnaviv Gallium driver on iMX6Q based board. > I have double free error at the end of any application using mesa. > I've found that the problem comes from current ARM g++ compilers > (at least from 4.

Re: [Mesa-dev] [PATCH] egl/wayland: break double/tripple buffering feedback loops

2019-01-16 Thread Lucas Stach
Am Dienstag, den 15.01.2019, 10:35 -0600 schrieb Derek Foreman: > On 1/15/19 8:02 AM, Daniel Stone wrote: > > Hi, > > > > > > On Tue, 18 Dec 2018 at 17:59, Lucas Stach > > > > wrote: > > > Am Dienstag, den 18.12.2018, 17:43 + schrieb Emil

Re: [Mesa-dev] [PATCH v4] etnaviv: fix resource usage tracking across different pipe_context's

2019-01-16 Thread Lucas Stach
Am Samstag, den 12.01.2019, 22:22 +0100 schrieb Marek Vasut: > > From: Christian Gmeiner > > A pipe_resource can be shared by all the pipe_context's hanging off the > same pipe_screen. > > > Signed-off-by: Christian Gmeiner > > Signed-off-by: Marek Vasut > To: mesa-dev@lists.freedesktop.org >

Re: [Mesa-dev] [PATCH v4] etnaviv: fix resource usage tracking across different pipe_context's

2019-01-14 Thread Lucas Stach
Am Montag, den 14.01.2019, 15:20 +0100 schrieb Marek Vasut: > On 1/14/19 3:02 PM, Lucas Stach wrote: > > Am Montag, den 14.01.2019, 14:54 +0100 schrieb Marek Vasut: > > > On 1/14/19 12:16 PM, Lucas Stach wrote: > > > > Hi Marek, > > > > > > >

Re: [Mesa-dev] [PATCH v4] etnaviv: fix resource usage tracking across different pipe_context's

2019-01-14 Thread Lucas Stach
Am Montag, den 14.01.2019, 14:54 +0100 schrieb Marek Vasut: > On 1/14/19 12:16 PM, Lucas Stach wrote: > > Hi Marek, > > > > Am Samstag, den 12.01.2019, 22:22 +0100 schrieb Marek Vasut: > > > > From: Christian Gmeiner > > > > > > A pipe_resou

Re: [Mesa-dev] [PATCH v4] etnaviv: fix resource usage tracking across different pipe_context's

2019-01-14 Thread Lucas Stach
Hi Marek, Am Samstag, den 12.01.2019, 22:22 +0100 schrieb Marek Vasut: > > From: Christian Gmeiner > > A pipe_resource can be shared by all the pipe_context's hanging off the > same pipe_screen. > > > Signed-off-by: Christian Gmeiner > > Signed-off-by: Marek Vasut > To: mesa-dev@lists.freedes

Re: [Mesa-dev] [PATCH] etnaviv: implement check_resource_capability

2019-01-07 Thread Lucas Stach
Hi Christian, Am Freitag, den 28.12.2018, 11:04 +0100 schrieb Christian Gmeiner: > Am Di., 18. Dez. 2018 um 19:09 Uhr schrieb Lucas Stach > : > > > > We try to avoid sharing all resources with KMS side of renderonly, as this > > adds some overhead that isn't really

[Mesa-dev] [PATCH v2 1/2] etnaviv: enable full overwrite in a few more cases

2018-12-19 Thread Lucas Stach
Take into account the render target format when checking if the color mask affects all channels of the RT. This allows to enable full override in a few cases where a non-alpha format is used. Signed-off-by: Lucas Stach --- v2: clarify comment --- src/gallium/drivers/etnaviv/etnaviv_blend.c | 11

[Mesa-dev] [PATCH v2 2/2] etnaviv: annotate variables only used in debug build

2018-12-19 Thread Lucas Stach
Some of the status variables in the compiler are only used in asserts and thus may be unused in release builds. Annotate them accordingly to avoid 'unused but set' warnings from the compiler. Signed-off-by: Lucas Stach --- v2: get rid of superfluous variable initialization --- s

[Mesa-dev] [PATCH] etnaviv: implement check_resource_capability

2018-12-18 Thread Lucas Stach
We try to avoid sharing all resources with KMS side of renderonly, as this adds some overhead that isn't really needed for most resources. If someone tries to validate a resource for scanout, this is a good indication that the sharing with the KMS side is actually needed. Signed-off-by:

Re: [Mesa-dev] [PATCH] egl/wayland: break double/tripple buffering feedback loops

2018-12-18 Thread Lucas Stach
Am Dienstag, den 18.12.2018, 17:43 + schrieb Emil Velikov: > > On Tue, 18 Dec 2018 at 11:16, Lucas Stach wrote: > > > > Currently we dispose any unneeded color buffers immediately if we detect > > that > > there are more unlocked buffers than we need. This c

[Mesa-dev] [PATCH] egl/wayland: break double/tripple buffering feedback loops

2018-12-18 Thread Lucas Stach
CPU time on rapidly freeing and reallocating color buffers break those feedback loops by letting the unneeded buffers sit around for a short while before disposing them. Signed-off-by: Lucas Stach --- src/egl/drivers/dri2/platform_wayland.c | 13 + 1 file changed, 9 insertions(+), 4

Re: [Mesa-dev] [PATCH] etnaviv: drop redundant ctx function parameter

2018-12-14 Thread Lucas Stach
Am Mittwoch, den 12.12.2018, 14:45 +0100 schrieb Christian Gmeiner: > There is no need to have an extra ctx paramter as all the other > parameters carry all the needed information. > > Signed-off-by: Christian Gmeiner Reviewed-by: Lucas Stach > --- >  src/galli

Re: [Mesa-dev] [PATCH] etnaviv: Make sure rs alignment checks match

2018-11-15 Thread Lucas Stach
Hi Guido, Am Dienstag, den 09.10.2018, 13:50 +0200 schrieb Guido Günther: > Hi, > On Mon, Sep 17, 2018 at 04:06:57PM +0200, Guido Günther wrote: > > etna_resource_alloc and etna_resource_from_handle currently use different > > checks. > > This leads to > > > >    etna_resource_from_handle:492: t

[Mesa-dev] [PATCH 4/4] etnaviv: annotate variables only used in debug build

2018-11-15 Thread Lucas Stach
Some of the status variables in the compiler are only used in asserts and thus may be unused in release builds. Annotate them accordingly to avoid 'unused but set' warnings from the compiler. Signed-off-by: Lucas Stach --- src/gallium/drivers/etnaviv/etnaviv_compiler.c | 8 --

[Mesa-dev] [PATCH 2/4] etnaviv: use surface format directly

2018-11-15 Thread Lucas Stach
There is no need to do the detour over the resource behind the surface to get the format. Use the surface format directly. Signed-off-by: Lucas Stach --- src/gallium/drivers/etnaviv/etnaviv_blend.c | 2 +- src/gallium/drivers/etnaviv/etnaviv_context.c | 9 ++--- 2 files changed, 3

[Mesa-dev] [PATCH 1/4] etnaviv: use dummy RT buffer when rendering without color buffer

2018-11-15 Thread Lucas Stach
o stop the core from pushing the dirt into a precious real render target, plug in dummy buffer when rendering without a color buffer. Signed-off-by: Lucas Stach --- src/gallium/drivers/etnaviv/etnaviv_context.c | 13 + src/gallium/drivers/etnaviv/etnaviv_context.h | 3 +++ src/galli

[Mesa-dev] [PATCH 3/4] etnaviv: enable full overwrite in a few more cases

2018-11-15 Thread Lucas Stach
Take into account the render target format when checking if the color mask affects all channels of the RT. This allows to enable full override in a few cases where a non-alpha format is used. Signed-off-by: Lucas Stach --- src/gallium/drivers/etnaviv/etnaviv_blend.c | 7 +-- 1 file changed

Re: [Mesa-dev] [PATCH] etnaviv: Use write combine instead of unached mappings for shader bo

2018-10-04 Thread Lucas Stach
Am Montag, den 01.10.2018, 18:37 +0200 schrieb Guido Günther: > The later are sensitive to unalligned accesses on arm64[1] and we don't > need an uncached mapping here. > > [1]: https://lists.freedesktop.org/archives/etnaviv/2018-September/001956.html > > > Signed-off-by: Guido Günther > --- >  

Re: [Mesa-dev] imx/etnaviv: loader_open_render_node() fails

2018-09-07 Thread Lucas Stach
Hi Emil, Am Freitag, den 07.09.2018, 10:52 +0100 schrieb Emil Velikov: > Hi Lukas, > > Adding the etnaviv ML - people in there may have some tips. > > > On 6 September 2018 at 15:43, Lukas F. Hartmann wrote: > > Hi, > > > > I've updated to and rebuilt the latest git versions of linux, drm, mes

Re: [Mesa-dev] imx/etnaviv: loader_open_render_node() fails

2018-09-07 Thread Lucas Stach
Am Donnerstag, den 06.09.2018, 16:43 +0200 schrieb Lukas F. Hartmann: > Hi, > > I've updated to and rebuilt the latest git versions of linux, drm, mesa > and kmscube on an imx6qp system. I tried both with etnaviv as a module > and compiled into the kernel (no difference). > > Mesa no longer picks

Re: [Mesa-dev] [PATCH 00/21] Towards NIR support for etnaviv

2018-09-05 Thread Lucas Stach
Hi Christian, Am Dienstag, den 05.06.2018, 17:43 +0200 schrieb Christian Gmeiner: > Am Di., 5. Juni 2018 um 16:40 Uhr schrieb Philipp Zabel > > : > > > > Hi! > > > > we have been interested in NIR support for etnaviv for a while, for the > > obvious reasons: gaining access to common optimization

Re: [Mesa-dev] [PATCH] gallium: Check pipe_screen::resource_changed before dereferencing it

2018-07-12 Thread Lucas Stach
texture" > Fixes: a37cf630b4d1 "gallium: add pipe_screen::resource_changed callback >  wrappers" > Signed-off-by: Michel Dänzer Urgh, thanks for fixing this up. Reviewed-by: Lucas Stach > --- >  src/gallium/auxiliary/driver_ddebug/dd_screen.c |

[Mesa-dev] [PATCH] st/mesa: call resource_changed when binding a EGLImage to a texture

2018-07-09 Thread Lucas Stach
When a EGLImage is newly bound to a texture, we need to make sure the driver is informed that the resource might have changed. Fixes stale texture content on Etnaviv when binding an existing EGLImage to an existing texture object. Signed-off-by: Lucas Stach --- src/mesa/state_tracker

[Mesa-dev] [PATCH 6/9] etnaviv: add 2D GPU YUV->RGB blitter

2018-07-09 Thread Lucas Stach
This adds a blit path using the 2D GPU for a linear YUV to tiled RGB blit. This allows to implement importing of planar YUV textures with a single copy. Signed-off-by: Lucas Stach --- src/gallium/drivers/etnaviv/Makefile.sources |2 + src/gallium/drivers/etnaviv/etnaviv_2d.c | 166

[Mesa-dev] [PATCH 8/9] etnaviv: use filter blit for 2D YUV import on old GC320

2018-07-09 Thread Lucas Stach
ngine on the 3D core. Not the most efficient path, but at least gives us the same level of functionality as on the newer GC320 cores and looks the same to the application. Signed-off-by: Lucas Stach --- src/gallium/drivers/etnaviv/etnaviv_2d.c | 194 +-- 1 file changed, 177 in

[Mesa-dev] [PATCH 2/9] etnaviv: reject imports of tiler incompatible linear buffers

2018-07-09 Thread Lucas Stach
We don't have a fallback to get them into a render/sampler compatible layout (yet). Rejecting the import at least forwards this issue to the client application, which might have a way to deal with this. Signed-off-by: Lucas Stach --- src/gallium/drivers/etnaviv/etnaviv_resource.

[Mesa-dev] [PATCH 7/9] etnaviv: export etna_submit_rs_state

2018-07-09 Thread Lucas Stach
The new 2D YUV blit needs this in some cases, so make it available. Signed-off-by: Lucas Stach --- src/gallium/drivers/etnaviv/etnaviv_rs.c | 2 +- src/gallium/drivers/etnaviv/etnaviv_rs.h | 4 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/gallium/drivers/etnaviv

[Mesa-dev] [PATCH 3/9] etnaviv: clear out next pointer when allocating resource

2018-07-09 Thread Lucas Stach
We copy the template resource content into the newly allocated resource. If the template derived from a planar resource this leads to a non reference counted copy of the next resource pointer. Make sure to clear this out when allocating a new resource. Signed-off-by: Lucas Stach --- src/gallium

[Mesa-dev] [PATCH 9/9] etnaviv: handle YUV textures with the 2D GPU

2018-07-09 Thread Lucas Stach
This allows color space conversion and tiling in a single step, as well as handling multi-planar formats like NV12, which are really useful when dealing with hardware video decoders. Signed-off-by: Lucas Stach --- src/gallium/drivers/etnaviv/etnaviv_clear_blit.c | 2 +- src/gallium/drivers

[Mesa-dev] [PATCH 5/9] etnaviv: create optional 2d pipe in screen

2018-07-09 Thread Lucas Stach
The 2D pipe is useful to implement fast planar and interleaved YUV buffer imports. Not all systems have a 2D capable core, so this is strictly optional. Signed-off-by: Lucas Stach --- src/gallium/drivers/etnaviv/etnaviv_context.c | 6 ++ src/gallium/drivers/etnaviv/etnaviv_context.h | 1

[Mesa-dev] [PATCH 1/9] etnaviv: improve PIPE_BIND_LINEAR handling

2018-07-09 Thread Lucas Stach
isn't used for rendering. Signed-off-by: Lucas Stach --- src/gallium/drivers/etnaviv/etnaviv_resource.c | 8 1 file changed, 8 insertions(+) diff --git a/src/gallium/drivers/etnaviv/etnaviv_resource.c b/src/gallium/drivers/etnaviv/etnaviv_resource.c index 7fd374ae23d5..c17a170453

[Mesa-dev] [PATCH 4/9] etnaviv: remember data offset into BO

2018-07-09 Thread Lucas Stach
Imported resources might not start at offset 0 into the buffer object. Make sure to remember the offset that is provided with the handle on import. Signed-off-by: Lucas Stach --- src/gallium/drivers/etnaviv/etnaviv_resource.c | 2 +- src/gallium/drivers/etnaviv/etnaviv_resource.h | 1 + 2 files

[Mesa-dev] [PATCH 0/9] Etnaviv direct YUV support

2018-07-09 Thread Lucas Stach
lease of this series, which only worked on the i.MX6QP. With this series NV12 should work on all supported Vivante GPUs. Regards, Lucas [1] https://marc.info/?l=mesa3d-dev&m=152655423402505&w=2 [2] https://bugzilla.gnome.org/show_bug.cgi?id=783521 Lucas Stach (9): etnaviv: improve PIP

Re: [Mesa-dev] [PATCH 2/2] st/dri: replace format conversion functions with single mapping table

2018-06-07 Thread Lucas Stach
Hi Marek, thanks for the review. Am Samstag, den 26.05.2018, 00:36 -0400 schrieb Marek Olšák: [...] > > > @@ -983,7 +760,7 @@ dri2_update_tex_buffer(struct dri_drawable *drawable, > > > >  static __DRIimage * > >  dri2_create_image_from_winsys(__DRIscreen *_screen, > > -                       

[Mesa-dev] [PATCH 0/2] st/dri format handling cleanups

2018-05-17 Thread Lucas Stach
t for drivers using the sampler rewrite (though I think I've covered all cases) I would appreciate some testing from the Freedreno folks, or whoever cares about this. Regards, Lucas Lucas Stach (2): st/dri: allow both render and sampler compatible dma-buf formats st/dri: replace format

[Mesa-dev] [PATCH 2/2] st/dri: replace format conversion functions with single mapping table

2018-05-17 Thread Lucas Stach
the different representations. Also this now stores all the known representations in the __DRIimageRec, to avoid the loss of information we currently have when importing a buffer with a fourcc, which doesn't have a corresponding dri format. Signed-off-by: Lucas Stach --- src/ga

[Mesa-dev] [PATCH 1/2] st/dri: allow both render and sampler compatible dma-buf formats

2018-05-17 Thread Lucas Stach
image APIs it doesn't distinguish between render or sampler compatible formats. So this patch aligns behavior between Intel and Gallium based drivers. Signed-off-by: Lucas Stach --- src/gallium/state_trackers/dri/dri2.c | 29 +-- 1 file changed, 18 insertions(+

Re: [Mesa-dev] [PATCH v2] st/mesa: only define GLSL 1.4 for compat if driver supports it

2018-05-16 Thread Lucas Stach
Am Mittwoch, den 16.05.2018, 16:02 +0200 schrieb Christian Gmeiner: > Currently GLSL 1.4 is defined for all gallium drivers even only > GLSL 1.2 is supported as seen on etnaviv. > > v1 -> v2: >  - use _min(..) as suggested by Lucas Stach and Michel Dänzer > > Fixes

Re: [Mesa-dev] [PATCH] st/mesa: only define GLSL 1.4 for compat if driver supports it

2018-05-16 Thread Lucas Stach
Am Mittwoch, den 16.05.2018, 15:31 +0200 schrieb Christian Gmeiner: > Currently GLSL 1.4 is defined for all gallium drivers even only > GLSL 1.2 is supported as seen on etnaviv. > > Fixes 4560aad780b ("mesa: add GLSLVersionCompat constant") > > > Signed-off-by: Christian Gmeiner > --- >  src/mes

Re: [Mesa-dev] [PATCH v2 05/14] etnaviv: take care of the number of layers

2018-05-04 Thread Lucas Stach
Am Dienstag, den 01.05.2018, 16:48 +0200 schrieb Christian Gmeiner: > With the help of the number of layers we can choose the correct > RS clear format - like the binary blob does. > > Signed-off-by: Christian Gmeiner > --- >  src/gallium/drivers/etnaviv/etnaviv_rs.c | 3 ++- >  1 file changed, 2

Re: [Mesa-dev] [PATCH v2 03/14] etnaviv: rs: add support for multi layer formats

2018-05-04 Thread Lucas Stach
Am Dienstag, den 01.05.2018, 16:48 +0200 schrieb Christian Gmeiner: > The binary blob driver supports 'multi layer' formats. For > instance: gcvSURF_A16B16G16R16F_2_A8R8G8B8 >  < format >_n_< base format > Sort of high-level comment, but to me the usage of the term layer for th

  1   2   3   4   >