Commit 90438926 authored by Guennadi Liakhovetski's avatar Guennadi Liakhovetski Committed by Mauro Carvalho Chehab

[media] soc-camera: don't attach the client to the host during probing

During client probing we only have to turn on the host's clock, no need to
actually attach the client to the host.
Signed-off-by: default avatarGuennadi Liakhovetski <g.liakhovetski@gmx.de>
Acked-by: default avatarHans Verkuil <hans.verkuil@cisco.com>
Acked-by: default avatarLaurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent a78fcc11
...@@ -1177,7 +1177,7 @@ static int soc_camera_probe(struct soc_camera_device *icd) ...@@ -1177,7 +1177,7 @@ static int soc_camera_probe(struct soc_camera_device *icd)
ssdd->reset(icd->pdev); ssdd->reset(icd->pdev);
mutex_lock(&ici->host_lock); mutex_lock(&ici->host_lock);
ret = soc_camera_add_device(icd); ret = ici->ops->clock_start(ici);
mutex_unlock(&ici->host_lock); mutex_unlock(&ici->host_lock);
if (ret < 0) if (ret < 0)
goto eadd; goto eadd;
...@@ -1250,7 +1250,7 @@ static int soc_camera_probe(struct soc_camera_device *icd) ...@@ -1250,7 +1250,7 @@ static int soc_camera_probe(struct soc_camera_device *icd)
icd->field = mf.field; icd->field = mf.field;
} }
soc_camera_remove_device(icd); ici->ops->clock_stop(ici);
mutex_unlock(&ici->host_lock); mutex_unlock(&ici->host_lock);
...@@ -1273,7 +1273,7 @@ static int soc_camera_probe(struct soc_camera_device *icd) ...@@ -1273,7 +1273,7 @@ static int soc_camera_probe(struct soc_camera_device *icd)
icd->vdev = NULL; icd->vdev = NULL;
evdc: evdc:
mutex_lock(&ici->host_lock); mutex_lock(&ici->host_lock);
soc_camera_remove_device(icd); ici->ops->clock_stop(ici);
mutex_unlock(&ici->host_lock); mutex_unlock(&ici->host_lock);
eadd: eadd:
v4l2_ctrl_handler_free(&icd->ctrl_handler); v4l2_ctrl_handler_free(&icd->ctrl_handler);
......
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