Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 369a9f5f authored by Fang, Yang A's avatar Fang, Yang A Committed by Mark Brown
Browse files

ASoC: Intel: fix machine driver warnings



this patch will fix below sparse warnings

warning: incorrect type in argument 2 (different base types) expected
unsigned int [unsigned] val got restricted snd_pcm_format_t [usertype]
<noident>

sound/soc/intel/haswell.c:61:37
sound/soc/intel/broadwell.c:115:37:
sound/soc/intel/bytcr_dpcm_rt5640.c:118:37:
sound/soc/intel/cht_bsw_rt5672.c:183:37:
sound/soc/intel/cht_bsw_rt5645.c:208:37:

Signed-off-by: default avatarFang, Yang A <yang.a.fang@intel.com>
Reviewed-by: default avatarTakashi Iwai <tiwai@suse.de>
Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent 052a9f69
Loading
Loading
Loading
Loading
+1 −3
Original line number Diff line number Diff line
@@ -110,9 +110,7 @@ static int broadwell_ssp0_fixup(struct snd_soc_pcm_runtime *rtd,
	channels->min = channels->max = 2;

	/* set SSP0 to 16 bit */
	snd_mask_set(&params->masks[SNDRV_PCM_HW_PARAM_FORMAT -
				    SNDRV_PCM_HW_PARAM_FIRST_MASK],
				    SNDRV_PCM_FORMAT_S16_LE);
	params_set_format(params, SNDRV_PCM_FORMAT_S16_LE);
	return 0;
}

+1 −3
Original line number Diff line number Diff line
@@ -113,9 +113,7 @@ static int byt_codec_fixup(struct snd_soc_pcm_runtime *rtd,
	channels->min = channels->max = 2;

	/* set SSP2 to 24-bit */
	snd_mask_set(&params->masks[SNDRV_PCM_HW_PARAM_FORMAT -
				    SNDRV_PCM_HW_PARAM_FIRST_MASK],
				    SNDRV_PCM_FORMAT_S24_LE);
	params_set_format(params, SNDRV_PCM_FORMAT_S24_LE);
	return 0;
}

+1 −3
Original line number Diff line number Diff line
@@ -203,9 +203,7 @@ static int cht_codec_fixup(struct snd_soc_pcm_runtime *rtd,
	channels->min = channels->max = 2;

	/* set SSP2 to 24-bit */
	snd_mask_set(&params->masks[SNDRV_PCM_HW_PARAM_FORMAT -
				    SNDRV_PCM_HW_PARAM_FIRST_MASK],
				    SNDRV_PCM_FORMAT_S24_LE);
	params_set_format(params, SNDRV_PCM_FORMAT_S24_LE);
	return 0;
}

+1 −3
Original line number Diff line number Diff line
@@ -178,9 +178,7 @@ static int cht_codec_fixup(struct snd_soc_pcm_runtime *rtd,
	channels->min = channels->max = 2;

	/* set SSP2 to 24-bit */
	snd_mask_set(&params->masks[SNDRV_PCM_HW_PARAM_FORMAT -
				    SNDRV_PCM_HW_PARAM_FIRST_MASK],
				    SNDRV_PCM_FORMAT_S24_LE);
	params_set_format(params, SNDRV_PCM_FORMAT_S24_LE);
	return 0;
}

+1 −3
Original line number Diff line number Diff line
@@ -56,9 +56,7 @@ static int haswell_ssp0_fixup(struct snd_soc_pcm_runtime *rtd,
	channels->min = channels->max = 2;

	/* set SSP0 to 16 bit */
	snd_mask_set(&params->masks[SNDRV_PCM_HW_PARAM_FORMAT -
				    SNDRV_PCM_HW_PARAM_FIRST_MASK],
				    SNDRV_PCM_FORMAT_S16_LE);
	params_set_format(params, SNDRV_PCM_FORMAT_S16_LE);
	return 0;
}