Commit fde28762 authored by Kaaira Gupta's avatar Kaaira Gupta Committed by Greg Kroah-Hartman

staging: media: imx: remove temporary variable

Remove unnecessary local variable `ret` in file `imx6-mipi-csi2.c` and
directly returning the value assigned to `ret.`
Signed-off-by: default avatarKaaira Gupta <kgupta@es.iitr.ac.in>
Reviewed-by: default avatarStefano Brivio <sbrivio@redhat.com>
Link: https://lore.kernel.org/r/20200313215406.2485-3-kgupta@es.iitr.ac.inSigned-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent e3d21cbf
......@@ -592,22 +592,19 @@ static int csi2_probe(struct platform_device *pdev)
csi2->pllref_clk = devm_clk_get(&pdev->dev, "ref");
if (IS_ERR(csi2->pllref_clk)) {
v4l2_err(&csi2->sd, "failed to get pll reference clock\n");
ret = PTR_ERR(csi2->pllref_clk);
return ret;
return PTR_ERR(csi2->pllref_clk);
}
csi2->dphy_clk = devm_clk_get(&pdev->dev, "dphy");
if (IS_ERR(csi2->dphy_clk)) {
v4l2_err(&csi2->sd, "failed to get dphy clock\n");
ret = PTR_ERR(csi2->dphy_clk);
return ret;
return PTR_ERR(csi2->dphy_clk);
}
csi2->pix_clk = devm_clk_get(&pdev->dev, "pix");
if (IS_ERR(csi2->pix_clk)) {
v4l2_err(&csi2->sd, "failed to get pixel clock\n");
ret = PTR_ERR(csi2->pix_clk);
return ret;
return PTR_ERR(csi2->pix_clk);
}
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment