summaryrefslogtreecommitdiff
path: root/linux/include/media
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@infradead.org>2008-02-25 12:12:17 +0000
committerMauro Carvalho Chehab <mchehab@infradead.org>2008-02-25 12:12:17 +0000
commit68f9dbd45264796ec356a4162cb1299a31c82101 (patch)
treed4686e91bb0f340e2693f7d41f9c44d9c5a65aed /linux/include/media
parent0bb418357c0e03d3d6fd6d5bea64dccefd9694eb (diff)
downloadmediapointer-dvb-s2-68f9dbd45264796ec356a4162cb1299a31c82101.tar.gz
mediapointer-dvb-s2-68f9dbd45264796ec356a4162cb1299a31c82101.tar.bz2
soc-camera: deactivate cameras when not used
From: Guennadi Liakhovetski <g.liakhovetski@pengutronix.de> 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 'linux/include/media')
-rw-r--r--linux/include/media/soc_camera.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/linux/include/media/soc_camera.h b/linux/include/media/soc_camera.h
index 69aba7188..c886b1e64 100644
--- a/linux/include/media/soc_camera.h
+++ b/linux/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 {