Commit c585a4ad authored by Xichao Zhao's avatar Xichao Zhao Committed by Greg Kroah-Hartman
Browse files

hpet: Use str_plural() to simplify the code



Use the string choice helper function str_plural() to simplify the code.

Signed-off-by: default avatarXichao Zhao <zhao.xichao@vivo.com>
Link: https://lore.kernel.org/r/20250811122358.542190-1-zhao.xichao@vivo.com


Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 0e805e8b
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -867,7 +867,7 @@ int hpet_alloc(struct hpet_data *hdp)

	printk(KERN_INFO "hpet%u: at MMIO 0x%lx, IRQ%s",
		hpetp->hp_which, hdp->hd_phys_address,
		hpetp->hp_ntimer > 1 ? "s" : "");
		str_plural(hpetp->hp_ntimer));
	for (i = 0; i < hpetp->hp_ntimer; i++)
		printk(KERN_CONT "%s %u", i > 0 ? "," : "", hdp->hd_irq[i]);
	printk(KERN_CONT "\n");