diff options
author | Eva Rachel Retuya <eraretuya@gmail.com> | 2016-02-18 10:35:40 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2016-02-21 01:45:56 +0300 |
commit | ddab4a02c4771346eff5a0304c62e3377e8254ce (patch) | |
tree | c141e5c6e5316bd82bc6d8b67b9dbbf9c3fe255f /drivers/staging/iio | |
parent | e537daa198ed2b0f3336c340e9abd540fd95125d (diff) | |
download | linux-ddab4a02c4771346eff5a0304c62e3377e8254ce.tar.xz |
staging: iio: light: fix multiple assignments in a single line
Rewrite the multiple assignments to clear checkpatch check:
CHECK: multiple assignments should be avoided
Signed-off-by: Eva Rachel Retuya <eraretuya@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/iio')
-rw-r--r-- | drivers/staging/iio/light/tsl2583.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/staging/iio/light/tsl2583.c b/drivers/staging/iio/light/tsl2583.c index e970b3ff140e..05b4ad4e941c 100644 --- a/drivers/staging/iio/light/tsl2583.c +++ b/drivers/staging/iio/light/tsl2583.c @@ -267,7 +267,8 @@ static int taos_get_lux(struct iio_dev *indio_dev) if (!ch0) { /* have no data, so return LAST VALUE */ - ret = chip->als_cur_info.lux = 0; + ret = 0; + chip->als_cur_info.lux = 0; goto out_unlock; } /* calculate ratio */ @@ -292,7 +293,8 @@ static int taos_get_lux(struct iio_dev *indio_dev) /* note: lux is 31 bit max at this point */ if (ch1lux > ch0lux) { dev_dbg(&chip->client->dev, "No Data - Return last value\n"); - ret = chip->als_cur_info.lux = 0; + ret = 0; + chip->als_cur_info.lux = 0; goto out_unlock; } |