From: Damien Le Moal <dlemoal@kernel.org>
To: Arnd Bergmann <arnd@kernel.org>,
Dongdong Hao <doubled@leap-io-kernel.com>,
"James E.J. Bottomley" <James.Bottomley@HansenPartnership.com>,
"Martin K. Petersen" <mkp@kernel.org>,
Hannes Reinecke <hare@kernel.org>
Cc: Arnd Bergmann <arnd@arndb.de>,
Bart Van Assche <bvanassche@acm.org>,
linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] scsi: leapraid: avoid -Wformat-security warning
Date: Wed, 16 Sep 2026 09:02:53 +0700 [thread overview]
Message-ID: <9771af84-afef-46eb-a848-058e60bcefce@kernel.org> (raw)
In-Reply-To: <20260915202134.3534708-1-arnd@kernel.org>
On 2026/09/16 3:20, Arnd Bergmann wrote:
> From: Arnd Bergmann <arnd@arndb.de>
>
> When extra warnings are enabled, the alloc_ordered_workqueue() function
> cannot be called with a variable name for the format string:
>
> drivers/scsi/leapraid/leapraid_os.c: In function 'leapraid_probe':
> drivers/scsi/leapraid/leapraid_os.c:2062:58: error: format not a string literal and no format arguments [-Werror=format-security]
> 2062 | alloc_ordered_workqueue(adapter->fw_evt_s.fw_evt_name, 0);
> | ~~~~~~~~~~~~~~~~~^~~~~~~~~~~~
>
> As the string is only assembled before the call and not used anywhere
> else, just fold the earlier snprintf() into the alloc_ordered_workqueue()
> call.
>
> Fixes: 5597088c9e79 ("scsi: leapraid: Add new SCSI driver")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Reviewed-by: Damien Le Moal <dlemoal@kernel.org>
--
Damien Le Moal
Western Digital Research
prev parent reply other threads:[~2026-09-16 2:03 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-15 20:20 Arnd Bergmann
2026-09-16 2:02 ` Damien Le Moal [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=9771af84-afef-46eb-a848-058e60bcefce@kernel.org \
--to=dlemoal@kernel.org \
--cc=James.Bottomley@HansenPartnership.com \
--cc=arnd@arndb.de \
--cc=arnd@kernel.org \
--cc=bvanassche@acm.org \
--cc=doubled@leap-io-kernel.com \
--cc=hare@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=mkp@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®