All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drm/i915: Hold irq uncore.lock when initialising fw_domains
@ 2016-07-03 17:29 Chris Wilson
  2016-07-04  5:26 ` ✓ Ro.CI.BAT: success for " Patchwork
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Chris Wilson @ 2016-07-03 17:29 UTC (permalink / raw)
  To: intel-gfx; +Cc: Mika Kuoppala

Acquiring the forcewake domain asserts that it is in an atomic section
(as we always expect to under the uncore.lock). This true expect for
initialising the domains on Ivybridge, and so we generate a warning.
Wrap the manual usage of fw_domains inside the spin_lock.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Cc: Mika Kuoppala <mika.kuoppala@intel.com>
---
 drivers/gpu/drm/i915/intel_uncore.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/gpu/drm/i915/intel_uncore.c b/drivers/gpu/drm/i915/intel_uncore.c
index 7da3906badf3..1d65209c0998 100644
--- a/drivers/gpu/drm/i915/intel_uncore.c
+++ b/drivers/gpu/drm/i915/intel_uncore.c
@@ -1299,9 +1299,11 @@ static void intel_uncore_fw_domains_init(struct drm_i915_private *dev_priv)
 		fw_domain_init(dev_priv, FW_DOMAIN_ID_RENDER,
 			       FORCEWAKE_MT, FORCEWAKE_MT_ACK);
 
+		spin_lock_irq(&dev_priv->uncore.lock);
 		fw_domains_get_with_thread_status(dev_priv, FORCEWAKE_ALL);
 		ecobus = __raw_i915_read32(dev_priv, ECOBUS);
 		fw_domains_put_with_fifo(dev_priv, FORCEWAKE_ALL);
+		spin_unlock_irq(&dev_priv->uncore.lock);
 
 		if (!(ecobus & FORCEWAKE_MT_ENABLE)) {
 			DRM_INFO("No MT forcewake available on Ivybridge, this can result in issues\n");
-- 
2.8.1

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

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

* ✓ Ro.CI.BAT: success for drm/i915: Hold irq uncore.lock when initialising fw_domains
  2016-07-03 17:29 [PATCH] drm/i915: Hold irq uncore.lock when initialising fw_domains Chris Wilson
@ 2016-07-04  5:26 ` Patchwork
  2016-07-04  9:06 ` [PATCH] " Tvrtko Ursulin
  2016-07-04  9:37 ` Mika Kuoppala
  2 siblings, 0 replies; 5+ messages in thread
From: Patchwork @ 2016-07-04  5:26 UTC (permalink / raw)
  To: Chris Wilson; +Cc: intel-gfx

== Series Details ==

Series: drm/i915: Hold irq uncore.lock when initialising fw_domains
URL   : https://patchwork.freedesktop.org/series/9432/
State : success

== Summary ==

Series 9432v1 drm/i915: Hold irq uncore.lock when initialising fw_domains
http://patchwork.freedesktop.org/api/1.0/series/9432/revisions/1/mbox

Test gem_exec_flush:
        Subgroup basic-batch-kernel-default-cmd:
                fail       -> PASS       (ro-byt-n2820)
        Subgroup basic-batch-kernel-default-uc:
                dmesg-fail -> PASS       (fi-skl-i5-6260u)
Test kms_pipe_crc_basic:
        Subgroup hang-read-crc-pipe-a:
                skip       -> PASS       (fi-skl-i5-6260u)

fi-kbl-qkkr      total:231  pass:160  dwarn:29  dfail:0   fail:2   skip:40 
fi-skl-i5-6260u  total:231  pass:204  dwarn:0   dfail:2   fail:0   skip:25 
fi-skl-i7-6700k  total:231  pass:190  dwarn:0   dfail:2   fail:0   skip:39 
fi-snb-i7-2600   total:231  pass:176  dwarn:0   dfail:0   fail:2   skip:53 
ro-bdw-i5-5250u  total:229  pass:204  dwarn:1   dfail:1   fail:0   skip:23 
ro-bdw-i7-5600u  total:229  pass:190  dwarn:0   dfail:1   fail:0   skip:38 
ro-bsw-n3050     total:229  pass:177  dwarn:0   dfail:1   fail:2   skip:49 
ro-byt-n2820     total:229  pass:181  dwarn:0   dfail:1   fail:2   skip:45 
ro-hsw-i3-4010u  total:229  pass:197  dwarn:0   dfail:1   fail:0   skip:31 
ro-hsw-i7-4770r  total:229  pass:197  dwarn:0   dfail:1   fail:0   skip:31 
ro-ilk-i7-620lm  total:229  pass:157  dwarn:0   dfail:1   fail:1   skip:70 
ro-ilk1-i5-650   total:224  pass:157  dwarn:0   dfail:1   fail:1   skip:65 
ro-ivb-i7-3770   total:229  pass:188  dwarn:0   dfail:1   fail:0   skip:40 
ro-skl3-i5-6260u total:229  pass:208  dwarn:1   dfail:1   fail:0   skip:19 
ro-snb-i7-2620M  total:229  pass:179  dwarn:0   dfail:1   fail:1   skip:48 
ro-bdw-i7-5557U failed to connect after reboot

Results at /archive/results/CI_IGT_test/RO_Patchwork_1389/

2fe5da8 drm-intel-nightly: 2016y-07m-02d-18h-31m-39s UTC integration manifest
f1e8235 drm/i915: Hold irq uncore.lock when initialising fw_domains

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

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

* Re: [PATCH] drm/i915: Hold irq uncore.lock when initialising fw_domains
  2016-07-03 17:29 [PATCH] drm/i915: Hold irq uncore.lock when initialising fw_domains Chris Wilson
  2016-07-04  5:26 ` ✓ Ro.CI.BAT: success for " Patchwork
@ 2016-07-04  9:06 ` Tvrtko Ursulin
  2016-07-04  9:29   ` Chris Wilson
  2016-07-04  9:37 ` Mika Kuoppala
  2 siblings, 1 reply; 5+ messages in thread
From: Tvrtko Ursulin @ 2016-07-04  9:06 UTC (permalink / raw)
  To: Chris Wilson, intel-gfx; +Cc: Mika Kuoppala


On 03/07/16 18:29, Chris Wilson wrote:
> Acquiring the forcewake domain asserts that it is in an atomic section
> (as we always expect to under the uncore.lock). This true expect for
> initialising the domains on Ivybridge, and so we generate a warning.
> Wrap the manual usage of fw_domains inside the spin_lock.
>
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> Cc: Mika Kuoppala <mika.kuoppala@intel.com>
> ---
>   drivers/gpu/drm/i915/intel_uncore.c | 2 ++
>   1 file changed, 2 insertions(+)
>
> diff --git a/drivers/gpu/drm/i915/intel_uncore.c b/drivers/gpu/drm/i915/intel_uncore.c
> index 7da3906badf3..1d65209c0998 100644
> --- a/drivers/gpu/drm/i915/intel_uncore.c
> +++ b/drivers/gpu/drm/i915/intel_uncore.c
> @@ -1299,9 +1299,11 @@ static void intel_uncore_fw_domains_init(struct drm_i915_private *dev_priv)
>   		fw_domain_init(dev_priv, FW_DOMAIN_ID_RENDER,
>   			       FORCEWAKE_MT, FORCEWAKE_MT_ACK);
>
> +		spin_lock_irq(&dev_priv->uncore.lock);
>   		fw_domains_get_with_thread_status(dev_priv, FORCEWAKE_ALL);
>   		ecobus = __raw_i915_read32(dev_priv, ECOBUS);
>   		fw_domains_put_with_fifo(dev_priv, FORCEWAKE_ALL);
> +		spin_unlock_irq(&dev_priv->uncore.lock);
>
>   		if (!(ecobus & FORCEWAKE_MT_ENABLE)) {
>   			DRM_INFO("No MT forcewake available on Ivybridge, this can result in issues\n");
>

Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>

Regards,

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

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

* Re: [PATCH] drm/i915: Hold irq uncore.lock when initialising fw_domains
  2016-07-04  9:06 ` [PATCH] " Tvrtko Ursulin
@ 2016-07-04  9:29   ` Chris Wilson
  0 siblings, 0 replies; 5+ messages in thread
From: Chris Wilson @ 2016-07-04  9:29 UTC (permalink / raw)
  To: Tvrtko Ursulin; +Cc: intel-gfx, Mika Kuoppala

On Mon, Jul 04, 2016 at 10:06:14AM +0100, Tvrtko Ursulin wrote:
> 
> On 03/07/16 18:29, Chris Wilson wrote:
> >Acquiring the forcewake domain asserts that it is in an atomic section
> >(as we always expect to under the uncore.lock). This true expect for
> >initialising the domains on Ivybridge, and so we generate a warning.
> >Wrap the manual usage of fw_domains inside the spin_lock.
> >
> >Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> >Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> >Cc: Mika Kuoppala <mika.kuoppala@intel.com>

> Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>

Thanks, gave the changelog a once-over for grammar and pushed.
-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] 5+ messages in thread

