]> git.ipfire.org Git - thirdparty/linux.git/commit
ACPICA: Define acpi_ut_safe_strncpy() as strscpy_pad() alias
authorRafael J. Wysocki <rafael.j.wysocki@intel.com>
Tue, 30 Jun 2026 16:03:03 +0000 (18:03 +0200)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Wed, 1 Jul 2026 10:29:24 +0000 (12:29 +0200)
commit9825cf2cb59fac7480e7fac9eee13ab9af3f1ea8
treebf3025f7d534a354c5cb0c1b3d67eb37b31af290
parentdc59e4fea9d83f03bad6bddf3fa2e52491777482
ACPICA: Define acpi_ut_safe_strncpy() as strscpy_pad() alias

Commit 292db66afd20 ("ACPICA: Unbreak tools build after switching over
to strscpy_pad()") added an #ifdef based on a __KERNEL__ check which is
sort of nasty to the acpi_ut_safe_strncpy() definition to unbreak ACPICA
tools builds broken by commit 97f7d3f9c9ac ("ACPICA: Replace strncpy()
with strscpy_pad() in acpi_ut_safe_strncpy()").  However, that #ifdef
effectively produces dead code when tools are built because they don't
call acpi_ut_safe_strncpy().

Accordingly, drop the existing definition of acpi_ut_safe_strncpy() and
define it as a strscpy_pad() alias.

Fixes: 292db66afd20 ("ACPICA: Unbreak tools build after switching over to strscpy_pad()")
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
[ rjw: Tweak the changelog ]
Link: https://patch.msgid.link/12941764.O9o76ZdvQC@rafael.j.wysocki
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/acpi/acpica/acutils.h
drivers/acpi/acpica/utnonansi.c
include/acpi/platform/aclinuxex.h