diff options
| author | Shawn Guo <shengchao.guo@oss.qualcomm.com> | 2026-10-21 12:10:43 +0800 |
|---|---|---|
| committer | Mark Brown <broonie@kernel.org> | 2026-10-26 19:24:15 +0000 |
| commit | 43c69604271d8b54c494fde70bd4a9eaab7a974d (patch) | |
| tree | 0022e5b7fdbaea038d4b448c76fc73f390ae8248 /scripts/basic/split-include.c | |
| parent | 4b832a2af523cbf857a977414c0f07d7f90a4c9d (diff) | |
| download | linux-43c69604271d8b54c494fde70bd4a9eaab7a974d.tar.gz linux-43c69604271d8b54c494fde70bd4a9eaab7a974d.zip | |
ASoC: qcom: q6apm: Clear the right handle on pos buffer unmap
Push/pull graphs map two shared-memory regions per graph, the circular
buffer and the position buffer, and keep a separate DSP handle for
each. The map path tags its token with APM_MMAP_TOKEN_MAP_TYPE_POS_BUF
so the response lands in the right handle, but the unmap path sends a
bare graph ID and the response handler always clears mem_map_handle.
Unmapping the position buffer therefore wipes the circular buffer's
handle and leaves pos_buf_mem_map_handle set. A subsequent unmap of the
circular buffer is skipped, leaking that DSP mapping, and a remap of
the position buffer is skipped because the stale handle looks valid.
Tag the unmap token the same way as the map token and decode it in the
response handler to clear the matching handle.
Fixes: 7c1ac23b178a ("ASoC: qcom: audioreach: Add support for shared memory push/pull modules")
Cc: stable@vger.kernel.org
Reviewed-by: Srinivas Kandagatla <srinivas.kandagatla@oss.qualcomm.com>
Signed-off-by: Shawn Guo <shengchao.guo@oss.qualcomm.com>
Link: https://patch.msgid.link/20261021041044.2080369-3-shengchao.guo@oss.qualcomm.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'scripts/basic/split-include.c')
0 files changed, 0 insertions, 0 deletions
