diff options
author | Guennadi Liakhovetski <g.liakhovetski@pengutronix.de> | 2008-04-22 17:45:32 (GMT) |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@infradead.org> | 2008-04-24 17:07:46 (GMT) |
commit | 9dc4e48fbea5412127ce2eb30d688c4fc55f5565 (patch) | |
tree | 8b0912f884f3613922f2bba2198d6b8fc3f95691 /include/media/soc_camera.h | |
parent | 6f2896756c4f1d4df5bd30599e6444c9513cfe8d (diff) | |
download | linux-9dc4e48fbea5412127ce2eb30d688c4fc55f5565.tar.xz |
V4L/DVB (7276): soc-camera: deactivate cameras when not used
Only attach cameras to the host interface for probing, then detach until
open. This allows platforms with several cameras on an interface,
physically supporting only one camera, to handle multiple cameras and
activate them selectively after initial probing. The first attach during
probe is needed to activate the host interface to be able to physically
communicate with cameras.
Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@pengutronix.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'include/media/soc_camera.h')
-rw-r--r-- | include/media/soc_camera.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/media/soc_camera.h b/include/media/soc_camera.h index 69aba718..c886b1e 100644 --- a/include/media/soc_camera.h +++ b/include/media/soc_camera.h @@ -41,6 +41,8 @@ struct soc_camera_device { int (*probe)(struct soc_camera_device *icd); void (*remove)(struct soc_camera_device *icd); struct module *owner; + /* soc_camera.c private count. Only accessed with video_lock held */ + int use_count; }; struct soc_camera_file { |