ASoC: hdmi-codec: avoid limiting params->msbits in hw_params()

Limiting the value of the passed in params->msbits in the hw_params()
callback is redundant on three counts:

1. We already specify in the DAI driver that we can only handle up to
   24 bits.  This means msbits will be limited to 24 via the ALSA
   constraints imposed by the ASoC core, unless we have multiple codecs
   that can handle more bits.

2. Nothing in our hw_params() implementation uses this value.

3. The copy of the params that we are passed by the ASoC core never
   reads back the msbits value.

Consequently, this code is unnecessary and does nothing useful.  Remove
it.

Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
Reviewed-by: Jyri Sarha <jsarha@ti.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
Russell King 2019-02-28 15:30:40 +00:00 коммит произвёл Mark Brown
Родитель ba54f278c3
Коммит bbf62563d8
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 24D68B725D5487D0
1 изменённых файлов: 0 добавлений и 3 удалений

Просмотреть файл

@ -484,9 +484,6 @@ static int hdmi_codec_hw_params(struct snd_pcm_substream *substream,
params_width(params), params_rate(params),
params_channels(params));
if (params_width(params) > 24)
params->msbits = 24;
ret = snd_pcm_create_iec958_consumer_hw_params(params, hp.iec.status,
sizeof(hp.iec.status));
if (ret < 0) {