linux-input.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Dzmitry Sankouski <dsankouski@gmail.com>,
	Sebastian Reichel <sre@kernel.org>,
	Chanwoo Choi <cw00.choi@samsung.com>,
	Krzysztof Kozlowski <krzk@kernel.org>, Lee Jones <lee@kernel.org>,
	Rob Herring <robh@kernel.org>, Conor Dooley <conor+dt@kernel.org>,
	Dmitry Torokhov <dmitry.torokhov@gmail.com>,
	Pavel Machek <pavel@ucw.cz>
Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev,
	linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org,
	devicetree@vger.kernel.org, linux-input@vger.kernel.org,
	linux-leds@vger.kernel.org,
	Dzmitry Sankouski <dsankouski@gmail.com>
Subject: Re: [PATCH v8 3/7] mfd: Add new driver for MAX77705 PMIC
Date: Sun, 3 Nov 2024 03:55:24 +0800	[thread overview]
Message-ID: <202411030141.DTmej8oX-lkp@intel.com> (raw)
In-Reply-To: <20241031-starqltechn_integration_upstream-v8-3-2fa666c2330e@gmail.com>

Hi Dzmitry,

kernel test robot noticed the following build warnings:

[auto build test WARNING on 86e3904dcdc7e70e3257fc1de294a1b75f3d8d04]

url:    https://github.com/intel-lab-lkp/linux/commits/Dzmitry-Sankouski/power-supply-add-undervoltage-health-status-property/20241031-053513
base:   86e3904dcdc7e70e3257fc1de294a1b75f3d8d04
patch link:    https://lore.kernel.org/r/20241031-starqltechn_integration_upstream-v8-3-2fa666c2330e%40gmail.com
patch subject: [PATCH v8 3/7] mfd: Add new driver for MAX77705 PMIC
config: x86_64-allyesconfig (https://download.01.org/0day-ci/archive/20241103/202411030141.DTmej8oX-lkp@intel.com/config)
compiler: clang version 19.1.3 (https://github.com/llvm/llvm-project ab51eccf88f5321e7c60591c5546b254b6afab99)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20241103/202411030141.DTmej8oX-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/202411030141.DTmej8oX-lkp@intel.com/

All warnings (new ones prefixed by >>):

   In file included from drivers/mfd/max77705.c:8:
   In file included from include/linux/i2c.h:19:
   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:2223:
   include/linux/vmstat.h:504:43: warning: arithmetic between different enumeration types ('enum zone_stat_item' and 'enum numa_stat_item') [-Wenum-enum-conversion]
     504 |         return vmstat_text[NR_VM_ZONE_STAT_ITEMS +
         |                            ~~~~~~~~~~~~~~~~~~~~~ ^
     505 |                            item];
         |                            ~~~~
   include/linux/vmstat.h:511:43: warning: arithmetic between different enumeration types ('enum zone_stat_item' and 'enum numa_stat_item') [-Wenum-enum-conversion]
     511 |         return vmstat_text[NR_VM_ZONE_STAT_ITEMS +
         |                            ~~~~~~~~~~~~~~~~~~~~~ ^
     512 |                            NR_VM_NUMA_EVENT_ITEMS +
         |                            ~~~~~~~~~~~~~~~~~~~~~~
   include/linux/vmstat.h:518:36: warning: arithmetic between different enumeration types ('enum node_stat_item' and 'enum lru_list') [-Wenum-enum-conversion]
     518 |         return node_stat_name(NR_LRU_BASE + lru) + 3; // skip "nr_"
         |                               ~~~~~~~~~~~ ^ ~~~
   include/linux/vmstat.h:524:43: warning: arithmetic between different enumeration types ('enum zone_stat_item' and 'enum numa_stat_item') [-Wenum-enum-conversion]
     524 |         return vmstat_text[NR_VM_ZONE_STAT_ITEMS +
         |                            ~~~~~~~~~~~~~~~~~~~~~ ^
     525 |                            NR_VM_NUMA_EVENT_ITEMS +
         |                            ~~~~~~~~~~~~~~~~~~~~~~
>> drivers/mfd/max77705.c:129:6: warning: variable 'pmic_rev' is uninitialized when used here [-Wuninitialized]
     129 |         if (pmic_rev != MAX77705_PASS3) {
         |             ^~~~~~~~
   drivers/mfd/max77705.c:108:13: note: initialize the variable 'pmic_rev' to silence this warning
     108 |         u8 pmic_rev;
         |                    ^
         |                     = '\0'
   5 warnings generated.


vim +/pmic_rev +129 drivers/mfd/max77705.c

   100	
   101	static int max77705_i2c_probe(struct i2c_client *i2c)
   102	{
   103		struct max77693_dev *max77705;
   104		struct regmap_irq_chip_data *irq_data;
   105		struct irq_domain *domain;
   106		int ret;
   107		unsigned int pmic_rev_value;
   108		u8 pmic_rev;
   109	
   110	
   111		max77705 = devm_kzalloc(&i2c->dev, sizeof(*max77705), GFP_KERNEL);
   112		if (!max77705)
   113			return -ENOMEM;
   114	
   115		max77705->i2c = i2c;
   116		max77705->dev = &i2c->dev;
   117		max77705->irq = i2c->irq;
   118		max77705->type = TYPE_MAX77705;
   119		i2c_set_clientdata(i2c, max77705);
   120	
   121		max77705->regmap = devm_regmap_init_i2c(i2c, &max77705_regmap_config);
   122	
   123		if (IS_ERR(max77705->regmap))
   124			return PTR_ERR(max77705->regmap);
   125	
   126		if (regmap_read(max77705->regmap, MAX77705_PMIC_REG_PMICREV, &pmic_rev_value) < 0)
   127			return -ENODEV;
   128	
 > 129		if (pmic_rev != MAX77705_PASS3) {
   130			dev_err(max77705->dev, "rev.0x%x is not tested",
   131				pmic_rev);
   132			return -ENODEV;
   133		}
   134	
   135		max77705->regmap_leds = devm_regmap_init_i2c(i2c, &max77705_leds_regmap_config);
   136	
   137		if (IS_ERR(max77705->regmap_leds))
   138			return PTR_ERR(max77705->regmap_leds);
   139	
   140		ret = devm_regmap_add_irq_chip(max77705->dev, max77705->regmap,
   141						max77705->irq,
   142						IRQF_ONESHOT | IRQF_SHARED, 0,
   143						&max77705_topsys_irq_chip,
   144						&irq_data);
   145	
   146		if (ret)
   147			dev_err(max77705->dev, "failed to add irq chip: %d\n", ret);
   148	
   149		/* Unmask interrupts from all blocks in interrupt source register */
   150		ret = regmap_update_bits(max77705->regmap,
   151					 MAX77705_PMIC_REG_INTSRC_MASK,
   152					 MAX77705_SRC_IRQ_ALL, (unsigned int)~MAX77705_SRC_IRQ_ALL);
   153	
   154		if (ret < 0) {
   155			dev_err(max77705->dev,
   156				"Could not unmask interrupts in INTSRC: %d\n", ret);
   157			return ret;
   158		}
   159	
   160		domain = regmap_irq_get_domain(irq_data);
   161	
   162		ret = devm_mfd_add_devices(max77705->dev, PLATFORM_DEVID_NONE,
   163					   max77705_devs, ARRAY_SIZE(max77705_devs),
   164					   NULL, 0, domain);
   165	
   166		if (ret) {
   167			dev_err(max77705->dev, "Failed to register child devices: %d\n", ret);
   168			return ret;
   169		}
   170	
   171		device_init_wakeup(max77705->dev, true);
   172	
   173		return 0;
   174	}
   175	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

  reply	other threads:[~2024-11-02 19:55 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-30 21:30 [PATCH v8 0/7] Add support for Maxim Integrated MAX77705 PMIC Dzmitry Sankouski
2024-10-30 21:30 ` [PATCH v8 1/7] power: supply: add undervoltage health status property Dzmitry Sankouski
2024-10-30 21:30 ` [PATCH v8 2/7] dt-bindings: mfd: add maxim,max77705 Dzmitry Sankouski
2024-10-30 21:30 ` [PATCH v8 3/7] mfd: Add new driver for MAX77705 PMIC Dzmitry Sankouski
2024-11-02 19:55   ` kernel test robot [this message]
2024-10-30 21:30 ` [PATCH v8 4/7] input: max77693: add max77705 haptic support Dzmitry Sankouski
2024-10-30 21:30 ` [PATCH v8 5/7] power: supply: max77705: Add charger driver for Maxim 77705 Dzmitry Sankouski
2024-10-30 21:30 ` [PATCH v8 6/7] power: supply: max77705: Add fuel gauge " Dzmitry Sankouski
2024-10-30 21:30 ` [PATCH v8 7/7] leds: max77705: Add LEDs support Dzmitry Sankouski

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=202411030141.DTmej8oX-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=conor+dt@kernel.org \
    --cc=cw00.choi@samsung.com \
    --cc=devicetree@vger.kernel.org \
    --cc=dmitry.torokhov@gmail.com \
    --cc=dsankouski@gmail.com \
    --cc=krzk@kernel.org \
    --cc=lee@kernel.org \
    --cc=linux-input@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-leds@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=llvm@lists.linux.dev \
    --cc=oe-kbuild-all@lists.linux.dev \
    --cc=pavel@ucw.cz \
    --cc=robh@kernel.org \
    --cc=sre@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).