summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/parallel-perf.py
diff options
context:
space:
mode:
authorRosen Penev <rosenp@gmail.com>2026-07-18 16:52:27 -0700
committerVinod Koul <vkoul@kernel.org>2026-09-03 19:22:36 +0530
commitd805aa5b6088b193debabaa80cc0991bfa2bd057 (patch)
tree53d4f1bc0260b3045a8dbb6552f2347bd93568a3 /tools/perf/scripts/python/parallel-perf.py
parent62c267ce97444f8a381f2bb3cd5d534eb362c540 (diff)
dmaengine: fsl_raid: avoid free_q underflow in free_chan_resources
fsl_re_free_chan_resources() loops alloc_count times calling list_first_entry() on free_q without checking whether the list still has entries. If descriptors remain un-acked or pending in submit_q / active_q / ack_q when the channel resources are freed, free_q becomes smaller than alloc_count and list_first_entry() returns the list head, causing list_del() to corrupt the list head and dereference a bogus pointer. Walk free_q with list_for_each_entry_safe() until it is empty, decrementing alloc_count per freed descriptor, instead of relying on the alloc_count count. Fixes: ad80da658bbc ("dmaengine: Driver support for FSL RaidEngine device.") Assisted-by: opencode:hy3-free Signed-off-by: Rosen Penev <rosenp@gmail.com> Reviewed-by: Frank Li <Frank.Li@nxp.com> Link: https://patch.msgid.link/20260718235227.385108-1-rosenp@gmail.com Signed-off-by: Vinod Koul <vkoul@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python/parallel-perf.py')
0 files changed, 0 insertions, 0 deletions