Tile4 patch still needs an ack from userspace, IGT tests and some essential fixes, related to new .plane_caps attribute being added. This reverts commit 3c542cfa8266e3364938d055b3d548b7bed7f08e.
Unified · Split
| @@ -7769,7 +7769,6 @@ static int intel_atomic_check_async(struct intel_atomic_state *state, struct int · 7768 unmodified lines | |||
| 7769 | case I915_FORMAT_MOD_X_TILED: | 7769 | case I915_FORMAT_MOD_X_TILED: |
| 7770 | case I915_FORMAT_MOD_Y_TILED: | 7770 | case I915_FORMAT_MOD_Y_TILED: |
| 7771 | case I915_FORMAT_MOD_Yf_TILED: | 7771 | case I915_FORMAT_MOD_Yf_TILED: |
| 7772 | case I915_FORMAT_MOD_4_TILED: | ||
| 7773 | break; | 7772 | break; |
| 7774 | default: | 7773 | default: |
| 7775 | drm_dbg_kms(&i915->drm, | 7774 | drm_dbg_kms(&i915->drm, |
| @@ -139,9 +139,6 @@ struct intel_modifier_desc { · 138 unmodified lines | |||
| 139 | 139 | ||
| 140 | static const struct intel_modifier_desc intel_modifiers[] = { | 140 | static const struct intel_modifier_desc intel_modifiers[] = { |
| 141 | { | 141 | { |
| 142 | .modifier = I915_FORMAT_MOD_4_TILED, | ||
| 143 | .display_ver = { 13, 13 }, | ||
| 144 | }, { | ||
| 145 | .modifier = I915_FORMAT_MOD_Y_TILED_GEN12_MC_CCS, | 142 | .modifier = I915_FORMAT_MOD_Y_TILED_GEN12_MC_CCS, |
| 146 | .display_ver = { 12, 13 }, | 143 | .display_ver = { 12, 13 }, |
| 147 | .plane_caps = INTEL_PLANE_CAP_TILING_Y | INTEL_PLANE_CAP_CCS_MC, | 144 | .plane_caps = INTEL_PLANE_CAP_TILING_Y | INTEL_PLANE_CAP_CCS_MC, |
| @@ -547,12 +544,6 @@ intel_tile_width_bytes(const struct drm_framebuffer *fb, int color_plane) · 399 unmodified lines | |||
| 547 | return 128; | 544 | return 128; |
| 548 | else | 545 | else |
| 549 | return 512; | 546 | return 512; |
| 550 | case I915_FORMAT_MOD_4_TILED: | ||
| 551 | /* | ||
| 552 | * Each 4K tile consists of 64B(8*8) subtiles, with | ||
| 553 | * same shape as Y Tile(i.e 4*16B OWords) | ||
| 554 | */ | ||
| 555 | return 128; | ||
| 556 | case I915_FORMAT_MOD_Y_TILED_CCS: | 547 | case I915_FORMAT_MOD_Y_TILED_CCS: |
| 557 | if (intel_fb_is_ccs_aux_plane(fb, color_plane)) | 548 | if (intel_fb_is_ccs_aux_plane(fb, color_plane)) |
| 558 | return 128; | 549 | return 128; |
| @@ -898,7 +898,6 @@ static bool tiling_is_valid(struct drm_i915_private *i915, · 897 unmodified lines | |||
| 898 | case I915_FORMAT_MOD_Y_TILED: | 898 | case I915_FORMAT_MOD_Y_TILED: |
| 899 | case I915_FORMAT_MOD_Yf_TILED: | 899 | case I915_FORMAT_MOD_Yf_TILED: |
| 900 | return DISPLAY_VER(i915) >= 9; | 900 | return DISPLAY_VER(i915) >= 9; |
| 901 | case I915_FORMAT_MOD_4_TILED: | ||
| 902 | case I915_FORMAT_MOD_X_TILED: | 901 | case I915_FORMAT_MOD_X_TILED: |
| 903 | return true; | 902 | return true; |
| 904 | default: | 903 | default: |
| @@ -125,7 +125,6 @@ intel_alloc_initial_plane_obj(struct intel_crtc *crtc, · 124 unmodified lines | |||
| 125 | case DRM_FORMAT_MOD_LINEAR: | 125 | case DRM_FORMAT_MOD_LINEAR: |
| 126 | case I915_FORMAT_MOD_X_TILED: | 126 | case I915_FORMAT_MOD_X_TILED: |
| 127 | case I915_FORMAT_MOD_Y_TILED: | 127 | case I915_FORMAT_MOD_Y_TILED: |
| 128 | case I915_FORMAT_MOD_4_TILED: | ||
| 129 | break; | 128 | break; |
| 130 | default: | 129 | default: |
| 131 | drm_dbg(&dev_priv->drm, | 130 | drm_dbg(&dev_priv->drm, |
| @@ -751,8 +751,6 @@ static u32 skl_plane_ctl_tiling(u64 fb_modifier) · 750 unmodified lines | |||
| 751 | return PLANE_CTL_TILED_X; | 751 | return PLANE_CTL_TILED_X; |
| 752 | case I915_FORMAT_MOD_Y_TILED: | 752 | case I915_FORMAT_MOD_Y_TILED: |
| 753 | return PLANE_CTL_TILED_Y; | 753 | return PLANE_CTL_TILED_Y; |
| 754 | case I915_FORMAT_MOD_4_TILED: | ||
| 755 | return PLANE_CTL_TILED_4; | ||
| 756 | case I915_FORMAT_MOD_Y_TILED_CCS: | 754 | case I915_FORMAT_MOD_Y_TILED_CCS: |
| 757 | case I915_FORMAT_MOD_Y_TILED_GEN12_RC_CCS_CC: | 755 | case I915_FORMAT_MOD_Y_TILED_GEN12_RC_CCS_CC: |
| 758 | return PLANE_CTL_TILED_Y | PLANE_CTL_RENDER_DECOMPRESSION_ENABLE; | 756 | return PLANE_CTL_TILED_Y | PLANE_CTL_RENDER_DECOMPRESSION_ENABLE; |
| @@ -1973,7 +1971,9 @@ static bool gen12_plane_format_mod_supported(struct drm_plane *_plane, · 1214 unmodified lines | |||
| 1973 | case DRM_FORMAT_Y216: | 1971 | case DRM_FORMAT_Y216: |
| 1974 | case DRM_FORMAT_XVYU12_16161616: | 1972 | case DRM_FORMAT_XVYU12_16161616: |
| 1975 | case DRM_FORMAT_XVYU16161616: | 1973 | case DRM_FORMAT_XVYU16161616: |
| 1976 | if (!intel_fb_is_ccs_modifier(modifier)) | 1974 | if (modifier == DRM_FORMAT_MOD_LINEAR || |
| 1975 | modifier == I915_FORMAT_MOD_X_TILED || | ||
| 1976 | modifier == I915_FORMAT_MOD_Y_TILED) | ||
| 1977 | return true; | 1977 | return true; |
| 1978 | fallthrough; | 1978 | fallthrough; |
| 1979 | default: | 1979 | default: |
| @@ -2299,15 +2299,11 @@ skl_get_initial_plane_config(struct intel_crtc *crtc, · 319 unmodified lines | |||
| 2299 | else | 2299 | else |
| 2300 | fb->modifier = I915_FORMAT_MOD_Y_TILED; | 2300 | fb->modifier = I915_FORMAT_MOD_Y_TILED; |
| 2301 | break; | 2301 | break; |
| 2302 | case PLANE_CTL_TILED_YF: /* aka PLANE_CTL_TILED_4 on XE_LPD+ */ | 2302 | case PLANE_CTL_TILED_YF: |
| 2303 | if (HAS_4TILE(dev_priv)) { | 2303 | if (val & PLANE_CTL_RENDER_DECOMPRESSION_ENABLE) |
| 2304 | fb->modifier = I915_FORMAT_MOD_4_TILED; | 2304 | fb->modifier = I915_FORMAT_MOD_Yf_TILED_CCS; |
| 2305 | } else { | 2305 | else |
| 2306 | if (val & PLANE_CTL_RENDER_DECOMPRESSION_ENABLE) | 2306 | fb->modifier = I915_FORMAT_MOD_Yf_TILED; |
| 2307 | fb->modifier = I915_FORMAT_MOD_Yf_TILED_CCS; | ||
| 2308 | else | ||
| 2309 | fb->modifier = I915_FORMAT_MOD_Yf_TILED; | ||
| 2310 | } | ||
| 2311 | break; | 2307 | break; |
| 2312 | default: | 2308 | default: |
| 2313 | MISSING_CASE(tiling); | 2309 | MISSING_CASE(tiling); |
| @@ -1624,7 +1624,6 @@ IS_SUBPLATFORM(const struct drm_i915_private *i915, · 1623 unmodified lines | |||
| 1624 | #define CMDPARSER_USES_GGTT(dev_priv) (GRAPHICS_VER(dev_priv) == 7) | 1624 | #define CMDPARSER_USES_GGTT(dev_priv) (GRAPHICS_VER(dev_priv) == 7) |
| 1625 | 1625 | ||
| 1626 | #define HAS_LLC(dev_priv) (INTEL_INFO(dev_priv)->has_llc) | 1626 | #define HAS_LLC(dev_priv) (INTEL_INFO(dev_priv)->has_llc) |
| 1627 | #define HAS_4TILE(dev_priv) (INTEL_INFO(dev_priv)->has_4tile) | ||
| 1628 | #define HAS_SNOOP(dev_priv) (INTEL_INFO(dev_priv)->has_snoop) | 1627 | #define HAS_SNOOP(dev_priv) (INTEL_INFO(dev_priv)->has_snoop) |
| 1629 | #define HAS_EDRAM(dev_priv) ((dev_priv)->edram_size_mb) | 1628 | #define HAS_EDRAM(dev_priv) ((dev_priv)->edram_size_mb) |
| 1630 | #define HAS_SECURE_BATCHES(dev_priv) (GRAPHICS_VER(dev_priv) < 6) | 1629 | #define HAS_SECURE_BATCHES(dev_priv) (GRAPHICS_VER(dev_priv) < 6) |
| @@ -1044,7 +1044,6 @@ static const struct intel_device_info dg2_info = { · 1043 unmodified lines | |||
| 1044 | DGFX_FEATURES, | 1044 | DGFX_FEATURES, |
| 1045 | .graphics_rel = 55, | 1045 | .graphics_rel = 55, |
| 1046 | .media_rel = 55, | 1046 | .media_rel = 55, |
| 1047 | .has_4tile = 1, | ||
| 1048 | PLATFORM(INTEL_DG2), | 1047 | PLATFORM(INTEL_DG2), |
| 1049 | .platform_engine_mask = | 1048 | .platform_engine_mask = |
| 1050 | BIT(RCS0) | BIT(BCS0) | | 1049 | BIT(RCS0) | BIT(BCS0) | |
| @@ -7210,7 +7210,6 @@ enum { · 7209 unmodified lines | |||
| 7210 | #define PLANE_CTL_TILED_X (1 << 10) | 7210 | #define PLANE_CTL_TILED_X (1 << 10) |
| 7211 | #define PLANE_CTL_TILED_Y (4 << 10) | 7211 | #define PLANE_CTL_TILED_Y (4 << 10) |
| 7212 | #define PLANE_CTL_TILED_YF (5 << 10) | 7212 | #define PLANE_CTL_TILED_YF (5 << 10) |
| 7213 | #define PLANE_CTL_TILED_4 (5 << 10) | ||
| 7214 | #define PLANE_CTL_ASYNC_FLIP (1 << 9) | 7213 | #define PLANE_CTL_ASYNC_FLIP (1 << 9) |
| 7215 | #define PLANE_CTL_FLIP_HORIZONTAL (1 << 8) | 7214 | #define PLANE_CTL_FLIP_HORIZONTAL (1 << 8) |
| 7216 | #define PLANE_CTL_MEDIA_DECOMPRESSION_ENABLE (1 << 4) /* TGL+ */ | 7215 | #define PLANE_CTL_MEDIA_DECOMPRESSION_ENABLE (1 << 4) /* TGL+ */ |
| @@ -125,7 +125,6 @@ enum intel_ppgtt_type { · 124 unmodified lines | |||
| 125 | func(has_64bit_reloc); \ | 125 | func(has_64bit_reloc); \ |
| 126 | func(gpu_reset_clobbers_display); \ | 126 | func(gpu_reset_clobbers_display); \ |
| 127 | func(has_reset_engine); \ | 127 | func(has_reset_engine); \ |
| 128 | func(has_4tile); \ | ||
| 129 | func(has_global_mocs); \ | 128 | func(has_global_mocs); \ |
| 130 | func(has_gt_uc); \ | 129 | func(has_gt_uc); \ |
| 131 | func(has_l3_dpf); \ | 130 | func(has_l3_dpf); \ |
| @@ -5386,7 +5386,6 @@ skl_compute_wm_params(const struct intel_crtc_state *crtc_state, · 5385 unmodified lines | |||
| 5386 | } | 5386 | } |
| 5387 | 5387 | ||
| 5388 | wp->y_tiled = modifier == I915_FORMAT_MOD_Y_TILED || | 5388 | wp->y_tiled = modifier == I915_FORMAT_MOD_Y_TILED || |
| 5389 | modifier == I915_FORMAT_MOD_4_TILED || | ||
| 5390 | modifier == I915_FORMAT_MOD_Yf_TILED || | 5389 | modifier == I915_FORMAT_MOD_Yf_TILED || |
| 5391 | modifier == I915_FORMAT_MOD_Y_TILED_CCS || | 5390 | modifier == I915_FORMAT_MOD_Y_TILED_CCS || |
| 5392 | modifier == I915_FORMAT_MOD_Yf_TILED_CCS; | 5391 | modifier == I915_FORMAT_MOD_Yf_TILED_CCS; |
| @@ -564,14 +564,6 @@ extern "C" { · 563 unmodified lines | |||
| 564 | * pitch is required to be a multiple of 4 tile widths. | 564 | * pitch is required to be a multiple of 4 tile widths. |
| 565 | */ | 565 | */ |
| 566 | #define I915_FORMAT_MOD_Y_TILED_GEN12_RC_CCS_CC fourcc_mod_code(INTEL, 8) | 566 | #define I915_FORMAT_MOD_Y_TILED_GEN12_RC_CCS_CC fourcc_mod_code(INTEL, 8) |
| 567 | /* | ||
| 568 | * Intel F-tiling(aka Tile4) layout | ||
| 569 | * | ||
| 570 | * This is a tiled layout using 4Kb tiles in row-major layout. | ||
| 571 | * Within the tile pixels are laid out in 64 byte units / sub-tiles in OWORD | ||
| 572 | * (16 bytes) chunks column-major.. | ||
| 573 | */ | ||
| 574 | #define I915_FORMAT_MOD_4_TILED fourcc_mod_code(INTEL, 9) | ||
| 575 | 567 | ||
| 576 | /* | 568 | /* |
| 577 | * Tiled, NV12MT, grouped in 64 (pixels) x 32 (lines) -sized macroblocks | 569 | * Tiled, NV12MT, grouped in 64 (pixels) x 32 (lines) -sized macroblocks |