[PATCH] firmware: arm_scmi: Avoid non-constant printk format strings

Sudeep Holla sudeep.holla at arm.com
Thu Apr 4 07:12:21 PDT 2024


On Wed, 03 Apr 2024 13:10:24 +0200, Arnd Bergmann wrote:
> A recent rework changed the constant format strings to a local variable,
> which causes warnings from clang when -Wformat-security is enabled:
>
> drivers/firmware/arm_scmi/driver.c: In function 'scmi_probe':
> drivers/firmware/arm_scmi/driver.c:2936:25: error: format not a string literal and no format arguments [-Werror=format-security]
>  2936 |                         dev_err(dev, err_str);
>       |                         ^~~~~~~
> drivers/firmware/arm_scmi/driver.c:2993:9: error: format not a string literal and no format arguments [-Werror=format-security]
>  2993 |         return dev_err_probe(dev, ret, err_str);
>
> [...]

Applied to sudeep.holla/linux (for-next/scmi/updates), thanks!

[1/1] firmware: arm_scmi: Avoid non-constant printk format strings
      https://git.kernel.org/sudeep.holla/c/495667d49c50
--
Regards,
Sudeep




More information about the linux-arm-kernel mailing list