* [PATCH] drm/i915: Flush the change in debugobject before reallocation
@ 2017-01-13 21:43 Chris Wilson
2017-01-13 22:23 ` ✓ Fi.CI.BAT: success for " Patchwork
2017-01-16 11:55 ` [PATCH] " Joonas Lahtinen
0 siblings, 2 replies; 3+ messages in thread
From: Chris Wilson @ 2017-01-13 21:43 UTC (permalink / raw)
To: intel-gfx
When marking the debugobject as freed, be sure that write is flushed
before another CPU may see it on a reallocation path.
Only seen once in CI:
[ 159.240873] WARNING: CPU: 3 PID: 6735 at lib/debugobjects.c:263 debug_print_object+0x87/0xb0
[ 159.240897] ODEBUG: init destroyed (active state 0) object type: i915_sw_fence hint: submit_notify+0x0/0x4c [i915]
[ 159.240902] Modules linked in: snd_hda_intel i915 x86_pkg_temp_thermal intel_powerclamp coretemp crct10dif_pclmul snd_hda_codec_realtek crc32_pclmul snd_hda_codec_generic snd_hda_codec_hdmi ghash_clmulni_intel snd_hda_codec snd_hwdep snd_hda_core snd_pcm mei_me lpc_ich mei e1000e ptp pps_core [last unloaded: i915]
[ 159.240913] CPU: 3 PID: 6735 Comm: gem_exec_nop Tainted: G U 4.10.0-rc3-CI-Trybot_479+ #1
[ 159.240913] Hardware name: LENOVO 10AGS00601/SHARKBAY, BIOS FBKT34AUS 04/24/2013
[ 159.240914] Call Trace:
[ 159.240916] dump_stack+0x67/0x92
[ 159.240919] __warn+0xc6/0xe0
[ 159.240920] warn_slowpath_fmt+0x4a/0x50
[ 159.240921] debug_print_object+0x87/0xb0
[ 159.240935] ? __i915_request_wait_for_execute+0x1d0/0x1d0 [i915]
[ 159.240936] __debug_object_init+0xb2/0x410
[ 159.240950] ? __i915_request_wait_for_execute+0x1d0/0x1d0 [i915]
[ 159.240951] debug_object_init+0x16/0x20
[ 159.240962] __i915_sw_fence_init+0x29/0x60 [i915]
[ 159.240975] i915_gem_request_alloc+0x1fb/0x450 [i915]
[ 159.240987] i915_gem_do_execbuffer.isra.15+0x798/0x1b20 [i915]
[ 159.241000] i915_gem_execbuffer2+0xc0/0x250 [i915]
[ 159.241003] drm_ioctl+0x200/0x450
[ 159.241016] ? i915_gem_execbuffer+0x330/0x330 [i915]
[ 159.241018] do_vfs_ioctl+0x90/0x6e0
[ 159.241020] ? trace_hardirqs_on_caller+0x122/0x1b0
[ 159.241021] SyS_ioctl+0x3c/0x70
[ 159.241023] entry_SYSCALL_64_fastpath+0x1c/0xb1
[ 159.241024] RIP: 0033:0x7f9bc4f41357
[ 159.241025] RSP: 002b:00007ffc6cd5c568 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
[ 159.241026] RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007f9bc4f41357
[ 159.241026] RDX: 00007ffc6cd5c640 RSI: 0000000040406469 RDI: 0000000000000003
[ 159.241027] RBP: 00007ffc6cd5c640 R08: 0000000000047508 R09: 0000000000000001
[ 159.241027] R10: 000b58552d323c3d R11: 0000000000000246 R12: 0000000040406469
[ 159.241028] R13: 0000000000000003 R14: 0000000000000004 R15: 0000000000000001
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
---
drivers/gpu/drm/i915/i915_sw_fence.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/gpu/drm/i915/i915_sw_fence.c b/drivers/gpu/drm/i915/i915_sw_fence.c
index f5a88092dacf..40f4e5efaf83 100644
--- a/drivers/gpu/drm/i915/i915_sw_fence.c
+++ b/drivers/gpu/drm/i915/i915_sw_fence.c
@@ -63,6 +63,7 @@ static inline void debug_fence_destroy(struct i915_sw_fence *fence)
static inline void debug_fence_free(struct i915_sw_fence *fence)
{
debug_object_free(fence, &i915_sw_fence_debug_descr);
+ smp_wmb(); /* flush the change in state before reallocation */
}
static inline void debug_fence_assert(struct i915_sw_fence *fence)
--
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] 3+ messages in thread
* ✓ Fi.CI.BAT: success for drm/i915: Flush the change in debugobject before reallocation
2017-01-13 21:43 [PATCH] drm/i915: Flush the change in debugobject before reallocation Chris Wilson
@ 2017-01-13 22:23 ` Patchwork
2017-01-16 11:55 ` [PATCH] " Joonas Lahtinen
1 sibling, 0 replies; 3+ messages in thread
From: Patchwork @ 2017-01-13 22:23 UTC (permalink / raw)
To: Chris Wilson; +Cc: intel-gfx
== Series Details ==
Series: drm/i915: Flush the change in debugobject before reallocation
URL : https://patchwork.freedesktop.org/series/17999/
State : success
== Summary ==
Series 17999v1 drm/i915: Flush the change in debugobject before reallocation
https://patchwork.freedesktop.org/api/1.0/series/17999/revisions/1/mbox/
fi-bdw-5557u total:246 pass:232 dwarn:0 dfail:0 fail:0 skip:14
fi-bsw-n3050 total:246 pass:207 dwarn:0 dfail:0 fail:0 skip:39
fi-bxt-j4205 total:246 pass:224 dwarn:0 dfail:0 fail:0 skip:22
fi-bxt-t5700 total:82 pass:69 dwarn:0 dfail:0 fail:0 skip:12
fi-byt-j1900 total:246 pass:219 dwarn:0 dfail:0 fail:0 skip:27
fi-byt-n2820 total:246 pass:215 dwarn:0 dfail:0 fail:0 skip:31
fi-hsw-4770 total:246 pass:227 dwarn:0 dfail:0 fail:0 skip:19
fi-hsw-4770r total:246 pass:227 dwarn:0 dfail:0 fail:0 skip:19
fi-ivb-3520m total:246 pass:225 dwarn:0 dfail:0 fail:0 skip:21
fi-ivb-3770 total:246 pass:225 dwarn:0 dfail:0 fail:0 skip:21
fi-kbl-7500u total:246 pass:225 dwarn:0 dfail:0 fail:0 skip:21
fi-skl-6260u total:246 pass:233 dwarn:0 dfail:0 fail:0 skip:13
fi-skl-6700hq total:246 pass:226 dwarn:0 dfail:0 fail:0 skip:20
fi-skl-6700k total:246 pass:222 dwarn:3 dfail:0 fail:0 skip:21
fi-skl-6770hq total:246 pass:233 dwarn:0 dfail:0 fail:0 skip:13
fi-snb-2520m total:246 pass:215 dwarn:0 dfail:0 fail:0 skip:31
fi-snb-2600 total:246 pass:214 dwarn:0 dfail:0 fail:0 skip:32
a957dfe613ab43c6af84833f2b88ea941320250f drm-tip: 2017y-01m-13d-18h-49m-04s UTC integration manifest
36722f5 drm/i915: Flush the change in debugobject before reallocation
== Logs ==
For more details see: https://intel-gfx-ci.01.org/CI/Patchwork_3515/
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] drm/i915: Flush the change in debugobject before reallocation
2017-01-13 21:43 [PATCH] drm/i915: Flush the change in debugobject before reallocation Chris Wilson
2017-01-13 22:23 ` ✓ Fi.CI.BAT: success for " Patchwork
@ 2017-01-16 11:55 ` Joonas Lahtinen
1 sibling, 0 replies; 3+ messages in thread
From: Joonas Lahtinen @ 2017-01-16 11:55 UTC (permalink / raw)
To: Chris Wilson, intel-gfx
On pe, 2017-01-13 at 21:43 +0000, Chris Wilson wrote:
> When marking the debugobject as freed, be sure that write is flushed
> before another CPU may see it on a reallocation path.
>
> Only seen once in CI:
>
> [ 159.240873] WARNING: CPU: 3 PID: 6735 at lib/debugobjects.c:263 debug_print_object+0x87/0xb0
> [ 159.240897] ODEBUG: init destroyed (active state 0) object type: i915_sw_fence hint: submit_notify+0x0/0x4c [i915]
> [ 159.240902] Modules linked in: snd_hda_intel i915 x86_pkg_temp_thermal intel_powerclamp coretemp crct10dif_pclmul snd_hda_codec_realtek crc32_pclmul snd_hda_codec_generic snd_hda_codec_hdmi ghash_clmulni_intel snd_hda_codec snd_hwdep snd_hda_core snd_pcm mei_me lpc_ich mei e1000e ptp pps_core [last unloaded: i915]
> [ 159.240913] CPU: 3 PID: 6735 Comm: gem_exec_nop Tainted: G U 4.10.0-rc3-CI-Trybot_479+ #1
> [ 159.240913] Hardware name: LENOVO 10AGS00601/SHARKBAY, BIOS FBKT34AUS 04/24/2013
> [ 159.240914] Call Trace:
> [ 159.240916] dump_stack+0x67/0x92
> [ 159.240919] __warn+0xc6/0xe0
> [ 159.240920] warn_slowpath_fmt+0x4a/0x50
> [ 159.240921] debug_print_object+0x87/0xb0
> [ 159.240935] ? __i915_request_wait_for_execute+0x1d0/0x1d0 [i915]
> [ 159.240936] __debug_object_init+0xb2/0x410
> [ 159.240950] ? __i915_request_wait_for_execute+0x1d0/0x1d0 [i915]
> [ 159.240951] debug_object_init+0x16/0x20
> [ 159.240962] __i915_sw_fence_init+0x29/0x60 [i915]
> [ 159.240975] i915_gem_request_alloc+0x1fb/0x450 [i915]
> [ 159.240987] i915_gem_do_execbuffer.isra.15+0x798/0x1b20 [i915]
> [ 159.241000] i915_gem_execbuffer2+0xc0/0x250 [i915]
> [ 159.241003] drm_ioctl+0x200/0x450
> [ 159.241016] ? i915_gem_execbuffer+0x330/0x330 [i915]
> [ 159.241018] do_vfs_ioctl+0x90/0x6e0
> [ 159.241020] ? trace_hardirqs_on_caller+0x122/0x1b0
> [ 159.241021] SyS_ioctl+0x3c/0x70
> [ 159.241023] entry_SYSCALL_64_fastpath+0x1c/0xb1
> [ 159.241024] RIP: 0033:0x7f9bc4f41357
> [ 159.241025] RSP: 002b:00007ffc6cd5c568 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
> [ 159.241026] RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007f9bc4f41357
> [ 159.241026] RDX: 00007ffc6cd5c640 RSI: 0000000040406469 RDI: 0000000000000003
> [ 159.241027] RBP: 00007ffc6cd5c640 R08: 0000000000047508 R09: 0000000000000001
> [ 159.241027] R10: 000b58552d323c3d R11: 0000000000000246 R12: 0000000040406469
> [ 159.241028] R13: 0000000000000003 R14: 0000000000000004 R15: 0000000000000001
>
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
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] 3+ messages in thread
end of thread, other threads:[~2017-01-16 11:55 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-01-13 21:43 [PATCH] drm/i915: Flush the change in debugobject before reallocation Chris Wilson
2017-01-13 22:23 ` ✓ Fi.CI.BAT: success for " Patchwork
2017-01-16 11:55 ` [PATCH] " Joonas Lahtinen
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.