[PATCH 1/1] nvme: use macro definitions for setting reservation values
Keith Busch
kbusch at kernel.org
Thu Sep 29 11:56:30 PDT 2022
On Thu, Sep 29, 2022 at 02:59:19PM +0300, Max Gurtovoy wrote:
> +/*
> + * Reservation Type Encoding
> + */
> +enum {
> + NVME_PR_WRITE_EXCLUSIVE = 1, /* Write Exclusive Reservation */
> + NVME_PR_EXCLUSIVE_ACCESS = 2, /* Exclusive Access Reservation */
> + NVME_PR_WRITE_EXCLUSIVE_REG_ONLY = 3, /* Write Exclusive - Registrants Only Reservation */
> + NVME_PR_EXCLUSIVE_ACCESS_REG_ONLY = 4, /* Exclusive Access - Registrants Only Reservation */
> + NVME_PR_WRITE_EXCLUSIVE_ALL_REGS = 5, /* Write Exclusive - All Registrants Reservation */
> + NVME_PR_EXCLUSIVE_ACCESS_ALL_REGS = 6, /* Exclusive Access - All Registrants Reservation */
> +};
The comments are unnecessary, and this would be more readable if the values
were tab aligned like 'enum pr_type'.
Otherwise looks good.
More information about the Linux-nvme
mailing list