public inbox for llvm@lists.linux.dev
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Hannes Reinecke <hare@suse.de>
Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev
Subject: [hare-scsi-devel:ns-migration 10/18] drivers/nvme/host/core.c:3704:30: error: incompatible pointer types passing 'struct nvme_subsystem *' to parameter of type 'struct nvme_ctrl *'
Date: Thu, 3 Apr 2025 11:15:51 +0800	[thread overview]
Message-ID: <202504031106.LFdMV2AX-lkp@intel.com> (raw)

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/hare/scsi-devel.git ns-migration
head:   1cd2ac8db713fdf42bc7bb10329d795f7aee4f1f
commit: 0ba654ee6c31e479dd7236afec32fcd3ba7e7578 [10/18] nvme: use a subsystem argument in nvme_alloc_ns_head()
config: i386-buildonly-randconfig-003-20250403 (https://download.01.org/0day-ci/archive/20250403/202504031106.LFdMV2AX-lkp@intel.com/config)
compiler: clang version 20.1.2 (https://github.com/llvm/llvm-project 58df0ef89dd64126512e4ee27b4ac3fd8ddf6247)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250403/202504031106.LFdMV2AX-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/202504031106.LFdMV2AX-lkp@intel.com/

All errors (new ones prefixed by >>):

>> drivers/nvme/host/core.c:3704:30: error: incompatible pointer types passing 'struct nvme_subsystem *' to parameter of type 'struct nvme_ctrl *' [-Werror,-Wincompatible-pointer-types]
    3704 |         ret = nvme_mpath_alloc_disk(subsys, head);
         |                                     ^~~~~~
   drivers/nvme/host/nvme.h:1005:59: note: passing argument to parameter 'ctrl' here
    1005 | static inline int nvme_mpath_alloc_disk(struct nvme_ctrl *ctrl,
         |                                                           ^
   drivers/nvme/host/core.c:4310:30: error: no member named 'ana_work' in 'struct nvme_ctrl'; did you mean 'ka_work'?
    4310 |                 queue_work(nvme_wq, &ctrl->ana_work);
         |                                            ^~~~~~~~
         |                                            ka_work
   drivers/nvme/host/nvme.h:356:22: note: 'ka_work' declared here
     356 |         struct delayed_work ka_work;
         |                             ^
   2 errors generated.


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

  3675	
  3676		head = kzalloc(size, GFP_KERNEL);
  3677		if (!head)
  3678			goto out;
  3679		ret = ida_alloc_min(&subsys->ns_ida, 1, GFP_KERNEL);
  3680		if (ret < 0)
  3681			goto out_free_head;
  3682		head->instance = ret;
  3683		INIT_LIST_HEAD(&head->list);
  3684		ret = init_srcu_struct(&head->srcu);
  3685		if (ret)
  3686			goto out_ida_remove;
  3687		head->subsys = subsys;
  3688		head->ns_id = info->nsid;
  3689		head->ids = info->ids;
  3690		head->shared = info->is_shared;
  3691		head->rotational = info->is_rotational;
  3692		head->unique_nsid = head->shared || nvme_ctrl_is_unique_nsid(ctrl);
  3693		ratelimit_state_init(&head->rs_nuse, 5 * HZ, 1);
  3694		ratelimit_set_flags(&head->rs_nuse, RATELIMIT_MSG_ON_RELEASE);
  3695		kref_init(&head->ref);
  3696	
  3697		if (head->ids.csi) {
  3698			ret = nvme_get_effects_log(ctrl, head->ids.csi, &head->effects);
  3699			if (ret)
  3700				goto out_cleanup_srcu;
  3701		} else
  3702			head->effects = ctrl->effects;
  3703	
> 3704		ret = nvme_mpath_alloc_disk(subsys, head);
  3705		if (ret)
  3706			goto out_cleanup_srcu;
  3707	
  3708		list_add_tail(&head->entry, &subsys->nsheads);
  3709	
  3710		kref_get(&subsys->ref);
  3711	
  3712		return head;
  3713	out_cleanup_srcu:
  3714		cleanup_srcu_struct(&head->srcu);
  3715	out_ida_remove:
  3716		ida_free(&subsys->ns_ida, head->instance);
  3717	out_free_head:
  3718		kfree(head);
  3719	out:
  3720		if (ret > 0)
  3721			ret = blk_status_to_errno(nvme_error_status(ret));
  3722		return ERR_PTR(ret);
  3723	}
  3724	

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

                 reply	other threads:[~2025-04-03  3:16 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=202504031106.LFdMV2AX-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=hare@suse.de \
    --cc=llvm@lists.linux.dev \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox