git.droids-corp.org
/
dpdk.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d9b8838
)
net/bnx2x: fix memzone name overrun
author
Andy Green
<andy@warmcat.com>
Mon, 14 May 2018 05:04:43 +0000
(13:04 +0800)
committer
Thomas Monjalon
<thomas@monjalon.net>
Tue, 15 May 2018 20:28:12 +0000
(22:28 +0200)
Fixes:
540a211084a7
("bnx2x: driver core")
Cc: stable@dpdk.org
Signed-off-by: Andy Green <andy@warmcat.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Rasesh Mody <rasesh.mody@cavium.com>
drivers/net/bnx2x/bnx2x.c
patch
|
blob
|
history
diff --git
a/drivers/net/bnx2x/bnx2x.c
b/drivers/net/bnx2x/bnx2x.c
index
bfd9cce
..
3892934
100644
(file)
--- a/
drivers/net/bnx2x/bnx2x.c
+++ b/
drivers/net/bnx2x/bnx2x.c
@@
-170,10
+170,10
@@
bnx2x_dma_alloc(struct bnx2x_softc *sc, size_t size, struct bnx2x_dma *dma,
dma->sc = sc;
if (IS_PF(sc))
- s
printf(mz_name
, "bnx2x%d_%s_%" PRIx64, SC_ABS_FUNC(sc), msg,
+ s
nprintf(mz_name, sizeof(mz_name)
, "bnx2x%d_%s_%" PRIx64, SC_ABS_FUNC(sc), msg,
rte_get_timer_cycles());
else
- s
printf(mz_name
, "bnx2x%d_%s_%" PRIx64, sc->pcie_device, msg,
+ s
nprintf(mz_name, sizeof(mz_name)
, "bnx2x%d_%s_%" PRIx64, sc->pcie_device, msg,
rte_get_timer_cycles());
/* Caller must take care that strlen(mz_name) < RTE_MEMZONE_NAMESIZE */