aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/input/touchscreen/wm97xx-core.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/input/touchscreen/wm97xx-core.c')
-rw-r--r--drivers/input/touchscreen/wm97xx-core.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/input/touchscreen/wm97xx-core.c b/drivers/input/touchscreen/wm97xx-core.c
index 2566b4d8b342..73856c2a8ac0 100644
--- a/drivers/input/touchscreen/wm97xx-core.c
+++ b/drivers/input/touchscreen/wm97xx-core.c
@@ -929,7 +929,8 @@ static int __init wm97xx_init(void)
static void __exit wm97xx_exit(void)
{
- driver_unregister(&wm97xx_driver);
+ if (IS_BUILTIN(CONFIG_AC97_BUS))
+ driver_unregister(&wm97xx_driver);
platform_driver_unregister(&wm97xx_mfd_driver);
}