Skip to content

Commit

Permalink
gpu: ipu-v3: Return proper error on ipu_add_client_devices error path
Browse files Browse the repository at this point in the history
Avoid returning an uninitialized variable in the error path.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
  • Loading branch information
Axel Lin authored and Philipp Zabel committed Sep 2, 2014
1 parent b6c044a commit e4946cd
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion drivers/gpu/ipu-v3/ipu-common.c
Original file line number Diff line number Diff line change
Expand Up @@ -1116,8 +1116,10 @@ static int ipu_add_client_devices(struct ipu_soc *ipu, unsigned long ipu_base)
id++, &reg->pdata, sizeof(reg->pdata));
}

if (IS_ERR(pdev))
if (IS_ERR(pdev)) {
ret = PTR_ERR(pdev);
goto err_register;
}
}

return 0;
Expand Down

0 comments on commit e4946cd

Please sign in to comment.