etnaviv: flush all pending contexts when accessing a resource with the CPU
authorLucas Stach <l.stach@pengutronix.de>
Wed, 27 Mar 2019 11:22:58 +0000 (12:22 +0100)
committerLucas Stach <l.stach@pengutronix.de>
Wed, 3 Apr 2019 10:54:09 +0000 (12:54 +0200)
commit3d8da347ac491f159ed0f5602301a841c103d7b0
tree8e832735041ab48049e2f7ff9b63f677afcdf42e
parentf317ee1aff4365df5b8d183565eeee535ebc6576
etnaviv: flush all pending contexts when accessing a resource with the CPU

When setting up a transfer to a resource, all contexts where the resource
is pending must be flushed. Otherwise a write transfer might be started
in the current context before all contexts that access the resource in
shared (read) mode have been executed.

Fixes: 64813541d575 (etnaviv: fix resource usage tracking across
different pipe_context's)
Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
Reviewed-by: Christian Gmeiner <christian.gmeiner@gmail.com>
Tested-By: Guido Günther <agx@sigxcpu.org>
src/gallium/drivers/etnaviv/etnaviv_transfer.c