summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/export-to-postgresql.py
diff options
context:
space:
mode:
authorElena Salomatkina <elena.salomatkina.cmc@gmail.com>2023-11-25 00:08:02 +0300
committerPaolo Abeni <pabeni@redhat.com>2023-11-28 12:43:37 +0300
commitad31c629ca3c87f6d557488c1f9faaebfbcd203c (patch)
tree101b0e32d2da01aab68877d27a83711975557ffd /tools/perf/scripts/python/export-to-postgresql.py
parentec2610b129b49fd3ba0fbbf1fe988774a1af4a2a (diff)
downloadlinux-ad31c629ca3c87f6d557488c1f9faaebfbcd203c.tar.xz
octeontx2-af: Fix possible buffer overflow
A loop in rvu_mbox_handler_nix_bandprof_free() contains a break if (idx == MAX_BANDPROF_PER_PFFUNC), but if idx may reach MAX_BANDPROF_PER_PFFUNC buffer '(*req->prof_idx)[layer]' overflow happens before that check. The patch moves the break to the beginning of the loop. Found by Linux Verification Center (linuxtesting.org) with SVACE. Fixes: e8e095b3b370 ("octeontx2-af: cn10k: Bandwidth profiles config support"). Signed-off-by: Elena Salomatkina <elena.salomatkina.cmc@gmail.com> Reviewed-by: Simon Horman <horms@kernel.org> Reviewed-by: Subbaraya Sundeep <sbhatta@marvell.com> Link: https://lore.kernel.org/r/20231124210802.109763-1-elena.salomatkina.cmc@gmail.com Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Diffstat (limited to 'tools/perf/scripts/python/export-to-postgresql.py')
0 files changed, 0 insertions, 0 deletions