From: "Ville Syrjälä" <ville.syrjala@linux.intel.com>
To: Thomas Zimmermann <tzimmermann@suse.de>
Cc: maarten.lankhorst@linux.intel.com, mripard@kernel.org,
airlied@gmail.com, simona@ffwll.ch, javierm@redhat.com,
louis.chauvet@bootlin.com, dri-devel@lists.freedesktop.org,
sashiko-reviews@lists.linux.dev, stable@vger.kernel.org
Subject: Re: [PATCH] drm/vblank: Restart enabling vblank timer on possible deadlock
Date: Tue, 3 Nov 2026 19:11:34 +0200 [thread overview]
Message-ID: <auoVxgQ0D1-6QEDD@intel.com> (raw)
In-Reply-To: <ec9020b5-28bb-45a5-89d7-e64e804769de@suse.de>
On Tue, Nov 03, 2026 at 04:55:34PM +0100, Thomas Zimmermann wrote:
> Hi
>
> Am 02.11.26 um 18:15 schrieb Ville Syrjälä:
> [...]
> > But what I'm thinking is:
>
> I've ran a lengthy session to explore various solutions.
>
> > - stop with the explicit cancel entirely and just rely on the
> > timer cancelling itself
> > - try to start the timer in vblank_enable(), and if that can somehow
> > fail because the timer is still running it should be fine because
> > the self cancellation should anyway have been aborted
>
> Having an old vblank timer still running while enable_vblank sets up a
> new one can mess up the hrtimer's internal ordering. It's full of subtle
> bugs, according to my LLM.
The hrtimer code looks like it's designed to handle this. It
first removes the old queued timer and then inserts it back
with the new expire time. And there's also locks in there.
>
>
> > - explicitly wait for the timer to have stoppped in drm_vblank_off()
> > to make sure the wrong interval can't leak from one mode to
> > another
>
> I'll soon send out a series implementing this idea.
>
> Best regards
> Thomas
>
> >
>
> --
> --
> Thomas Zimmermann
> Graphics Driver Developer
> SUSE Software Solutions Germany GmbH
> Frankenstr. 146, 90461 Nürnberg, Germany, www.suse.com
> GF: Stefan Gaiser, Jochen Jaser, Abhinav Puri, (HRB 36809, AG Nürnberg)
>
--
Ville Syrjälä
Intel
prev parent reply other threads:[~2026-11-03 17:11 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-02 14:38 [PATCH] drm/vblank: Restart enabling vblank timer on possible deadlock Thomas Zimmermann
2026-11-02 14:52 ` sashiko-bot
2026-11-02 15:11 ` Ville Syrjälä
2026-11-02 16:48 ` Thomas Zimmermann
2026-11-02 17:15 ` Ville Syrjälä
2026-11-03 15:55 ` Thomas Zimmermann
2026-11-03 17:11 ` Ville Syrjälä [this message]
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=auoVxgQ0D1-6QEDD@intel.com \
--to=ville.syrjala@linux.intel.com \
--cc=airlied@gmail.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=javierm@redhat.com \
--cc=louis.chauvet@bootlin.com \
--cc=maarten.lankhorst@linux.intel.com \
--cc=mripard@kernel.org \
--cc=sashiko-reviews@lists.linux.dev \
--cc=simona@ffwll.ch \
--cc=stable@vger.kernel.org \
--cc=tzimmermann@suse.de \
/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.