diff options
author | Andrzej Pietrasiewicz <andrzej.p@collabora.com> | 2020-10-05 07:16:07 +0300 |
---|---|---|
committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2020-12-03 09:10:33 +0300 |
commit | d69f0a43c677e8afc67a222e1e7b51b9acc69cd3 (patch) | |
tree | 1b03a8d3ed76cb507f344c85cd0d0c474e6b7fa3 /drivers/input/touchscreen/bu21029_ts.c | |
parent | 39be39ceffd572baddfeff8b50aba931d3d6d785 (diff) | |
download | linux-d69f0a43c677e8afc67a222e1e7b51b9acc69cd3.tar.xz |
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>
Diffstat (limited to 'drivers/input/touchscreen/bu21029_ts.c')
-rw-r--r-- | drivers/input/touchscreen/bu21029_ts.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/input/touchscreen/bu21029_ts.c b/drivers/input/touchscreen/bu21029_ts.c index 49a8d4bbca3a..341925edb8e6 100644 --- a/drivers/input/touchscreen/bu21029_ts.c +++ b/drivers/input/touchscreen/bu21029_ts.c @@ -430,7 +430,7 @@ static int __maybe_unused bu21029_suspend(struct device *dev) if (!device_may_wakeup(dev)) { mutex_lock(&bu21029->in_dev->mutex); - if (bu21029->in_dev->users) + if (input_device_enabled(bu21029->in_dev)) bu21029_stop_chip(bu21029->in_dev); mutex_unlock(&bu21029->in_dev->mutex); } @@ -445,7 +445,7 @@ static int __maybe_unused bu21029_resume(struct device *dev) if (!device_may_wakeup(dev)) { mutex_lock(&bu21029->in_dev->mutex); - if (bu21029->in_dev->users) + if (input_device_enabled(bu21029->in_dev)) bu21029_start_chip(bu21029->in_dev); mutex_unlock(&bu21029->in_dev->mutex); } |