mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: kbuild test robot <lkp@intel.com>
To: "Richard, Gong," <richard.gong@intel.com>
Cc: kbuild-all@lists.01.org, linux-kernel@vger.kernel.org,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Subject: drivers/firmware/stratix10-rsu.c:293:21: sparse: sparse: Using plain integer as NULL pointer
Date: Wed, 3 Jun 2020 05:09:53 +0800	[thread overview]
Message-ID: <202006030549.dHauNQR7%lkp@intel.com> (raw)

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

Hi Richard,

First bad commit (maybe != root cause):

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   f359287765c04711ff54fbd11645271d8e5ff763
commit: 231d901d1e368c47c4786e826195520e0000a5ea firmware: intel_stratix10_service: add depend on agilex
date:   3 months ago
config: arm64-randconfig-s032-20200602 (attached as .config)
compiler: aarch64-linux-gcc (GCC) 9.3.0
reproduce:
        # apt-get install sparse
        # sparse version: v0.6.1-244-g0ee050a8-dirty
        git checkout 231d901d1e368c47c4786e826195520e0000a5ea
        # save the attached .config to linux build tree
        make W=1 C=1 ARCH=arm64 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__'

If you fix the issue, kindly add following tag as appropriate
Reported-by: kbuild test robot <lkp@intel.com>


sparse warnings: (new ones prefixed by >>)

>> drivers/firmware/stratix10-rsu.c:293:21: sparse: sparse: Using plain integer as NULL pointer
   drivers/firmware/stratix10-rsu.c:318:21: sparse: sparse: Using plain integer as NULL pointer

vim +293 drivers/firmware/stratix10-rsu.c

4526ebbc77732b Richard Gong 2019-09-03  284  
4526ebbc77732b Richard Gong 2019-09-03  285  static ssize_t reboot_image_store(struct device *dev,
4526ebbc77732b Richard Gong 2019-09-03  286  				  struct device_attribute *attr,
4526ebbc77732b Richard Gong 2019-09-03  287  				  const char *buf, size_t count)
4526ebbc77732b Richard Gong 2019-09-03  288  {
4526ebbc77732b Richard Gong 2019-09-03  289  	struct stratix10_rsu_priv *priv = dev_get_drvdata(dev);
4526ebbc77732b Richard Gong 2019-09-03  290  	unsigned long address;
4526ebbc77732b Richard Gong 2019-09-03  291  	int ret;
4526ebbc77732b Richard Gong 2019-09-03  292  
4526ebbc77732b Richard Gong 2019-09-03 @293  	if (priv == 0)
4526ebbc77732b Richard Gong 2019-09-03  294  		return -ENODEV;
4526ebbc77732b Richard Gong 2019-09-03  295  
4526ebbc77732b Richard Gong 2019-09-03  296  	ret = kstrtoul(buf, 0, &address);
4526ebbc77732b Richard Gong 2019-09-03  297  	if (ret)
4526ebbc77732b Richard Gong 2019-09-03  298  		return ret;
4526ebbc77732b Richard Gong 2019-09-03  299  
4526ebbc77732b Richard Gong 2019-09-03  300  	ret = rsu_send_msg(priv, COMMAND_RSU_UPDATE,
4526ebbc77732b Richard Gong 2019-09-03  301  			   address, rsu_command_callback);
4526ebbc77732b Richard Gong 2019-09-03  302  	if (ret) {
4526ebbc77732b Richard Gong 2019-09-03  303  		dev_err(dev, "Error, RSU update returned %i\n", ret);
4526ebbc77732b Richard Gong 2019-09-03  304  		return ret;
4526ebbc77732b Richard Gong 2019-09-03  305  	}
4526ebbc77732b Richard Gong 2019-09-03  306  
4526ebbc77732b Richard Gong 2019-09-03  307  	return count;
4526ebbc77732b Richard Gong 2019-09-03  308  }
4526ebbc77732b Richard Gong 2019-09-03  309  

:::::: The code at line 293 was first introduced by commit
:::::: 4526ebbc77732bcae965ee374cf3e8d86436b2ad firmware: add Intel Stratix10 remote system update driver

:::::: TO: Richard Gong <richard.gong@intel.com>
:::::: CC: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

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

                 reply	other threads:[~2020-06-02 21:12 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=202006030549.dHauNQR7%lkp@intel.com \
    --to=lkp@intel.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=kbuild-all@lists.01.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=richard.gong@intel.com \
    /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

all inboxes | Powered by JetHome®