freedreno/msm: fix issue where same bo is on multiple rings
authorRob Clark <robclark@freedesktop.org>
Tue, 21 Jul 2015 15:57:00 +0000 (11:57 -0400)
committerRob Clark <robclark@freedesktop.org>
Mon, 17 Aug 2015 14:35:08 +0000 (10:35 -0400)
commit9e34ee4f75ef559ff3a3c6d4b8f285453eea1f29
treece325f8b90e683d24f749a3f9313fca4d5c1b519
parent2fa58ef8f43b41a6d12396ff637f09860665072f
freedreno/msm: fix issue where same bo is on multiple rings

It should be a less common case, but it is possible for a single bo to
be on multiple rings, for example when sharing a buffer across multiple
pipe_context's created from same pipe_screen.

So rather than completely fall over in this case, fallback to slow-path
of looping over all bo's in the ring's bo-table (but retain the fast-
path of constant-lookup for the first ring the buffer is on).

Signed-off-by: Rob Clark <robclark@freedesktop.org>
freedreno/msm/msm_bo.c
freedreno/msm/msm_priv.h
freedreno/msm/msm_ringbuffer.c