All of lore.kernel.org
 help / color / mirror / Atom feed
From: Chris Wilson <chris-Y6uKTt2uX1cEflXRtASbqLVCufUGDwFn@public.gmane.org>
To: Chunming Zhou <david1.zhou-5C7GfCeVMHo@public.gmane.org>,
	dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org
Cc: Dave Airlie <airlied-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>,
	Daniel Rakos <Daniel.Rakos-5C7GfCeVMHo@public.gmane.org>,
	Christian Konig <christian.koenig-5C7GfCeVMHo@public.gmane.org>,
	amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org
Subject: Re: [PATCH 2/7] drm: add syncobj timeline support v8
Date: Fri, 19 Oct 2018 09:49:02 +0100	[thread overview]
Message-ID: <153993893770.19935.6989551886574520401@skylake-alporthouse-com> (raw)
In-Reply-To: <20181015085553.30656-2-david1.zhou-5C7GfCeVMHo@public.gmane.org>

Quoting Chunming Zhou (2018-10-15 09:55:48)
> This patch is for VK_KHR_timeline_semaphore extension, semaphore is called syncobj in kernel side:
> This extension introduces a new type of syncobj that has an integer payload
> identifying a point in a timeline. Such timeline syncobjs support the
> following operations:
>    * CPU query - A host operation that allows querying the payload of the
>      timeline syncobj.
>    * CPU wait - A host operation that allows a blocking wait for a
>      timeline syncobj to reach a specified value.
>    * Device wait - A device operation that allows waiting for a
>      timeline syncobj to reach a specified value.
>    * Device signal - A device operation that allows advancing the
>      timeline syncobj to a specified value.


Spinlock recursion:

https://bugs.freedesktop.org/show_bug.cgi?id=108490
<6> [363.585915] [IGT] syncobj_wait: executing
<6> [363.646916] [IGT] syncobj_wait: starting subtest wait-for-submit-delayed-submit
<4> [363.752517]
<4> [363.752542] ============================================
<4> [363.752561] WARNING: possible recursive locking detected
<4> [363.752582] 4.19.0-rc8-CI-CI_DRM_5006+ #1 Tainted: G U
<4> [363.752602] --------------------------------------------
<4> [363.752621] syncobj_wait/2297 is trying to acquire lock:
<4> [363.752641] 0000000029228054 (&(&syncobj->lock)->rlock){+.+.}, at: drm_syncobj_garbage_collection+0x25/0x140
<4> [363.752699] \x0abut task is already holding lock:
<4> [363.752721] 0000000029228054 (&(&syncobj->lock)->rlock){+.+.}, at: drm_syncobj_replace_fence+0x1b6/0x2c0
<4> [363.752768] \x0aother info that might help us debug this:
<4> [363.752791] Possible unsafe locking scenario:\x0a
<4> [363.752812] CPU0
<4> [363.752824] ----
<4> [363.752835] lock(&(&syncobj->lock)->rlock);
<4> [363.752856] lock(&(&syncobj->lock)->rlock);
<4> [363.752877] \x0a *** DEADLOCK ***\x0a
<4> [363.752905] May be due to missing lock nesting notation\x0a
<4> [363.752932] 1 lock held by syncobj_wait/2297:
<4> [363.752949] #0: 0000000029228054 (&(&syncobj->lock)->rlock){+.+.}, at: drm_syncobj_replace_fence+0x1b6/0x2c0
<4> [363.753001] \x0astack backtrace:
<4> [363.753030] CPU: 2 PID: 2297 Comm: syncobj_wait Tainted: G U 4.19.0-rc8-CI-CI_DRM_5006+ #1
<4> [363.753060] Hardware name: Google Caroline/Caroline, BIOS MrChromebox 08/27/2018
<4> [363.753083] Call Trace:
<4> [363.753109] dump_stack+0x67/0x9b
<4> [363.753136] __lock_acquire+0xc67/0x1b50
<4> [363.753164] ? deactivate_slab.isra.26+0x7a4/0x7e0
<4> [363.753203] ? __lock_acquire+0x3c8/0x1b50
<4> [363.753242] ? __wake_up_common_lock+0x5e/0xb0
<4> [363.753285] ? lock_acquire+0xa6/0x1c0
<4> [363.753306] lock_acquire+0xa6/0x1c0
<4> [363.753334] ? drm_syncobj_garbage_collection+0x25/0x140
<4> [363.753365] _raw_spin_lock+0x2a/0x40
<4> [363.753392] ? drm_syncobj_garbage_collection+0x25/0x140
<4> [363.753419] drm_syncobj_garbage_collection+0x25/0x140
<4> [363.753450] drm_syncobj_search_fence+0x38/0x200
<4> [363.753478] ? drm_syncobj_replace_fence+0x1b6/0x2c0
<4> [363.753509] syncobj_wait_syncobj_func+0x11/0x20
<4> [363.753536] drm_syncobj_replace_fence+0x1f8/0x2c0
<4> [363.753561] ? drm_syncobj_handle_to_fd_ioctl+0x170/0x170
<4> [363.753585] drm_syncobj_fd_to_handle_ioctl+0x120/0x1d0
<4> [363.753609] ? drm_syncobj_handle_to_fd_ioctl+0x170/0x170
<4> [363.753638] drm_ioctl_kernel+0x81/0xf0
<4> [363.753665] drm_ioctl+0x2e6/0x3a0
<4> [363.753686] ? drm_syncobj_handle_to_fd_ioctl+0x170/0x170
<4> [363.753717] ? lock_acquire+0xa6/0x1c0
<4> [363.753743] do_vfs_ioctl+0xa0/0x6d0
<4> [363.753769] ? __fget+0xfc/0x1e0
<4> [363.753792] ksys_ioctl+0x35/0x60
<4> [363.753816] __x64_sys_ioctl+0x11/0x20
<4> [363.753840] do_syscall_64+0x55/0x190
<4> [363.753866] entry_SYSCALL_64_after_hwframe+0x49/0xbe
<4> [363.753890] RIP: 0033:0x7f0d84f9a5d7
<4> [363.753911] Code: b3 66 90 48 8b 05 b1 48 2d 00 64 c7 00 26 00 00 00 48 c7 c0 ff ff ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 b8 10 00 00 00 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 8b 0d 81 48 2d 00 f7 d8 64 89 01 48
<4> [363.753959] RSP: 002b:00007f0d79804ac8 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
<4> [363.753990] RAX: ffffffffffffffda RBX: 00007f0d74000b20 RCX: 00007f0d84f9a5d7
<4> [363.754016] RDX: 00007f0d79804b50 RSI: 00000000c01064c2 RDI: 0000000000000005
<4> [363.754040] RBP: 00007f0d79804b50 R08: 0000000000000000 R09: 000000000000001e
<4> [363.754064] R10: 0000000000000054 R11: 0000000000000246 R12: 00000000c01064c2
<4> [363.754088] R13: 0000000000000005 R14: 00007f0d74000b20 R15: 000055ab44e2c3f8
-Chris
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

  parent reply	other threads:[~2018-10-19  8:49 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-10-15  8:55 [PATCH 1/7] drm: add flags to drm_syncobj_find_fence Chunming Zhou
2018-10-15  8:55 ` [PATCH 2/7] drm: add syncobj timeline support v8 Chunming Zhou
2018-10-17  8:09   ` Daniel Vetter
     [not found]     ` <20181017080908.GK31561-dv86pmgwkMBes7Z6vYuT8azUEOm+Xw19@public.gmane.org>
2018-10-17  9:17       ` zhoucm1
2018-10-17  9:29         ` Koenig, Christian
2018-10-17 10:24           ` Daniel Vetter
     [not found]             ` <CAKMK7uGxptMKtz-4JzT9us3M2dsLGhTSVuAKduNH+VGCsCSsQw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2018-10-18  3:11               ` zhoucm1
     [not found]                 ` <b08b1f23-d8dc-a294-2176-5125075c9acc-5C7GfCeVMHo@public.gmane.org>
2018-10-18 11:50                   ` Christian König
2018-10-19  2:29                     ` zhoucm1
2018-10-19  8:55                       ` Daniel Vetter
2018-10-19  9:20                         ` zhoucm1
     [not found]                           ` <19972bac-f2a9-49ee-592d-85f9eaf06145-5C7GfCeVMHo@public.gmane.org>
2018-10-19 10:12                             ` zhoucm1
     [not found]                               ` <22a52713-0ab5-80d9-a604-b171f916eedd-5C7GfCeVMHo@public.gmane.org>
2018-10-19 10:45                                 ` zhoucm1
     [not found]                                   ` <69039ffa-425e-81e7-4b08-1d431d8a212f-5C7GfCeVMHo@public.gmane.org>
2018-10-19 18:17                                     ` Daniel Vetter
     [not found]         ` <2066a18d-8002-014b-ef3c-a6f6014bdb55-5C7GfCeVMHo@public.gmane.org>
2018-10-17 10:22           ` Daniel Vetter
     [not found]             ` <CAKMK7uEEKpzjdON-qOstM67OYfDjHc5gS0+kSpuh1pm5t4BAHA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2018-10-17 10:37               ` zhoucm1
     [not found]   ` <20181015085553.30656-2-david1.zhou-5C7GfCeVMHo@public.gmane.org>
2018-10-19  8:49     ` Chris Wilson [this message]
2018-10-15  8:55 ` [PATCH 3/7] drm: add support of syncobj timeline point wait v2 Chunming Zhou
2018-10-15  8:55 ` [PATCH 4/7] drm: add timeline syncobj payload query ioctl v2 Chunming Zhou
     [not found] ` <20181015085553.30656-1-david1.zhou-5C7GfCeVMHo@public.gmane.org>
2018-10-15  8:55   ` [PATCH 5/7] drm: add timeline support for syncobj export/import Chunming Zhou
2018-10-15  8:55   ` [PATCH 6/7] drm/amdgpu: add timeline support in amdgpu CS v2 Chunming Zhou
2018-10-15  8:55   ` [PATCH 7/7] drm/amdgpu: update version for timeline syncobj support in amdgpu Chunming Zhou
2018-10-15  9:01     ` Zhou, David(ChunMing)
     [not found]       ` <BY1PR12MB0502F0E543F50239A43E5F94B4FD0-PicGAnIBOobrCwm+z9iKNgdYzm3356FpvxpqHgZTriW3zl9H0oFU5g@public.gmane.org>
2018-10-15  9:04         ` Koenig, Christian
     [not found]           ` <cf4590f5-8e0a-ac0e-f34b-3e1b4b01fd99-5C7GfCeVMHo@public.gmane.org>
2018-10-16 12:54             ` Christian König
     [not found]               ` <dcb28515-7250-9a1c-2784-a4cbf517e467-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2018-10-17  7:46                 ` zhoucm1

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=153993893770.19935.6989551886574520401@skylake-alporthouse-com \
    --to=chris-y6uktt2ux1ceflxrtasbqlvcufugdwfn@public.gmane.org \
    --cc=Daniel.Rakos-5C7GfCeVMHo@public.gmane.org \
    --cc=airlied-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org \
    --cc=amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org \
    --cc=christian.koenig-5C7GfCeVMHo@public.gmane.org \
    --cc=david1.zhou-5C7GfCeVMHo@public.gmane.org \
    --cc=dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.