[PATCH i-g-t 10/23] lib/igt_fb: Extract is_gen12_rc_ccs_cc_modifier()
Ville Syrjala
ville.syrjala at linux.intel.com
Mon Sep 2 14:37:45 UTC 2024
From: Ville Syrjälä <ville.syrjala at linux.intel.com>
Extract a helper to identify the clear color compressed modifiers.
Reviewed-by: Juha-Pekka Heikkila <juhapekka.heikkila at gmail.com>
Signed-off-by: Ville Syrjälä <ville.syrjala at linux.intel.com>
---
lib/igt_fb.c | 13 +++++++++----
1 file changed, 9 insertions(+), 4 deletions(-)
diff --git a/lib/igt_fb.c b/lib/igt_fb.c
index 0eb3897d0f8b..6c379f6d86ba 100644
--- a/lib/igt_fb.c
+++ b/lib/igt_fb.c
@@ -596,15 +596,20 @@ static bool is_gen12_mc_ccs_modifier(uint64_t modifier)
modifier == I915_FORMAT_MOD_4_TILED_MTL_MC_CCS;
}
+static bool is_gen12_rc_ccs_cc_modifier(uint64_t modifier)
+{
+ return modifier == I915_FORMAT_MOD_Y_TILED_GEN12_RC_CCS_CC ||
+ modifier == I915_FORMAT_MOD_4_TILED_DG2_RC_CCS_CC ||
+ modifier == I915_FORMAT_MOD_4_TILED_MTL_RC_CCS_CC;
+}
+
static bool is_gen12_ccs_modifier(uint64_t modifier)
{
return is_gen12_mc_ccs_modifier(modifier) ||
+ is_gen12_rc_ccs_cc_modifier(modifier) ||
modifier == I915_FORMAT_MOD_Y_TILED_GEN12_RC_CCS ||
- modifier == I915_FORMAT_MOD_Y_TILED_GEN12_RC_CCS_CC ||
modifier == I915_FORMAT_MOD_4_TILED_DG2_RC_CCS ||
- modifier == I915_FORMAT_MOD_4_TILED_DG2_RC_CCS_CC ||
- modifier == I915_FORMAT_MOD_4_TILED_MTL_RC_CCS ||
- modifier == I915_FORMAT_MOD_4_TILED_MTL_RC_CCS_CC;
+ modifier == I915_FORMAT_MOD_4_TILED_MTL_RC_CCS;
}
static bool is_ccs_modifier(uint64_t modifier)
--
2.44.2
More information about the igt-dev
mailing list