From: Mark Brown Date: Thu, 31 Jul 2014 11:28:13 +0000 (+0100) Subject: ASoC: 88pm860x: Convert to params_width() X-Git-Tag: v3.17-rc1~101^2~5^2~1^3~55 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=0caf3eb7213a14b44977d1ca4b69d7f3d7fd474a;p=karo-tx-linux.git ASoC: 88pm860x: Convert to params_width() The CODEC doesn't care how data is laid out in memory. Signed-off-by: Mark Brown --- diff --git a/sound/soc/codecs/88pm860x-codec.c b/sound/soc/codecs/88pm860x-codec.c index 3c4b10ff48c1..922006dd0583 100644 --- a/sound/soc/codecs/88pm860x-codec.c +++ b/sound/soc/codecs/88pm860x-codec.c @@ -945,11 +945,11 @@ static int pm860x_pcm_hw_params(struct snd_pcm_substream *substream, unsigned char inf = 0, mask = 0; /* bit size */ - switch (params_format(params)) { - case SNDRV_PCM_FORMAT_S16_LE: + switch (params_width(params)) { + case 16: inf &= ~PCM_INF2_18WL; break; - case SNDRV_PCM_FORMAT_S18_3LE: + case 18: inf |= PCM_INF2_18WL; break; default: @@ -1044,11 +1044,11 @@ static int pm860x_i2s_hw_params(struct snd_pcm_substream *substream, unsigned char inf; /* bit size */ - switch (params_format(params)) { - case SNDRV_PCM_FORMAT_S16_LE: + switch (params_width(params)) { + case 16: inf = 0; break; - case SNDRV_PCM_FORMAT_S18_3LE: + case 18: inf = PCM_INF2_18WL; break; default: