diff options
author | Eldad Zack <eldad@fogrefinery.com> | 2013-04-23 01:00:41 +0200 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2013-04-29 13:36:15 +0200 |
commit | 74c34ca1cc12884703c70d34ed333517d978c2e7 (patch) | |
tree | 6d06b76a9fbe829f2427899aa708d682167420c0 /sound/drivers | |
parent | ALSA: compress: fix the states to check for allowing read (diff) | |
download | linux-74c34ca1cc12884703c70d34ed333517d978c2e7.tar.xz linux-74c34ca1cc12884703c70d34ed333517d978c2e7.zip |
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) struct loopback_pcm *dpcm = runtime->private_data; struct loopback_cable *cable = dpcm->cable; - cable->hw.formats = (1ULL << runtime->format); + cable->hw.formats = pcm_format_to_bits(runtime->format); cable->hw.rate_min = runtime->rate; cable->hw.rate_max = runtime->rate; cable->hw.channels_min = runtime->channels; |