The Linux Kernel Mailing List
 help / color / mirror / Atom feed
* [PATCH] ntfs: use str_plural in ntfs_attr_make_non_resident
@ 2026-05-11  9:50 Thorsten Blum
  2026-05-11 14:54 ` Namjae Jeon
  0 siblings, 1 reply; 2+ messages in thread
From: Thorsten Blum @ 2026-05-11  9:50 UTC (permalink / raw)
  To: Namjae Jeon, Hyunchul Lee; +Cc: Thorsten Blum, linux-fsdevel, linux-kernel

Replace the manual ternary "s" pluralization with str_plural() to
simplify the code.

Signed-off-by: Thorsten Blum <thorsten.blum@linux.dev>
---
 fs/ntfs/attrib.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/fs/ntfs/attrib.c b/fs/ntfs/attrib.c
index 97b660eaa00c..162aad2cd08e 100644
--- a/fs/ntfs/attrib.c
+++ b/fs/ntfs/attrib.c
@@ -16,6 +16,7 @@
  * Copyright (c) 2010 Erik Larsson
  */
 
+#include <linux/string_choices.h>
 #include <linux/writeback.h>
 #include <linux/iomap.h>
 
@@ -1857,7 +1858,7 @@ int ntfs_attr_make_non_resident(struct ntfs_inode *ni, const u32 data_size)
 		if (IS_ERR(rl)) {
 			err = PTR_ERR(rl);
 			ntfs_debug("Failed to allocate cluster%s, error code %i.",
-					ntfs_bytes_to_cluster(vol, new_size) > 1 ? "s" : "",
+					str_plural(ntfs_bytes_to_cluster(vol, new_size)),
 					err);
 			goto folio_err_out;
 		}

^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2026-05-11 14:54 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-05-11  9:50 [PATCH] ntfs: use str_plural in ntfs_attr_make_non_resident Thorsten Blum
2026-05-11 14:54 ` Namjae Jeon

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox