mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-06 08:46:46 +00:00
media: imx: csc/scaler: fix v4l2_ctrl_handler memory leak
[ Upstream commit4797a3dd46
] Free the memory allocated in v4l2_ctrl_handler_init on release. Fixes:a8ef0488cc
("media: imx: add csc/scaler mem2mem device") Signed-off-by: Lucas Stach <l.stach@pengutronix.de> Reviewed-by: Philipp Zabel <p.zabel@pengutronix.de> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
parent
d7e352130a
commit
42492b0015
1 changed files with 1 additions and 0 deletions
|
@ -803,6 +803,7 @@ static int ipu_csc_scaler_release(struct file *file)
|
|||
|
||||
dev_dbg(priv->dev, "Releasing instance %p\n", ctx);
|
||||
|
||||
v4l2_ctrl_handler_free(&ctx->ctrl_hdlr);
|
||||
v4l2_m2m_ctx_release(ctx->fh.m2m_ctx);
|
||||
v4l2_fh_del(&ctx->fh);
|
||||
v4l2_fh_exit(&ctx->fh);
|
||||
|
|
Loading…
Reference in a new issue