* [linux-next:master 4017/6533] drivers/iio/adc/ingenic-adc.c:657 ingenic_adc_read_chan_info_raw() error: uninitialized symbol 'cmd'.
@ 2021-08-10 23:30 kernel test robot
0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2021-08-10 23:30 UTC (permalink / raw)
To: kbuild
[-- Attachment #1: Type: text/plain, Size: 5393 bytes --]
CC: kbuild-all(a)lists.01.org
CC: Linux Memory Management List <linux-mm@kvack.org>
TO: Christophe Branchereau <cbranchereau@gmail.com>
CC: Jonathan Cameron <Jonathan.Cameron@huawei.com>
CC: Paul Cercueil <paul@crapouillou.net>
tree: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head: 92d00774360dfd4151f15ab9905c643347b9f242
commit: b9e9bdd425a3c99e15f5dfd465bef936130b7491 [4017/6533] iio/adc: ingenic: add JZ4760 support to the sadc driver
:::::: branch date: 15 hours ago
:::::: commit date: 10 days ago
config: openrisc-randconfig-m031-20210811 (attached as .config)
compiler: or1k-linux-gcc (GCC) 10.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
smatch warnings:
drivers/iio/adc/ingenic-adc.c:657 ingenic_adc_read_chan_info_raw() error: uninitialized symbol 'cmd'.
vim +/cmd +657 drivers/iio/adc/ingenic-adc.c
1a78daea107ddb Artur Rojek 2019-02-04 627
1a99dc467943c0 Artur Rojek 2020-07-19 628 static int ingenic_adc_read_chan_info_raw(struct iio_dev *iio_dev,
1a78daea107ddb Artur Rojek 2019-02-04 629 struct iio_chan_spec const *chan,
a515d648850546 Artur Rojek 2019-07-27 630 int *val)
1a78daea107ddb Artur Rojek 2019-02-04 631 {
b9e9bdd425a3c9 Christophe Branchereau 2021-07-26 632 int cmd, ret, engine = (chan->channel == INGENIC_ADC_BATTERY);
1a99dc467943c0 Artur Rojek 2020-07-19 633 struct ingenic_adc *adc = iio_priv(iio_dev);
1a99dc467943c0 Artur Rojek 2020-07-19 634
1a99dc467943c0 Artur Rojek 2020-07-19 635 ret = clk_enable(adc->clk);
1a99dc467943c0 Artur Rojek 2020-07-19 636 if (ret) {
1a99dc467943c0 Artur Rojek 2020-07-19 637 dev_err(iio_dev->dev.parent, "Failed to enable clock: %d\n",
1a99dc467943c0 Artur Rojek 2020-07-19 638 ret);
1a99dc467943c0 Artur Rojek 2020-07-19 639 return ret;
1a99dc467943c0 Artur Rojek 2020-07-19 640 }
1a78daea107ddb Artur Rojek 2019-02-04 641
b9e9bdd425a3c9 Christophe Branchereau 2021-07-26 642 /* We cannot sample the aux channels in parallel. */
a515d648850546 Artur Rojek 2019-07-27 643 mutex_lock(&adc->aux_lock);
9c5eb724f96f8d Christophe Branchereau 2021-07-26 644 if (adc->soc_data->has_aux_md && engine == 0) {
b9e9bdd425a3c9 Christophe Branchereau 2021-07-26 645 switch (chan->channel) {
b9e9bdd425a3c9 Christophe Branchereau 2021-07-26 646 case INGENIC_ADC_AUX0:
b9e9bdd425a3c9 Christophe Branchereau 2021-07-26 647 cmd = 0;
b9e9bdd425a3c9 Christophe Branchereau 2021-07-26 648 break;
b9e9bdd425a3c9 Christophe Branchereau 2021-07-26 649 case INGENIC_ADC_AUX:
b9e9bdd425a3c9 Christophe Branchereau 2021-07-26 650 cmd = 1;
b9e9bdd425a3c9 Christophe Branchereau 2021-07-26 651 break;
b9e9bdd425a3c9 Christophe Branchereau 2021-07-26 652 case INGENIC_ADC_AUX2:
b9e9bdd425a3c9 Christophe Branchereau 2021-07-26 653 cmd = 2;
b9e9bdd425a3c9 Christophe Branchereau 2021-07-26 654 break;
b9e9bdd425a3c9 Christophe Branchereau 2021-07-26 655 }
b9e9bdd425a3c9 Christophe Branchereau 2021-07-26 656
b9e9bdd425a3c9 Christophe Branchereau 2021-07-26 @657 ingenic_adc_set_config(adc, JZ_ADC_REG_CFG_AUX_MD, cmd);
1a78daea107ddb Artur Rojek 2019-02-04 658 }
1a78daea107ddb Artur Rojek 2019-02-04 659
a515d648850546 Artur Rojek 2019-07-27 660 ret = ingenic_adc_capture(adc, engine);
a515d648850546 Artur Rojek 2019-07-27 661 if (ret)
a515d648850546 Artur Rojek 2019-07-27 662 goto out;
a515d648850546 Artur Rojek 2019-07-27 663
1a78daea107ddb Artur Rojek 2019-02-04 664 switch (chan->channel) {
b9e9bdd425a3c9 Christophe Branchereau 2021-07-26 665 case INGENIC_ADC_AUX0:
1a78daea107ddb Artur Rojek 2019-02-04 666 case INGENIC_ADC_AUX:
a515d648850546 Artur Rojek 2019-07-27 667 case INGENIC_ADC_AUX2:
1a78daea107ddb Artur Rojek 2019-02-04 668 *val = readw(adc->base + JZ_ADC_REG_ADSDAT);
1a78daea107ddb Artur Rojek 2019-02-04 669 break;
1a78daea107ddb Artur Rojek 2019-02-04 670 case INGENIC_ADC_BATTERY:
1a78daea107ddb Artur Rojek 2019-02-04 671 *val = readw(adc->base + JZ_ADC_REG_ADBDAT);
1a78daea107ddb Artur Rojek 2019-02-04 672 break;
1a78daea107ddb Artur Rojek 2019-02-04 673 }
1a78daea107ddb Artur Rojek 2019-02-04 674
a515d648850546 Artur Rojek 2019-07-27 675 ret = IIO_VAL_INT;
a515d648850546 Artur Rojek 2019-07-27 676 out:
a515d648850546 Artur Rojek 2019-07-27 677 mutex_unlock(&adc->aux_lock);
1a99dc467943c0 Artur Rojek 2020-07-19 678 clk_disable(adc->clk);
1a78daea107ddb Artur Rojek 2019-02-04 679
a515d648850546 Artur Rojek 2019-07-27 680 return ret;
a515d648850546 Artur Rojek 2019-07-27 681 }
a515d648850546 Artur Rojek 2019-07-27 682
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 27410 bytes --]
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2021-08-10 23:30 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-10 23:30 [linux-next:master 4017/6533] drivers/iio/adc/ingenic-adc.c:657 ingenic_adc_read_chan_info_raw() error: uninitialized symbol 'cmd' kernel test robot
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.