* Re: [PATCH] drm/i915: Hold irq uncore.lock when initialising fw_domains
  2016-07-03 17:29 [PATCH] drm/i915: Hold irq uncore.lock when initialising fw_domains Chris Wilson
  2016-07-04  5:26 ` ✓ Ro.CI.BAT: success for " Patchwork
  2016-07-04  9:06 ` [PATCH] " Tvrtko Ursulin
@ 2016-07-04  9:37 ` Mika Kuoppala
  2 siblings, 0 replies; 5+ messages in thread
From: Mika Kuoppala @ 2016-07-04  9:37 UTC (permalink / raw)
  To: Chris Wilson, intel-gfx

Chris Wilson <chris@chris-wilson.co.uk> writes:

> Acquiring the forcewake domain asserts that it is in an atomic section
> (as we always expect to under the uncore.lock). This true expect for
> initialising the domains on Ivybridge, and so we generate a warning.
> Wrap the manual usage of fw_domains inside the spin_lock.
>
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> Cc: Mika Kuoppala <mika.kuoppala@intel.com>

Reviewed-by: Mika Kuoppala <mika.kuoppala@intel.com>

> ---
>  drivers/gpu/drm/i915/intel_uncore.c | 2 ++
>  1 file changed, 2 insertions(+)
>
> diff --git a/drivers/gpu/drm/i915/intel_uncore.c b/drivers/gpu/drm/i915/intel_uncore.c
> index 7da3906badf3..1d65209c0998 100644
> --- a/drivers/gpu/drm/i915/intel_uncore.c
> +++ b/drivers/gpu/drm/i915/intel_uncore.c
> @@ -1299,9 +1299,11 @@ static void intel_uncore_fw_domains_init(struct drm_i915_private *dev_priv)
>  		fw_domain_init(dev_priv, FW_DOMAIN_ID_RENDER,
>  			       FORCEWAKE_MT, FORCEWAKE_MT_ACK);
>  
> +		spin_lock_irq(&dev_priv->uncore.lock);
>  		fw_domains_get_with_thread_status(dev_priv, FORCEWAKE_ALL);
>  		ecobus = __raw_i915_read32(dev_priv, ECOBUS);
>  		fw_domains_put_with_fifo(dev_priv, FORCEWAKE_ALL);
> +		spin_unlock_irq(&dev_priv->uncore.lock);
>  
>  		if (!(ecobus & FORCEWAKE_MT_ENABLE)) {
>  			DRM_INFO("No MT forcewake available on Ivybridge, this can result in issues\n");
> -- 
> 2.8.1
>
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

end of thread, other threads:[~2016-07-04  9:38 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-07-03 17:29 [PATCH] drm/i915: Hold irq uncore.lock when initialising fw_domains Chris Wilson
2016-07-04  5:26 ` ✓ Ro.CI.BAT: success for " Patchwork
2016-07-04  9:06 ` [PATCH] " Tvrtko Ursulin
2016-07-04  9:29   ` Chris Wilson
2016-07-04  9:37 ` Mika Kuoppala

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.