diff options
author | Laurentiu Palcu <laurentiu.palcu@oss.nxp.com> | 2024-10-23 08:45:22 +0000 |
---|---|---|
committer | Jason Liu <jason.hui.liu@nxp.com> | 2024-11-18 20:24:05 +0800 |
commit | da02bb4fef0bd7f249b43c41c18b78b77c16d3b3 (patch) | |
tree | 9e5a83417ae4608ec875def60282f0c5c232d9c6 /lib/debugobjects.c | |
parent | d0fd392ad3432fa2daa0c66ef8baddd26fc0a5b5 (diff) |
LF-13923 media: nxp: imx8-isi: better handle the m2m usage_count
Currently, if streamon/streamoff calls are imbalanced we can either end up
with a negative ISI m2m usage_count (if streamoff() is called more times
than streamon()) in which case we'll not be able to restart the ISI pipe
next time, or the usage_count never gets to 0 and the pipe is never
switched off.
To avoid that, add a 'streaming' flag to mxc_isi_m2m_ctx_queue_data and use it
in the streamon/streamoff to avoid incrementing/decrementing the usage_count
uselessly, if called multiple times from the same context.
Fixes: cf21f328fcaf ("media: nxp: Add i.MX8 ISI driver")
Suggested-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Laurentiu Palcu <laurentiu.palcu@oss.nxp.com>
Tested-by: Guoniu Zhou <guoniu.zhou@nxp.com>
Reviewed-by: Robert Chiras <robert.chiras@nxp.com>
Acked-by: Jason Liu <jason.hui.liu@nxp.com>
Diffstat (limited to 'lib/debugobjects.c')
0 files changed, 0 insertions, 0 deletions