All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drm/i915/debugfs: Increment return value of gt.next_seqno
@ 2016-11-24  9:47 Chris Wilson
  2016-11-24 10:45 ` ✗ Fi.CI.BAT: warning for " Patchwork
  2016-11-24 12:15 ` [PATCH] " Joonas Lahtinen
  0 siblings, 2 replies; 6+ messages in thread
From: Chris Wilson @ 2016-11-24  9:47 UTC (permalink / raw)
  To: intel-gfx

The i915_next_seqno read value is to be the next seqno used by the
kernel. However, in the conversion to atomics ops for gt.next_seqno, in
commit 28176ef4cfa5 ("drm/i915: Reserve space in the global seqno during
request allocation"), this was changed from a post-increment to a
pre-increment. This increment was missed from the value reported by
debugfs, so in effect it was reporting the current seqno (last
assigned), not the next seqno.

Fixes: 28176ef4cfa5 ("drm/i915: Reserve space in the global seqno during request allocation")
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=81209
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
---
 drivers/gpu/drm/i915/i915_debugfs.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/i915/i915_debugfs.c b/drivers/gpu/drm/i915/i915_debugfs.c
index 4cad5bf116b5..7b0fcd7461ea 100644
--- a/drivers/gpu/drm/i915/i915_debugfs.c
+++ b/drivers/gpu/drm/i915/i915_debugfs.c
@@ -1026,7 +1026,7 @@ i915_next_seqno_get(void *data, u64 *val)
 {
 	struct drm_i915_private *dev_priv = data;
 
-	*val = atomic_read(&dev_priv->gt.global_timeline.next_seqno);
+	*val = 1 + atomic_read(&dev_priv->gt.global_timeline.next_seqno);
 	return 0;
 }
 
-- 
2.10.2

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

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

* ✗ Fi.CI.BAT: warning for drm/i915/debugfs: Increment return value of gt.next_seqno
  2016-11-24  9:47 [PATCH] drm/i915/debugfs: Increment return value of gt.next_seqno Chris Wilson
@ 2016-11-24 10:45 ` Patchwork
  2016-11-24 11:25   ` Saarinen, Jani
  2016-11-24 12:15 ` [PATCH] " Joonas Lahtinen
  1 sibling, 1 reply; 6+ messages in thread
From: Patchwork @ 2016-11-24 10:45 UTC (permalink / raw)
  To: Chris Wilson; +Cc: intel-gfx

== Series Details ==

Series: drm/i915/debugfs: Increment return value of gt.next_seqno
URL   : https://patchwork.freedesktop.org/series/15887/
State : warning

== Summary ==

Series 15887v1 drm/i915/debugfs: Increment return value of gt.next_seqno
https://patchwork.freedesktop.org/api/1.0/series/15887/revisions/1/mbox/

Test kms_force_connector_basic:
        Subgroup force-connector-state:
                pass       -> DMESG-WARN (fi-snb-2520m)
Test kms_pipe_crc_basic:
        Subgroup nonblocking-crc-pipe-a:
                pass       -> DMESG-WARN (fi-ilk-650)

fi-bdw-5557u     total:244  pass:229  dwarn:0   dfail:0   fail:0   skip:15 
fi-bsw-n3050     total:244  pass:204  dwarn:0   dfail:0   fail:0   skip:40 
fi-byt-j1900     total:244  pass:216  dwarn:0   dfail:0   fail:0   skip:28 
fi-byt-n2820     total:244  pass:212  dwarn:0   dfail:0   fail:0   skip:32 
fi-hsw-4770      total:244  pass:224  dwarn:0   dfail:0   fail:0   skip:20 
fi-hsw-4770r     total:244  pass:224  dwarn:0   dfail:0   fail:0   skip:20 
fi-ilk-650       total:244  pass:190  dwarn:1   dfail:0   fail:0   skip:53 
fi-ivb-3520m     total:244  pass:222  dwarn:0   dfail:0   fail:0   skip:22 
fi-ivb-3770      total:244  pass:222  dwarn:0   dfail:0   fail:0   skip:22 
fi-kbl-7200u     total:244  pass:222  dwarn:0   dfail:0   fail:0   skip:22 
fi-skl-6260u     total:244  pass:230  dwarn:0   dfail:0   fail:0   skip:14 
fi-skl-6700hq    total:244  pass:223  dwarn:0   dfail:0   fail:0   skip:21 
fi-skl-6700k     total:244  pass:222  dwarn:1   dfail:0   fail:0   skip:21 
fi-skl-6770hq    total:244  pass:230  dwarn:0   dfail:0   fail:0   skip:14 
fi-snb-2520m     total:244  pass:211  dwarn:1   dfail:0   fail:0   skip:32 
fi-snb-2600      total:244  pass:211  dwarn:0   dfail:0   fail:0   skip:33 

2154a854b8c9f732ef446a5c99cb24b8d97347f7 drm-intel-nightly: 2016y-11m-24d-07h-21m-33s UTC integration manifest
43dccf2 drm/i915/debugfs: Increment return value of gt.next_seqno

== Logs ==

For more details see: https://intel-gfx-ci.01.org/CI/Patchwork_3104/
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

* Re: ✗ Fi.CI.BAT: warning for drm/i915/debugfs: Increment return value of gt.next_seqno
  2016-11-24 10:45 ` ✗ Fi.CI.BAT: warning for " Patchwork
@ 2016-11-24 11:25   ` Saarinen, Jani
  0 siblings, 0 replies; 6+ messages in thread
From: Saarinen, Jani @ 2016-11-24 11:25 UTC (permalink / raw)
  To: intel-gfx, Chris Wilson

> == Series Details ==
> 
> Series: drm/i915/debugfs: Increment return value of gt.next_seqno
> URL   : https://patchwork.freedesktop.org/series/15887/
> State : warning
> 
> == Summary ==
> 
> Series 15887v1 drm/i915/debugfs: Increment return value of
> gt.next_seqno
> https://patchwork.freedesktop.org/api/1.0/series/15887/revisions/1/mbo
> x/
> 
> Test kms_force_connector_basic:
>         Subgroup force-connector-state:
>                 pass       -> DMESG-WARN (fi-snb-2520m)
*ERROR* EDID checksum is invalid, remainder is 204 =>
https://bugs.freedesktop.org/show_bug.cgi?id=98625

> Test kms_pipe_crc_basic:
>         Subgroup nonblocking-crc-pipe-a:
>                 pass       -> DMESG-WARN (fi-ilk-650)
https://bugs.freedesktop.org/show_bug.cgi?id=98251 but now on pipe-a.

> 
> fi-bdw-5557u     total:244  pass:229  dwarn:0   dfail:0   fail:0   skip:15
> fi-bsw-n3050     total:244  pass:204  dwarn:0   dfail:0   fail:0   skip:40
> fi-byt-j1900     total:244  pass:216  dwarn:0   dfail:0   fail:0   skip:28
> fi-byt-n2820     total:244  pass:212  dwarn:0   dfail:0   fail:0   skip:32
> fi-hsw-4770      total:244  pass:224  dwarn:0   dfail:0   fail:0   skip:20
> fi-hsw-4770r     total:244  pass:224  dwarn:0   dfail:0   fail:0   skip:20
> fi-ilk-650       total:244  pass:190  dwarn:1   dfail:0   fail:0   skip:53
> fi-ivb-3520m     total:244  pass:222  dwarn:0   dfail:0   fail:0   skip:22
> fi-ivb-3770      total:244  pass:222  dwarn:0   dfail:0   fail:0   skip:22
> fi-kbl-7200u     total:244  pass:222  dwarn:0   dfail:0   fail:0   skip:22
> fi-skl-6260u     total:244  pass:230  dwarn:0   dfail:0   fail:0   skip:14
> fi-skl-6700hq    total:244  pass:223  dwarn:0   dfail:0   fail:0   skip:21
> fi-skl-6700k     total:244  pass:222  dwarn:1   dfail:0   fail:0   skip:21
> fi-skl-6770hq    total:244  pass:230  dwarn:0   dfail:0   fail:0   skip:14
> fi-snb-2520m     total:244  pass:211  dwarn:1   dfail:0   fail:0   skip:32
> fi-snb-2600      total:244  pass:211  dwarn:0   dfail:0   fail:0   skip:33
> 
> 2154a854b8c9f732ef446a5c99cb24b8d97347f7 drm-intel-nightly: 2016y-
> 11m-24d-07h-21m-33s UTC integration manifest
> 43dccf2 drm/i915/debugfs: Increment return value of gt.next_seqno
> 
> == Logs ==
> 
> For more details see: https://intel-gfx-ci.01.org/CI/Patchwork_3104/


Jani Saarinen
Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo


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

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

* Re: [PATCH] drm/i915/debugfs: Increment return value of gt.next_seqno
  2016-11-24  9:47 [PATCH] drm/i915/debugfs: Increment return value of gt.next_seqno Chris Wilson
  2016-11-24 10:45 ` ✗ Fi.CI.BAT: warning for " Patchwork
@ 2016-11-24 12:15 ` Joonas Lahtinen
  2016-11-24 12:26   ` Chris Wilson
  2016-11-24 12:49   ` Chris Wilson
  1 sibling, 2 replies; 6+ messages in thread
From: Joonas Lahtinen @ 2016-11-24 12:15 UTC (permalink / raw)
  To: Chris Wilson, intel-gfx

On to, 2016-11-24 at 09:47 +0000, Chris Wilson wrote:
> The i915_next_seqno read value is to be the next seqno used by the
> kernel. However, in the conversion to atomics ops for gt.next_seqno, in
> commit 28176ef4cfa5 ("drm/i915: Reserve space in the global seqno during
> request allocation"), this was changed from a post-increment to a
> pre-increment. This increment was missed from the value reported by
> debugfs, so in effect it was reporting the current seqno (last
> assigned), not the next seqno.
> 
> Fixes: 28176ef4cfa5 ("drm/i915: Reserve space in the global seqno during request allocation")
> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=81209
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>

<SNIP>

> @@ -1026,7 +1026,7 @@ i915_next_seqno_get(void *data, u64 *val)
>  {
>  	struct drm_i915_private *dev_priv = data;
>  
> -	*val = atomic_read(&dev_priv->gt.global_timeline.next_seqno);
> +	*val = 1 + atomic_read(&dev_priv->gt.global_timeline.next_seqno);

The variable name really should be last_seqno or so...

But as a hotfix;

Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>

Regards, joonas
-- 
Joonas Lahtinen
Open Source Technology Center
Intel Corporation
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

* Re: [PATCH] drm/i915/debugfs: Increment return value of gt.next_seqno
  2016-11-24 12:15 ` [PATCH] " Joonas Lahtinen
@ 2016-11-24 12:26   ` Chris Wilson
  2016-11-24 12:49   ` Chris Wilson
  1 sibling, 0 replies; 6+ messages in thread
From: Chris Wilson @ 2016-11-24 12:26 UTC (permalink / raw)
  To: Joonas Lahtinen; +Cc: intel-gfx

On Thu, Nov 24, 2016 at 02:15:07PM +0200, Joonas Lahtinen wrote:
> On to, 2016-11-24 at 09:47 +0000, Chris Wilson wrote:
> > The i915_next_seqno read value is to be the next seqno used by the
> > kernel. However, in the conversion to atomics ops for gt.next_seqno, in
> > commit 28176ef4cfa5 ("drm/i915: Reserve space in the global seqno during
> > request allocation"), this was changed from a post-increment to a
> > pre-increment. This increment was missed from the value reported by
> > debugfs, so in effect it was reporting the current seqno (last
> > assigned), not the next seqno.
> > 
> > Fixes: 28176ef4cfa5 ("drm/i915: Reserve space in the global seqno during request allocation")
> > Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=81209
> > Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> > Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
> 
> <SNIP>
> 
> > @@ -1026,7 +1026,7 @@ i915_next_seqno_get(void *data, u64 *val)
> >  {
> >  	struct drm_i915_private *dev_priv = data;
> >  
> > -	*val = atomic_read(&dev_priv->gt.global_timeline.next_seqno);
> > +	*val = 1 + atomic_read(&dev_priv->gt.global_timeline.next_seqno);
> 
> The variable name really should be last_seqno or so...

I'd sign off on a s/timeline.next_seqno/timeline.seqno/.
-Chris

-- 
Chris Wilson, Intel Open Source Technology Centre
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

* Re: [PATCH] drm/i915/debugfs: Increment return value of gt.next_seqno
  2016-11-24 12:15 ` [PATCH] " Joonas Lahtinen
  2016-11-24 12:26   ` Chris Wilson
@ 2016-11-24 12:49   ` Chris Wilson
  1 sibling, 0 replies; 6+ messages in thread
From: Chris Wilson @ 2016-11-24 12:49 UTC (permalink / raw)
  To: Joonas Lahtinen; +Cc: intel-gfx

On Thu, Nov 24, 2016 at 02:15:07PM +0200, Joonas Lahtinen wrote:
> On to, 2016-11-24 at 09:47 +0000, Chris Wilson wrote:
> > The i915_next_seqno read value is to be the next seqno used by the
> > kernel. However, in the conversion to atomics ops for gt.next_seqno, in
> > commit 28176ef4cfa5 ("drm/i915: Reserve space in the global seqno during
> > request allocation"), this was changed from a post-increment to a
> > pre-increment. This increment was missed from the value reported by
> > debugfs, so in effect it was reporting the current seqno (last
> > assigned), not the next seqno.
> > 
> > Fixes: 28176ef4cfa5 ("drm/i915: Reserve space in the global seqno during request allocation")
> > Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=81209
> > Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> > Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
> 
> <SNIP>
> 
> > @@ -1026,7 +1026,7 @@ i915_next_seqno_get(void *data, u64 *val)
> >  {
> >  	struct drm_i915_private *dev_priv = data;
> >  
> > -	*val = atomic_read(&dev_priv->gt.global_timeline.next_seqno);
> > +	*val = 1 + atomic_read(&dev_priv->gt.global_timeline.next_seqno);
> 
> The variable name really should be last_seqno or so...
> 
> But as a hotfix;
> 
> Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>

Thanks, pushed and another (albeit recent) bug closed.
-Chris

-- 
Chris Wilson, Intel Open Source Technology Centre
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

end of thread, other threads:[~2016-11-24 12:49 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-11-24  9:47 [PATCH] drm/i915/debugfs: Increment return value of gt.next_seqno Chris Wilson
2016-11-24 10:45 ` ✗ Fi.CI.BAT: warning for " Patchwork
2016-11-24 11:25   ` Saarinen, Jani
2016-11-24 12:15 ` [PATCH] " Joonas Lahtinen
2016-11-24 12:26   ` Chris Wilson
2016-11-24 12:49   ` Chris Wilson

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.