Commit 44378cd1 authored by Duy Nguyen's avatar Duy Nguyen Committed by Mark Brown

ASoC: da7213.c: add missing pm_runtime_disable()

da7213.c is missing pm_runtime_disable(), thus we will get
below error when rmmod -> insmod.

	$ rmmod  snd-soc-da7213.ko
	$ insmod snd-soc-da7213.ko
	da7213 0-001a: Unbalanced pm_runtime_enable!"

[Kuninori adjusted to latest upstream]
Signed-off-by: default avatarDuy Nguyen <duy.nguyen.rh@renesas.com>
Signed-off-by: default avatarKuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Tested-by: default avatarKhanh Le <khanh.le.xr@renesas.com>
Link: https://lore.kernel.org/r/87mt3xg2tk.wl-kuninori.morimoto.gx@renesas.comSigned-off-by: default avatarMark Brown <broonie@kernel.org>
parent f6887a71
...@@ -2022,6 +2022,11 @@ static int da7213_i2c_probe(struct i2c_client *i2c) ...@@ -2022,6 +2022,11 @@ static int da7213_i2c_probe(struct i2c_client *i2c)
return ret; return ret;
} }
static void da7213_i2c_remove(struct i2c_client *i2c)
{
pm_runtime_disable(&i2c->dev);
}
static int __maybe_unused da7213_runtime_suspend(struct device *dev) static int __maybe_unused da7213_runtime_suspend(struct device *dev)
{ {
struct da7213_priv *da7213 = dev_get_drvdata(dev); struct da7213_priv *da7213 = dev_get_drvdata(dev);
...@@ -2065,6 +2070,7 @@ static struct i2c_driver da7213_i2c_driver = { ...@@ -2065,6 +2070,7 @@ static struct i2c_driver da7213_i2c_driver = {
.pm = &da7213_pm, .pm = &da7213_pm,
}, },
.probe_new = da7213_i2c_probe, .probe_new = da7213_i2c_probe,
.remove = da7213_i2c_remove,
.id_table = da7213_i2c_id, .id_table = da7213_i2c_id,
}; };
......
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