mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-03 23:58:05 +00:00
media: max9286: Free control handler
The control handler is leaked in some probe-time error paths, as well as
in the remove path. Fix it.
Fixes: 66d8c9d242
("media: i2c: Add MAX9286 driver")
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se>
Reviewed-by: Jacopo Mondi <jacopo.mondi@ideasonboard.com>
Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
This commit is contained in:
parent
1968808dd1
commit
bfce6a12e5
1 changed files with 1 additions and 0 deletions
|
@ -1122,6 +1122,7 @@ static int max9286_v4l2_register(struct max9286_priv *priv)
|
|||
static void max9286_v4l2_unregister(struct max9286_priv *priv)
|
||||
{
|
||||
fwnode_handle_put(priv->sd.fwnode);
|
||||
v4l2_ctrl_handler_free(&priv->ctrls);
|
||||
v4l2_async_unregister_subdev(&priv->sd);
|
||||
max9286_v4l2_notifier_unregister(priv);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue