[linux-nvme:nvme-6.7 5/6] drivers/nvme/host/rdma.c:987:47: error: incompatible pointer types passing 'struct nvme_rdma_ctrl *' to parameter of type 'struct nvme_ctrl *'
kernel test robot
lkp at intel.com
Wed Nov 29 20:02:54 PST 2023
tree: git://git.infradead.org/nvme.git nvme-6.7
head: b6cbe703db447a22f70caa0ee9cf616ac26cdc37
commit: 822d50c036c6af2e6a42b45b2e63cb02d6233c2b [5/6] nvme: ensure reset state check ordering
config: x86_64-allyesconfig (https://download.01.org/0day-ci/archive/20231130/202311301141.jPWaYfLH-lkp@intel.com/config)
compiler: clang version 16.0.4 (https://github.com/llvm/llvm-project.git ae42196bc493ffe877a7e3dff8be32035dea4d07)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20231130/202311301141.jPWaYfLH-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 at intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202311301141.jPWaYfLH-lkp@intel.com/
All errors (new ones prefixed by >>):
>> drivers/nvme/host/rdma.c:987:47: error: incompatible pointer types passing 'struct nvme_rdma_ctrl *' to parameter of type 'struct nvme_ctrl *' [-Werror,-Wincompatible-pointer-types]
enum nvme_ctrl_state state = nvme_ctrl_state(ctrl);
^~~~
drivers/nvme/host/nvme.h:390:70: note: passing argument to parameter 'ctrl' here
static inline enum nvme_ctrl_state nvme_ctrl_state(struct nvme_ctrl *ctrl)
^
drivers/nvme/host/rdma.c:1063:48: error: incompatible pointer types passing 'struct nvme_rdma_ctrl *' to parameter of type 'struct nvme_ctrl *' [-Werror,-Wincompatible-pointer-types]
enum nvme_ctrl_state state = nvme_ctrl_state(ctrl);
^~~~
drivers/nvme/host/nvme.h:390:70: note: passing argument to parameter 'ctrl' here
static inline enum nvme_ctrl_state nvme_ctrl_state(struct nvme_ctrl *ctrl)
^
drivers/nvme/host/rdma.c:1135:48: error: incompatible pointer types passing 'struct nvme_rdma_ctrl *' to parameter of type 'struct nvme_ctrl *' [-Werror,-Wincompatible-pointer-types]
enum nvme_ctrl_state state = nvme_ctrl_state(ctrl);
^~~~
drivers/nvme/host/nvme.h:390:70: note: passing argument to parameter 'ctrl' here
static inline enum nvme_ctrl_state nvme_ctrl_state(struct nvme_ctrl *ctrl)
^
drivers/nvme/host/rdma.c:1170:22: error: incompatible pointer types passing 'struct nvme_rdma_ctrl *' to parameter of type 'struct nvme_ctrl *' [-Werror,-Wincompatible-pointer-types]
if (nvme_ctrl_state(ctrl) == NVME_CTRL_LIVE)
^~~~
drivers/nvme/host/nvme.h:390:70: note: passing argument to parameter 'ctrl' here
static inline enum nvme_ctrl_state nvme_ctrl_state(struct nvme_ctrl *ctrl)
^
drivers/nvme/host/rdma.c:1953:22: error: incompatible pointer types passing 'struct nvme_rdma_ctrl *' to parameter of type 'struct nvme_ctrl *' [-Werror,-Wincompatible-pointer-types]
if (nvme_ctrl_state(ctrl) != NVME_CTRL_LIVE) {
^~~~
drivers/nvme/host/nvme.h:390:70: note: passing argument to parameter 'ctrl' here
static inline enum nvme_ctrl_state nvme_ctrl_state(struct nvme_ctrl *ctrl)
^
5 errors generated.
vim +987 drivers/nvme/host/rdma.c
984
985 static void nvme_rdma_reconnect_or_remove(struct nvme_rdma_ctrl *ctrl)
986 {
> 987 enum nvme_ctrl_state state = nvme_ctrl_state(ctrl);
988
989 /* If we are resetting/deleting then do nothing */
990 if (state != NVME_CTRL_CONNECTING) {
991 WARN_ON_ONCE(state == NVME_CTRL_NEW || state == NVME_CTRL_LIVE);
992 return;
993 }
994
995 if (nvmf_should_reconnect(&ctrl->ctrl)) {
996 dev_info(ctrl->ctrl.device, "Reconnecting in %d seconds...\n",
997 ctrl->ctrl.opts->reconnect_delay);
998 queue_delayed_work(nvme_wq, &ctrl->reconnect_work,
999 ctrl->ctrl.opts->reconnect_delay * HZ);
1000 } else {
1001 nvme_delete_ctrl(&ctrl->ctrl);
1002 }
1003 }
1004
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
More information about the Linux-nvme
mailing list