mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-07 02:48:06 +02:00
zink: directly set batch->state->flush_res from flush_resource hook
there's no need to have an intermediate pointer here since that only complicates keeping scanout synchronized this also eliminates the pointer on the context since it isn't used anymore Fixes:104603fa76("zink: create separate linear tiling image for scanout") Reviewed-by: Adam Jackson <ajax@redhat.com> Acked-by: Erik Faye-Lund <erik.faye-lund@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10358> (cherry picked from commitbe6532ecdf)
This commit is contained in:
parent
687a8bf579
commit
9988f53d51
3 changed files with 2 additions and 7 deletions
|
|
@ -67,7 +67,7 @@
|
|||
"description": "zink: directly set batch->state->flush_res from flush_resource hook",
|
||||
"nominated": true,
|
||||
"nomination_type": 1,
|
||||
"resolution": 0,
|
||||
"resolution": 1,
|
||||
"master_sha": null,
|
||||
"because_sha": "104603fa763c52e98a79785dd514beab949546db"
|
||||
},
|
||||
|
|
|
|||
|
|
@ -1704,10 +1704,6 @@ zink_flush(struct pipe_context *pctx,
|
|||
/* start rp to do all the clears */
|
||||
zink_begin_render_pass(ctx, batch);
|
||||
zink_end_render_pass(ctx, batch);
|
||||
if (ctx->flush_res) {
|
||||
batch->state->flush_res = ctx->flush_res;
|
||||
ctx->flush_res = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
if (!batch->has_work) {
|
||||
|
|
@ -2053,7 +2049,7 @@ zink_flush_resource(struct pipe_context *pctx,
|
|||
* WSI support is added
|
||||
*/
|
||||
if (pres->bind & (PIPE_BIND_SHARED | PIPE_BIND_SCANOUT))
|
||||
ctx->flush_res = zink_resource(pres);
|
||||
ctx->batch.state->flush_res = zink_resource(pres);
|
||||
}
|
||||
|
||||
void
|
||||
|
|
|
|||
|
|
@ -181,7 +181,6 @@ struct zink_context {
|
|||
|
||||
struct primconvert_context *primconvert;
|
||||
|
||||
struct zink_resource *flush_res;
|
||||
struct zink_framebuffer *framebuffer;
|
||||
struct zink_framebuffer_clear fb_clears[PIPE_MAX_COLOR_BUFS + 1];
|
||||
uint16_t clears_enabled;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue