summaryrefslogtreecommitdiffstats
path: root/src/amd/common/ac_surface.c
diff options
context:
space:
mode:
authorMarek Olšák <[email protected]>2019-02-07 00:04:32 -0500
committerMarek Olšák <[email protected]>2019-07-29 17:52:51 -0400
commit19d04191c4e7c2022fb3534d94ad21683feb1604 (patch)
treeda9326420175a619033d59849ebe06861d48c161 /src/amd/common/ac_surface.c
parentc82f33885574e0f8199415b79d6f2b812360b969 (diff)
radeonsi: add support for compute-only chips
Reviewed-by: Pierre-Eric Pelloux-Prayer <[email protected]>
Diffstat (limited to 'src/amd/common/ac_surface.c')
-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 7d871c47204..53353cdee18 100644
--- a/src/amd/common/ac_surface.c
+++ b/src/amd/common/ac_surface.c
@@ -658,6 +658,7 @@ static int gfx6_compute_surface(ADDR_HANDLE addrlib,
*/
AddrSurfInfoIn.flags.dccCompatible =
info->chip_class >= GFX8 &&
+ info->has_graphics && /* disable DCC on compute-only chips */
!(surf->flags & RADEON_SURF_Z_OR_SBUFFER) &&
!(surf->flags & RADEON_SURF_DISABLE_DCC) &&
!compressed &&
@@ -1122,7 +1123,9 @@ static int gfx9_compute_miptree(ADDR_HANDLE addrlib,
}
/* DCC */
- if (!(surf->flags & RADEON_SURF_DISABLE_DCC) && !compressed &&
+ if (info->has_graphics &&
+ !(surf->flags & RADEON_SURF_DISABLE_DCC) &&
+ !compressed &&
gfx9_is_dcc_capable(info, in->swizzleMode)) {
ADDR2_COMPUTE_DCCINFO_INPUT din = {0};
ADDR2_COMPUTE_DCCINFO_OUTPUT dout = {0};