diff options
author | Eldad Zack <eldad@fogrefinery.com> | 2013-04-22 19:00:41 -0400 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2013-04-29 07:36:15 -0400 |
commit | 74c34ca1cc12884703c70d34ed333517d978c2e7 (patch) | |
tree | 6d06b76a9fbe829f2427899aa708d682167420c0 /sound/drivers | |
parent | 754813473c1a8b7711802313125f0fafc60141f8 (diff) |
ALSA: pcm_format_to_bits strong-typed conversion
Add a function to handle conversion from snd_pcm_format_t
to bitwise with proper typing.
Change such conversions to use this function and silence sparse
warnings.
Signed-off-by: Eldad Zack <eldad@fogrefinery.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/drivers')
-rw-r--r-- | sound/drivers/aloop.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sound/drivers/aloop.c b/sound/drivers/aloop.c index 64d534710b51..6f78de9c6fb6 100644 --- a/sound/drivers/aloop.c +++ b/sound/drivers/aloop.c | |||
@@ -325,7 +325,7 @@ static void params_change(struct snd_pcm_substream *substream) | |||
325 | struct loopback_pcm *dpcm = runtime->private_data; | 325 | struct loopback_pcm *dpcm = runtime->private_data; |
326 | struct loopback_cable *cable = dpcm->cable; | 326 | struct loopback_cable *cable = dpcm->cable; |
327 | 327 | ||
328 | cable->hw.formats = (1ULL << runtime->format); | 328 | cable->hw.formats = pcm_format_to_bits(runtime->format); |
329 | cable->hw.rate_min = runtime->rate; | 329 | cable->hw.rate_min = runtime->rate; |
330 | cable->hw.rate_max = runtime->rate; | 330 | cable->hw.rate_max = runtime->rate; |
331 | cable->hw.channels_min = runtime->channels; | 331 | cable->hw.channels_min = runtime->channels; |