Skip to content

panfrost: Fix the DISCARD_WHOLE_RES case in transfer_map()

The current implementation does not synchronize on BO readiness when DISCARD_WHOLE_RES flag is set, which can lead to misbehaviours when the resource being updated is being used by one of the pending or already flushed batches.

Adding unconditional BO synchronization would do the trick, but we can sometimes optimize this path by re-allocating a new BO instead of waiting for the existing one to be ready.

Reported-by: Daniel Stone daniels@collabora.com Reported-by: Heinrich Fink heinrich.fink@daqri.com Signed-off-by: Boris Brezillon boris.brezillon@collabora.com Cc: Heinrich Fink heinrich.fink@daqri.com Cc: Daniel Stone daniels@collabora.com

Fixes the kms-quad issue reported here [1]

[1]daniels/kms-quads!10 (merged)

/cc @daniels @alyssa @tomeu

Merge request reports