]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
ASoC: rt5645: del btn_check_timer on remove
authorHans de Goede <hdegoede@redhat.com>
Wed, 28 Jun 2017 13:01:24 +0000 (15:01 +0200)
committerMark Brown <broonie@kernel.org>
Wed, 28 Jun 2017 17:34:46 +0000 (18:34 +0100)
The timer may still be running when rt5645_i2c_remove() gets called,
call del_timer_sync() to make sure it is stopped.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/codecs/rt5645.c

index 87844a45886a5f965d04abaeb670e28ab32efdee..206b41688d960d6930a45e5854c2810099ed1e83 100644 (file)
@@ -3897,6 +3897,7 @@ static int rt5645_i2c_remove(struct i2c_client *i2c)
 
        cancel_delayed_work_sync(&rt5645->jack_detect_work);
        cancel_delayed_work_sync(&rt5645->rcclock_work);
+       del_timer_sync(&rt5645->btn_check_timer);
 
        snd_soc_unregister_codec(&i2c->dev);
        regulator_bulk_disable(ARRAY_SIZE(rt5645->supplies), rt5645->supplies);