Message ID | 20240921181939.392517-2-vassilisamir@gmail.com (mailing list archive) |
---|---|
State | Rejected |
Headers | show |
Series | iio: core: remove iio_validate_own_trigger() function | expand |
Hi Vasileios, kernel test robot noticed the following build errors: [auto build test ERROR on 8bea3878a1511bceadc2fbf284b00bcc5a2ef28d] url: https://github.com/intel-lab-lkp/linux/commits/Vasileios-Amoiridis/iio-Drop-usage-of-iio_validate_own_trigger/20240922-022124 base: 8bea3878a1511bceadc2fbf284b00bcc5a2ef28d patch link: https://lore.kernel.org/r/20240921181939.392517-2-vassilisamir%40gmail.com patch subject: [PATCH v1 1/2] iio: Drop usage of iio_validate_own_trigger() config: x86_64-buildonly-randconfig-002-20240922 (https://download.01.org/0day-ci/archive/20240922/202409221122.4BTAc5w1-lkp@intel.com/config) compiler: clang version 18.1.8 (https://github.com/llvm/llvm-project 3b5b5c1ec4a3095ab096dd780e84d7ab81f3d7ff) reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240922/202409221122.4BTAc5w1-lkp@intel.com/reproduce) If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags | Reported-by: kernel test robot <lkp@intel.com> | Closes: https://lore.kernel.org/oe-kbuild-all/202409221122.4BTAc5w1-lkp@intel.com/ All errors (new ones prefixed by >>): >> drivers/iio/accel/kionix-kx022a.c:876:22: error: incompatible function pointer types initializing 'int (*)(struct iio_dev *, struct iio_trigger *)' with an expression of type 'int (struct iio_trigger *, struct iio_dev *)' [-Wincompatible-function-pointer-types] 876 | .validate_trigger = iio_trigger_validate_own_device, | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 1 error generated. -- >> drivers/iio/light/rohm-bu27008.c:1389:22: error: incompatible function pointer types initializing 'int (*)(struct iio_dev *, struct iio_trigger *)' with an expression of type 'int (struct iio_trigger *, struct iio_dev *)' [-Wincompatible-function-pointer-types] 1389 | .validate_trigger = iio_trigger_validate_own_device, | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 1 error generated. vim +876 drivers/iio/accel/kionix-kx022a.c 869 870 static const struct iio_info kx022a_info = { 871 .read_raw = &kx022a_read_raw, 872 .write_raw = &kx022a_write_raw, 873 .write_raw_get_fmt = &kx022a_write_raw_get_fmt, 874 .read_avail = &kx022a_read_avail, 875 > 876 .validate_trigger = iio_trigger_validate_own_device, 877 .hwfifo_set_watermark = kx022a_set_watermark, 878 .hwfifo_flush_to_buffer = kx022a_fifo_flush, 879 }; 880
Hi Vasileios, kernel test robot noticed the following build errors: [auto build test ERROR on 8bea3878a1511bceadc2fbf284b00bcc5a2ef28d] url: https://github.com/intel-lab-lkp/linux/commits/Vasileios-Amoiridis/iio-Drop-usage-of-iio_validate_own_trigger/20240922-022124 base: 8bea3878a1511bceadc2fbf284b00bcc5a2ef28d patch link: https://lore.kernel.org/r/20240921181939.392517-2-vassilisamir%40gmail.com patch subject: [PATCH v1 1/2] iio: Drop usage of iio_validate_own_trigger() config: arc-randconfig-002-20240922 (https://download.01.org/0day-ci/archive/20240922/202409221140.AyQ2zQ81-lkp@intel.com/config) compiler: arc-elf-gcc (GCC) 13.2.0 reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240922/202409221140.AyQ2zQ81-lkp@intel.com/reproduce) If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags | Reported-by: kernel test robot <lkp@intel.com> | Closes: https://lore.kernel.org/oe-kbuild-all/202409221140.AyQ2zQ81-lkp@intel.com/ All errors (new ones prefixed by >>): >> drivers/iio/light/rohm-bu27008.c:1389:29: error: initialization of 'int (*)(struct iio_dev *, struct iio_trigger *)' from incompatible pointer type 'int (*)(struct iio_trigger *, struct iio_dev *)' [-Werror=incompatible-pointer-types] 1389 | .validate_trigger = iio_trigger_validate_own_device, | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ drivers/iio/light/rohm-bu27008.c:1389:29: note: (near initialization for 'bu27008_info.validate_trigger') cc1: some warnings being treated as errors -- >> drivers/iio/accel/kionix-kx022a.c:876:35: error: initialization of 'int (*)(struct iio_dev *, struct iio_trigger *)' from incompatible pointer type 'int (*)(struct iio_trigger *, struct iio_dev *)' [-Werror=incompatible-pointer-types] 876 | .validate_trigger = iio_trigger_validate_own_device, | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ drivers/iio/accel/kionix-kx022a.c:876:35: note: (near initialization for 'kx022a_info.validate_trigger') cc1: some warnings being treated as errors vim +1389 drivers/iio/light/rohm-bu27008.c 1382 1383 static const struct iio_info bu27008_info = { 1384 .read_raw = &bu27008_read_raw, 1385 .write_raw = &bu27008_write_raw, 1386 .write_raw_get_fmt = &bu27008_write_raw_get_fmt, 1387 .read_avail = &bu27008_read_avail, 1388 .update_scan_mode = bu27008_update_scan_mode, > 1389 .validate_trigger = iio_trigger_validate_own_device, 1390 }; 1391
diff --git a/drivers/iio/accel/kionix-kx022a.c b/drivers/iio/accel/kionix-kx022a.c index 53d59a04ae15..0487610bab33 100644 --- a/drivers/iio/accel/kionix-kx022a.c +++ b/drivers/iio/accel/kionix-kx022a.c @@ -873,7 +873,7 @@ static const struct iio_info kx022a_info = { .write_raw_get_fmt = &kx022a_write_raw_get_fmt, .read_avail = &kx022a_read_avail, - .validate_trigger = iio_validate_own_trigger, + .validate_trigger = iio_trigger_validate_own_device, .hwfifo_set_watermark = kx022a_set_watermark, .hwfifo_flush_to_buffer = kx022a_fifo_flush, }; diff --git a/drivers/iio/industrialio-trigger.c b/drivers/iio/industrialio-trigger.c index 54416a384232..3da8b8c25185 100644 --- a/drivers/iio/industrialio-trigger.c +++ b/drivers/iio/industrialio-trigger.c @@ -315,7 +315,7 @@ int iio_trigger_attach_poll_func(struct iio_trigger *trig, * this is the case if the IIO device and the trigger device share the * same parent device. */ - if (!iio_validate_own_trigger(pf->indio_dev, trig)) + if (!iio_trigger_validate_own_device(trig, pf->indio_dev)) trig->attached_own_device = true; return ret; diff --git a/drivers/iio/light/rohm-bu27008.c b/drivers/iio/light/rohm-bu27008.c index 0f010eff1981..12cfaa7614ce 100644 --- a/drivers/iio/light/rohm-bu27008.c +++ b/drivers/iio/light/rohm-bu27008.c @@ -1386,7 +1386,7 @@ static const struct iio_info bu27008_info = { .write_raw_get_fmt = &bu27008_write_raw_get_fmt, .read_avail = &bu27008_read_avail, .update_scan_mode = bu27008_update_scan_mode, - .validate_trigger = iio_validate_own_trigger, + .validate_trigger = iio_trigger_validate_own_device, }; static int bu27008_trigger_set_state(struct iio_trigger *trig, bool state)
Change iio_validate_own_trigger() for iio_trigger_validate_own_device() since they are the same function. Signed-off-by: Vasileios Amoiridis <vassilisamir@gmail.com> --- drivers/iio/accel/kionix-kx022a.c | 2 +- drivers/iio/industrialio-trigger.c | 2 +- drivers/iio/light/rohm-bu27008.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) base-commit: 8bea3878a1511bceadc2fbf284b00bcc5a2ef28d