* [PATCH] drm/i915: Ironlake do_idle_maps w/a may be called w/o struct_mutex
@ 2017-03-30 8:53 ` Chris Wilson
0 siblings, 0 replies; 7+ messages in thread
From: Chris Wilson @ 2017-03-30 8:53 UTC (permalink / raw)
To: intel-gfx
Cc: Chris Wilson, Joonas Lahtinen, Daniel Vetter, Jani Nikula, # v4 . 10+
Since commit 1233e2db199d ("drm/i915: Move object backing storage
manipulation to its own locking"), i915_gem_object_put_pages() and
specifically the i915_gem_gtt_finish_pages() may be called from outside
of the struct_mutex and so we can no longer pass I915_WAIT_LOCKED to
i915_gem_wait_for_idle.
Fixes: 1233e2db199d ("drm/i915: Move object backing storage manipulation to its own locking")
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Cc: Daniel Vetter <daniel.vetter@intel.com>
Cc: Jani Nikula <jani.nikula@linux.intel.com>
Cc: intel-gfx@lists.freedesktop.org
Cc: <stable@vger.kernel.org> # v4.10+
---
drivers/gpu/drm/i915/i915_gem_gtt.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/i915/i915_gem_gtt.c b/drivers/gpu/drm/i915/i915_gem_gtt.c
index 895ee27d1d03..de14978fdb2e 100644
--- a/drivers/gpu/drm/i915/i915_gem_gtt.c
+++ b/drivers/gpu/drm/i915/i915_gem_gtt.c
@@ -2364,7 +2364,7 @@ void i915_gem_gtt_finish_pages(struct drm_i915_gem_object *obj,
struct i915_ggtt *ggtt = &dev_priv->ggtt;
if (unlikely(ggtt->do_idle_maps)) {
- if (i915_gem_wait_for_idle(dev_priv, I915_WAIT_LOCKED)) {
+ if (i915_gem_wait_for_idle(dev_priv, 0)) {
DRM_ERROR("Failed to wait for idle; VT'd may hang.\n");
/* Wait a bit, in hopes it avoids the hang */
udelay(10);
--
2.11.0
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [PATCH] drm/i915: Ironlake do_idle_maps w/a may be called w/o struct_mutex
@ 2017-03-30 8:53 ` Chris Wilson
0 siblings, 0 replies; 7+ messages in thread
From: Chris Wilson @ 2017-03-30 8:53 UTC (permalink / raw)
To: intel-gfx; +Cc: Daniel Vetter, # v4 . 10+
Since commit 1233e2db199d ("drm/i915: Move object backing storage
manipulation to its own locking"), i915_gem_object_put_pages() and
specifically the i915_gem_gtt_finish_pages() may be called from outside
of the struct_mutex and so we can no longer pass I915_WAIT_LOCKED to
i915_gem_wait_for_idle.
Fixes: 1233e2db199d ("drm/i915: Move object backing storage manipulation to its own locking")
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Cc: Daniel Vetter <daniel.vetter@intel.com>
Cc: Jani Nikula <jani.nikula@linux.intel.com>
Cc: intel-gfx@lists.freedesktop.org
Cc: <stable@vger.kernel.org> # v4.10+
---
drivers/gpu/drm/i915/i915_gem_gtt.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/i915/i915_gem_gtt.c b/drivers/gpu/drm/i915/i915_gem_gtt.c
index 895ee27d1d03..de14978fdb2e 100644
--- a/drivers/gpu/drm/i915/i915_gem_gtt.c
+++ b/drivers/gpu/drm/i915/i915_gem_gtt.c
@@ -2364,7 +2364,7 @@ void i915_gem_gtt_finish_pages(struct drm_i915_gem_object *obj,
struct i915_ggtt *ggtt = &dev_priv->ggtt;
if (unlikely(ggtt->do_idle_maps)) {
- if (i915_gem_wait_for_idle(dev_priv, I915_WAIT_LOCKED)) {
+ if (i915_gem_wait_for_idle(dev_priv, 0)) {
DRM_ERROR("Failed to wait for idle; VT'd may hang.\n");
/* Wait a bit, in hopes it avoids the hang */
udelay(10);
--
2.11.0
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH] drm/i915: Ironlake do_idle_maps w/a may be called w/o struct_mutex
2017-03-30 8:53 ` Chris Wilson
@ 2017-03-30 10:02 ` Joonas Lahtinen
-1 siblings, 0 replies; 7+ messages in thread
From: Joonas Lahtinen @ 2017-03-30 10:02 UTC (permalink / raw)
To: Chris Wilson, intel-gfx; +Cc: Daniel Vetter, Jani Nikula, # v4 . 10+
On to, 2017-03-30 at 09:53 +0100, Chris Wilson wrote:
> Since commit 1233e2db199d ("drm/i915: Move object backing storage
> manipulation to its own locking"), i915_gem_object_put_pages() and
> specifically the i915_gem_gtt_finish_pages() may be called from outside
> of the struct_mutex and so we can no longer pass I915_WAIT_LOCKED to
> i915_gem_wait_for_idle.
>
> Fixes: 1233e2db199d ("drm/i915: Move object backing storage manipulation to its own locking")
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
> Cc: Daniel Vetter <daniel.vetter@intel.com>
> Cc: Jani Nikula <jani.nikula@linux.intel.com>
> Cc: intel-gfx@lists.freedesktop.org
> Cc: <stable@vger.kernel.org> # v4.10+
Is there Bugzilla or did you just hit the assert on your own?
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Regards, Joonas
--
Joonas Lahtinen
Open Source Technology Center
Intel Corporation
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] drm/i915: Ironlake do_idle_maps w/a may be called w/o struct_mutex
@ 2017-03-30 10:02 ` Joonas Lahtinen
0 siblings, 0 replies; 7+ messages in thread
From: Joonas Lahtinen @ 2017-03-30 10:02 UTC (permalink / raw)
To: Chris Wilson, intel-gfx; +Cc: Daniel Vetter, # v4 . 10+
On to, 2017-03-30 at 09:53 +0100, Chris Wilson wrote:
> Since commit 1233e2db199d ("drm/i915: Move object backing storage
> manipulation to its own locking"), i915_gem_object_put_pages() and
> specifically the i915_gem_gtt_finish_pages() may be called from outside
> of the struct_mutex and so we can no longer pass I915_WAIT_LOCKED to
> i915_gem_wait_for_idle.
>
> Fixes: 1233e2db199d ("drm/i915: Move object backing storage manipulation to its own locking")
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
> Cc: Daniel Vetter <daniel.vetter@intel.com>
> Cc: Jani Nikula <jani.nikula@linux.intel.com>
> Cc: intel-gfx@lists.freedesktop.org
> Cc: <stable@vger.kernel.org> # v4.10+
Is there Bugzilla or did you just hit the assert on your own?
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] 7+ messages in thread
* Re: [PATCH] drm/i915: Ironlake do_idle_maps w/a may be called w/o struct_mutex
2017-03-30 10:02 ` Joonas Lahtinen
(?)
@ 2017-03-30 10:11 ` Chris Wilson
-1 siblings, 0 replies; 7+ messages in thread
From: Chris Wilson @ 2017-03-30 10:11 UTC (permalink / raw)
To: Joonas Lahtinen; +Cc: intel-gfx, Daniel Vetter, Jani Nikula, # v4 . 10+
On Thu, Mar 30, 2017 at 01:02:52PM +0300, Joonas Lahtinen wrote:
> On to, 2017-03-30 at 09:53 +0100, Chris Wilson wrote:
> > Since commit 1233e2db199d ("drm/i915: Move object backing storage
> > manipulation to its own locking"), i915_gem_object_put_pages() and
> > specifically the i915_gem_gtt_finish_pages() may be called from outside
> > of the struct_mutex and so we can no longer pass I915_WAIT_LOCKED to
> > i915_gem_wait_for_idle.
> >
> > Fixes: 1233e2db199d ("drm/i915: Move object backing storage manipulation to its own locking")
> > Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> > Cc: Chris Wilson <chris@chris-wilson.co.uk>
> > Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
> > Cc: Daniel Vetter <daniel.vetter@intel.com>
> > Cc: Jani Nikula <jani.nikula@linux.intel.com>
> > Cc: intel-gfx@lists.freedesktop.org
> > Cc: <stable@vger.kernel.org> # v4.10+
>
> Is there Bugzilla or did you just hit the assert on your own?
Just reviewing callers of i915_gem_wait_for_idle() prior to refactor.
Seems like we got the message across about not using Ironlake + VT'd, or
that those that do are using enterprise kernels and won't have lockdep
enabled when they finally get the kernel update in a few years time.
-Chris
--
Chris Wilson, Intel Open Source Technology Centre
^ permalink raw reply [flat|nested] 7+ messages in thread
* ✓ Fi.CI.BAT: success for drm/i915: Ironlake do_idle_maps w/a may be called w/o struct_mutex
2017-03-30 8:53 ` Chris Wilson
(?)
(?)
@ 2017-03-30 11:33 ` Patchwork
2017-03-30 11:47 ` Chris Wilson
-1 siblings, 1 reply; 7+ messages in thread
From: Patchwork @ 2017-03-30 11:33 UTC (permalink / raw)
To: Chris Wilson; +Cc: intel-gfx
== Series Details ==
Series: drm/i915: Ironlake do_idle_maps w/a may be called w/o struct_mutex
URL : https://patchwork.freedesktop.org/series/22179/
State : success
== Summary ==
Series 22179v1 drm/i915: Ironlake do_idle_maps w/a may be called w/o struct_mutex
https://patchwork.freedesktop.org/api/1.0/series/22179/revisions/1/mbox/
Test kms_flip:
Subgroup basic-flip-vs-wf_vblank:
fail -> PASS (fi-skl-6770hq) fdo#99739
fdo#99739 https://bugs.freedesktop.org/show_bug.cgi?id=99739
fi-bdw-5557u total:278 pass:267 dwarn:0 dfail:0 fail:0 skip:11 time: 428s
fi-bdw-gvtdvm total:278 pass:256 dwarn:8 dfail:0 fail:0 skip:14 time: 425s
fi-bsw-n3050 total:278 pass:239 dwarn:0 dfail:0 fail:0 skip:39 time: 578s
fi-bxt-j4205 total:278 pass:259 dwarn:0 dfail:0 fail:0 skip:19 time: 504s
fi-bxt-t5700 total:278 pass:258 dwarn:0 dfail:0 fail:0 skip:20 time: 566s
fi-byt-j1900 total:278 pass:251 dwarn:0 dfail:0 fail:0 skip:27 time: 486s
fi-byt-n2820 total:278 pass:247 dwarn:0 dfail:0 fail:0 skip:31 time: 481s
fi-hsw-4770 total:278 pass:262 dwarn:0 dfail:0 fail:0 skip:16 time: 413s
fi-hsw-4770r total:278 pass:262 dwarn:0 dfail:0 fail:0 skip:16 time: 414s
fi-ilk-650 total:278 pass:228 dwarn:0 dfail:0 fail:0 skip:50 time: 434s
fi-ivb-3520m total:278 pass:260 dwarn:0 dfail:0 fail:0 skip:18 time: 484s
fi-ivb-3770 total:278 pass:260 dwarn:0 dfail:0 fail:0 skip:18 time: 483s
fi-kbl-7500u total:278 pass:260 dwarn:0 dfail:0 fail:0 skip:18 time: 454s
fi-kbl-7560u total:278 pass:267 dwarn:1 dfail:0 fail:0 skip:10 time: 567s
fi-skl-6260u total:278 pass:268 dwarn:0 dfail:0 fail:0 skip:10 time: 457s
fi-skl-6700hq total:278 pass:261 dwarn:0 dfail:0 fail:0 skip:17 time: 568s
fi-skl-6700k total:278 pass:256 dwarn:4 dfail:0 fail:0 skip:18 time: 457s
fi-skl-6770hq total:278 pass:268 dwarn:0 dfail:0 fail:0 skip:10 time: 496s
fi-skl-gvtdvm total:278 pass:265 dwarn:0 dfail:0 fail:0 skip:13 time: 429s
fi-snb-2520m total:278 pass:250 dwarn:0 dfail:0 fail:0 skip:28 time: 535s
fi-snb-2600 total:278 pass:249 dwarn:0 dfail:0 fail:0 skip:29 time: 410s
66e17cacf58689a0d6ca38138217e667d100a64a drm-tip: 2017y-03m-30d-10h-12m-59s UTC integration manifest
b83e490 drm/i915: Ironlake do_idle_maps w/a may be called w/o struct_mutex
== Logs ==
For more details see: https://intel-gfx-ci.01.org/CI/Patchwork_4356/
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: ✓ Fi.CI.BAT: success for drm/i915: Ironlake do_idle_maps w/a may be called w/o struct_mutex
2017-03-30 11:33 ` ✓ Fi.CI.BAT: success for " Patchwork
@ 2017-03-30 11:47 ` Chris Wilson
0 siblings, 0 replies; 7+ messages in thread
From: Chris Wilson @ 2017-03-30 11:47 UTC (permalink / raw)
To: intel-gfx
On Thu, Mar 30, 2017 at 11:33:59AM -0000, Patchwork wrote:
> == Series Details ==
>
> Series: drm/i915: Ironlake do_idle_maps w/a may be called w/o struct_mutex
> URL : https://patchwork.freedesktop.org/series/22179/
> State : success
>
> == Summary ==
>
> Series 22179v1 drm/i915: Ironlake do_idle_maps w/a may be called w/o struct_mutex
> https://patchwork.freedesktop.org/api/1.0/series/22179/revisions/1/mbox/
>
> Test kms_flip:
> Subgroup basic-flip-vs-wf_vblank:
> fail -> PASS (fi-skl-6770hq) fdo#99739
>
> fdo#99739 https://bugs.freedesktop.org/show_bug.cgi?id=99739
Pushed this little fixup for ilk + vtd + lockdep. Hmm, though I am
wondering if the code should be a little smarter, as it may be called
under the struct_mutex along the shrinker path. Or we just get around to
fixing that.
-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] 7+ messages in thread
end of thread, other threads:[~2017-03-30 11:48 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-03-30 8:53 [PATCH] drm/i915: Ironlake do_idle_maps w/a may be called w/o struct_mutex Chris Wilson
2017-03-30 8:53 ` Chris Wilson
2017-03-30 10:02 ` Joonas Lahtinen
2017-03-30 10:02 ` Joonas Lahtinen
2017-03-30 10:11 ` Chris Wilson
2017-03-30 11:33 ` ✓ Fi.CI.BAT: success for " Patchwork
2017-03-30 11:47 ` 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.