From: kernel test robot <lkp@intel.com>
To: Laurent Pinchart <laurent.pinchart@ideasonboard.com>,
linux-iio@vger.kernel.org
Cc: kbuild-all@lists.01.org, Jonathan Cameron <jic23@kernel.org>,
Lars-Peter Clausen <lars@metafoo.de>,
Rob Herring <robh+dt@kernel.org>, Sean Nyekjaer <sean@geanix.com>,
devicetree@vger.kernel.org, Jose Cazarin <joseespiriki@gmail.com>,
linux-i2c@vger.kernel.org,
Wolfram Sang <wsa-dev@sang-engineering.com>
Subject: Re: [PATCH 2/2] iio: dac: dac5571: Fix chip id detection for OF devices
Date: Sat, 24 Jul 2021 07:06:38 +0800 [thread overview]
Message-ID: <202107240716.MQqdbrCA-lkp@intel.com> (raw)
In-Reply-To: <20210723183114.26017-3-laurent.pinchart@ideasonboard.com>
[-- Attachment #1: Type: text/plain, Size: 4176 bytes --]
Hi Laurent,
Thank you for the patch! Yet something to improve:
[auto build test ERROR on iio/togreg]
[also build test ERROR on robh/for-next v5.14-rc2 next-20210723]
[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]
url: https://github.com/0day-ci/linux/commits/Laurent-Pinchart/iio-ti-dac5571-Add-TI-DAC081C081-support/20210724-023333
base: https://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio.git togreg
config: arc-randconfig-r012-20210723 (attached as .config)
compiler: arceb-elf-gcc (GCC) 10.3.0
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/0day-ci/linux/commit/aea544dbbcecf5d723ede9b42a2da945ac5038f9
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Laurent-Pinchart/iio-ti-dac5571-Add-TI-DAC081C081-support/20210724-023333
git checkout aea544dbbcecf5d723ede9b42a2da945ac5038f9
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-10.3.0 make.cross ARCH=arc
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
All errors (new ones prefixed by >>):
drivers/iio/dac/ti-dac5571.c: In function 'dac5571_probe':
>> drivers/iio/dac/ti-dac5571.c:331:24: error: implicit declaration of function 'of_device_get_match_data'; did you mean 'device_get_match_data'? [-Werror=implicit-function-declaration]
331 | chip_id = (uintptr_t)of_device_get_match_data(dev);
| ^~~~~~~~~~~~~~~~~~~~~~~~
| device_get_match_data
cc1: some warnings being treated as errors
vim +331 drivers/iio/dac/ti-dac5571.c
306
307 static int dac5571_probe(struct i2c_client *client,
308 const struct i2c_device_id *id)
309 {
310 struct device *dev = &client->dev;
311 const struct dac5571_spec *spec;
312 struct dac5571_data *data;
313 struct iio_dev *indio_dev;
314 enum chip_id chip_id;
315 int ret, i;
316
317 indio_dev = devm_iio_device_alloc(dev, sizeof(*data));
318 if (!indio_dev)
319 return -ENOMEM;
320
321 data = iio_priv(indio_dev);
322 i2c_set_clientdata(client, indio_dev);
323 data->client = client;
324
325 indio_dev->info = &dac5571_info;
326 indio_dev->name = id->name;
327 indio_dev->modes = INDIO_DIRECT_MODE;
328 indio_dev->channels = dac5571_channels;
329
330 if (dev->of_node)
> 331 chip_id = (uintptr_t)of_device_get_match_data(dev);
332 else
333 chip_id = id->driver_data;
334
335 spec = &dac5571_spec[chip_id];
336
337 indio_dev->num_channels = spec->num_channels;
338 data->spec = spec;
339
340 data->vref = devm_regulator_get(dev, "vref");
341 if (IS_ERR(data->vref))
342 return PTR_ERR(data->vref);
343
344 ret = regulator_enable(data->vref);
345 if (ret < 0)
346 return ret;
347
348 mutex_init(&data->lock);
349
350 switch (spec->num_channels) {
351 case 1:
352 data->dac5571_cmd = dac5571_cmd_single;
353 data->dac5571_pwrdwn = dac5571_pwrdwn_single;
354 break;
355 case 4:
356 data->dac5571_cmd = dac5571_cmd_quad;
357 data->dac5571_pwrdwn = dac5571_pwrdwn_quad;
358 break;
359 default:
360 goto err;
361 }
362
363 for (i = 0; i < spec->num_channels; i++) {
364 ret = data->dac5571_cmd(data, i, 0);
365 if (ret) {
366 dev_err(dev, "failed to initialize channel %d to 0\n", i);
367 goto err;
368 }
369 }
370
371 ret = iio_device_register(indio_dev);
372 if (ret)
373 goto err;
374
375 return 0;
376
377 err:
378 regulator_disable(data->vref);
379 return ret;
380 }
381
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 33497 bytes --]
next prev parent reply other threads:[~2021-07-23 23:07 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-07-23 18:31 [PATCH 0/2] iio: ti-dac5571: Add TI DAC081C081 support Laurent Pinchart
2021-07-23 18:31 ` [PATCH 1/2] dt-bindings: iio: dac: ti,dac5571: " Laurent Pinchart
2021-07-29 21:26 ` Rob Herring
2021-07-23 18:31 ` [PATCH 2/2] iio: dac: dac5571: Fix chip id detection for OF devices Laurent Pinchart
2021-07-23 23:06 ` kernel test robot
2021-07-23 23:06 ` kernel test robot [this message]
2021-07-24 0:06 ` [PATCH v1.1 " Laurent Pinchart
2021-07-24 14:43 ` Jonathan Cameron
2021-07-24 23:14 ` Laurent Pinchart
2021-08-17 20:44 ` Wolfram Sang
2021-08-17 20:52 ` Laurent Pinchart
2021-08-17 20:58 ` Wolfram Sang
2021-08-17 21:20 ` Laurent Pinchart
2022-03-24 23:25 ` Laurent Pinchart
2022-03-28 9:20 ` Wolfram Sang
2022-03-28 10:04 ` Laurent Pinchart
2022-03-28 12:22 ` Wolfram Sang
2022-03-29 0:44 ` Laurent Pinchart
2022-03-29 8:59 ` Wolfram Sang
2021-07-24 14:44 ` 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=202107240716.MQqdbrCA-lkp@intel.com \
--to=lkp@intel.com \
--cc=devicetree@vger.kernel.org \
--cc=jic23@kernel.org \
--cc=joseespiriki@gmail.com \
--cc=kbuild-all@lists.01.org \
--cc=lars@metafoo.de \
--cc=laurent.pinchart@ideasonboard.com \
--cc=linux-i2c@vger.kernel.org \
--cc=linux-iio@vger.kernel.org \
--cc=robh+dt@kernel.org \
--cc=sean@geanix.com \
--cc=wsa-dev@sang-engineering.com \
/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).