From 61bdbecb27911e5bb5bc6eec261efc08e407386e Mon Sep 17 00:00:00 2001 From: Caleb Sander Date: Thu, 14 Sep 2023 15:52:17 -0600 Subject: [PATCH] ioctl: fix swapped parameters in nvme_set_features_host_id() nvme_set_features_host_id()'s prototype says the parameter EXHID comes before SAVE, but its definition does the opposite, causing the parameters to be misinterpreted. Match the definition to the declaration. Signed-off-by: Caleb Sander --- src/nvme/ioctl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/nvme/ioctl.c b/src/nvme/ioctl.c index a183f501..c0136490 100644 --- a/src/nvme/ioctl.c +++ b/src/nvme/ioctl.c @@ -845,7 +845,7 @@ int nvme_set_features_sw_progress(int fd, __u8 pbslc, bool save, result); } -int nvme_set_features_host_id(int fd, bool save, bool exhid, __u8 *hostid) +int nvme_set_features_host_id(int fd, bool exhid, bool save, __u8 *hostid) { __u32 len = exhid ? 16 : 8; __u32 value = !!exhid; -- 2.50.1