[PATCH v7 01/17] nvmet: Rapid Path Failure Recovery set controller identify fields

sashiko-bot at kernel.org sashiko-bot at kernel.org
Fri Nov 13 19:17:21 PST 2026


Thank you for your contribution! Sashiko AI review found 1 potential
issue to consider:
- [Medium] nvmet: missing TP8028 field overrides in
  nvmet_passthru_override_id_ctrl()
--

commit b07e2fdf2211131fb02142faf21d5cf7328792da
Author: Mohamed Khalfella <mkhalfella at purestorage.com>

nvmet: Rapid Path Failure Recovery set controller identify fields

This commit adds the TP8028 Rapid Path Failure Recovery fields (ciu, cirn,
and ccrl) to struct nvme_id_ctrl, initializes ciu and cirn on controller
allocation and start, and populates them in the Identify Controller
response for non-discovery subsystems.

> diff --git a/drivers/nvme/target/admin-cmd.c b/drivers/nvme/target/admin-cmd.c
> index f12d830986446..5710ae53eb83a 100644
> --- a/drivers/nvme/target/admin-cmd.c
> +++ b/drivers/nvme/target/admin-cmd.c
> @@ -702,6 +702,11 @@ static void nvmet_execute_identify_ctrl(struct nvmet_req *req)
>  	id->mdts = nvmet_ctrl_mdts(req);
>  	id->cntlid = cpu_to_le16(ctrl->cntlid);
>  	id->ver = cpu_to_le32(ctrl->subsys->ver);
> +	if (!nvmet_is_disc_subsys(ctrl->subsys)) {
> +		id->ciu = ctrl->ciu;
> +		id->cirn = cpu_to_le64(ctrl->cirn);
> +		id->ccrl = NVMF_CCR_LIMIT;
> +	}

[Severity: Medium]
Should nvmet_passthru_override_id_ctrl() also override id->ciu, id->cirn,
and id->ccrl?

On a passthrough subsystem, Identify Controller runs through
nvmet_passthru_execute_cmd_work() -> nvmet_passthru_override_id_ctrl(),
which overrides id->cntlid and id->ver but leaves id->ciu, id->cirn, and
id->ccrl with whatever the backend controller returned.  Every fabric
controller connected to the passthrough subsystem will report the backend
device's ciu and cirn instead of ctrl->ciu and ctrl->cirn, and if the
backend controller advertises a non-zero ccrl, hosts will issue
Cross-Controller Reset commands that nvmet_parse_passthru_admin_cmd()
rejects.

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20261114030454.2836543-1-mkhalfella@purestorage.com?part=1



More information about the Linux-nvme mailing list