[PATCH v3 1/1] nvme : Add ioctl to query nvme attributes

Keith Busch kbusch at kernel.org
Fri Nov 18 14:35:03 PST 2022


On Thu, Nov 17, 2022 at 03:13:37PM +0100, Joel Granados wrote:
> +#define NVME_IOCTL_GET_ATTR	_IOWR('N', 0x50, struct nvme_get_attr)

Isn't the ioctl's number derived from the sizeof the parameter? IOW, if
you add new fields to the struct in the future, the ioctl number will
change, breaking older applications that were using it. I don't think we
want to keep adding new ioctl's to support legacy users, so probably
padding that struct with plenty of reserved space is the way to go.



More information about the Linux-nvme mailing list