* [arnd-playground:warnings-2 5/9] drivers/opp/debugfs.c:43:42: warning: '%.62s' directive argument is null
@ 2023-08-11 16:55 kernel test robot
0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2023-08-11 16:55 UTC (permalink / raw)
To: Arnd Bergmann; +Cc: oe-kbuild-all
tree: https://git.kernel.org/pub/scm/linux/kernel/git/arnd/playground.git warnings-2
head: 5ddc13aed5c9ee03dd6bad7254a5918e6f36f1fa
commit: 707697efa19c54618ea9271158661fa31b4d7461 [5/9] extrawarn: enable format and stringop overflow warnings in W=1
config: um-randconfig-r031-20230811 (https://download.01.org/0day-ci/archive/20230812/202308120043.oZBsNtYV-lkp@intel.com/config)
compiler: gcc-12 (Debian 12.2.0-14) 12.2.0
reproduce: (https://download.01.org/0day-ci/archive/20230812/202308120043.oZBsNtYV-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/202308120043.oZBsNtYV-lkp@intel.com/
All warnings (new ones prefixed by >>):
drivers/opp/debugfs.c: In function 'bw_name_read':
>> drivers/opp/debugfs.c:43:42: warning: '%.62s' directive argument is null [-Wformat-overflow=]
43 | i = scnprintf(buf, sizeof(buf), "%.62s\n", icc_get_name(path));
| ^~~~~
vim +43 drivers/opp/debugfs.c
deaa51465105a7 drivers/base/power/opp/debugfs.c Viresh Kumar 2015-11-11 35
0430b1d5704b0f drivers/opp/debugfs.c Viresh Kumar 2020-05-18 36 static ssize_t bw_name_read(struct file *fp, char __user *userbuf,
0430b1d5704b0f drivers/opp/debugfs.c Viresh Kumar 2020-05-18 37 size_t count, loff_t *ppos)
0430b1d5704b0f drivers/opp/debugfs.c Viresh Kumar 2020-05-18 38 {
0430b1d5704b0f drivers/opp/debugfs.c Viresh Kumar 2020-05-18 39 struct icc_path *path = fp->private_data;
0430b1d5704b0f drivers/opp/debugfs.c Viresh Kumar 2020-05-18 40 char buf[64];
0430b1d5704b0f drivers/opp/debugfs.c Viresh Kumar 2020-05-18 41 int i;
0430b1d5704b0f drivers/opp/debugfs.c Viresh Kumar 2020-05-18 42
0430b1d5704b0f drivers/opp/debugfs.c Viresh Kumar 2020-05-18 @43 i = scnprintf(buf, sizeof(buf), "%.62s\n", icc_get_name(path));
0430b1d5704b0f drivers/opp/debugfs.c Viresh Kumar 2020-05-18 44
0430b1d5704b0f drivers/opp/debugfs.c Viresh Kumar 2020-05-18 45 return simple_read_from_buffer(userbuf, count, ppos, buf, i);
0430b1d5704b0f drivers/opp/debugfs.c Viresh Kumar 2020-05-18 46 }
0430b1d5704b0f drivers/opp/debugfs.c Viresh Kumar 2020-05-18 47
:::::: The code at line 43 was first introduced by commit
:::::: 0430b1d5704b0f0f1d237236dde9c143f8669e49 opp: Expose bandwidth information via debugfs
:::::: TO: Viresh Kumar <viresh.kumar@linaro.org>
:::::: CC: Viresh Kumar <viresh.kumar@linaro.org>
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2023-08-11 16:55 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-08-11 16:55 [arnd-playground:warnings-2 5/9] drivers/opp/debugfs.c:43:42: warning: '%.62s' directive argument is null kernel test robot
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).