Skip to contentSkip to conversation

drm/i915/icl: Avoid Gen10 watermark workarounds in Gen11

PATCH Superseded Karthik B S 3 participants 6 messages Aug 23, 2018 – Sep 4, 2018

Subsystems (2)

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drm/i915/icl: Avoid Gen10 watermark workarounds in Gen11

Check added to skip the watermark workarounds intended for Gen10 and below platforms in Gen11.

---
 drivers/gpu/drm/i915/intel_pm.c | 39 +++++++++++++++++++++++----------------
 1 file changed, 23 insertions(+), 16 deletions(-)
drivers/gpu/drm/i915/intel_pm.c +23 -16
index d99e5fa..1928fe0 100644
@@ -4677,28 +4677,35 @@ static int skl_compute_plane_wm(const struct drm_i915_private *dev_priv,
 	res_lines = div_round_up_fixed16(selected_result,
 					 wp->plane_blocks_per_line);
 
-	/* Display WA #1125: skl,bxt,kbl,glk */
-	if (level == 0 && wp->rc_surface)
-		res_blocks += fixed16_to_u32_round_up(wp->y_tile_minimum);
-
-	/* Display WA #1126: skl,bxt,kbl,glk */
-	if (level >= 1 && level <= 7) {
-		if (wp->y_tiled) {
+	if (INTEL_GEN(dev_priv) < 11) {
+		/* Display WA #1125: skl,bxt,kbl,glk */
+		if (level == 0 && wp->rc_surface)
 			res_blocks += fixed16_to_u32_round_up(
 							wp->y_tile_minimum);
-			res_lines += wp->y_min_scanlines;
-		} else {
-			res_blocks++;
+
+		/* Display WA #1126: skl,bxt,kbl,glk */
+		if (level >= 1 && level <= 7) {
+			if (wp->y_tiled) {
+				res_blocks += fixed16_to_u32_round_up(
+							wp->y_tile_minimum);
+				res_lines += wp->y_min_scanlines;
+			} else {
+				res_blocks++;
+			}
 		}
+	}
 
-		/*
-		 * Make sure result blocks for higher latency levels are atleast
-		 * as high as level below the current level.
-		 * Assumption in DDB algorithm optimization for special cases.
-		 * Also covers Display WA #1125 for RC.
-		 */
+	/*
+	 * Make sure result blocks for higher latency levels are atleast
+	 * as high as level below the current level.
+	 * Assumption in DDB algorithm optimization for special cases.
+	 * Also covers Display WA #1125 for RC.
+	 */
+	if (level >= 1 && level <= 7) {
 		if (result_prev->plane_res_b > res_blocks)
 			res_blocks = result_prev->plane_res_b;
+		if (result_prev->plane_res_l > res_lines)
+			res_lines = result_prev->plane_res_l;
 	}
 
 	if (INTEL_GEN(dev_priv) >= 11) {
Signature · 6 lines
2.7.4

_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
#1 lore raw

✗ Fi.CI.CHECKPATCH: warning for drm/i915/icl: Avoid Gen10 watermark workarounds in Gen11

== Series Details ==

== Series Details ==

Series: drm/i915/icl: Avoid Gen10 watermark workarounds in Gen11
URL : https://patchwork.freedesktop.org/series/48601/
State : warning

== Summary ==

$ dim checkpatch origin/drm-tip
578f56edabd2 drm/i915/icl: Avoid Gen10 watermark workarounds in Gen11
-:38: CHECK:OPEN_ENDED_LINE: Lines should not end with a '('
#38: FILE: drivers/gpu/drm/i915/intel_pm.c:4689:
+				res_blocks += fixed16_to_u32_round_up(

total: 0 errors, 0 warnings, 1 checks, 51 lines checked

_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

#2 lore raw

✓ Fi.CI.BAT: success for drm/i915/icl: Avoid Gen10 watermark workarounds in Gen11

In reply to Karthik B S
== Series Details ==

== Series Details ==

Series: drm/i915/icl: Avoid Gen10 watermark workarounds in Gen11
URL : https://patchwork.freedesktop.org/series/48601/
State : success

== Summary ==

= CI Bug Log - changes from CI_DRM_4700 -> Patchwork_9999 =

== Summary - SUCCESS ==

No regressions found.

External URL: https://patchwork.freedesktop.org/api/1.0/series/48601/revisions/1/mbox/

== Known issues ==

Here are the changes found in Patchwork_9999 that come from known issues:

=== IGT changes ===

    ==== Issues hit ====

    igt@drv_selftest@live_hangcheck:
      fi-cfl-s3:          PASS -> DMESG-FAIL (fdo#106560)

    
    ==== Possible fixes ====

    igt@kms_pipe_crc_basic@hang-read-crc-pipe-b:
      {fi-byt-clapper}:   FAIL (fdo#103191, fdo#107362) -> PASS

    
    ==== Warnings ====

    {igt@pm_rpm@module-reload}:
      fi-cnl-psr:         FAIL -> WARN (fdo#107602)

{name}: This element is suppressed. This means it is ignored when computing
the status of the difference (SUCCESS, WARNING, or FAILURE).

fdo#103191 https://bugs.freedesktop.org/show_bug.cgi?id=103191
fdo#106560 https://bugs.freedesktop.org/show_bug.cgi?id=106560
fdo#107362 https://bugs.freedesktop.org/show_bug.cgi?id=107362
fdo#107602 https://bugs.freedesktop.org/show_bug.cgi?id=107602

== Participating hosts (53 -> 47) ==

Missing (6): fi-ilk-m540 fi-hsw-4200u fi-skl-guc fi-byt-squawks fi-bsw-cyan fi-ctg-p8600

== Build changes ==

* Linux: CI_DRM_4700 -> Patchwork_9999

CI_DRM_4700: b7d51b8e106cf75ee061244eff6281a9867e3651 @ git://anongit.freedesktop.org/gfx-ci/linux
IGT_4608: 94ebd21177feedf03e8f6dd1e73dca1a6ec7a0ac @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools
Patchwork_9999: 578f56edabd27b85425f5533fe2ec1c0589108be @ git://anongit.freedesktop.org/gfx-ci/linux

== Linux commits ==

578f56edabd2 drm/i915/icl: Avoid Gen10 watermark workarounds in Gen11

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_9999/issues.html
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

#3 lore raw

✓ Fi.CI.IGT: success for drm/i915/icl: Avoid Gen10 watermark workarounds in Gen11

In reply to Karthik B S
== Series Details ==

== Series Details ==

Series: drm/i915/icl: Avoid Gen10 watermark workarounds in Gen11
URL : https://patchwork.freedesktop.org/series/48601/
State : success

== Summary ==

= CI Bug Log - changes from CI_DRM_4700_full -> Patchwork_9999_full =

== Summary - SUCCESS ==

No regressions found.

== Known issues ==

Here are the changes found in Patchwork_9999_full that come from known issues:

=== IGT changes ===

    ==== Issues hit ====

    igt@gem_exec_await@wide-contexts:
      shard-glk:          PASS -> FAIL (fdo#105900)

    igt@kms_flip@2x-flip-vs-expired-vblank-interruptible:
      shard-glk:          PASS -> FAIL (fdo#105363)

    igt@kms_flip@dpms-vs-vblank-race:
      shard-glk:          PASS -> FAIL (fdo#103060)

    
    ==== Possible fixes ====

    igt@kms_flip@modeset-vs-vblank-race:
      shard-snb:          FAIL (fdo#103060) -> PASS

fdo#103060 https://bugs.freedesktop.org/show_bug.cgi?id=103060
fdo#105363 https://bugs.freedesktop.org/show_bug.cgi?id=105363
fdo#105900 https://bugs.freedesktop.org/show_bug.cgi?id=105900

== Participating hosts (5 -> 5) ==

No changes in participating hosts

== Build changes ==

* Linux: CI_DRM_4700 -> Patchwork_9999

CI_DRM_4700: b7d51b8e106cf75ee061244eff6281a9867e3651 @ git://anongit.freedesktop.org/gfx-ci/linux
IGT_4608: 94ebd21177feedf03e8f6dd1e73dca1a6ec7a0ac @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools
Patchwork_9999: 578f56edabd27b85425f5533fe2ec1c0589108be @ git://anongit.freedesktop.org/gfx-ci/linux
piglit_4509: fdc5a4ca11124ab8413c7988896eec4c97336694 @ git://anongit.freedesktop.org/piglit

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_9999/shards.html
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

maintainer
#4 lore raw
In reply to Karthik B S
Quoted 2 lines · Karthik B S

Check added to skip the watermark workarounds intended for Gen10 and below platforms in Gen11.

This seems a bit ambiguous for me, could you please improve the commit message a bit?

Quoted 47 lines
---
 drivers/gpu/drm/i915/intel_pm.c | 39 +++++++++++++++++++++++----------------
 1 file changed, 23 insertions(+), 16 deletions(-)
drivers/gpu/drm/i915/intel_pm.c +14 -15
index d99e5fa..1928fe0 100644
@@ -4677,28 +4677,35 @@ static int skl_compute_plane_wm(const struct drm_i915_private *dev_priv,
 	res_lines = div_round_up_fixed16(selected_result,
 					 wp->plane_blocks_per_line);
 
-	/* Display WA #1125: skl,bxt,kbl,glk */
-	if (level == 0 && wp->rc_surface)
-		res_blocks += fixed16_to_u32_round_up(wp->y_tile_minimum);
-
-	/* Display WA #1126: skl,bxt,kbl,glk */
-	if (level >= 1 && level <= 7) {
-		if (wp->y_tiled) {
+	if (INTEL_GEN(dev_priv) < 11) {
+		/* Display WA #1125: skl,bxt,kbl,glk */
+		if (level == 0 && wp->rc_surface)
 			res_blocks += fixed16_to_u32_round_up(
 							wp->y_tile_minimum);
-			res_lines += wp->y_min_scanlines;
-		} else {
-			res_blocks++;
+
+		/* Display WA #1126: skl,bxt,kbl,glk */
+		if (level >= 1 && level <= 7) {
+			if (wp->y_tiled) {
+				res_blocks += fixed16_to_u32_round_up(
+							wp->y_tile_minimum);
+				res_lines += wp->y_min_scanlines;
+			} else {
+				res_blocks++;
+			}
 		}
+	}
 
-		/*
-		 * Make sure result blocks for higher latency levels are atleast
-		 * as high as level below the current level.
-		 * Assumption in DDB algorithm optimization for special cases.
-		 * Also covers Display WA #1125 for RC.

drivers/gpu/drm/i915/intel_pm.c static int skl_compute_plane_wm(const struct drm_i915_private *dev_priv, · line 4706

Quoted 10 lines
drivers/gpu/drm/i915/intel_pm.c +7 -1
-		 */
+	/*
+	 * Make sure result blocks for higher latency levels are atleast
+	 * as high as level below the current level.
+	 * Assumption in DDB algorithm optimization for special cases.
+	 * Also covers Display WA #1125 for RC.
+	 */
+	if (level >= 1 && level <= 7) {
 		if (result_prev->plane_res_b > res_blocks)
 			res_blocks = result_prev->plane_res_b;

Everything above makes sense and I checked against spec and it is right.

drivers/gpu/drm/i915/intel_pm.c static int skl_compute_plane_wm(const struct drm_i915_private *dev_priv, · line 4708

Quoted 2 lines
drivers/gpu/drm/i915/intel_pm.c +2 -0
+		if (result_prev->plane_res_l > res_lines)
+			res_lines = result_prev->plane_res_l;

My on;y concern here is with this line...
This seems a new addition that if needed needs to come in a separated patch with its own justification.

Sorry for taking so long to review it.

Thanks,
Rodrigo.

Quoted 10 lines
drivers/gpu/drm/i915/intel_pm.c +0 -0
 	}
 
 	if (INTEL_GEN(dev_priv) >= 11) {
Signature · 6 lines
2.7.4

_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

#5 lore raw
Quoted 5 lines · Rodrigo Vivi
Quoted 2 lines · Karthik B S

Check added to skip the watermark workarounds intended for Gen10 and below platforms in Gen11.

This seems a bit ambiguous for me, could you please improve the commit message a bit?

Sure. I'll do it.

Quoted 59 lines
Quoted 47 lines
---
  drivers/gpu/drm/i915/intel_pm.c | 39 +++++++++++++++++++++++----------------
  1 file changed, 23 insertions(+), 16 deletions(-)
drivers/gpu/drm/i915/intel_pm.c +14 -15
index d99e5fa..1928fe0 100644
@@ -4677,28 +4677,35 @@ static int skl_compute_plane_wm(const struct drm_i915_private *dev_priv,
  	res_lines = div_round_up_fixed16(selected_result,
  					 wp->plane_blocks_per_line);
 
-	/* Display WA #1125: skl,bxt,kbl,glk */
-	if (level == 0 && wp->rc_surface)
-		res_blocks += fixed16_to_u32_round_up(wp->y_tile_minimum);
-
-	/* Display WA #1126: skl,bxt,kbl,glk */
-	if (level >= 1 && level <= 7) {
-		if (wp->y_tiled) {
+	if (INTEL_GEN(dev_priv) < 11) {
+		/* Display WA #1125: skl,bxt,kbl,glk */
+		if (level == 0 && wp->rc_surface)
  			res_blocks += fixed16_to_u32_round_up(
  							wp->y_tile_minimum);
-			res_lines += wp->y_min_scanlines;
-		} else {
-			res_blocks++;
+
+		/* Display WA #1126: skl,bxt,kbl,glk */
+		if (level >= 1 && level <= 7) {
+			if (wp->y_tiled) {
+				res_blocks += fixed16_to_u32_round_up(
+							wp->y_tile_minimum);
+				res_lines += wp->y_min_scanlines;
+			} else {
+				res_blocks++;
+			}
  		}
+	}
 
-		/*
-		 * Make sure result blocks for higher latency levels are atleast
-		 * as high as level below the current level.
-		 * Assumption in DDB algorithm optimization for special cases.
-		 * Also covers Display WA #1125 for RC.

drivers/gpu/drm/i915/intel_pm.c static int skl_compute_plane_wm(const struct drm_i915_private *dev_priv, · line 4706

Quoted 10 lines
drivers/gpu/drm/i915/intel_pm.c +7 -1
-		 */
+	/*
+	 * Make sure result blocks for higher latency levels are atleast
+	 * as high as level below the current level.
+	 * Assumption in DDB algorithm optimization for special cases.
+	 * Also covers Display WA #1125 for RC.
+	 */
+	if (level >= 1 && level <= 7) {
  		if (result_prev->plane_res_b > res_blocks)
  			res_blocks = result_prev->plane_res_b;

Everything above makes sense and I checked against spec and it is right.

Quoted 5 lines

drivers/gpu/drm/i915/intel_pm.c static int skl_compute_plane_wm(const struct drm_i915_private *dev_priv, · line 4708

Quoted 2 lines
drivers/gpu/drm/i915/intel_pm.c +2 -0
+		if (result_prev->plane_res_l > res_lines)
+			res_lines = result_prev->plane_res_l;

My on;y concern here is with this line...
This seems a new addition that if needed needs to come in a separated patch with its own justification.

Sure. I will make a separate patch for the same.

Quoted 16 lines

Sorry for taking so long to review it.

Thanks,
Rodrigo.

Quoted 10 lines
drivers/gpu/drm/i915/intel_pm.c +0 -0
  	}
 
  	if (INTEL_GEN(dev_priv) >= 11) {
Signature · 6 lines
2.7.4

_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx