Re: [PATCH 2/3] nvme-core: don't check non-mdts for disc ctrl

Keith Busch
2022-04-11T14:14:43Z

On Mon, Apr 11, 2022 at 12:40:22PM +0000, Chaitanya Kulkarni wrote:
> @@ -3101,9 +3101,12 @@ int nvme_init_ctrl_finish(struct nvme_ctrl *ctrl)
> if (ret)
> return ret;
>
> - ret = nvme_init_non_mdts_limits(ctrl);
> - if (ret < 0)
> - return ret;
> + /* only check non mdts for the I/O controller */
> + if (ctrl->tagset) {
> + ret = nvme_init_non_mdts_limits(ctrl);
> + if (ret < 0)
> + return ret;
> + }

The nvme pci driver doesn't initialize the ctrl->tagset until after
nvme_init_ctrl_finish(), so this won't work.