|
@@ -132,7 +132,8 @@ static int dmaengine_pcm_set_runtime_hwparams(struct snd_pcm_substream *substrea
|
|
|
u32 addr_widths = BIT(DMA_SLAVE_BUSWIDTH_1_BYTE) |
|
|
|
BIT(DMA_SLAVE_BUSWIDTH_2_BYTES) |
|
|
|
BIT(DMA_SLAVE_BUSWIDTH_4_BYTES);
|
|
|
- int i, ret;
|
|
|
+ snd_pcm_format_t i;
|
|
|
+ int ret;
|
|
|
|
|
|
if (pcm->config && pcm->config->pcm_hardware)
|
|
|
return snd_soc_set_runtime_hwparams(substream,
|
|
@@ -182,7 +183,7 @@ static int dmaengine_pcm_set_runtime_hwparams(struct snd_pcm_substream *substrea
|
|
|
* default assumption is that it supports 1, 2 and 4 bytes
|
|
|
* widths.
|
|
|
*/
|
|
|
- for (i = 0; i <= SNDRV_PCM_FORMAT_LAST; i++) {
|
|
|
+ for (i = SNDRV_PCM_FORMAT_FIRST; i <= SNDRV_PCM_FORMAT_LAST; i++) {
|
|
|
int bits = snd_pcm_format_physical_width(i);
|
|
|
|
|
|
/*
|