All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Danilo Krummrich" <dakr@kernel.org>
To: "Christian König" <christian.koenig@amd.com>
Cc: <phasta@kernel.org>, "Tvrtko Ursulin" <tvrtko.ursulin@igalia.com>,
	<dri-devel@lists.freedesktop.org>, <kernel-dev@igalia.com>,
	"Lyude Paul" <lyude@redhat.com>, <nouveau@lists.freedesktop.org>,
	"Alice Ryhl" <aliceryhl@google.com>,
	"Boris Brezillon" <boris.brezillon@collabora.com>,
	"Dave Airlie" <airlied@gmail.com>, "Gary Guo" <gary@garyguo.net>
Subject: Re: [PATCH v3] drm/nouveau: Simplify nouveau_cli_work
Date: Mon, 22 Jun 2026 20:20:03 +0200	[thread overview]
Message-ID: <DJFSAVPR4EE0.1L3AWTWLI9CE2@kernel.org> (raw)
In-Reply-To: <cf9f4a62-ed02-46d6-9560-481ceda2d1a3@amd.com>

On Mon Jun 22, 2026 at 2:17 PM CEST, Christian König wrote:
> Maybe an idea how to generally tackle this for all drivers: Never let the
> dma-fence framework call dma_fence_signal(), that should only the driver do by
> itself.
>
> This way we don't run into the issue in the first place that the driver needs
> to install some callbacks *and* the driver also knows when the installed
> callbacks are finished because that is when dma_fence_signal() returns.
>
> Does that sound valid to you guys? If yes I will be sending out patches to do
> this.

I think that's a good idea, as it would get us rid of having to rely on API
internals to synchronize struct dma_fence_cb callbacks without doing the full
RCU dance, which can be quite cumbersome (as described in the nouveau case).

It still leaves us with the full RCU dance for struct dma_fence_ops callbacks,
but that's a different topic.

Thanks,
Danilo

WARNING: multiple messages have this Message-ID (diff)
From: "Danilo Krummrich" <dakr@kernel.org>
To: "Christian König" <christian.koenig@amd.com>
Cc: phasta@kernel.org, Tvrtko Ursulin <tvrtko.ursulin@igalia.com>,
	dri-devel@lists.freedesktop.org, kernel-dev@igalia.com,
	nouveau@lists.freedesktop.org, Alice Ryhl <aliceryhl@google.com>,
	Boris Brezillon <boris.brezillon@collabora.com>,
	Gary Guo <gary@garyguo.net>
Subject: Re: [PATCH v3] drm/nouveau: Simplify nouveau_cli_work
Date: Mon, 22 Jun 2026 20:20:03 +0200	[thread overview]
Message-ID: <DJFSAVPR4EE0.1L3AWTWLI9CE2@kernel.org> (raw)
In-Reply-To: <cf9f4a62-ed02-46d6-9560-481ceda2d1a3@amd.com>

On Mon Jun 22, 2026 at 2:17 PM CEST, Christian König wrote:
> Maybe an idea how to generally tackle this for all drivers: Never let the
> dma-fence framework call dma_fence_signal(), that should only the driver do by
> itself.
>
> This way we don't run into the issue in the first place that the driver needs
> to install some callbacks *and* the driver also knows when the installed
> callbacks are finished because that is when dma_fence_signal() returns.
>
> Does that sound valid to you guys? If yes I will be sending out patches to do
> this.

I think that's a good idea, as it would get us rid of having to rely on API
internals to synchronize struct dma_fence_cb callbacks without doing the full
RCU dance, which can be quite cumbersome (as described in the nouveau case).

It still leaves us with the full RCU dance for struct dma_fence_ops callbacks,
but that's a different topic.

Thanks,
Danilo

  parent reply	other threads:[~2026-06-22 18:20 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-06-12 16:54 [PATCH] drm/nouveau: Simplify nouveau_cli_work Tvrtko Ursulin
2026-06-12 16:54 ` Tvrtko Ursulin
2026-06-12 17:01 ` sashiko-bot
2026-06-12 17:14 ` Philipp Stanner
2026-06-12 17:14   ` Philipp Stanner
2026-06-12 17:18   ` Tvrtko Ursulin
2026-06-12 17:18     ` Tvrtko Ursulin
2026-06-12 17:29     ` Tvrtko Ursulin
2026-06-12 17:29       ` Tvrtko Ursulin
2026-06-12 17:22 ` [PATCH v2] " Tvrtko Ursulin
2026-06-12 17:22   ` Tvrtko Ursulin
2026-06-12 17:33   ` sashiko-bot
2026-06-15  9:26 ` [PATCH v3] " Tvrtko Ursulin
2026-06-15  9:26   ` Tvrtko Ursulin
2026-06-15  9:31   ` Philipp Stanner
2026-06-15  9:31     ` Philipp Stanner
2026-06-21 15:29   ` Danilo Krummrich
2026-06-21 15:29     ` Danilo Krummrich
2026-06-21 15:30   ` Danilo Krummrich
2026-06-21 15:30     ` Danilo Krummrich
2026-06-22  8:57     ` Philipp Stanner
2026-06-22  8:57       ` Philipp Stanner
2026-06-22  9:53       ` Tvrtko Ursulin
2026-06-22  9:53         ` Tvrtko Ursulin
2026-06-22 12:17       ` Christian König
2026-06-22 12:17         ` Christian König
2026-06-22 12:45         ` Philipp Stanner
2026-06-22 12:45           ` Philipp Stanner
2026-06-22 18:20         ` Danilo Krummrich [this message]
2026-06-22 18:20           ` Danilo Krummrich
2026-06-22 17:51       ` Danilo Krummrich
2026-06-22 17:51         ` Danilo Krummrich

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=DJFSAVPR4EE0.1L3AWTWLI9CE2@kernel.org \
    --to=dakr@kernel.org \
    --cc=airlied@gmail.com \
    --cc=aliceryhl@google.com \
    --cc=boris.brezillon@collabora.com \
    --cc=christian.koenig@amd.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=gary@garyguo.net \
    --cc=kernel-dev@igalia.com \
    --cc=lyude@redhat.com \
    --cc=nouveau@lists.freedesktop.org \
    --cc=phasta@kernel.org \
    --cc=tvrtko.ursulin@igalia.com \
    /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.