[PATCH] nvme: reject an administrative controller type on reinitialization

Christoph Hellwig hch at lst.de
Tue Nov 24 21:16:08 PST 2026


On Tue, Nov 24, 2026 at 10:31:22PM +0900, Yehyeong Lee wrote:
> nvme_init_ctrl_finish() takes the controller type from the Identify
> Controller data, and for an administrative controller it overrides
> ctrl->queue_count to 1 so that only an admin queue is created.  The
> Identify data is read again on every reconnect, so a controller that
> reported itself as an I/O controller on the first connect, and whose
> namespaces are in use, can report itself as an administrative controller
> on a reconnect.

Well, we'll have more issues if a reconnect changes the controller
type.  So please check for that just after issuing the identify
controller and reject such a shape changing controller.

And please cut the commit message down to the basics.




More information about the Linux-nvme mailing list