Commit 721110b3 authored by Sachin Kamat's avatar Sachin Kamat Committed by Mauro Carvalho Chehab

[media] soc_camera/sh_mobile_csi2: Remove redundant platform_set_drvdata()

Commit 0998d063 (device-core: Ensure drvdata = NULL when no
driver is bound) removes the need to set driver data field to
NULL.
Signed-off-by: default avatarSachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: default avatarGuennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent 8b070680
...@@ -340,18 +340,13 @@ static int sh_csi2_probe(struct platform_device *pdev) ...@@ -340,18 +340,13 @@ static int sh_csi2_probe(struct platform_device *pdev)
ret = v4l2_device_register_subdev(pdata->v4l2_dev, &priv->subdev); ret = v4l2_device_register_subdev(pdata->v4l2_dev, &priv->subdev);
dev_dbg(&pdev->dev, "%s(%p): ret(register_subdev) = %d\n", __func__, priv, ret); dev_dbg(&pdev->dev, "%s(%p): ret(register_subdev) = %d\n", __func__, priv, ret);
if (ret < 0) if (ret < 0)
goto esdreg; return ret;
pm_runtime_enable(&pdev->dev); pm_runtime_enable(&pdev->dev);
dev_dbg(&pdev->dev, "CSI2 probed.\n"); dev_dbg(&pdev->dev, "CSI2 probed.\n");
return 0; return 0;
esdreg:
platform_set_drvdata(pdev, NULL);
return ret;
} }
static int sh_csi2_remove(struct platform_device *pdev) static int sh_csi2_remove(struct platform_device *pdev)
...@@ -360,7 +355,6 @@ static int sh_csi2_remove(struct platform_device *pdev) ...@@ -360,7 +355,6 @@ static int sh_csi2_remove(struct platform_device *pdev)
v4l2_device_unregister_subdev(&priv->subdev); v4l2_device_unregister_subdev(&priv->subdev);
pm_runtime_disable(&pdev->dev); pm_runtime_disable(&pdev->dev);
platform_set_drvdata(pdev, NULL);
return 0; return 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