Re: [PATCH v1] ACPICA: Unbreak tools build after switching over to strscpy_pad()
From: Kees Cook
Date: Tue Jun 23 2026 - 15:29:39 EST
On Mon, Jun 22, 2026 at 08:23:09PM +0200, Rafael J. Wysocki wrote:
> From: Rafael J. Wysocki <rafael.j.wysocki@xxxxxxxxx>
>
> Commit 97f7d3f9c9ac ("ACPICA: Replace strncpy() with strscpy_pad() in
> acpi_ut_safe_strncpy()") switched over the ACPICA code in the kernel to
> using strscpy_pad() instead of a combination of strncpy() and manual
> NUL-termination of the destination string, but it overlooked the fact
> that tools also use the code in question and strscpy_pad() is not
> defined in those builds.
Eek. Thanks for fixing this! (This looks almost exactly like the shared
BPF header solution: non-kernel build just keeps using strncpy.)
Reviewed-by: Kees Cook <kees@xxxxxxxxxx>
--
Kees Cook