Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

hpet: 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://lore.kernel.org/r/20250811122358.542190-1-zhao.xichao@vivo.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Xichao Zhao and committed by
Greg Kroah-Hartman
c585a4ad 0e805e8b

+1 -1
+1 -1
drivers/char/hpet.c
··· 867 867 868 868 printk(KERN_INFO "hpet%u: at MMIO 0x%lx, IRQ%s", 869 869 hpetp->hp_which, hdp->hd_phys_address, 870 - hpetp->hp_ntimer > 1 ? "s" : ""); 870 + str_plural(hpetp->hp_ntimer)); 871 871 for (i = 0; i < hpetp->hp_ntimer; i++) 872 872 printk(KERN_CONT "%s %u", i > 0 ? "," : "", hdp->hd_irq[i]); 873 873 printk(KERN_CONT "\n");