summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/amd/common/ac_surface.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/amd/common/ac_surface.c b/src/amd/common/ac_surface.c
index c5bce0b651..93b75bc48f 100644
--- a/src/amd/common/ac_surface.c
+++ b/src/amd/common/ac_surface.c
@@ -265,8 +265,11 @@ static int gfx6_compute_level(ADDR_HANDLE addrlib,
/* Make GFX6 linear surfaces compatible with GFX9 for hybrid graphics,
* because GFX9 needs linear alignment of 256 bytes.
+ *
+ * This should not be applied to staging surfaces.
*/
- if (config->info.levels == 1 &&
+ if ((surf->flags & (RADEON_SURF_SCANOUT | RADEON_SURF_SHAREABLE)) &&
+ config->info.levels == 1 &&
AddrSurfInfoIn->tileMode == ADDR_TM_LINEAR_ALIGNED &&
AddrSurfInfoIn->bpp) {
unsigned alignment = 256 / (AddrSurfInfoIn->bpp / 8);