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

Configure Feed

Select the types of activity you want to include in your feed.

iio: proximity: irsd200: simplify code in write_event_config callback

iio_ev_state_store is actually using kstrtobool to check user
input, then gives the converted boolean value to the write_event_config
callback.

Remove useless code in write_event_config callback.

Signed-off-by: Julien Stephan <jstephan@baylibre.com>
Link: https://patch.msgid.link/20241031-iio-fix-write-event-config-signature-v2-4-2bcacbb517a2@baylibre.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>

authored by

Julien Stephan and committed by
Jonathan Cameron
63023e8a e41edccb

+1 -1
+1 -1
drivers/iio/proximity/irsd200.c
··· 662 662 return ret; 663 663 664 664 return regmap_field_write( 665 - data->regfields[IRS_REGF_INTR_COUNT_THR_OR], !!state); 665 + data->regfields[IRS_REGF_INTR_COUNT_THR_OR], state); 666 666 default: 667 667 return -EINVAL; 668 668 }