projects
/
platform
/
kernel
/
linux-rpi.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
30a4bb1
)
ntb: avoid format string in dev_set_name
author
Kees Cook
<keescook@chromium.org>
Fri, 24 Jul 2015 23:35:59 +0000
(16:35 -0700)
committer
Jon Mason
<jdmason@kudzu.us>
Sun, 9 Aug 2015 20:32:22 +0000
(16:32 -0400)
Avoid any chance of format string expansion when calling dev_set_name.
Signed-off-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Jon Mason <jdmason@kudzu.us>
drivers/ntb/ntb.c
patch
|
blob
|
history
diff --git
a/drivers/ntb/ntb.c
b/drivers/ntb/ntb.c
index
23435f2
..
2e25307
100644
(file)
--- a/
drivers/ntb/ntb.c
+++ b/
drivers/ntb/ntb.c
@@
-114,7
+114,7
@@
int ntb_register_device(struct ntb_dev *ntb)
ntb->dev.bus = &ntb_bus;
ntb->dev.parent = &ntb->pdev->dev;
ntb->dev.release = ntb_dev_release;
- dev_set_name(&ntb->dev, pci_name(ntb->pdev));
+ dev_set_name(&ntb->dev,
"%s",
pci_name(ntb->pdev));
ntb->ctx = NULL;
ntb->ctx_ops = NULL;