From: kernel test robot <lkp@intel.com>
To: Kim Seer Paller <kimseer.paller@analog.com>,
linux-kernel@vger.kernel.org, linux-iio@vger.kernel.org,
devicetree@vger.kernel.org
Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev,
"Jonathan Cameron" <jic23@kernel.org>,
"David Lechner" <dlechner@baylibre.com>,
"Lars-Peter Clausen" <lars@metafoo.de>,
"Liam Girdwood" <lgirdwood@gmail.com>,
"Mark Brown" <broonie@kernel.org>,
"Dimitri Fedrau" <dima.fedrau@gmail.com>,
"Krzysztof Kozlowski" <krzk@kernel.org>,
"Rob Herring" <robh@kernel.org>,
"Conor Dooley" <conor+dt@kernel.org>,
"Michael Hennerich" <michael.hennerich@analog.com>,
"Nuno Sá" <noname.nuno@gmail.com>
Subject: Re: [PATCH v2 5/5] iio: dac: ltc2664: Add driver for LTC2664 and LTC2672
Date: Fri, 24 May 2024 11:28:10 +0800 [thread overview]
Message-ID: <202405241141.kYcxrSem-lkp@intel.com> (raw)
In-Reply-To: <20240523031909.19427-6-kimseer.paller@analog.com>
Hi Kim,
kernel test robot noticed the following build warnings:
[auto build test WARNING on 827dca3129708a8465bde90c86c2e3c38e62dd4f]
url: https://github.com/intel-lab-lkp/linux/commits/Kim-Seer-Paller/iio-ABI-Generalize-ABI-documentation-for-DAC/20240523-112246
base: 827dca3129708a8465bde90c86c2e3c38e62dd4f
patch link: https://lore.kernel.org/r/20240523031909.19427-6-kimseer.paller%40analog.com
patch subject: [PATCH v2 5/5] iio: dac: ltc2664: Add driver for LTC2664 and LTC2672
config: arm64-allmodconfig (https://download.01.org/0day-ci/archive/20240524/202405241141.kYcxrSem-lkp@intel.com/config)
compiler: clang version 19.0.0git (https://github.com/llvm/llvm-project 7aa382fd7257d9bd4f7fc50bb7078a3c26a1628c)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240524/202405241141.kYcxrSem-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/202405241141.kYcxrSem-lkp@intel.com/
All warnings (new ones prefixed by >>):
In file included from drivers/iio/dac/ltc2664.c:20:
In file included from include/linux/regulator/consumer.h:35:
In file included from include/linux/suspend.h:5:
In file included from include/linux/swap.h:9:
In file included from include/linux/memcontrol.h:21:
In file included from include/linux/mm.h:2208:
include/linux/vmstat.h:508:43: warning: arithmetic between different enumeration types ('enum zone_stat_item' and 'enum numa_stat_item') [-Wenum-enum-conversion]
508 | return vmstat_text[NR_VM_ZONE_STAT_ITEMS +
| ~~~~~~~~~~~~~~~~~~~~~ ^
509 | item];
| ~~~~
include/linux/vmstat.h:515:43: warning: arithmetic between different enumeration types ('enum zone_stat_item' and 'enum numa_stat_item') [-Wenum-enum-conversion]
515 | return vmstat_text[NR_VM_ZONE_STAT_ITEMS +
| ~~~~~~~~~~~~~~~~~~~~~ ^
516 | NR_VM_NUMA_EVENT_ITEMS +
| ~~~~~~~~~~~~~~~~~~~~~~
include/linux/vmstat.h:522:36: warning: arithmetic between different enumeration types ('enum node_stat_item' and 'enum lru_list') [-Wenum-enum-conversion]
522 | return node_stat_name(NR_LRU_BASE + lru) + 3; // skip "nr_"
| ~~~~~~~~~~~ ^ ~~~
include/linux/vmstat.h:527:43: warning: arithmetic between different enumeration types ('enum zone_stat_item' and 'enum numa_stat_item') [-Wenum-enum-conversion]
527 | return vmstat_text[NR_VM_ZONE_STAT_ITEMS +
| ~~~~~~~~~~~~~~~~~~~~~ ^
528 | NR_VM_NUMA_EVENT_ITEMS +
| ~~~~~~~~~~~~~~~~~~~~~~
include/linux/vmstat.h:536:43: warning: arithmetic between different enumeration types ('enum zone_stat_item' and 'enum numa_stat_item') [-Wenum-enum-conversion]
536 | return vmstat_text[NR_VM_ZONE_STAT_ITEMS +
| ~~~~~~~~~~~~~~~~~~~~~ ^
537 | NR_VM_NUMA_EVENT_ITEMS +
| ~~~~~~~~~~~~~~~~~~~~~~
>> drivers/iio/dac/ltc2664.c:627:8: warning: variable 'span' is uninitialized when used here [-Wuninitialized]
627 | if (span < 0)
| ^~~~
drivers/iio/dac/ltc2664.c:563:15: note: initialize the variable 'span' to silence this warning
563 | int ret, span;
| ^
| = 0
6 warnings generated.
vim +/span +627 drivers/iio/dac/ltc2664.c
557
558 static int ltc2664_channel_config(struct ltc2664_state *st)
559 {
560 const struct ltc2664_chip_info *chip_info = st->chip_info;
561 struct device *dev = &st->spi->dev;
562 u32 reg, tmp[2], mspan;
563 int ret, span;
564
565 mspan = LTC2664_MSPAN_SOFTSPAN;
566 ret = device_property_read_u32(dev, "adi,manual-span-operation-config",
567 &mspan);
568 if (!ret) {
569 if (!chip_info->manual_span_support)
570 return dev_err_probe(dev, -EINVAL,
571 "adi,manual-span-operation-config not supported\n");
572
573 if (mspan > ARRAY_SIZE(ltc2664_mspan_lut))
574 return dev_err_probe(dev, -EINVAL,
575 "adi,manual-span-operation-config not in range\n");
576 }
577
578 st->rfsadj = 20000;
579 ret = device_property_read_u32(dev, "adi,rfsadj-ohms", &st->rfsadj);
580 if (!ret) {
581 if (!chip_info->rfsadj_support)
582 return dev_err_probe(dev, -EINVAL,
583 "adi,rfsadj-ohms not supported\n");
584
585 if (st->rfsadj < 19000 || st->rfsadj > 41000)
586 return dev_err_probe(dev, -EINVAL,
587 "adi,rfsadj-ohms not in range\n");
588 }
589
590 device_for_each_child_node_scoped(dev, child) {
591 struct ltc2664_chan *chan;
592
593 ret = fwnode_property_read_u32(child, "reg", ®);
594 if (ret)
595 return dev_err_probe(dev, ret,
596 "Failed to get reg property\n");
597
598 if (reg >= chip_info->num_channels)
599 return dev_err_probe(dev, -EINVAL,
600 "reg bigger than: %d\n",
601 chip_info->num_channels);
602
603 chan = &st->channels[reg];
604
605 if (fwnode_property_read_bool(child, "adi,toggle-mode")) {
606 chan->toggle_chan = true;
607 /* assume sw toggle ABI */
608 st->iio_channels[reg].ext_info = ltc2664_toggle_sym_ext_info;
609 /*
610 * Clear IIO_CHAN_INFO_RAW bit as toggle channels expose
611 * out_voltage/current_raw{0|1} files.
612 */
613 __clear_bit(IIO_CHAN_INFO_RAW,
614 &st->iio_channels[reg].info_mask_separate);
615 }
616
617 chan->raw[0] = ltc2664_mspan_lut[mspan][1];
618 chan->raw[1] = ltc2664_mspan_lut[mspan][1];
619
620 chan->span = ltc2664_mspan_lut[mspan][0];
621
622 ret = fwnode_property_read_u32_array(child, "adi,output-range-microvolt",
623 tmp, ARRAY_SIZE(tmp));
624 if (!ret && mspan == LTC2664_MSPAN_SOFTSPAN) {
625 chan->span = ltc2664_set_span(st, tmp[0] / 1000,
626 tmp[1] / 1000, reg);
> 627 if (span < 0)
628 return dev_err_probe(dev, span,
629 "Failed to set span\n");
630
631 }
632
633 ret = fwnode_property_read_u32(child,
634 "adi,output-range-microamp",
635 &tmp[0]);
636 if (!ret) {
637 chan->span = ltc2664_set_span(st, 0, tmp[0] / 1000, reg);
638 if (span < 0)
639 return dev_err_probe(dev, span,
640 "Failed to set span\n");
641 }
642 }
643
644 return 0;
645 }
646
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
prev parent reply other threads:[~2024-05-24 3:28 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-05-23 3:19 [PATCH v2 0/5] Add driver for LTC2664 and LTC2672 Kim Seer Paller
2024-05-23 3:19 ` [PATCH v2 1/5] iio: ABI: Generalize ABI documentation for DAC Kim Seer Paller
2024-05-23 16:52 ` Jonathan Cameron
2024-05-23 3:19 ` [PATCH v2 2/5] iio: ABI: add DAC 42kohm_to_gnd powerdown mode Kim Seer Paller
2024-06-03 18:46 ` David Lechner
2024-05-23 3:19 ` [PATCH v2 3/5] dt-bindings: iio: dac: Add adi,ltc2664.yaml Kim Seer Paller
2024-05-23 6:39 ` Krzysztof Kozlowski
2024-05-24 6:28 ` Paller, Kim Seer
2024-05-25 16:49 ` Krzysztof Kozlowski
2024-05-25 17:17 ` Jonathan Cameron
2024-05-23 3:19 ` [PATCH v2 4/5] dt-bindings: iio: dac: Add adi,ltc2672.yaml Kim Seer Paller
2024-05-23 4:24 ` Rob Herring (Arm)
2024-05-23 12:33 ` Rob Herring
2024-05-23 3:19 ` [PATCH v2 5/5] iio: dac: ltc2664: Add driver for LTC2664 and LTC2672 Kim Seer Paller
2024-05-23 17:02 ` Jonathan Cameron
2024-05-28 5:53 ` Paller, Kim Seer
2024-06-02 13:13 ` Jonathan Cameron
2024-05-24 3:28 ` kernel test robot [this message]
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=202405241141.kYcxrSem-lkp@intel.com \
--to=lkp@intel.com \
--cc=broonie@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=dima.fedrau@gmail.com \
--cc=dlechner@baylibre.com \
--cc=jic23@kernel.org \
--cc=kimseer.paller@analog.com \
--cc=krzk@kernel.org \
--cc=lars@metafoo.de \
--cc=lgirdwood@gmail.com \
--cc=linux-iio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=llvm@lists.linux.dev \
--cc=michael.hennerich@analog.com \
--cc=noname.nuno@gmail.com \
--cc=oe-kbuild-all@lists.linux.dev \
--cc=robh@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