linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [mcgrof-next:20210817-add-disk-error-handling-next 1/89] drivers/nvme/host/core.c:3760:29: error: 'NVME_QUIRK_LIGHTNVM' undeclared; did you mean 'NVME_NS_LIGHTNVM'?
@ 2021-08-18 11:42 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2021-08-18 11:42 UTC (permalink / raw)
  To: Christoph Hellwig; +Cc: kbuild-all, linux-kernel, Luis Chamberlain

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

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux-next.git 20210817-add-disk-error-handling-next
head:   3d00c210d7fd616243af9cf41829f4a56f116ba8
commit: 6e8cedeeaa2d0b259010b0d956020ba8284196ce [1/89] nvme: use blk_mq_alloc_disk
config: arc-randconfig-r043-20210816 (attached as .config)
compiler: arc-elf-gcc (GCC) 11.2.0
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # https://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux-next.git/commit/?id=6e8cedeeaa2d0b259010b0d956020ba8284196ce
        git remote add mcgrof-next https://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux-next.git
        git fetch --no-tags mcgrof-next 20210817-add-disk-error-handling-next
        git checkout 6e8cedeeaa2d0b259010b0d956020ba8284196ce
        # save the attached .config to linux build tree
        mkdir build_dir
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=arc 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>

All errors (new ones prefixed by >>):

   drivers/nvme/host/core.c: In function 'nvme_alloc_ns':
>> drivers/nvme/host/core.c:3760:29: error: 'NVME_QUIRK_LIGHTNVM' undeclared (first use in this function); did you mean 'NVME_NS_LIGHTNVM'?
    3760 |         if ((ctrl->quirks & NVME_QUIRK_LIGHTNVM) && id->vs[0] == 0x1) {
         |                             ^~~~~~~~~~~~~~~~~~~
         |                             NVME_NS_LIGHTNVM
   drivers/nvme/host/core.c:3760:29: note: each undeclared identifier is reported only once for each function it appears in
>> drivers/nvme/host/core.c:3761:21: error: implicit declaration of function 'nvme_nvm_register'; did you mean 'nvme_pr_register'? [-Werror=implicit-function-declaration]
    3761 |                 if (nvme_nvm_register(ns, disk->disk_name, node)) {
         |                     ^~~~~~~~~~~~~~~~~
         |                     nvme_pr_register
   cc1: some warnings being treated as errors


vim +3760 drivers/nvme/host/core.c

  3710	
  3711	static void nvme_alloc_ns(struct nvme_ctrl *ctrl, unsigned nsid,
  3712			struct nvme_ns_ids *ids)
  3713	{
  3714		struct nvme_ns *ns;
  3715		struct gendisk *disk;
  3716		struct nvme_id_ns *id;
  3717		int node = ctrl->numa_node;
  3718	
  3719		if (nvme_identify_ns(ctrl, nsid, ids, &id))
  3720			return;
  3721	
  3722		ns = kzalloc_node(sizeof(*ns), GFP_KERNEL, node);
  3723		if (!ns)
  3724			goto out_free_id;
  3725	
  3726		disk = blk_mq_alloc_disk(ctrl->tagset, ns);
  3727		if (IS_ERR(disk))
  3728			goto out_free_ns;
  3729		disk->fops = &nvme_bdev_ops;
  3730		disk->private_data = ns;
  3731	
  3732		ns->disk = disk;
  3733		ns->queue = disk->queue;
  3734	
  3735		if (ctrl->opts && ctrl->opts->data_digest)
  3736			blk_queue_flag_set(QUEUE_FLAG_STABLE_WRITES, ns->queue);
  3737	
  3738		blk_queue_flag_set(QUEUE_FLAG_NONROT, ns->queue);
  3739		if (ctrl->ops->flags & NVME_F_PCI_P2PDMA)
  3740			blk_queue_flag_set(QUEUE_FLAG_PCI_P2PDMA, ns->queue);
  3741	
  3742		ns->ctrl = ctrl;
  3743		kref_init(&ns->kref);
  3744	
  3745		if (nvme_init_ns_head(ns, nsid, ids, id->nmic & NVME_NS_NMIC_SHARED))
  3746			goto out_cleanup_disk;
  3747	
  3748		/*
  3749		 * Without the multipath code enabled, multiple controller per
  3750		 * subsystems are visible as devices and thus we cannot use the
  3751		 * subsystem instance.
  3752		 */
  3753		if (!nvme_mpath_set_disk_name(ns, disk->disk_name, &disk->flags))
  3754			sprintf(disk->disk_name, "nvme%dn%d", ctrl->instance,
  3755				ns->head->instance);
  3756	
  3757		if (nvme_update_ns_info(ns, id))
  3758			goto out_unlink_ns;
  3759	
> 3760		if ((ctrl->quirks & NVME_QUIRK_LIGHTNVM) && id->vs[0] == 0x1) {
> 3761			if (nvme_nvm_register(ns, disk->disk_name, node)) {
  3762				dev_warn(ctrl->device, "LightNVM init failure\n");
  3763				goto out_unlink_ns;
  3764			}
  3765		}
  3766	
  3767		down_write(&ctrl->namespaces_rwsem);
  3768		list_add_tail(&ns->list, &ctrl->namespaces);
  3769		up_write(&ctrl->namespaces_rwsem);
  3770	
  3771		nvme_get_ctrl(ctrl);
  3772	
  3773		device_add_disk(ctrl->device, ns->disk, nvme_ns_id_attr_groups);
  3774		if (!nvme_ns_head_multipath(ns->head))
  3775			nvme_add_ns_cdev(ns);
  3776	
  3777		nvme_mpath_add_disk(ns, id);
  3778		nvme_fault_inject_init(&ns->fault_inject, ns->disk->disk_name);
  3779		kfree(id);
  3780	
  3781		return;
  3782	
  3783	 out_unlink_ns:
  3784		mutex_lock(&ctrl->subsys->lock);
  3785		list_del_rcu(&ns->siblings);
  3786		if (list_empty(&ns->head->list))
  3787			list_del_init(&ns->head->entry);
  3788		mutex_unlock(&ctrl->subsys->lock);
  3789		nvme_put_ns_head(ns->head);
  3790	 out_cleanup_disk:
  3791		blk_cleanup_disk(disk);
  3792	 out_free_ns:
  3793		kfree(ns);
  3794	 out_free_id:
  3795		kfree(id);
  3796	}
  3797	

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

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-08-18 11:43 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-18 11:42 [mcgrof-next:20210817-add-disk-error-handling-next 1/89] drivers/nvme/host/core.c:3760:29: error: 'NVME_QUIRK_LIGHTNVM' undeclared; did you mean 'NVME_NS_LIGHTNVM'? kernel test robot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).