All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Keith Busch <kbusch@meta.com>
Cc: oe-kbuild-all@lists.linux.dev
Subject: Re: [PATCH 5/5] nvmet: implement copy support for bdev backed target
Date: Thu, 22 May 2025 20:51:43 +0800	[thread overview]
Message-ID: <202505222048.SmFqu3B0-lkp@intel.com> (raw)
In-Reply-To: <20250521223107.709131-6-kbusch@meta.com>

Hi Keith,

kernel test robot noticed the following build warnings:

[auto build test WARNING on axboe-block/for-next]
[also build test WARNING on next-20250522]
[cannot apply to linux-nvme/for-next brauner-vfs/vfs.all linus/master v6.15-rc7]
[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#_base_tree_information]

url:    https://github.com/intel-lab-lkp/linux/commits/Keith-Busch/block-new-sector-copy-api/20250522-063316
base:   https://git.kernel.org/pub/scm/linux/kernel/git/axboe/linux-block.git for-next
patch link:    https://lore.kernel.org/r/20250521223107.709131-6-kbusch%40meta.com
patch subject: [PATCH 5/5] nvmet: implement copy support for bdev backed target
config: csky-randconfig-r132-20250522 (https://download.01.org/0day-ci/archive/20250522/202505222048.SmFqu3B0-lkp@intel.com/config)
compiler: csky-linux-gcc (GCC) 15.1.0
reproduce: (https://download.01.org/0day-ci/archive/20250522/202505222048.SmFqu3B0-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/202505222048.SmFqu3B0-lkp@intel.com/

sparse warnings: (new ones prefixed by >>)
>> drivers/nvme/target/io-cmd-bdev.c:447:62: sparse: sparse: incorrect type in argument 2 (different base types) @@     expected restricted __le64 [usertype] lba @@     got unsigned long long [assigned] [usertype] slba @@
   drivers/nvme/target/io-cmd-bdev.c:447:62: sparse:     expected restricted __le64 [usertype] lba
   drivers/nvme/target/io-cmd-bdev.c:447:62: sparse:     got unsigned long long [assigned] [usertype] slba
>> drivers/nvme/target/io-cmd-bdev.c:448:63: sparse: sparse: incorrect type in argument 2 (different base types) @@     expected restricted __le64 [usertype] lba @@     got unsigned short [assigned] [usertype] nlb @@
   drivers/nvme/target/io-cmd-bdev.c:448:63: sparse:     expected restricted __le64 [usertype] lba
   drivers/nvme/target/io-cmd-bdev.c:448:63: sparse:     got unsigned short [assigned] [usertype] nlb
>> drivers/nvme/target/io-cmd-bdev.c:454:35: sparse: sparse: cast to restricted __le64

vim +447 drivers/nvme/target/io-cmd-bdev.c

   419	
   420	static void nvmet_bdev_execute_copy(struct nvmet_req *req)
   421	{
   422		struct bio_vec *bv, fast_bv[UIO_FASTIOV];
   423		struct nvme_copy_range range;
   424		u64 dst_sector, slba;
   425		u16 status, nlb, nr;
   426		int ret, i;
   427	
   428		nr = req->cmd->copy.nr_range + 1;
   429		if (nr <= UIO_FASTIOV) {
   430			bv = fast_bv;
   431		} else {
   432			bv = kmalloc_array(nr, sizeof(*bv), GFP_KERNEL);
   433			if (!bv) {
   434				status = NVME_SC_INTERNAL;
   435				goto done;
   436			}
   437		}
   438	
   439		for (i = 0; i < nr; i++) {
   440			status = nvmet_copy_from_sgl(req, i * sizeof(range), &range,
   441					sizeof(range));
   442			if (status)
   443				goto done;
   444	
   445			slba = le64_to_cpu(range.slba);
   446			nlb = le16_to_cpu(range.nlb) + 1;
 > 447			bv[i].bv_sector = nvmet_lba_to_sect(req->ns, slba);
 > 448			bv[i].bv_sectors = nvmet_lba_to_sect(req->ns, nlb);
   449		}
   450	
   451		dst_sector = nvmet_lba_to_sect(req->ns, req->cmd->copy.sdlba);
   452		ret = blkdev_copy_range(req->ns->bdev, dst_sector, bv, nr, GFP_KERNEL);
   453		if (ret) {
 > 454			req->error_slba = le64_to_cpu(dst_sector);
   455			status = errno_to_nvme_status(req, ret);
   456		} else
   457			status = NVME_SC_SUCCESS;
   458	done:
   459		nvmet_req_complete(req, status);
   460		if (bv != fast_bv)
   461			kfree(bv);
   462	}
   463	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

  reply	other threads:[~2025-05-22 12:52 UTC|newest]

Thread overview: 49+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-05-21 22:31 [PATCH 0/5] block: another block copy offload Keith Busch
2025-05-21 22:31 ` [PATCH 1/5] block: new sector copy api Keith Busch
2025-05-22 10:02   ` Hannes Reinecke
2025-05-22 16:43     ` Keith Busch
2025-05-22 19:22   ` Bart Van Assche
2025-05-22 20:04     ` Keith Busch
2025-05-23 12:45   ` Christoph Hellwig
2025-05-23 17:02     ` Keith Busch
2025-05-26  5:18       ` Christoph Hellwig
2025-05-27 17:45         ` Keith Busch
2025-05-28  7:46           ` Christoph Hellwig
2025-05-28 22:41             ` Keith Busch
2025-06-02  4:58               ` Christoph Hellwig
2025-05-21 22:31 ` [PATCH 2/5] block: add support for copy offload Keith Busch
2025-05-22 10:04   ` kernel test robot
2025-05-22 13:49   ` Hannes Reinecke
2025-05-23 12:46   ` Christoph Hellwig
2025-05-23 13:26     ` Keith Busch
2025-05-23 13:37       ` Christoph Hellwig
2025-05-23 13:48         ` Keith Busch
2025-05-26  5:22           ` Christoph Hellwig
2025-05-27 21:33         ` Keith Busch
2025-05-28  7:47           ` Christoph Hellwig
2025-05-21 22:31 ` [PATCH 3/5] nvme: " Keith Busch
2025-05-22  0:47   ` Caleb Sander Mateos
2025-05-22  0:51     ` Caleb Sander Mateos
2025-05-22  3:23       ` Keith Busch
2025-05-22  3:41         ` Caleb Sander Mateos
2025-05-22  4:29           ` Keith Busch
2025-05-22 14:16             ` Caleb Sander Mateos
2025-05-23 12:49             ` Christoph Hellwig
2025-05-23 12:48           ` Christoph Hellwig
2025-05-22 13:54   ` Hannes Reinecke
2025-05-23 12:50     ` Christoph Hellwig
2025-05-23 14:22       ` Caleb Sander Mateos
2025-06-09  9:29   ` Niklas Cassel
2025-05-21 22:31 ` [PATCH 4/5] block: add support for vectored copies Keith Busch
2025-05-22  9:33   ` kernel test robot
2025-05-22 13:58   ` Hannes Reinecke
2025-05-22 16:36     ` Keith Busch
2025-05-21 22:31 ` [PATCH 5/5] nvmet: implement copy support for bdev backed target Keith Busch
2025-05-22 12:51   ` kernel test robot [this message]
2025-05-22 13:59   ` Hannes Reinecke
2025-05-23 13:18   ` Christoph Hellwig
2025-05-23 14:00     ` Keith Busch
2025-05-23 14:02       ` Christoph Hellwig
2025-05-22 15:52 ` [PATCH 0/5] block: another block copy offload Bart Van Assche
2025-05-23 12:53   ` Christoph Hellwig
2025-07-03 14:47 ` Niklas Cassel

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=202505222048.SmFqu3B0-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=kbusch@meta.com \
    --cc=oe-kbuild-all@lists.linux.dev \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.