iio: accel: kxsd9: fix the usage of spi_w8r8()
authorLinus Walleij <linus.walleij@linaro.org>
Fri, 17 Jun 2016 13:22:24 +0000 (15:22 +0200)
committerJiri Slaby <jslaby@suse.cz>
Fri, 19 Aug 2016 07:50:48 +0000 (09:50 +0200)
commit95ac11690be655f4ff52586951eced513da9be12
tree93e0e418d7cdcf2228117b96b2b61c2a598dd806
parent14a450ef2462fbfe75822d82840fbbb7b8e5baff
iio: accel: kxsd9: fix the usage of spi_w8r8()

commit 0c1f91b98552da49d9d8eed32b3132a58d2f4598 upstream.

These two spi_w8r8() calls return a value with is used by the code
following the error check. The dubious use was caused by a cleanup
patch.

Fixes: d34dbee8ac8e ("staging:iio:accel:kxsd9 cleanup and conversion to iio_chan_spec.")
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
drivers/iio/accel/kxsd9.c