public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: zhenwei pi <pizhenwei@bytedance.com>,
	hch@lst.de, sagi@grimberg.me, chaitanya.kulkarni@wdc.com
Cc: kbuild-all@lists.01.org, linux-nvme@lists.infradead.org,
	linux-kernel@vger.kernel.org, pizhenwei@bytedance.com
Subject: Re: [PATCH] nvmet: fix mismatched serial
Date: Sat, 12 Dec 2020 01:39:12 +0800	[thread overview]
Message-ID: <202012120118.iOYJ7mXK-lkp@intel.com> (raw)
In-Reply-To: <20201211065456.826822-1-pizhenwei@bytedance.com>

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

Hi zhenwei,

Thank you for the patch! Perhaps something to improve:

[auto build test WARNING on hch-configfs/for-next]
[also build test WARNING on linux/master linus/master v5.10-rc7 next-20201211]
[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/zhenwei-pi/nvmet-fix-mismatched-serial/20201211-150008
base:   git://git.infradead.org/users/hch/configfs.git for-next
config: openrisc-randconfig-s031-20201209 (attached as .config)
compiler: or1k-linux-gcc (GCC) 9.3.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # apt-get install sparse
        # sparse version: v0.6.3-179-ga00755aa-dirty
        # https://github.com/0day-ci/linux/commit/57f71eb4dff3b1b3ecef2f0368f710025c5d47f2
        git remote add linux-review https://github.com/0day-ci/linux
        git fetch --no-tags linux-review zhenwei-pi/nvmet-fix-mismatched-serial/20201211-150008
        git checkout 57f71eb4dff3b1b3ecef2f0368f710025c5d47f2
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=openrisc 

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


"sparse warnings: (new ones prefixed by >>)"
>> drivers/nvme/target/configfs.c:1000:52: sparse: sparse: cast to restricted __be64
>> drivers/nvme/target/configfs.c:1012:33: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned long long [usertype] serial @@     got restricted __be64 [usertype] @@
   drivers/nvme/target/configfs.c:1012:33: sparse:     expected unsigned long long [usertype] serial
   drivers/nvme/target/configfs.c:1012:33: sparse:     got restricted __be64 [usertype]

vim +1000 drivers/nvme/target/configfs.c

   994	
   995	static ssize_t nvmet_subsys_attr_serial_show(struct config_item *item,
   996						     char *page)
   997	{
   998		struct nvmet_subsys *subsys = to_subsys(item);
   999	
> 1000		return snprintf(page, PAGE_SIZE, "%llx\n", be64_to_cpu(subsys->serial));
  1001	}
  1002	
  1003	static ssize_t nvmet_subsys_attr_serial_store(struct config_item *item,
  1004						      const char *page, size_t count)
  1005	{
  1006		u64 serial;
  1007	
  1008		if (sscanf(page, "%llx\n", &serial) != 1)
  1009			return -EINVAL;
  1010	
  1011		down_write(&nvmet_config_sem);
> 1012		to_subsys(item)->serial = cpu_to_be64(serial);
  1013		up_write(&nvmet_config_sem);
  1014	
  1015		return count;
  1016	}
  1017	CONFIGFS_ATTR(nvmet_subsys_, attr_serial);
  1018	

---
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: 21934 bytes --]

      reply	other threads:[~2020-12-11 19:25 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-11  6:54 [PATCH] nvmet: fix mismatched serial zhenwei pi
2020-12-11 17:39 ` kernel 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=202012120118.iOYJ7mXK-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=chaitanya.kulkarni@wdc.com \
    --cc=hch@lst.de \
    --cc=kbuild-all@lists.01.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-nvme@lists.infradead.org \
    --cc=pizhenwei@bytedance.com \
    --cc=sagi@grimberg.me \
    /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