freedreno: fix corrupted fb state
authorRob Clark <robdclark@gmail.com>
Mon, 10 Sep 2018 14:58:28 +0000 (10:58 -0400)
committerRob Clark <robdclark@gmail.com>
Thu, 27 Sep 2018 19:27:38 +0000 (15:27 -0400)
commitef6d15f8a86128251cb6320f7dcda0ee9e36d86a
tree90fe67f95debc37dac11b6bdd47a88c3079a5453
parent5bb96bf73a1b2a9978c4cb766477e453610345f1
freedreno: fix corrupted fb state

In c3d9f29b we allowed ctx->batch to be null, and started tracking the
current framebuffer state in fd_context.  But the existing logic in
fd_blitter_pipe_begin() would, if !ctx->batch, set null fb state to be
restored after blit.  Which broke the world of deqp (and probably other
things)

Fixes: c3d9f29b781 freedreno: allocate ctx's batch on demand
Signed-off-by: Rob Clark <robdclark@gmail.com>
src/gallium/drivers/freedreno/freedreno_resource.c
src/gallium/drivers/freedreno/freedreno_state.c