From: kernel test robot <lkp@intel.com>
To: Ciprian Regus <ciprian.regus@analog.com>,
jic23@kernel.org, robh+dt@kernel.org,
krzysztof.kozlowski+dt@linaro.org, linux-iio@vger.kernel.org,
devicetree@vger.kernel.org, linux-kernel@vger.kernel.org
Cc: llvm@lists.linux.dev, kbuild-all@lists.01.org,
Ciprian Regus <ciprian.regus@analog.com>
Subject: Re: [PATCH v2 4/5] drivers: iio: adc: LTC2499 support
Date: Fri, 2 Sep 2022 04:00:05 +0800 [thread overview]
Message-ID: <202209020359.vCYzjn4X-lkp@intel.com> (raw)
In-Reply-To: <20220901121700.1325733-4-ciprian.regus@analog.com>
Hi Ciprian,
Thank you for the patch! Yet something to improve:
[auto build test ERROR on jic23-iio/togreg]
[also build test ERROR on robh/for-next linus/master v6.0-rc3 next-20220901]
[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/Ciprian-Regus/dt-bindings-iio-adc-Add-docs-for-LTC2499/20220901-202115
base: https://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio.git togreg
config: hexagon-randconfig-r003-20220901 (https://download.01.org/0day-ci/archive/20220902/202209020359.vCYzjn4X-lkp@intel.com/config)
compiler: clang version 16.0.0 (https://github.com/llvm/llvm-project c55b41d5199d2394dd6cdb8f52180d8b81d809d4)
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://github.com/intel-lab-lkp/linux/commit/08ff9ae09bfde86fc512e13a4ea2af894e4aa442
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review Ciprian-Regus/dt-bindings-iio-adc-Add-docs-for-LTC2499/20220901-202115
git checkout 08ff9ae09bfde86fc512e13a4ea2af894e4aa442
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=hexagon SHELL=/bin/bash drivers/iio/adc/
If you fix the issue, kindly add following tag where applicable
Reported-by: kernel test robot <lkp@intel.com>
All errors (new ones prefixed by >>):
>> drivers/iio/adc/ltc2497.c:60:12: error: call to undeclared function 'get_unaligned_be24'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
*val = (get_unaligned_be24(st->data.d8) >> st->sub_lsb)
^
drivers/iio/adc/ltc2497.c:122:4: error: field designator 'name' does not refer to any field in type 'const struct ltc2497_chip_info'
.name = NULL,
^
drivers/iio/adc/ltc2497.c:126:4: error: field designator 'name' does not refer to any field in type 'const struct ltc2497_chip_info'
.name = "ltc2499",
^
3 errors generated.
vim +/get_unaligned_be24 +60 drivers/iio/adc/ltc2497.c
34
35 static int ltc2497_result_and_measure(struct ltc2497core_driverdata *ddata,
36 u8 address, int *val)
37 {
38 struct ltc2497_driverdata *st =
39 container_of(ddata, struct ltc2497_driverdata, common_ddata);
40 int ret;
41
42 if (val) {
43 if (st->recv_size == 3)
44 ret = i2c_master_recv(st->client, (char *)&st->data.d8, st->recv_size);
45 else
46 ret = i2c_master_recv(st->client, (char *)&st->data.d32, st->recv_size);
47
48 if (ret < 0) {
49 dev_err(&st->client->dev, "i2c_master_recv failed\n");
50 return ret;
51 }
52
53 /*
54 * The data format is 16/24 bit 2s complement, but with an upper sign bit on the
55 * resolution + 1 position, which is set for positive values only. Given this
56 * bit's value, subtracting BIT(resolution + 1) from the ADC's result is
57 * equivalent to a sign extension.
58 */
59 if (st->recv_size == 3) {
> 60 *val = (get_unaligned_be24(st->data.d8) >> st->sub_lsb)
61 - BIT(ddata->chip_info->resolution + 1);
62 } else {
63 *val = (be32_to_cpu(st->data.d32) >> st->sub_lsb)
64 - BIT(ddata->chip_info->resolution + 1);
65 }
66 }
67
68 ret = i2c_smbus_write_byte(st->client,
69 LTC2497_ENABLE | address);
70 if (ret)
71 dev_err(&st->client->dev, "i2c transfer failed: %pe\n",
72 ERR_PTR(ret));
73 return ret;
74 }
75
--
0-DAY CI Kernel Test Service
https://01.org/lkp
next prev parent reply other threads:[~2022-09-01 20:01 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-09-01 12:16 [PATCH v2 1/5] dt-bindings: iio: adc: Add docs for LTC2499 Ciprian Regus
2022-09-01 12:16 ` [PATCH v2 2/5] Add the LTC2496 MAINTAINERS entry Ciprian Regus
2022-09-04 14:54 ` Jonathan Cameron
2022-09-01 12:16 ` [PATCH v2 3/5] Remove duplicate matching entry Ciprian Regus
2022-09-01 12:16 ` [PATCH v2 4/5] drivers: iio: adc: LTC2499 support Ciprian Regus
2022-09-01 13:23 ` Krzysztof Kozlowski
2022-09-02 11:06 ` Jonathan Cameron
2022-09-02 11:37 ` Andy Shevchenko
2022-09-04 14:55 ` Jonathan Cameron
2022-09-05 8:58 ` Krzysztof Kozlowski
2022-09-01 20:00 ` kernel test robot [this message]
2022-09-04 15:08 ` Jonathan Cameron
2022-09-01 20:10 ` kernel test robot
2022-09-04 15:06 ` Jonathan Cameron
2022-09-01 12:17 ` [PATCH v2 5/5] drivers: iio: adc: Rename the LTC2499 iio device Ciprian Regus
2022-09-04 15:09 ` Jonathan Cameron
2022-09-01 13:27 ` [PATCH v2 1/5] dt-bindings: iio: adc: Add docs for LTC2499 Krzysztof Kozlowski
2022-09-04 14:53 ` Jonathan Cameron
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=202209020359.vCYzjn4X-lkp@intel.com \
--to=lkp@intel.com \
--cc=ciprian.regus@analog.com \
--cc=devicetree@vger.kernel.org \
--cc=jic23@kernel.org \
--cc=kbuild-all@lists.01.org \
--cc=krzysztof.kozlowski+dt@linaro.org \
--cc=linux-iio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=llvm@lists.linux.dev \
--cc=robh+dt@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).