Re: [PATCH] power: reset: reboot-mode: fix -Wformat-security warning

From: Sebastian Reichel

Date: Wed Mar 11 2026 - 03:21:38 EST



On Fri, 06 Mar 2026 16:07:34 +0100, Arnd Bergmann wrote:
> The device_create() function expects a format string to construct a device
> name, so passing a variable here introduces a possible vulnerability in
> case the string can contain '%' characters:
>
> drivers/power/reset/reboot-mode.c:148:22: error: format string is not a string literal (potentially insecure) [-Werror,-Wformat-security]
> drivers/power/reset/reboot-mode.c:148:22: note: treat the string as an argument to avoid this
> 148 | (void *)priv, reboot->dev->driver->name);
>
> [...]

Applied, thanks!

[1/1] power: reset: reboot-mode: fix -Wformat-security warning
commit: c7e05ab38adc44d0cae4888016829359dcbba7b2

Best regards,
--
Sebastian Reichel <sebastian.reichel@xxxxxxxxxxxxx>