From: Bryan Freed Date: Tue, 21 Jun 2011 22:54:57 +0000 (-0700) Subject: iio: light sensor: Fix a panic in the tsl2563 driver. X-Git-Tag: MMI-PSA29.97-13-9~18845^2~432 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=9e4216fd6a547261c54bede60108347646c95a69;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git iio: light sensor: Fix a panic in the tsl2563 driver. Add the required read/write_raw functions to the tsl2563_info_no_irq data structure. This structure is used insted of tsl2563_info when the I2C client has no IRQ. The absence of these functions causes a panic when reading or writing the created sysfs files. Signed-off-by: Bryan Freed Acked-by: Jonathan Cameron Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/iio/light/tsl2563.c b/drivers/staging/iio/light/tsl2563.c index c47341212382..98ea6afc5cc8 100644 --- a/drivers/staging/iio/light/tsl2563.c +++ b/drivers/staging/iio/light/tsl2563.c @@ -691,6 +691,8 @@ static struct i2c_driver tsl2563_i2c_driver; static const struct iio_info tsl2563_info_no_irq = { .driver_module = THIS_MODULE, + .read_raw = &tsl2563_read_raw, + .write_raw = &tsl2563_write_raw, }; static const struct iio_info tsl2563_info = {