From: kernel test robot <lkp@intel.com>
To: kbuild-all@lists.01.org
Subject: Re: [RFC 7/7] nvme: add support for enhanced metadata
Date: Tue, 25 Jan 2022 06:23:35 +0800 [thread overview]
Message-ID: <202201250552.LY0QkQNT-lkp@intel.com> (raw)
In-Reply-To: <20220124160107.1683901-8-kbusch@kernel.org>
[-- Attachment #1: Type: text/plain, Size: 4039 bytes --]
Hi Keith,
[FYI, it's a private test report for your RFC patch.]
[auto build test WARNING on axboe-block/for-next]
[also build test WARNING on linux/master linus/master v5.17-rc1 next-20220124]
[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/Keith-Busch/64-bit-data-integrity-field-support/20220125-000232
base: https://git.kernel.org/pub/scm/linux/kernel/git/axboe/linux-block.git for-next
config: x86_64-randconfig-s021-20220124 (https://download.01.org/0day-ci/archive/20220125/202201250552.LY0QkQNT-lkp(a)intel.com/config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce:
# apt-get install sparse
# sparse version: v0.6.4-dirty
# https://github.com/0day-ci/linux/commit/15e965a414da565fcf7d7aa958a9850bb714db17
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Keith-Busch/64-bit-data-integrity-field-support/20220125-000232
git checkout 15e965a414da565fcf7d7aa958a9850bb714db17
# save the config file to linux build tree
mkdir build_dir
make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=x86_64 SHELL=/bin/bash drivers/nvme/host/
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/host/core.c:1805:17: sparse: sparse: cast from restricted __le32
>> drivers/nvme/host/core.c:1805:15: sparse: sparse: incorrect type in assignment (different base types) @@ expected unsigned int [usertype] elbaf @@ got restricted __le32 [usertype] @@
drivers/nvme/host/core.c:1805:15: sparse: expected unsigned int [usertype] elbaf
drivers/nvme/host/core.c:1805:15: sparse: got restricted __le32 [usertype]
vim +1805 drivers/nvme/host/core.c
1773
1774 static int nvme_init_ms(struct nvme_ns *ns, struct nvme_id_ns *id)
1775 {
1776 bool first = id->dps & NVME_NS_DPS_PI_FIRST;
1777 unsigned lbaf = nvme_lbaf_index(id->flbas);
1778 struct nvme_ctrl *ctrl = ns->ctrl;
1779 struct nvme_command c = { };
1780 struct nvme_id_ns_nvm *nvm;
1781 u8 pi_size = 0;
1782 int ret = 0;
1783 u32 elbaf;
1784
1785 ns->ms = le16_to_cpu(id->lbaf[lbaf].ms);
1786 if (!(ctrl->ctratt & NVME_CTRL_ATTR_ELBAS)) {
1787 pi_size = sizeof(struct t10_pi_tuple);
1788 ns->guard_type = NVME_NVM_NS_16B_GUARD;
1789 goto set_pi;
1790 }
1791
1792 nvm = kzalloc(sizeof(*nvm), GFP_KERNEL);
1793 if (!nvm)
1794 return -ENOMEM;
1795
1796 c.identify.opcode = nvme_admin_identify;
1797 c.identify.nsid = cpu_to_le32(ns->head->ns_id);
1798 c.identify.cns = NVME_ID_CNS_CS_NS;
1799 c.identify.csi = NVME_CSI_NVM;
1800
1801 ret = nvme_submit_sync_cmd(ns->ctrl->admin_q, &c, nvm, sizeof(*nvm));
1802 if (ret)
1803 goto free_data;
1804
> 1805 elbaf = cpu_to_le32(nvm->elbaf[lbaf]);
1806
1807 /* no support for storage tag formats right now */
1808 if (nvme_elbaf_sts(elbaf))
1809 goto free_data;
1810
1811 ns->guard_type = nvme_elbaf_guard_type(elbaf);
1812 switch (ns->guard_type) {
1813 case NVME_NVM_NS_64B_GUARD:
1814 pi_size = sizeof(struct nvme_crc64_pi_tuple);
1815 break;
1816 case NVME_NVM_NS_16B_GUARD:
1817 pi_size = sizeof(struct t10_pi_tuple);
1818 break;
1819 default:
1820 break;
1821 }
1822
1823 free_data:
1824 kfree(nvm);
1825 set_pi:
1826 if (pi_size && (first || ns->ms == pi_size))
1827 ns->pi_type = id->dps & NVME_NS_DPS_PI_MASK;
1828 else
1829 ns->pi_type = 0;
1830
1831 return ret;
1832 }
1833
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
next prev parent reply other threads:[~2022-01-24 22:23 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-24 16:01 [RFC 0/7] 64-bit data integrity field support Keith Busch
2022-01-24 16:01 ` [RFC 1/7] block: support pi with extended metadata Keith Busch
2022-01-24 16:01 ` [RFC 2/7] nvme: allow integrity on extended metadata formats Keith Busch
2022-01-24 16:01 ` [RFC 3/7] lib: add rocksoft model crc64 Keith Busch
2022-01-25 5:10 ` Eric Biggers
2022-01-25 15:39 ` Keith Busch
2022-01-24 16:01 ` [RFC 4/7] lib: add crc64 tests Keith Busch
2022-01-25 14:12 ` kernel test robot
2022-01-24 16:01 ` [RFC 5/7] asm-generic: introduce be48 unaligned accessors Keith Busch
2022-01-24 17:38 ` Arnd Bergmann
2022-01-24 16:01 ` [RFC 6/7] block: add pi for nvme enhanced integrity Keith Busch
2022-01-24 16:01 ` [RFC 7/7] nvme: add support for enhanced metadata Keith Busch
2022-01-24 22:23 ` kernel test robot [this message]
2022-01-26 14:38 ` [RFC 0/7] 64-bit data integrity field support Klaus Jensen
2022-01-26 16:52 ` Keith Busch
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=202201250552.LY0QkQNT-lkp@intel.com \
--to=lkp@intel.com \
--cc=kbuild-all@lists.01.org \
/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.