The feature GPIO implementation checks gpio_private when cleaning up the line-in and line-out notification IRQs.
However, ftr_set_notify() registers these IRQs using request_irq() and tracks the registered callbacks through the notify field. Check notify consistently for all notification IRQs so that registered line-in and line-out IRQs are released during teardown. Signed-off-by: Sreeraj S Kurup <[email protected]> --- sound/aoa/core/gpio-feature.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sound/aoa/core/gpio-feature.c b/sound/aoa/core/gpio-feature.c index 19ed0e6907da..2549b660caa4 100644 --- a/sound/aoa/core/gpio-feature.c +++ b/sound/aoa/core/gpio-feature.c @@ -285,9 +285,9 @@ static void ftr_gpio_exit(struct gpio_runtime *rt) rt->implementation_private = 0; if (rt->headphone_notify.notify) free_irq(headphone_detect_irq, &rt->headphone_notify); - if (rt->line_in_notify.gpio_private) + if (rt->line_in_notify.notify) free_irq(linein_detect_irq, &rt->line_in_notify); - if (rt->line_out_notify.gpio_private) + if (rt->line_out_notify.notify) free_irq(lineout_detect_irq, &rt->line_out_notify); cancel_delayed_work_sync(&rt->headphone_notify.work); cancel_delayed_work_sync(&rt->line_in_notify.work); -- 2.55.0
