aboutsummaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/iris
diff options
context:
space:
mode:
authorNanley Chery <[email protected]>2019-09-05 16:51:26 -0700
committerMarge Bot <[email protected]>2020-06-19 23:32:29 +0000
commit3915b56e39cb8abb53146797e2806c2e5bb75477 (patch)
treedadb077b3432293d3c2e25e62a9f84e2e752ea1b /src/gallium/drivers/iris
parent2305ab693820f6f08b054cb8b33536e4b1178e45 (diff)
iris: Support I915_FORMAT_MOD_Y_TILED_GEN12_RC_CCS
Reviewed-by: Jordan Justen <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5420>
Diffstat (limited to 'src/gallium/drivers/iris')
-rw-r--r--src/gallium/drivers/iris/iris_resource.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/gallium/drivers/iris/iris_resource.c b/src/gallium/drivers/iris/iris_resource.c
index c2f1b2a300e..032e756cd6a 100644
--- a/src/gallium/drivers/iris/iris_resource.c
+++ b/src/gallium/drivers/iris/iris_resource.c
@@ -59,6 +59,7 @@ enum modifier_priority {
MODIFIER_PRIORITY_X,
MODIFIER_PRIORITY_Y,
MODIFIER_PRIORITY_Y_CCS,
+ MODIFIER_PRIORITY_Y_GEN12_RC_CCS,
};
static const uint64_t priority_to_modifier[] = {
@@ -67,6 +68,7 @@ static const uint64_t priority_to_modifier[] = {
[MODIFIER_PRIORITY_X] = I915_FORMAT_MOD_X_TILED,
[MODIFIER_PRIORITY_Y] = I915_FORMAT_MOD_Y_TILED,
[MODIFIER_PRIORITY_Y_CCS] = I915_FORMAT_MOD_Y_TILED_CCS,
+ [MODIFIER_PRIORITY_Y_GEN12_RC_CCS] = I915_FORMAT_MOD_Y_TILED_GEN12_RC_CCS,
};
static bool
@@ -83,6 +85,10 @@ modifier_is_supported(const struct gen_device_info *devinfo,
if (devinfo->gen <= 8 || devinfo->gen >= 12)
return false;
break;
+ case I915_FORMAT_MOD_Y_TILED_GEN12_RC_CCS:
+ if (devinfo->gen != 12)
+ return false;
+ break;
case DRM_FORMAT_MOD_INVALID:
default:
return false;
@@ -90,6 +96,7 @@ modifier_is_supported(const struct gen_device_info *devinfo,
/* Check remaining requirements. */
switch (modifier) {
+ case I915_FORMAT_MOD_Y_TILED_GEN12_RC_CCS:
case I915_FORMAT_MOD_Y_TILED_CCS: {
if (unlikely(INTEL_DEBUG & DEBUG_NO_RBC))
return false;
@@ -121,6 +128,9 @@ select_best_modifier(struct gen_device_info *devinfo, enum pipe_format pfmt,
continue;
switch (modifiers[i]) {
+ case I915_FORMAT_MOD_Y_TILED_GEN12_RC_CCS:
+ prio = MAX2(prio, MODIFIER_PRIORITY_Y_GEN12_RC_CCS);
+ break;
case I915_FORMAT_MOD_Y_TILED_CCS:
prio = MAX2(prio, MODIFIER_PRIORITY_Y_CCS);
break;
@@ -180,6 +190,7 @@ iris_query_dmabuf_modifiers(struct pipe_screen *pscreen,
I915_FORMAT_MOD_X_TILED,
I915_FORMAT_MOD_Y_TILED,
I915_FORMAT_MOD_Y_TILED_CCS,
+ I915_FORMAT_MOD_Y_TILED_GEN12_RC_CCS,
};
int supported_mods = 0;