summaryrefslogtreecommitdiffstats
path: root/kernel/drivers/media/platform/blackfin/ppi.c
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/drivers/media/platform/blackfin/ppi.c')
-rw-r--r--kernel/drivers/media/platform/blackfin/ppi.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/kernel/drivers/media/platform/blackfin/ppi.c b/kernel/drivers/media/platform/blackfin/ppi.c
index cff63e511..b8f3d9fa6 100644
--- a/kernel/drivers/media/platform/blackfin/ppi.c
+++ b/kernel/drivers/media/platform/blackfin/ppi.c
@@ -214,6 +214,8 @@ static int ppi_set_params(struct ppi_if *ppi, struct ppi_params *params)
if (params->dlen > 24 || params->dlen <= 0)
return -EINVAL;
pctrl = devm_pinctrl_get(ppi->dev);
+ if (IS_ERR(pctrl))
+ return PTR_ERR(pctrl);
pstate = pinctrl_lookup_state(pctrl,
pin_state[(params->dlen + 7) / 8 - 1]);
if (pinctrl_select_state(pctrl, pstate))