Skip to content

Commit b8db551

Browse files
Xichao Zhaorafaeljw
authored andcommitted
PNP: isapnp: use str_plural() to simplify the code
Use the string choice helper function str_plural() to simplify the code. Signed-off-by: Xichao Zhao <zhao.xichao@vivo.com> Link: https://patch.msgid.link/20250818082451.497935-1-zhao.xichao@vivo.com Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
1 parent 1b237f1 commit b8db551

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

drivers/pnp/isapnp/core.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@
2727
#include <linux/init.h>
2828
#include <linux/isapnp.h>
2929
#include <linux/mutex.h>
30+
#include <linux/string_choices.h>
3031
#include <asm/io.h>
3132

3233
#include "../base.h"
@@ -1037,7 +1038,7 @@ static int __init isapnp_init(void)
10371038
if (cards)
10381039
printk(KERN_INFO
10391040
"isapnp: %i Plug & Play card%s detected total\n", cards,
1040-
cards > 1 ? "s" : "");
1041+
str_plural(cards));
10411042
else
10421043
printk(KERN_INFO "isapnp: No Plug & Play card found\n");
10431044

0 commit comments

Comments
 (0)