From: Kuninori Morimoto kuninori.morimoto.gx@renesas.com
codec driver and component driver has duplicated .probe/.remove functions, and codec side is just relayed it. This was quick-hack, but no longer needed. This patch uses component .probe/.remove
Signed-off-by: Kuninori Morimoto kuninori.morimoto.gx@renesas.com --- sound/soc/codecs/es8328.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/sound/soc/codecs/es8328.c b/sound/soc/codecs/es8328.c index 37722194..19e8d7e 100644 --- a/sound/soc/codecs/es8328.c +++ b/sound/soc/codecs/es8328.c @@ -755,8 +755,9 @@ static int es8328_resume(struct snd_soc_codec *codec) return 0; }
-static int es8328_codec_probe(struct snd_soc_codec *codec) +static int es8328_codec_probe(struct snd_soc_component *component) { + struct snd_soc_codec *codec = snd_soc_component_to_codec(component); struct es8328_priv *es8328; int ret;
@@ -791,8 +792,9 @@ clk_fail: return ret; }
-static int es8328_remove(struct snd_soc_codec *codec) +static void es8328_remove(struct snd_soc_component *component) { + struct snd_soc_codec *codec = snd_soc_component_to_codec(component); struct es8328_priv *es8328;
es8328 = snd_soc_codec_get_drvdata(codec); @@ -802,8 +804,6 @@ static int es8328_remove(struct snd_soc_codec *codec)
regulator_bulk_disable(ARRAY_SIZE(es8328->supplies), es8328->supplies); - - return 0; }
const struct regmap_config es8328_regmap_config = { @@ -816,14 +816,14 @@ const struct regmap_config es8328_regmap_config = { EXPORT_SYMBOL_GPL(es8328_regmap_config);
static struct snd_soc_codec_driver es8328_codec_driver = { - .probe = es8328_codec_probe, .suspend = es8328_suspend, .resume = es8328_resume, - .remove = es8328_remove, .set_bias_level = es8328_set_bias_level, .suspend_bias_off = true,
.component_driver = { + .probe = es8328_codec_probe, + .remove = es8328_remove, .controls = es8328_snd_controls, .num_controls = ARRAY_SIZE(es8328_snd_controls), .dapm_widgets = es8328_dapm_widgets,