summaryrefslogtreecommitdiffstats
path: root/drivers/scsi/aacraid/commsup.c
diff options
context:
space:
mode:
authorKees Cook <keescook@chromium.org>2013-07-03 15:04:58 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2013-07-03 16:07:41 -0700
commitf170168b9a0b61ea1e647b082b38f605f1d3de3e (patch)
tree4381c129ee9af108e368e6c8255df53cbe233257 /drivers/scsi/aacraid/commsup.c
parentd8537548c924db3c44afde7646b6e220c7beb79d (diff)
downloadtalos-obmc-linux-f170168b9a0b61ea1e647b082b38f605f1d3de3e.tar.gz
talos-obmc-linux-f170168b9a0b61ea1e647b082b38f605f1d3de3e.zip
drivers: avoid parsing names as kthread_run() format strings
Calling kthread_run with a single name parameter causes it to be handled as a format string. Many callers are passing potentially dynamic string content, so use "%s" in those cases to avoid any potential accidents. Signed-off-by: Kees Cook <keescook@chromium.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/scsi/aacraid/commsup.c')
-rw-r--r--drivers/scsi/aacraid/commsup.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/scsi/aacraid/commsup.c b/drivers/scsi/aacraid/commsup.c
index 1be0776a80c4..cab190af6345 100644
--- a/drivers/scsi/aacraid/commsup.c
+++ b/drivers/scsi/aacraid/commsup.c
@@ -1336,7 +1336,8 @@ static int _aac_reset_adapter(struct aac_dev *aac, int forced)
if ((retval = pci_set_dma_mask(aac->pdev, DMA_BIT_MASK(32))))
goto out;
if (jafo) {
- aac->thread = kthread_run(aac_command_thread, aac, aac->name);
+ aac->thread = kthread_run(aac_command_thread, aac, "%s",
+ aac->name);
if (IS_ERR(aac->thread)) {
retval = PTR_ERR(aac->thread);
goto out;
OpenPOWER on IntegriCloud