From: Thorsten Blum Date: Tue, 27 Jan 2026 22:49:49 +0000 (+0100) Subject: genirq/proc: Replace snprintf with strscpy in register_handler_proc X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2dfc417414c6eea4e167b2f46283cded846c531a;p=thirdparty%2Flinux.git genirq/proc: Replace snprintf with strscpy in register_handler_proc Replace snprintf("%s", ...) with the faster and more direct strscpy(). Signed-off-by: Thorsten Blum Signed-off-by: Thomas Gleixner Link: https://patch.msgid.link/20260127224949.441391-2-thorsten.blum@linux.dev --- diff --git a/kernel/irq/proc.c b/kernel/irq/proc.c index 77258eafbf632..b0999a4f1f688 100644 --- a/kernel/irq/proc.c +++ b/kernel/irq/proc.c @@ -12,6 +12,7 @@ #include #include #include +#include #include "internals.h" @@ -317,7 +318,7 @@ void register_handler_proc(unsigned int irq, struct irqaction *action) if (!desc->dir || action->dir || !action->name || !name_unique(irq, action)) return; - snprintf(name, MAX_NAMELEN, "%s", action->name); + strscpy(name, action->name); /* create /proc/irq/1234/handler/ */ action->dir = proc_mkdir(name, desc->dir);