[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <202410052012.iy9nXdU8-lkp@intel.com>
Date: Sat, 5 Oct 2024 20:25:59 +0800
From: kernel test robot <lkp@...el.com>
To: Abhash Jha <abhashkumarjha123@...il.com>, linux-iio@...r.kernel.org
Cc: llvm@...ts.linux.dev, oe-kbuild-all@...ts.linux.dev, jic23@...nel.org,
lars@...afoo.de, linux-kernel@...r.kernel.org,
Abhash Jha <abhashkumarjha123@...il.com>
Subject: Re: [PATCH 1/3] iio: light: vl6180: Add configurable
inter-measurement period support
Hi Abhash,
kernel test robot noticed the following build errors:
[auto build test ERROR on jic23-iio/togreg]
[also build test ERROR on linus/master v6.12-rc1 next-20241004]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Abhash-Jha/iio-light-vl6180-Add-configurable-inter-measurement-period-support/20241004-230433
base: https://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio.git togreg
patch link: https://lore.kernel.org/r/20241004150148.14033-2-abhashkumarjha123%40gmail.com
patch subject: [PATCH 1/3] iio: light: vl6180: Add configurable inter-measurement period support
config: x86_64-buildonly-randconfig-001-20241005 (https://download.01.org/0day-ci/archive/20241005/202410052012.iy9nXdU8-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/20241005/202410052012.iy9nXdU8-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@...el.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202410052012.iy9nXdU8-lkp@intel.com/
All error/warnings (new ones prefixed by >>):
>> drivers/iio/light/vl6180.c:461:3: warning: label followed by a declaration is a C23 extension [-Wc23-extensions]
461 | guard(mutex)(&data->lock);
| ^
include/linux/cleanup.h:167:2: note: expanded from macro 'guard'
167 | CLASS(_name, __UNIQUE_ID(guard))
| ^
include/linux/cleanup.h:122:2: note: expanded from macro 'CLASS'
122 | class_##_name##_t var __cleanup(class_##_name##_destructor) = \
| ^
<scratch space>:101:1: note: expanded from here
101 | class_mutex_t
| ^
>> drivers/iio/light/vl6180.c:477:2: error: cannot jump from switch statement to this case label
477 | default:
| ^
drivers/iio/light/vl6180.c:461:3: note: jump bypasses initialization of variable with __attribute__((cleanup))
461 | guard(mutex)(&data->lock);
| ^
include/linux/cleanup.h:167:15: note: expanded from macro 'guard'
167 | CLASS(_name, __UNIQUE_ID(guard))
| ^
include/linux/compiler.h:189:29: note: expanded from macro '__UNIQUE_ID'
189 | #define __UNIQUE_ID(prefix) __PASTE(__PASTE(__UNIQUE_ID_, prefix), __COUNTER__)
| ^
include/linux/compiler_types.h:84:22: note: expanded from macro '__PASTE'
84 | #define __PASTE(a,b) ___PASTE(a,b)
| ^
include/linux/compiler_types.h:83:23: note: expanded from macro '___PASTE'
83 | #define ___PASTE(a,b) a##b
| ^
<scratch space>:99:1: note: expanded from here
99 | __UNIQUE_ID_guard385
| ^
1 warning and 1 error generated.
vim +477 drivers/iio/light/vl6180.c
006f437eee8f94 Abhash Jha 2024-10-04 442
5e7f47e495ad36 Manivannan Sadhasivam 2017-03-19 443 static int vl6180_write_raw(struct iio_dev *indio_dev,
5e7f47e495ad36 Manivannan Sadhasivam 2017-03-19 444 struct iio_chan_spec const *chan,
5e7f47e495ad36 Manivannan Sadhasivam 2017-03-19 445 int val, int val2, long mask)
5e7f47e495ad36 Manivannan Sadhasivam 2017-03-19 446 {
5e7f47e495ad36 Manivannan Sadhasivam 2017-03-19 447 struct vl6180_data *data = iio_priv(indio_dev);
006f437eee8f94 Abhash Jha 2024-10-04 448 unsigned int reg_val;
5e7f47e495ad36 Manivannan Sadhasivam 2017-03-19 449
5e7f47e495ad36 Manivannan Sadhasivam 2017-03-19 450 switch (mask) {
5e7f47e495ad36 Manivannan Sadhasivam 2017-03-19 451 case IIO_CHAN_INFO_INT_TIME:
1e2ed3d0d27d80 Stefan BrĂ¼ns 2017-09-24 452 return vl6180_set_it(data, val, val2);
5e7f47e495ad36 Manivannan Sadhasivam 2017-03-19 453
5e7f47e495ad36 Manivannan Sadhasivam 2017-03-19 454 case IIO_CHAN_INFO_HARDWAREGAIN:
5e7f47e495ad36 Manivannan Sadhasivam 2017-03-19 455 if (chan->type != IIO_LIGHT)
5e7f47e495ad36 Manivannan Sadhasivam 2017-03-19 456 return -EINVAL;
5e7f47e495ad36 Manivannan Sadhasivam 2017-03-19 457
5e7f47e495ad36 Manivannan Sadhasivam 2017-03-19 458 return vl6180_set_als_gain(data, val, val2);
006f437eee8f94 Abhash Jha 2024-10-04 459
006f437eee8f94 Abhash Jha 2024-10-04 460 case IIO_CHAN_INFO_SAMP_FREQ:
006f437eee8f94 Abhash Jha 2024-10-04 @461 guard(mutex)(&data->lock);
006f437eee8f94 Abhash Jha 2024-10-04 462 switch (chan->type) {
006f437eee8f94 Abhash Jha 2024-10-04 463 case IIO_DISTANCE:
006f437eee8f94 Abhash Jha 2024-10-04 464 data->range_meas_rate = val;
006f437eee8f94 Abhash Jha 2024-10-04 465 reg_val = vl6180_meas_reg_val_from_ms(val);
006f437eee8f94 Abhash Jha 2024-10-04 466 return vl6180_write_byte(data->client, VL6180_RANGE_INTER_MEAS_TIME, reg_val);
006f437eee8f94 Abhash Jha 2024-10-04 467
006f437eee8f94 Abhash Jha 2024-10-04 468 case IIO_LIGHT:
006f437eee8f94 Abhash Jha 2024-10-04 469 data->als_meas_rate = val;
006f437eee8f94 Abhash Jha 2024-10-04 470 reg_val = vl6180_meas_reg_val_from_ms(val);
006f437eee8f94 Abhash Jha 2024-10-04 471 return vl6180_write_byte(data->client, VL6180_ALS_INTER_MEAS_TIME, reg_val);
006f437eee8f94 Abhash Jha 2024-10-04 472
006f437eee8f94 Abhash Jha 2024-10-04 473 default:
006f437eee8f94 Abhash Jha 2024-10-04 474 return -EINVAL;
006f437eee8f94 Abhash Jha 2024-10-04 475 }
006f437eee8f94 Abhash Jha 2024-10-04 476
5e7f47e495ad36 Manivannan Sadhasivam 2017-03-19 @477 default:
5e7f47e495ad36 Manivannan Sadhasivam 2017-03-19 478 return -EINVAL;
5e7f47e495ad36 Manivannan Sadhasivam 2017-03-19 479 }
5e7f47e495ad36 Manivannan Sadhasivam 2017-03-19 480 }
5e7f47e495ad36 Manivannan Sadhasivam 2017-03-19 481
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
Powered by blists - more mailing lists