media: omap3isp: Fix memleak in isp_probe
authorDinghao Liu <dinghao.liu@zju.edu.cn>
Mon, 24 Aug 2020 06:53:52 +0000 (08:53 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 29 Oct 2020 08:07:01 +0000 (09:07 +0100)
commit4e439ef0f8c1ff2a9699aa5fded4943e975891cb
treed306abd2012a4bee8b734d80323403886711a09c
parent068e68ba26d7d460e26b58cc9a061cd1641277b3
media: omap3isp: Fix memleak in isp_probe

[ Upstream commit d8fc21c17099635e8ebd986d042be65a6c6b5bd0 ]

When devm_ioremap_resource() fails, isp should be
freed just like other error paths in isp_probe.

Fixes: 8644cdf972dd6 ("[media] omap3isp: Replace many MMIO regions by two")
Signed-off-by: Dinghao Liu <dinghao.liu@zju.edu.cn>
Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/media/platform/omap3isp/isp.c