summaryrefslogtreecommitdiff
path: root/sound
diff options
context:
space:
mode:
Diffstat (limited to 'sound')
-rw-r--r--sound/soc/codecs/rt5639.c1
-rw-r--r--sound/soc/codecs/rt5640.c1
-rw-r--r--sound/soc/codecs/rt5645.c2
3 files changed, 4 insertions, 0 deletions
diff --git a/sound/soc/codecs/rt5639.c b/sound/soc/codecs/rt5639.c
index 6aebb6463c29..e9a5a4db3538 100644
--- a/sound/soc/codecs/rt5639.c
+++ b/sound/soc/codecs/rt5639.c
@@ -3148,6 +3148,7 @@ static int rt5639_probe(struct snd_soc_codec *codec)
static int rt5639_remove(struct snd_soc_codec *codec)
{
rt5639_set_bias_level(codec, SND_SOC_BIAS_OFF);
+ device_remove_file(codec->dev, &dev_attr_index_reg);
return 0;
}
diff --git a/sound/soc/codecs/rt5640.c b/sound/soc/codecs/rt5640.c
index 30932cb20e50..65d213b2dc5d 100644
--- a/sound/soc/codecs/rt5640.c
+++ b/sound/soc/codecs/rt5640.c
@@ -2824,6 +2824,7 @@ static int rt5640_remove(struct snd_soc_codec *codec)
CHECK_I2C_SHUTDOWN(rt5640, codec)
rt5640_reset(codec);
snd_soc_write(codec, RT5640_PWR_ANLG1, 0);
+ device_remove_file(codec->dev, &dev_attr_index_reg);
mutex_unlock(&rt5640->lock);
return 0;
diff --git a/sound/soc/codecs/rt5645.c b/sound/soc/codecs/rt5645.c
index 689e7bd7f1f7..0fde9c09c1c2 100644
--- a/sound/soc/codecs/rt5645.c
+++ b/sound/soc/codecs/rt5645.c
@@ -3598,6 +3598,8 @@ static int rt5645_probe(struct snd_soc_codec *codec)
static int rt5645_remove(struct snd_soc_codec *codec)
{
rt5645_set_bias_level(codec, SND_SOC_BIAS_OFF);
+ device_remove_file(codec->dev, &dev_attr_codec_reg);
+ device_remove_file(codec->dev, &dev_attr_index_reg);
return 0;
}