CC: [email protected] CC: [email protected] In-Reply-To: <[email protected]> References: <[email protected]> TO: Srinivas Kandagatla <[email protected]> TO: [email protected] CC: [email protected] CC: [email protected] CC: [email protected] CC: Srinivas Kandagatla <[email protected]>
Hi Srinivas, I love your patch! Perhaps something to improve: [auto build test WARNING on shawnguo/for-next] [also build test WARNING on linux/master linus/master v5.15-rc3 next-20210922] [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/Srinivas-Kandagatla/nvmem-Add-cell-post-processing-support/20211006-224852 base: https://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux.git for-next :::::: branch date: 11 hours ago :::::: commit date: 11 hours ago config: i386-randconfig-c001-20211003 (attached as .config) compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project c0039de2953d15815448b4b3c3bafb45607781e0) 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/fb2ac1de1c351669a22c806d32cd6ec6a8329238 git remote add linux-review https://github.com/0day-ci/linux git fetch --no-tags linux-review Srinivas-Kandagatla/nvmem-Add-cell-post-processing-support/20211006-224852 git checkout fb2ac1de1c351669a22c806d32cd6ec6a8329238 # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=i386 clang-analyzer If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot <[email protected]> clang-analyzer warnings: (new ones prefixed by >>) 6 warnings generated. Suppressed 6 warnings (6 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 6 warnings generated. Suppressed 6 warnings (6 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 6 warnings generated. Suppressed 6 warnings (6 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 6 warnings generated. Suppressed 6 warnings (6 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 5 warnings generated. Suppressed 5 warnings (5 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 7 warnings generated. Suppressed 7 warnings (7 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 7 warnings generated. Suppressed 7 warnings (7 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 7 warnings generated. Suppressed 7 warnings (7 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 7 warnings generated. Suppressed 7 warnings (7 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 7 warnings generated. Suppressed 7 warnings (7 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 7 warnings generated. Suppressed 7 warnings (7 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 6 warnings generated. Suppressed 6 warnings (6 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 6 warnings generated. Suppressed 6 warnings (6 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 7 warnings generated. drivers/comedi/drivers/pcm3724.c:97:2: warning: Value stored to 'buffer_config' is never read [clang-analyzer-deadcode.DeadStores] buffer_config = 0; ^ ~ drivers/comedi/drivers/pcm3724.c:97:2: note: Value stored to 'buffer_config' is never read buffer_config = 0; ^ ~ Suppressed 6 warnings (6 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 6 warnings generated. Suppressed 6 warnings (6 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 6 warnings generated. Suppressed 6 warnings (6 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 6 warnings generated. Suppressed 6 warnings (6 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 6 warnings generated. Suppressed 6 warnings (6 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 6 warnings generated. Suppressed 6 warnings (6 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 6 warnings generated. Suppressed 6 warnings (6 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 6 warnings generated. Suppressed 6 warnings (6 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 6 warnings generated. Suppressed 6 warnings (6 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 8 warnings generated. sound/soc/amd/vangogh/acp5x-i2s.c:97:2: warning: Value stored to 'lrclk_div_val' is never read [clang-analyzer-deadcode.DeadStores] lrclk_div_val = 0; ^ ~ sound/soc/amd/vangogh/acp5x-i2s.c:97:2: note: Value stored to 'lrclk_div_val' is never read lrclk_div_val = 0; ^ ~ sound/soc/amd/vangogh/acp5x-i2s.c:98:2: warning: Value stored to 'bclk_div_val' is never read [clang-analyzer-deadcode.DeadStores] bclk_div_val = 0; ^ ~ sound/soc/amd/vangogh/acp5x-i2s.c:98:2: note: Value stored to 'bclk_div_val' is never read bclk_div_val = 0; ^ ~ Suppressed 6 warnings (6 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 6 warnings generated. Suppressed 6 warnings (6 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 6 warnings generated. Suppressed 6 warnings (6 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 6 warnings generated. Suppressed 6 warnings (6 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 6 warnings generated. Suppressed 6 warnings (6 in non-user code). Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well. 10 warnings generated. >> drivers/nvmem/core.c:1312:7: warning: Potential leak of memory pointed to by >> 'cell' [clang-analyzer-unix.Malloc] if (!id) ^ drivers/nvmem/core.c:1747:8: note: Calling 'nvmem_cell_read_variable_common' buf = nvmem_cell_read_variable_common(dev, cell_id, sizeof(*val), &len); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ drivers/nvmem/core.c:1675:9: note: Calling 'nvmem_cell_get' cell = nvmem_cell_get(dev, cell_id); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ drivers/nvmem/core.c:1305:6: note: Assuming field 'of_node' is non-null if (dev->of_node) { /* try dt first */ ^~~~~~~~~~~~ drivers/nvmem/core.c:1305:2: note: Taking true branch if (dev->of_node) { /* try dt first */ ^ drivers/nvmem/core.c:1306:10: note: Calling 'of_nvmem_cell_get' cell = of_nvmem_cell_get(dev->of_node, id); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ drivers/nvmem/core.c:1258:6: note: Assuming 'id' is null if (id) ^~ drivers/nvmem/core.c:1258:2: note: Taking false branch if (id) ^ drivers/nvmem/core.c:1262:6: note: Assuming 'cell_np' is non-null if (!cell_np) ^~~~~~~~ drivers/nvmem/core.c:1262:2: note: Taking false branch if (!cell_np) ^ drivers/nvmem/core.c:1266:6: note: Assuming 'nvmem_np' is non-null if (!nvmem_np) ^~~~~~~~~ drivers/nvmem/core.c:1266:2: note: Taking false branch if (!nvmem_np) ^ drivers/nvmem/core.c:1271:2: note: Taking false branch if (IS_ERR(nvmem)) ^ drivers/nvmem/core.c:1275:6: note: Assuming 'cell_entry' is non-null if (!cell_entry) { ^~~~~~~~~~~ drivers/nvmem/core.c:1275:2: note: Taking false branch if (!cell_entry) { ^ drivers/nvmem/core.c:1280:9: note: Calling 'nvmem_create_cell' cell = nvmem_create_cell(cell_entry, id); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ drivers/nvmem/core.c:1154:9: note: Calling 'kzalloc' cell = kzalloc(sizeof(*cell), GFP_KERNEL); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ include/linux/slab.h:721:9: note: Memory is allocated return kmalloc(size, flags | __GFP_ZERO); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ drivers/nvmem/core.c:1154:9: note: Returned allocated memory cell = kzalloc(sizeof(*cell), GFP_KERNEL); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ drivers/nvmem/core.c:1155:6: note: Assuming 'cell' is non-null if (!cell) ^~~~~ drivers/nvmem/core.c:1155:2: note: Taking false branch if (!cell) ^ drivers/nvmem/core.c:1158:6: note: 'id' is null if (id) { ^~ drivers/nvmem/core.c:1158:2: note: Taking false branch if (id) { ^ drivers/nvmem/core.c:1280:9: note: Returned allocated memory cell = nvmem_create_cell(cell_entry, id); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ drivers/nvmem/core.c:1281:2: note: Taking true branch if (IS_ERR(cell)) ^ drivers/nvmem/core.c:1306:10: note: Returned allocated memory cell = of_nvmem_cell_get(dev->of_node, id); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ drivers/nvmem/core.c:1307:7: note: Left side of '||' is false if (!IS_ERR(cell) || PTR_ERR(cell) == -EPROBE_DEFER) ^ drivers/nvmem/core.c:1307:24: note: Assuming the condition is false if (!IS_ERR(cell) || PTR_ERR(cell) == -EPROBE_DEFER) ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ drivers/nvmem/core.c:1307:3: note: Taking false branch if (!IS_ERR(cell) || PTR_ERR(cell) == -EPROBE_DEFER) ^ drivers/nvmem/core.c:1312:7: note: Potential leak of memory pointed to by 'cell' if (!id) ^ drivers/nvmem/core.c:1426:8: warning: The result of the right shift is undefined due to shifting by '32', which is greater or equal to the width of type 'unsigned long' [clang-analyzer-core.UndefinedBinaryOperatorResult] *p &= GENMASK((cell->nbits%BITS_PER_BYTE) - 1, 0); ^ include/linux/bits.h:38:31: note: expanded from macro 'GENMASK' (GENMASK_INPUT_CHECK(h, l) + __GENMASK(h, l)) ^ include/linux/bits.h:36:11: note: expanded from macro '__GENMASK' (~UL(0) >> (BITS_PER_LONG - 1 - (h)))) ^ drivers/nvmem/core.c:1779:6: note: Assuming 'nvmem' is non-null if (!nvmem) vim +/cell +1312 drivers/nvmem/core.c 69aba7948cbe53 Srinivas Kandagatla 2015-07-27 1288 69aba7948cbe53 Srinivas Kandagatla 2015-07-27 1289 /** 69aba7948cbe53 Srinivas Kandagatla 2015-07-27 1290 * nvmem_cell_get() - Get nvmem cell of device form a given cell name 69aba7948cbe53 Srinivas Kandagatla 2015-07-27 1291 * 29143268ec7d29 Vivek Gautam 2017-01-22 1292 * @dev: Device that requests the nvmem cell. 165589f0cb52b3 Bartosz Golaszewski 2018-09-21 1293 * @id: nvmem cell name to get (this corresponds with the name from the 165589f0cb52b3 Bartosz Golaszewski 2018-09-21 1294 * nvmem-cell-names property for DT systems and with the con_id from 165589f0cb52b3 Bartosz Golaszewski 2018-09-21 1295 * the lookup entry for non-DT systems). 69aba7948cbe53 Srinivas Kandagatla 2015-07-27 1296 * 69aba7948cbe53 Srinivas Kandagatla 2015-07-27 1297 * Return: Will be an ERR_PTR() on error or a valid pointer 69aba7948cbe53 Srinivas Kandagatla 2015-07-27 1298 * to a struct nvmem_cell. The nvmem_cell will be freed by the 69aba7948cbe53 Srinivas Kandagatla 2015-07-27 1299 * nvmem_cell_put(). 69aba7948cbe53 Srinivas Kandagatla 2015-07-27 1300 */ 165589f0cb52b3 Bartosz Golaszewski 2018-09-21 1301 struct nvmem_cell *nvmem_cell_get(struct device *dev, const char *id) 69aba7948cbe53 Srinivas Kandagatla 2015-07-27 1302 { 69aba7948cbe53 Srinivas Kandagatla 2015-07-27 1303 struct nvmem_cell *cell; 69aba7948cbe53 Srinivas Kandagatla 2015-07-27 1304 69aba7948cbe53 Srinivas Kandagatla 2015-07-27 1305 if (dev->of_node) { /* try dt first */ 165589f0cb52b3 Bartosz Golaszewski 2018-09-21 1306 cell = of_nvmem_cell_get(dev->of_node, id); 69aba7948cbe53 Srinivas Kandagatla 2015-07-27 1307 if (!IS_ERR(cell) || PTR_ERR(cell) == -EPROBE_DEFER) 69aba7948cbe53 Srinivas Kandagatla 2015-07-27 1308 return cell; 69aba7948cbe53 Srinivas Kandagatla 2015-07-27 1309 } 69aba7948cbe53 Srinivas Kandagatla 2015-07-27 1310 165589f0cb52b3 Bartosz Golaszewski 2018-09-21 1311 /* NULL cell id only allowed for device tree; invalid otherwise */ 165589f0cb52b3 Bartosz Golaszewski 2018-09-21 @1312 if (!id) 87ed1405ef09d2 Douglas Anderson 2018-06-18 1313 return ERR_PTR(-EINVAL); 87ed1405ef09d2 Douglas Anderson 2018-06-18 1314 165589f0cb52b3 Bartosz Golaszewski 2018-09-21 1315 return nvmem_cell_get_from_lookup(dev, id); 69aba7948cbe53 Srinivas Kandagatla 2015-07-27 1316 } 69aba7948cbe53 Srinivas Kandagatla 2015-07-27 1317 EXPORT_SYMBOL_GPL(nvmem_cell_get); 69aba7948cbe53 Srinivas Kandagatla 2015-07-27 1318 --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/[email protected]
.config.gz
Description: application/gzip
_______________________________________________ kbuild mailing list -- [email protected] To unsubscribe send an email to [email protected]
