* [tobetter-linux:odroid-5.9.y 45/71] drivers/regulator/s2mps11.c:1252 s2mps11_pmic_shutdown() warn: unsigned 'ret' is never less than zero.
@ 2020-10-07 18:54 kernel test robot
0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2020-10-07 18:54 UTC (permalink / raw)
To: kbuild-all
[-- Attachment #1: Type: text/plain, Size: 1650 bytes --]
tree: https://github.com/tobetter/linux odroid-5.9.y
head: 2189c37332c364084ef11d5aaeb2d79860f60715
commit: 2d7fa59f425970d0bb1bdc9fbc1a5d2532abbc33 [45/71] ODROID-XU4: regulator: s2mps11: call shutdown function to poweroff
config: i386-randconfig-m021-20201008 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
smatch warnings:
drivers/regulator/s2mps11.c:1252 s2mps11_pmic_shutdown() warn: unsigned 'ret' is never less than zero.
vim +/ret +1252 drivers/regulator/s2mps11.c
1245
1246 static void s2mps11_pmic_shutdown(struct platform_device *pdev)
1247 {
1248 struct sec_pmic_dev *iodev = dev_get_drvdata(pdev->dev.parent);
1249 unsigned int reg_val, ret;
1250
1251 ret = regmap_read(iodev->regmap_pmic, S2MPS11_REG_CTRL1, ®_val);
> 1252 if (ret < 0) {
1253 dev_crit(&pdev->dev, "could not read S2MPS11_REG_CTRL1 value\n");
1254 } else {
1255 /*
1256 * s2mps11-pmic: S2MPS11_REG_CTRL1 reg value
1257 * is 00000000000000000000000000010000
1258 * clear the S2MPS11_REG_CTRL1 0x10 value to shutdown.
1259 */
1260 if (reg_val & BIT(4)) {
1261 ret = regmap_update_bits(iodev->regmap_pmic,
1262 S2MPS11_REG_CTRL1,
1263 BIT(4), BIT(0));
1264 if (ret)
1265 dev_crit(&pdev->dev,
1266 "could not write S2MPS11_REG_CTRL1 value\n");
1267 }
1268 }
1269 }
1270
---
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: 30158 bytes --]
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2020-10-07 18:54 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-10-07 18:54 [tobetter-linux:odroid-5.9.y 45/71] drivers/regulator/s2mps11.c:1252 s2mps11_pmic_shutdown() warn: unsigned 'ret' is never less than zero 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.