Commit 5156a8d9 authored by Thorsten Blum's avatar Thorsten Blum Committed by Kevin Hilman
Browse files

ARM: omap2: Replace scnprintf with strscpy in omap3_cpuinfo



Replace scnprintf("%s", ...) with the faster and more direct strscpy().

Signed-off-by: default avatarThorsten Blum <thorsten.blum@linux.dev>
Reviewed-by: default avatarAndreas Kemnade <andreas@kemnade.info>
Link: https://patch.msgid.link/20260224144552.585272-1-thorsten.blum@linux.dev


Signed-off-by: default avatarKevin Hilman <khilman@baylibre.com>
parent 6de23f81
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -17,6 +17,7 @@
#include <linux/io.h>
#include <linux/random.h>
#include <linux/slab.h>
#include <linux/string.h>

#ifdef CONFIG_SOC_BUS
#include <linux/sys_soc.h>
@@ -250,7 +251,7 @@ static void __init omap3_cpuinfo(void)
		cpu_name = "OMAP3503";
	}

	scnprintf(soc_name, sizeof(soc_name), "%s", cpu_name);
	strscpy(soc_name, cpu_name);

	/* Print verbose information */
	n += scnprintf(buf, sizeof(buf) - n, "%s %s (", soc_name, soc_rev);