[alsa-devel] [PATCH] ALSA: usb: refine delay information with USB frame counter

Clemens Ladisch clemens at ladisch.de
Mon Sep 5 09:53:26 CEST 2011

Pierre-Louis Bossart wrote:
> ... This should improve audio/video sync

It does indeed; mplayer's A-V difference gets lowered from up to
nrpacks ms down to at most 1 ms.

> +	est_delay =  subs->last_delay-(frame_diff*rate/1000L);

Why a long dividend?

The spacing around operators is inconsistent; please use checkpatch.

> +		snd_printk(KERN_DEBUG "ALSA usb.c: Delay %d actual delay %d\n",
> +			est_delay, subs->last_delay);

snd_printk already can print the "ALSA" and file name prefixes.
(And it uses the correct file name.  ;-)


More information about the Alsa-devel mailing list