[alsa-devel] [PATCH 3/3] imx-ssi: Use a hrtimer in FIQ mode

Mark Brown broonie at opensource.wolfsonmicro.com
Thu Apr 8 11:53:25 CEST 2010

On Thu, Apr 08, 2010 at 11:31:26AM +0200, Sascha Hauer wrote:

> -	/* Restart the timer; if we didn't report we'll run on the next tick */
> -	add_timer(&iprtd->timer);
> +	hrtimer_forward_now(hrt, ns_to_ktime(iprtd->poll_time_ns));

Hrm, this looks like it's going to have an issue with clock drift -
we're now unconditionally advancing the timer every period, even if the
data transfer hasn't pushed through a period of data.  This will cause
problems on lengthy playbacks (and shorter ones if the clocks are
sufficiently out of sync).

More information about the Alsa-devel mailing list