All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drm/i915: Use the correct maximum in skl_compute_plane_wm
@ 2018-01-30 13:54 Maarten Lankhorst
  2018-01-30 14:06 ` Ville Syrjälä
                   ` (3 more replies)
  0 siblings, 4 replies; 8+ messages in thread
From: Maarten Lankhorst @ 2018-01-30 13:54 UTC (permalink / raw)
  To: intel-gfx

According to bspec, result_lines > 31 is only a maximum for latency
level 1 through 7, so correctly apply the check there.

This is required to make NV12 work.

Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
---
 drivers/gpu/drm/i915/intel_pm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/i915/intel_pm.c b/drivers/gpu/drm/i915/intel_pm.c
index 26132fa6ebce..f19a3fc2466e 100644
--- a/drivers/gpu/drm/i915/intel_pm.c
+++ b/drivers/gpu/drm/i915/intel_pm.c
@@ -4805,7 +4805,7 @@ static int skl_compute_plane_wm(const struct drm_i915_private *dev_priv,
 			res_blocks = result_prev->plane_res_b;
 	}
 
-	if (res_blocks >= ddb_allocation || res_lines > 31) {
+	if (res_blocks >= ddb_allocation || (level >= 1 && level <= 7 && res_lines > 31)) {
 		result->plane_en = false;
 
 		/*
-- 
2.15.1

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply related	[flat|nested] 8+ messages in thread

* Re: [PATCH] drm/i915: Use the correct maximum in skl_compute_plane_wm
  2018-01-30 13:54 [PATCH] drm/i915: Use the correct maximum in skl_compute_plane_wm Maarten Lankhorst
@ 2018-01-30 14:06 ` Ville Syrjälä
  2018-01-30 15:05   ` [PATCH] drm/i915: Ignore minimum lines for level 0 " Maarten Lankhorst
  2018-01-30 18:28 ` ✗ Fi.CI.BAT: failure for drm/i915: Use the correct maximum in skl_compute_plane_wm (rev2) Patchwork
                   ` (2 subsequent siblings)
  3 siblings, 1 reply; 8+ messages in thread
From: Ville Syrjälä @ 2018-01-30 14:06 UTC (permalink / raw)
  To: Maarten Lankhorst; +Cc: intel-gfx

On Tue, Jan 30, 2018 at 02:54:11PM +0100, Maarten Lankhorst wrote:
> According to bspec, result_lines > 31 is only a maximum for latency
> level 1 through 7, so correctly apply the check there.

The register still has only 5 bits for the line watermark. However the
spec says "Hardware ignores the lines for the level 0 watermark.", so
I think what we should be doing is just setting the line watermark to
zero for level 0.

> 
> This is required to make NV12 work.
> 
> Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
> ---
>  drivers/gpu/drm/i915/intel_pm.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/i915/intel_pm.c b/drivers/gpu/drm/i915/intel_pm.c
> index 26132fa6ebce..f19a3fc2466e 100644
> --- a/drivers/gpu/drm/i915/intel_pm.c
> +++ b/drivers/gpu/drm/i915/intel_pm.c
> @@ -4805,7 +4805,7 @@ static int skl_compute_plane_wm(const struct drm_i915_private *dev_priv,
>  			res_blocks = result_prev->plane_res_b;
>  	}
>  
> -	if (res_blocks >= ddb_allocation || res_lines > 31) {
> +	if (res_blocks >= ddb_allocation || (level >= 1 && level <= 7 && res_lines > 31)) {
>  		result->plane_en = false;
>  
>  		/*
> -- 
> 2.15.1
> 
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx

-- 
Ville Syrjälä
Intel OTC
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [PATCH] drm/i915: Ignore minimum lines for level 0 in skl_compute_plane_wm
  2018-01-30 14:06 ` Ville Syrjälä
@ 2018-01-30 15:05   ` Maarten Lankhorst
  2018-01-30 15:16     ` Ville Syrjälä
  0 siblings, 1 reply; 8+ messages in thread
From: Maarten Lankhorst @ 2018-01-30 15:05 UTC (permalink / raw)
  To: intel-gfx

According to bspec, result_lines > 31 is only a maximum for latency
level 1 through 7.

For level 0 the number of lines is ignored, so always write 0 there
to prevent overflowing the 5 bits value.

This is required to make NV12 work.

Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
---
 drivers/gpu/drm/i915/intel_pm.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/drivers/gpu/drm/i915/intel_pm.c b/drivers/gpu/drm/i915/intel_pm.c
index 26132fa6ebce..ed0ec0188962 100644
--- a/drivers/gpu/drm/i915/intel_pm.c
+++ b/drivers/gpu/drm/i915/intel_pm.c
@@ -4805,6 +4805,10 @@ static int skl_compute_plane_wm(const struct drm_i915_private *dev_priv,
 			res_blocks = result_prev->plane_res_b;
 	}
 
+	/* The number of lines are ignored for the level 0 watermark. */
+	if (!level)
+		res_lines = 0;
+
 	if (res_blocks >= ddb_allocation || res_lines > 31) {
 		result->plane_en = false;
 
-- 
2.15.1

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply related	[flat|nested] 8+ messages in thread

* Re: [PATCH] drm/i915: Ignore minimum lines for level 0 in skl_compute_plane_wm
  2018-01-30 15:05   ` [PATCH] drm/i915: Ignore minimum lines for level 0 " Maarten Lankhorst
@ 2018-01-30 15:16     ` Ville Syrjälä
  2018-01-31  9:46       ` [(rebase for CI) PATCH] " Maarten Lankhorst
  0 siblings, 1 reply; 8+ messages in thread
From: Ville Syrjälä @ 2018-01-30 15:16 UTC (permalink / raw)
  To: Maarten Lankhorst; +Cc: intel-gfx

On Tue, Jan 30, 2018 at 04:05:20PM +0100, Maarten Lankhorst wrote:
> According to bspec, result_lines > 31 is only a maximum for latency
> level 1 through 7.
> 
> For level 0 the number of lines is ignored, so always write 0 there
> to prevent overflowing the 5 bits value.
> 
> This is required to make NV12 work.
> 
> Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
> Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
> ---
>  drivers/gpu/drm/i915/intel_pm.c | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/drivers/gpu/drm/i915/intel_pm.c b/drivers/gpu/drm/i915/intel_pm.c
> index 26132fa6ebce..ed0ec0188962 100644
> --- a/drivers/gpu/drm/i915/intel_pm.c
> +++ b/drivers/gpu/drm/i915/intel_pm.c
> @@ -4805,6 +4805,10 @@ static int skl_compute_plane_wm(const struct drm_i915_private *dev_priv,
>  			res_blocks = result_prev->plane_res_b;
>  	}
>  
> +	/* The number of lines are ignored for the level 0 watermark. */
> +	if (!level)
> +		res_lines = 0;
> +

Looks like we could just skip computing res_lines entirely.
But this should work too so

Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>a

>  	if (res_blocks >= ddb_allocation || res_lines > 31) {
>  		result->plane_en = false;
>  
> -- 
> 2.15.1

-- 
Ville Syrjälä
Intel OTC
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 8+ messages in thread

* ✗ Fi.CI.BAT: failure for drm/i915: Use the correct maximum in skl_compute_plane_wm (rev2)
  2018-01-30 13:54 [PATCH] drm/i915: Use the correct maximum in skl_compute_plane_wm Maarten Lankhorst
  2018-01-30 14:06 ` Ville Syrjälä
@ 2018-01-30 18:28 ` Patchwork
  2018-01-31 10:20 ` ✓ Fi.CI.BAT: success for drm/i915: Use the correct maximum in skl_compute_plane_wm (rev3) Patchwork
  2018-01-31 13:01 ` ✓ Fi.CI.IGT: " Patchwork
  3 siblings, 0 replies; 8+ messages in thread
From: Patchwork @ 2018-01-30 18:28 UTC (permalink / raw)
  To: Maarten Lankhorst; +Cc: intel-gfx

== Series Details ==

Series: drm/i915: Use the correct maximum in skl_compute_plane_wm (rev2)
URL   : https://patchwork.freedesktop.org/series/37342/
State : failure

== Summary ==

Applying: drm/i915: Ignore minimum lines for level 0 in skl_compute_plane_wm
error: sha1 information is lacking or useless (drivers/gpu/drm/i915/intel_pm.c).
error: could not build fake ancestor
Patch failed at 0001 drm/i915: Ignore minimum lines for level 0 in skl_compute_plane_wm
The copy of the patch that failed is found in: .git/rebase-apply/patch
When you have resolved this problem, run "git am --continue".
If you prefer to skip this patch, run "git am --skip" instead.
To restore the original branch and stop patching, run "git am --abort".

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [(rebase for CI) PATCH] drm/i915: Ignore minimum lines for level 0 in skl_compute_plane_wm
  2018-01-30 15:16     ` Ville Syrjälä
@ 2018-01-31  9:46       ` Maarten Lankhorst
  0 siblings, 0 replies; 8+ messages in thread
From: Maarten Lankhorst @ 2018-01-31  9:46 UTC (permalink / raw)
  To: intel-gfx

According to bspec, result_lines > 31 is only a maximum for latency
level 1 through 7.

For level 0 the number of lines is ignored, so always write 0 there
to prevent overflowing the 5 bits value.

This is required to make NV12 work.

Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
---
 drivers/gpu/drm/i915/intel_pm.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/drivers/gpu/drm/i915/intel_pm.c b/drivers/gpu/drm/i915/intel_pm.c
index 0b92ea1dbd40..e33368c870b1 100644
--- a/drivers/gpu/drm/i915/intel_pm.c
+++ b/drivers/gpu/drm/i915/intel_pm.c
@@ -4554,6 +4554,10 @@ static int skl_compute_plane_wm(const struct drm_i915_private *dev_priv,
 		}
 	}
 
+	/* The number of lines are ignored for the level 0 watermark. */
+	if (!level)
+		res_lines = 0;
+
 	if (res_blocks >= ddb_allocation || res_lines > 31) {
 		*enabled = false;
 
-- 
2.15.1

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply related	[flat|nested] 8+ messages in thread

* ✓ Fi.CI.BAT: success for drm/i915: Use the correct maximum in skl_compute_plane_wm (rev3)
  2018-01-30 13:54 [PATCH] drm/i915: Use the correct maximum in skl_compute_plane_wm Maarten Lankhorst
  2018-01-30 14:06 ` Ville Syrjälä
  2018-01-30 18:28 ` ✗ Fi.CI.BAT: failure for drm/i915: Use the correct maximum in skl_compute_plane_wm (rev2) Patchwork
@ 2018-01-31 10:20 ` Patchwork
  2018-01-31 13:01 ` ✓ Fi.CI.IGT: " Patchwork
  3 siblings, 0 replies; 8+ messages in thread
From: Patchwork @ 2018-01-31 10:20 UTC (permalink / raw)
  To: Maarten Lankhorst; +Cc: intel-gfx

== Series Details ==

Series: drm/i915: Use the correct maximum in skl_compute_plane_wm (rev3)
URL   : https://patchwork.freedesktop.org/series/37342/
State : success

== Summary ==

Series 37342v3 drm/i915: Use the correct maximum in skl_compute_plane_wm
https://patchwork.freedesktop.org/api/1.0/series/37342/revisions/3/mbox/

Test debugfs_test:
        Subgroup read_all_entries:
                dmesg-warn -> DMESG-FAIL (fi-elk-e7500) fdo#103989
                incomplete -> PASS       (fi-snb-2520m) fdo#103713 +1

fdo#103989 https://bugs.freedesktop.org/show_bug.cgi?id=103989
fdo#103713 https://bugs.freedesktop.org/show_bug.cgi?id=103713

fi-bdw-5557u     total:288  pass:267  dwarn:0   dfail:0   fail:0   skip:21  time:426s
fi-bdw-gvtdvm    total:288  pass:264  dwarn:0   dfail:0   fail:0   skip:24  time:427s
fi-blb-e6850     total:288  pass:223  dwarn:1   dfail:0   fail:0   skip:64  time:372s
fi-bsw-n3050     total:288  pass:242  dwarn:0   dfail:0   fail:0   skip:46  time:488s
fi-bwr-2160      total:288  pass:183  dwarn:0   dfail:0   fail:0   skip:105 time:280s
fi-bxt-dsi       total:288  pass:258  dwarn:0   dfail:0   fail:0   skip:30  time:483s
fi-bxt-j4205     total:288  pass:259  dwarn:0   dfail:0   fail:0   skip:29  time:486s
fi-byt-j1900     total:288  pass:253  dwarn:0   dfail:0   fail:0   skip:35  time:465s
fi-byt-n2820     total:288  pass:249  dwarn:0   dfail:0   fail:0   skip:39  time:453s
fi-cfl-s2        total:288  pass:262  dwarn:0   dfail:0   fail:0   skip:26  time:566s
fi-elk-e7500     total:224  pass:168  dwarn:9   dfail:1   fail:0   skip:45 
fi-gdg-551       total:288  pass:180  dwarn:0   dfail:0   fail:0   skip:108 time:279s
fi-glk-1         total:288  pass:260  dwarn:0   dfail:0   fail:0   skip:28  time:510s
fi-hsw-4770      total:288  pass:261  dwarn:0   dfail:0   fail:0   skip:27  time:391s
fi-hsw-4770r     total:288  pass:261  dwarn:0   dfail:0   fail:0   skip:27  time:398s
fi-ilk-650       total:288  pass:228  dwarn:0   dfail:0   fail:0   skip:60  time:411s
fi-ivb-3520m     total:288  pass:259  dwarn:0   dfail:0   fail:0   skip:29  time:461s
fi-ivb-3770      total:288  pass:255  dwarn:0   dfail:0   fail:0   skip:33  time:411s
fi-kbl-7500u     total:288  pass:263  dwarn:1   dfail:0   fail:0   skip:24  time:458s
fi-kbl-7560u     total:288  pass:269  dwarn:0   dfail:0   fail:0   skip:19  time:497s
fi-kbl-7567u     total:288  pass:268  dwarn:0   dfail:0   fail:0   skip:20  time:454s
fi-kbl-r         total:288  pass:261  dwarn:0   dfail:0   fail:0   skip:27  time:499s
fi-pnv-d510      total:288  pass:222  dwarn:1   dfail:0   fail:0   skip:65  time:580s
fi-skl-6260u     total:288  pass:268  dwarn:0   dfail:0   fail:0   skip:20  time:434s
fi-skl-6600u     total:288  pass:261  dwarn:0   dfail:0   fail:0   skip:27  time:508s
fi-skl-6700hq    total:288  pass:262  dwarn:0   dfail:0   fail:0   skip:26  time:527s
fi-skl-6700k2    total:288  pass:264  dwarn:0   dfail:0   fail:0   skip:24  time:484s
fi-skl-6770hq    total:288  pass:268  dwarn:0   dfail:0   fail:0   skip:20  time:486s
fi-skl-guc       total:288  pass:260  dwarn:0   dfail:0   fail:0   skip:28  time:416s
fi-skl-gvtdvm    total:288  pass:265  dwarn:0   dfail:0   fail:0   skip:23  time:429s
fi-snb-2520m     total:245  pass:211  dwarn:0   dfail:0   fail:0   skip:33 
fi-snb-2600      total:288  pass:248  dwarn:0   dfail:0   fail:0   skip:40  time:397s
Blacklisted hosts:
fi-glk-dsi       total:288  pass:258  dwarn:0   dfail:0   fail:0   skip:30  time:469s

7dc5917dc7dddff0c7f2a0361c8698030c6899fc drm-tip: 2018y-01m-31d-09h-37m-52s UTC integration manifest
2292a62dd685 drm/i915: Ignore minimum lines for level 0 in skl_compute_plane_wm

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_7835/issues.html
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 8+ messages in thread

* ✓ Fi.CI.IGT: success for drm/i915: Use the correct maximum in skl_compute_plane_wm (rev3)
  2018-01-30 13:54 [PATCH] drm/i915: Use the correct maximum in skl_compute_plane_wm Maarten Lankhorst
                   ` (2 preceding siblings ...)
  2018-01-31 10:20 ` ✓ Fi.CI.BAT: success for drm/i915: Use the correct maximum in skl_compute_plane_wm (rev3) Patchwork
@ 2018-01-31 13:01 ` Patchwork
  3 siblings, 0 replies; 8+ messages in thread
From: Patchwork @ 2018-01-31 13:01 UTC (permalink / raw)
  To: Maarten Lankhorst; +Cc: intel-gfx

== Series Details ==

Series: drm/i915: Use the correct maximum in skl_compute_plane_wm (rev3)
URL   : https://patchwork.freedesktop.org/series/37342/
State : success

== Summary ==

Test kms_flip:
        Subgroup modeset-vs-vblank-race-interruptible:
                pass       -> FAIL       (shard-snb) fdo#103060
Test gem_eio:
        Subgroup in-flight:
                dmesg-warn -> PASS       (shard-snb) fdo#104058
Test perf:
        Subgroup enable-disable:
                pass       -> FAIL       (shard-apl) fdo#103715
Test kms_pipe_crc_basic:
        Subgroup suspend-read-crc-pipe-b:
                pass       -> SKIP       (shard-snb) fdo#103375

fdo#103060 https://bugs.freedesktop.org/show_bug.cgi?id=103060
fdo#104058 https://bugs.freedesktop.org/show_bug.cgi?id=104058
fdo#103715 https://bugs.freedesktop.org/show_bug.cgi?id=103715
fdo#103375 https://bugs.freedesktop.org/show_bug.cgi?id=103375

shard-apl        total:1401 pass:878  dwarn:1   dfail:0   fail:12  skip:510 time:6184s
shard-hsw        total:2838 pass:1736 dwarn:1   dfail:0   fail:10  skip:1090 time:12019s
shard-snb        total:2838 pass:1328 dwarn:1   dfail:0   fail:11  skip:1498 time:6653s

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_7835/shards.html
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2018-01-31 13:01 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-01-30 13:54 [PATCH] drm/i915: Use the correct maximum in skl_compute_plane_wm Maarten Lankhorst
2018-01-30 14:06 ` Ville Syrjälä
2018-01-30 15:05   ` [PATCH] drm/i915: Ignore minimum lines for level 0 " Maarten Lankhorst
2018-01-30 15:16     ` Ville Syrjälä
2018-01-31  9:46       ` [(rebase for CI) PATCH] " Maarten Lankhorst
2018-01-30 18:28 ` ✗ Fi.CI.BAT: failure for drm/i915: Use the correct maximum in skl_compute_plane_wm (rev2) Patchwork
2018-01-31 10:20 ` ✓ Fi.CI.BAT: success for drm/i915: Use the correct maximum in skl_compute_plane_wm (rev3) Patchwork
2018-01-31 13:01 ` ✓ Fi.CI.IGT: " Patchwork

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.