[PATCH v2] nvme/ioctl: add missing space in err message

Caleb Sander Mateos posted 1 patch 10 months, 1 week ago
drivers/nvme/host/ioctl.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
[PATCH v2] nvme/ioctl: add missing space in err message
Posted by Caleb Sander Mateos 10 months, 1 week ago
nvme_validate_passthru_nsid() logs an err message whose format string is
split over 2 lines. There is a missing space between the two pieces,
resulting in log lines like "... does not match nsid (1)of namespace".
Add the missing space between ")" and "of". Also combine the format
string pieces onto a single line to make the err message easier to grep.

Signed-off-by: Caleb Sander Mateos <csander@purestorage.com>
Fixes: e7d4b5493a2d ("nvme: factor out a nvme_validate_passthru_nsid helper")
---
v2: combine format string onto one line

 drivers/nvme/host/ioctl.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/nvme/host/ioctl.c b/drivers/nvme/host/ioctl.c
index e8930146847a..b1b46c2713e1 100644
--- a/drivers/nvme/host/ioctl.c
+++ b/drivers/nvme/host/ioctl.c
@@ -281,12 +281,11 @@ static int nvme_submit_io(struct nvme_ns *ns, struct nvme_user_io __user *uio)
 static bool nvme_validate_passthru_nsid(struct nvme_ctrl *ctrl,
 					struct nvme_ns *ns, __u32 nsid)
 {
 	if (ns && nsid != ns->head->ns_id) {
 		dev_err(ctrl->device,
-			"%s: nsid (%u) in cmd does not match nsid (%u)"
-			"of namespace\n",
+			"%s: nsid (%u) in cmd does not match nsid (%u) of namespace\n",
 			current->comm, nsid, ns->head->ns_id);
 		return false;
 	}
 
 	return true;
-- 
2.45.2
Re: [PATCH v2] nvme/ioctl: add missing space in err message
Posted by Keith Busch 10 months ago
On Thu, Feb 13, 2025 at 10:05:14AM -0700, Caleb Sander Mateos wrote:
> nvme_validate_passthru_nsid() logs an err message whose format string is
> split over 2 lines. There is a missing space between the two pieces,
> resulting in log lines like "... does not match nsid (1)of namespace".
> Add the missing space between ")" and "of". Also combine the format
> string pieces onto a single line to make the err message easier to grep.

Thanks, applied to nvme-6.14.
Re: [PATCH v2] nvme/ioctl: add missing space in err message
Posted by Christoph Hellwig 10 months ago
Looks good:

Reviewed-by: Christoph Hellwig <hch@lst.de>