diff options
author | Sakari Ailus <sakari.ailus@linux.intel.com> | 2017-02-28 06:53:27 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@s-opensource.com> | 2017-07-19 15:50:13 -0400 |
commit | 58f6d3675a2c423a95739ad6719607a7681af954 (patch) | |
tree | f1b02a2dce994dc29300f35ded34e731869154b0 /drivers/media/platform/omap3isp/isp.c | |
parent | a4573084cb7596b13e0853fa97b069c8fb30b6e7 (diff) | |
download | linux-58f6d3675a2c423a95739ad6719607a7681af954.tar.bz2 |
media: omap3isp: Ignore endpoints with invalid configuration
If endpoint has an invalid configuration, ignore it instead of happily
proceeding to use it nonetheless. Ignoring such an endpoint is better than
failing since there could be multiple endpoints, only some of which are
bad.
Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Tested-by: Pavel Machek <pavel@ucw.cz>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Diffstat (limited to 'drivers/media/platform/omap3isp/isp.c')
-rw-r--r-- | drivers/media/platform/omap3isp/isp.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/media/platform/omap3isp/isp.c b/drivers/media/platform/omap3isp/isp.c index dbaede0d8974..2de7a27bb0e5 100644 --- a/drivers/media/platform/omap3isp/isp.c +++ b/drivers/media/platform/omap3isp/isp.c @@ -2111,10 +2111,12 @@ static int isp_fwnodes_parse(struct device *dev, if (!isd) goto error; - notifier->subdevs[notifier->num_subdevs] = &isd->asd; + if (isp_fwnode_parse(dev, fwnode, isd)) { + devm_kfree(dev, isd); + continue; + } - if (isp_fwnode_parse(dev, fwnode, isd)) - goto error; + notifier->subdevs[notifier->num_subdevs] = &isd->asd; isd->asd.match.fwnode.fwnode = fwnode_graph_get_remote_port_parent(fwnode); |