mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: kbuild test robot <lkp@intel.com>
To: SF Markus Elfring <elfring@users.sourceforge.net>
Cc: kbuild-all@01.org, linux-alpha@vger.kernel.org,
	Al Viro <viro@zeniv.linux.org.uk>,
	Ivan Kokshaysky <ink@jurassic.park.msu.ru>,
	Jan-Benedict Glaw <jbglaw@lug-owl.de>,
	Matt Turner <mattst88@gmail.com>,
	Nicolas Pitre <nicolas.pitre@linaro.org>,
	Richard Cochran <richardcochran@gmail.com>,
	Richard Henderson <rth@twiddle.net>,
	Thomas Gleixner <tglx@linutronix.de>,
	LKML <linux-kernel@vger.kernel.org>,
	kernel-janitors@vger.kernel.org
Subject: Re: [PATCH 4/4] alpha: Move two assignments for the variable "res" in srm_env_proc_write()
Date: Thu, 19 Jan 2017 08:45:41 +0800	[thread overview]
Message-ID: <201701190856.7ULDKXLC%fengguang.wu@intel.com> (raw)
In-Reply-To: <986573fa-e636-f864-14dc-5e65a31b454e@users.sourceforge.net>

[-- Attachment #1: Type: text/plain, Size: 3197 bytes --]

Hi Markus,

[auto build test WARNING on linus/master]
[also build test WARNING on v4.10-rc4 next-20170118]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/SF-Markus-Elfring/alpha-Fine-tuning-for-five-function-implementations/20170119-075247
config: alpha-defconfig (attached as .config)
compiler: alpha-linux-gnu-gcc (Debian 6.1.1-9) 6.1.1 20160705
reproduce:
        wget https://git.kernel.org/cgit/linux/kernel/git/wfg/lkp-tests.git/plain/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # save the attached .config to linux build tree
        make.cross ARCH=alpha 

Note: it may well be a FALSE warning. FWIW you are at least aware of it now.
http://gcc.gnu.org/wiki/Better_Uninitialized_Warnings

All warnings (new ones prefixed by >>):

   arch/alpha/kernel/srm_env.c: In function 'srm_env_proc_write':
>> arch/alpha/kernel/srm_env.c:108:6: warning: 'res' may be used uninitialized in this function [-Wmaybe-uninitialized]
     int res;
         ^~~

vim +/res +108 arch/alpha/kernel/srm_env.c

0ead0f84 Alexey Dobriyan   2009-12-14   92  		seq_write(m, page, ret);
0ead0f84 Alexey Dobriyan   2009-12-14   93  		ret = 0;
16b7f4dc Jan-Benedict Glaw 2006-11-07   94  	} else
0ead0f84 Alexey Dobriyan   2009-12-14   95  		ret = -EFAULT;
0ead0f84 Alexey Dobriyan   2009-12-14   96  	free_page((unsigned long)page);
0ead0f84 Alexey Dobriyan   2009-12-14   97  	return ret;
0ead0f84 Alexey Dobriyan   2009-12-14   98  }
^1da177e Linus Torvalds    2005-04-16   99  
0ead0f84 Alexey Dobriyan   2009-12-14  100  static int srm_env_proc_open(struct inode *inode, struct file *file)
0ead0f84 Alexey Dobriyan   2009-12-14  101  {
d9dda78b Al Viro           2013-03-31  102  	return single_open(file, srm_env_proc_show, PDE_DATA(inode));
^1da177e Linus Torvalds    2005-04-16  103  }
^1da177e Linus Torvalds    2005-04-16  104  
0ead0f84 Alexey Dobriyan   2009-12-14  105  static ssize_t srm_env_proc_write(struct file *file, const char __user *buffer,
0ead0f84 Alexey Dobriyan   2009-12-14  106  				  size_t count, loff_t *pos)
^1da177e Linus Torvalds    2005-04-16  107  {
^1da177e Linus Torvalds    2005-04-16 @108  	int res;
1c1ec6c6 Al Viro           2013-03-31  109  	unsigned long	id = (unsigned long)PDE_DATA(file_inode(file));
^1da177e Linus Torvalds    2005-04-16  110  	char		*buf = (char *) __get_free_page(GFP_USER);
^1da177e Linus Torvalds    2005-04-16  111  	unsigned long	ret1, ret2;
^1da177e Linus Torvalds    2005-04-16  112  
^1da177e Linus Torvalds    2005-04-16  113  	if (!buf)
^1da177e Linus Torvalds    2005-04-16  114  		return -ENOMEM;
^1da177e Linus Torvalds    2005-04-16  115  
cb234559 Markus Elfring    2017-01-18  116  	if (count >= PAGE_SIZE) {

:::::: The code at line 108 was first introduced by commit
:::::: 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 Linux-2.6.12-rc2

:::::: TO: Linus Torvalds <torvalds@ppc970.osdl.org>
:::::: CC: Linus Torvalds <torvalds@ppc970.osdl.org>

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 12178 bytes --]

      parent reply	other threads:[~2017-01-19  0:49 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-18 11:40 [PATCH 0/4] alpha: Fine-tuning for five function implementations SF Markus Elfring
2017-01-18 11:45 ` [PATCH 1/4] alpha: Return an error code only as a constant in osf_sigstack() SF Markus Elfring
2017-01-18 11:46 ` [PATCH 2/4] alpha: Move two assignments for the variable "error" in osf_utsname() SF Markus Elfring
2017-01-18 11:47 ` [PATCH 3/4] alpha: Return directly after a failed copy_from_user() or getname() in two functions SF Markus Elfring
2017-01-18 11:50 ` [PATCH 4/4] alpha: Move two assignments for the variable "res" in srm_env_proc_write() SF Markus Elfring
2017-01-18 13:14   ` Jan-Benedict Glaw
2017-01-18 14:27     ` SF Markus Elfring
2017-01-18 14:11   ` Al Viro
2017-01-18 15:41     ` alpha: Checking source code positions for the setting of error codes SF Markus Elfring
2017-01-18 17:43       ` Al Viro
2017-01-19  0:45   ` kbuild test robot [this message]

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=201701190856.7ULDKXLC%fengguang.wu@intel.com \
    --to=lkp@intel.com \
    --cc=elfring@users.sourceforge.net \
    --cc=ink@jurassic.park.msu.ru \
    --cc=jbglaw@lug-owl.de \
    --cc=kbuild-all@01.org \
    --cc=kernel-janitors@vger.kernel.org \
    --cc=linux-alpha@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mattst88@gmail.com \
    --cc=nicolas.pitre@linaro.org \
    --cc=richardcochran@gmail.com \
    --cc=rth@twiddle.net \
    --cc=tglx@linutronix.de \
    --cc=viro@zeniv.linux.org.uk \
    /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

Powered by JetHome