Commit 35407f9f authored by Kuninori Morimoto's avatar Kuninori Morimoto Committed by Mark Brown

ASoC: ak4118: use devm_snd_soc_register_component()

We have devm_xxx version of snd_soc_register_component,
let's use it.

This patch also removes related empty functions
Signed-off-by: default avatarKuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent 61c8a7d6
...@@ -400,14 +400,8 @@ static int ak4118_i2c_probe(struct i2c_client *i2c, ...@@ -400,14 +400,8 @@ static int ak4118_i2c_probe(struct i2c_client *i2c,
return ret; return ret;
} }
return snd_soc_register_component(&i2c->dev, &soc_component_drv_ak4118, return devm_snd_soc_register_component(&i2c->dev,
&ak4118_dai, 1); &soc_component_drv_ak4118, &ak4118_dai, 1);
}
static int ak4118_i2c_remove(struct i2c_client *i2c)
{
snd_soc_unregister_component(&i2c->dev);
return 0;
} }
static const struct of_device_id ak4118_of_match[] = { static const struct of_device_id ak4118_of_match[] = {
...@@ -429,7 +423,6 @@ static struct i2c_driver ak4118_i2c_driver = { ...@@ -429,7 +423,6 @@ static struct i2c_driver ak4118_i2c_driver = {
}, },
.id_table = ak4118_id_table, .id_table = ak4118_id_table,
.probe = ak4118_i2c_probe, .probe = ak4118_i2c_probe,
.remove = ak4118_i2c_remove,
}; };
module_i2c_driver(ak4118_i2c_driver); module_i2c_driver(ak4118_i2c_driver);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment