diff options
author | Rob Clark <[email protected]> | 2019-06-07 09:29:53 -0700 |
---|---|---|
committer | Rob Clark <[email protected]> | 2019-06-11 10:55:27 -0700 |
commit | 12201d7a8be809d9dfbd682eeb4d73211ad96c00 (patch) | |
tree | 2f45454022d2ba52f50334f537016294af4571be /src/gallium/drivers/freedreno/freedreno_resource.c | |
parent | 3c9a31eb50ce598c89bc93a8ebb33acb5f3ba53f (diff) |
freedreno: swap UBWC state in shadow path
It doesn't come up yet, as so far we only hit this path with linear
buffers. But it will when we start re-using the shadow path for
uncompressing UBWC buffers.
Signed-off-by: Rob Clark <[email protected]>
Reviewed-by: Kristian H. Kristensen <[email protected]>
Diffstat (limited to 'src/gallium/drivers/freedreno/freedreno_resource.c')
-rw-r--r-- | src/gallium/drivers/freedreno/freedreno_resource.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/gallium/drivers/freedreno/freedreno_resource.c b/src/gallium/drivers/freedreno/freedreno_resource.c index dc5d1463155..5cb04ea9bd8 100644 --- a/src/gallium/drivers/freedreno/freedreno_resource.c +++ b/src/gallium/drivers/freedreno/freedreno_resource.c @@ -200,6 +200,10 @@ fd_try_shadow_resource(struct fd_context *ctx, struct fd_resource *rsc, /* TODO valid_buffer_range?? */ swap(rsc->bo, shadow->bo); swap(rsc->write_batch, shadow->write_batch); + swap(rsc->offset, shadow->offset); + swap(rsc->ubwc_offset, shadow->ubwc_offset); + swap(rsc->ubwc_pitch, shadow->ubwc_pitch); + swap(rsc->ubwc_size, shadow->ubwc_size); rsc->seqno = p_atomic_inc_return(&ctx->screen->rsc_seqno); /* at this point, the newly created shadow buffer is not referenced |