Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

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 <bfreed@chromium.org>
Acked-by: Jonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>

authored by

Bryan Freed and committed by
Greg Kroah-Hartman
9e4216fd 8f518d71

+2
+2
drivers/staging/iio/light/tsl2563.c
··· 691 691 692 692 static const struct iio_info tsl2563_info_no_irq = { 693 693 .driver_module = THIS_MODULE, 694 + .read_raw = &tsl2563_read_raw, 695 + .write_raw = &tsl2563_write_raw, 694 696 }; 695 697 696 698 static const struct iio_info tsl2563_info = {