Re: [PATCH 03/12] staging: iio: tsl2x7x: add common function for reading chip status

2018-03-10 Thread Jonathan Cameron
On Sat, 3 Mar 2018 20:49:33 -0500 Brian Masney wrote: > There were three places where the same chunk of code was used to read > the chip status. This patch creates a common function > tsl2x7x_read_status() to reduce duplicate code. This patch also corrects > tsl2x7x_event_handler() to properly c

[PATCH 03/12] staging: iio: tsl2x7x: add common function for reading chip status

2018-03-03 Thread Brian Masney
There were three places where the same chunk of code was used to read the chip status. This patch creates a common function tsl2x7x_read_status() to reduce duplicate code. This patch also corrects tsl2x7x_event_handler() to properly check for an error after reading the chip status. Signed-off-by: