summaryrefslogtreecommitdiffstats
path: root/sound/pci
diff options
context:
space:
mode:
authorRichard Fitzgerald <rf@opensource.wolfsonmicro.com>2013-02-11 14:44:53 +0100
committerTakashi Iwai <tiwai@suse.de>2013-02-11 15:03:48 +0100
commit17ac8e5c6d3478dcfeb75ed5716ca7e5cee612f0 (patch)
treedbf86ce267ccd64c980bc496145e596a97769520 /sound/pci
parentALSA: hda/ca0132 - Slight optimization for build with DSP (diff)
downloadlinux-17ac8e5c6d3478dcfeb75ed5716ca7e5cee612f0.tar.xz
linux-17ac8e5c6d3478dcfeb75ed5716ca7e5cee612f0.zip
ALSA: core: don't return uninitialized snd_compr_tstamp
The snd_compr_update_tstamp() can only fill in the snd_compr_tstamp if the codec implements the pointer() function. If that happened the code was previously returning uninitialized garbage in the tstamp because it wasn't initialized anywhere. This change zero-fills the tstamp in the two places it is used before calling snd_compr_update_tstamp(), and also has snd_compr_update_tstamp() return an error indication if it can't provide a tstamp. For the case of snd_compr_calc_avail() it ignores this error because we still need to return info on the available buffer space even if we can't provide tstamp info - when the tstamp is not valid all fields are now guaranteed to be zero. Signed-off-by: Richard Fitzgerald <rf@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Vinod Koul <vinod.koul@intel.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci')
0 files changed, 0 insertions, 0 deletions