All of lore.kernel.org
 help / color / mirror / Atom feed
From: Takashi Iwai <tiwai@suse.de>
To: Yu-Hsuan Hsu <yuhsuan@chromium.org>
Cc: linux-kernel@vger.kernel.org, "Jaroslav Kysela" <perex@perex.cz>,
	"Takashi Iwai" <tiwai@suse.com>,
	"Cássio Gabriel" <cassiogabrielcontato@gmail.com>,
	linux-sound@vger.kernel.org
Subject: Re: [PATCH v2] ALSA: aloop: Add 'hrtimer' option to timer_source
Date: Wed, 08 Jul 2026 12:31:32 +0200	[thread overview]
Message-ID: <877bn56ad7.wl-tiwai@suse.de> (raw)
In-Reply-To: <20260705125941.1203871-1-yuhsuan@chromium.org>

On Sun, 05 Jul 2026 14:59:30 +0200,
Yu-Hsuan Hsu wrote:
> 
> The snd-aloop driver currently defaults to using the system jiffies
> timer (struct timer_list). On systems configured with a low timer
> interrupt frequency (e.g., CONFIG_HZ=250), the jiffies resolution
> (4ms per tick) is insufficient for precise audio timing. For
> example, a 10ms audio period requires 2.5 jiffies ticks, causing
> timing jitter that leads to capture underruns.
> 
> Introduce "hrtimer" as a supported timer_source option. When
> timer_source="hrtimer" is set, aloop uses high-resolution timers
> (hrtimer) to drive period updates. This provides nanosecond-level
> accuracy regardless of CONFIG_HZ and operates independently of other
> hardware audio cards.
> 
> Signed-off-by: Yu-Hsuan Hsu <yuhsuan@chromium.org>
> ---
> v1 -> v2:
>  - Guard hrtimer implementation with #ifdef CONFIG_HIGH_RES_TIMERS
>    to handle kernels built without CONFIG_HIGH_RES_TIMERS.

Applied to for-next branch now.  Thanks.


Takashi

      reply	other threads:[~2026-07-08 10:31 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-02 17:03 [PATCH] ALSA: aloop: Add 'hrtimer' option to timer_source Yu-Hsuan Hsu
2026-07-03 11:12 ` Takashi Iwai
2026-07-05 12:59 ` [PATCH v2] " Yu-Hsuan Hsu
2026-07-08 10:31   ` Takashi Iwai [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=877bn56ad7.wl-tiwai@suse.de \
    --to=tiwai@suse.de \
    --cc=cassiogabrielcontato@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-sound@vger.kernel.org \
    --cc=perex@perex.cz \
    --cc=tiwai@suse.com \
    --cc=yuhsuan@chromium.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.