Input: use input_device_enabled()

Use the newly added helper in relevant input drivers.

Signed-off-by: Andrzej Pietrasiewicz <andrzej.p@collabora.com>
Link: https://lore.kernel.org/r/20200608112211.12125-3-andrzej.p@collabora.com
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
This commit is contained in:
Andrzej Pietrasiewicz
2020-10-04 21:16:07 -07:00
committed by Dmitry Torokhov
parent 39be39ceff
commit d69f0a43c6
41 changed files with 96 additions and 90 deletions

View File

@@ -532,7 +532,7 @@ static int __maybe_unused zinitix_suspend(struct device *dev)
mutex_lock(&bt541->input_dev->mutex);
if (bt541->input_dev->users)
if (input_device_enabled(bt541->input_dev))
zinitix_stop(bt541);
mutex_unlock(&bt541->input_dev->mutex);
@@ -548,7 +548,7 @@ static int __maybe_unused zinitix_resume(struct device *dev)
mutex_lock(&bt541->input_dev->mutex);
if (bt541->input_dev->users)
if (input_device_enabled(bt541->input_dev))
ret = zinitix_start(bt541);
mutex_unlock(&bt541->input_dev->mutex);