diff options
author | Amitoj Kaur Chawla <amitoj1606@gmail.com> | 2016-03-17 16:55:11 +0300 |
---|---|---|
committer | Jonathan Cameron <jic23@kernel.org> | 2016-03-20 14:04:49 +0300 |
commit | 9e61d901155bcd4e58cbce5eb4aaa8e870267334 (patch) | |
tree | b9c97373e65305451d3c4bbf4e26d0970e0b5e9e /drivers/iio/light | |
parent | 334ecdd0ba45bb68bce0f1429a4a1e9584ba437e (diff) | |
download | linux-9e61d901155bcd4e58cbce5eb4aaa8e870267334.tar.xz |
iio: light: tsl2563: Remove flush_scheduled_work
flush_scheduled_work is scheduled for deprecation.
Replace cancel_delayed_work and flush_scheduled_work with
cancel_delayed_work_sync instead to ensure there is no pending or
running work item.
Since there is only one work item, chip->poweroff_work, there are
no further dependencies of flush_scheduled_work().
Acked-by: Tejun Heo <tj@kernel.org>
Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
Diffstat (limited to 'drivers/iio/light')
-rw-r--r-- | drivers/iio/light/tsl2563.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/iio/light/tsl2563.c b/drivers/iio/light/tsl2563.c index 12731d6b89ec..57b108c30e98 100644 --- a/drivers/iio/light/tsl2563.c +++ b/drivers/iio/light/tsl2563.c @@ -806,8 +806,7 @@ static int tsl2563_probe(struct i2c_client *client, return 0; fail: - cancel_delayed_work(&chip->poweroff_work); - flush_scheduled_work(); + cancel_delayed_work_sync(&chip->poweroff_work); return err; } |