aboutsummaryrefslogtreecommitdiffstats
path: root/sound/aoa
diff options
context:
space:
mode:
authorEldad Zack <eldad@fogrefinery.com>2013-04-22 19:00:41 -0400
committerTakashi Iwai <tiwai@suse.de>2013-04-29 07:36:15 -0400
commit74c34ca1cc12884703c70d34ed333517d978c2e7 (patch)
tree6d06b76a9fbe829f2427899aa708d682167420c0 /sound/aoa
parent754813473c1a8b7711802313125f0fafc60141f8 (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/aoa')
-rw-r--r--sound/aoa/soundbus/i2sbus/pcm.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sound/aoa/soundbus/i2sbus/pcm.c b/sound/aoa/soundbus/i2sbus/pcm.c
index 19491ed9292f..7b74a4ba75f8 100644
--- a/sound/aoa/soundbus/i2sbus/pcm.c
+++ b/sound/aoa/soundbus/i2sbus/pcm.c
@@ -179,7 +179,7 @@ static int i2sbus_pcm_open(struct i2sbus_dev *i2sdev, int in)
179 */ 179 */
180 if (other->active) { 180 if (other->active) {
181 /* FIXME: is this guaranteed by the alsa api? */ 181 /* FIXME: is this guaranteed by the alsa api? */
182 hw->formats &= (1ULL << i2sdev->format); 182 hw->formats &= pcm_format_to_bits(i2sdev->format);
183 /* see above, restrict rates to the one we already have */ 183 /* see above, restrict rates to the one we already have */
184 hw->rate_min = i2sdev->rate; 184 hw->rate_min = i2sdev->rate;
185 hw->rate_max = i2sdev->rate; 185 hw->rate_max = i2sdev->rate;