mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-11-24 02:40:52 +07:00
ASoC: sun8i-codec: Use snd_soc_dai_get_drvdata
Remove a level of indirection by getting the device directly from the passed-in struct snd_soc_dai, instead of going through its component. Signed-off-by: Samuel Holland <samuel@sholland.org> Acked-by: Maxime Ripard <mripard@kernel.org> Link: https://lore.kernel.org/r/20201001021148.15852-9-samuel@sholland.org Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
parent
18ebd62c30
commit
a886990c95
@ -167,7 +167,7 @@ static int sun8i_codec_get_hw_rate(struct snd_pcm_hw_params *params)
|
||||
|
||||
static int sun8i_set_fmt(struct snd_soc_dai *dai, unsigned int fmt)
|
||||
{
|
||||
struct sun8i_codec *scodec = snd_soc_component_get_drvdata(dai->component);
|
||||
struct sun8i_codec *scodec = snd_soc_dai_get_drvdata(dai);
|
||||
u32 value;
|
||||
|
||||
/* clock masters */
|
||||
@ -299,7 +299,7 @@ static int sun8i_codec_hw_params(struct snd_pcm_substream *substream,
|
||||
struct snd_pcm_hw_params *params,
|
||||
struct snd_soc_dai *dai)
|
||||
{
|
||||
struct sun8i_codec *scodec = snd_soc_component_get_drvdata(dai->component);
|
||||
struct sun8i_codec *scodec = snd_soc_dai_get_drvdata(dai);
|
||||
int sample_rate, lrck_div;
|
||||
u8 bclk_div;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user