aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2009-06-17 00:15:42 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2009-06-17 00:15:42 -0400
commit0dd5198672dd2bbeb933862e1fc82162e0b636be (patch)
treec9efed20d90603c4d1626c21bd7aab1e7fc74a58 /include
parentc868d550115b9ccc0027c67265b9520790f05601 (diff)
parent11c635a25b9f3a5d87409ce46cf2e05c500251ec (diff)
Merge branch 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6
* 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6: (425 commits) V4L/DVB (11870): gspca - main: VIDIOC_ENUM_FRAMESIZES ioctl added. V4L/DVB (12004): poll method lose race condition V4L/DVB (11894): flexcop-pci: dmesg visible names broken V4L/DVB (11892): Siano: smsendian - declare function as extern V4L/DVB (11891): Siano: smscore - bind the GPIO SMS protocol V4L/DVB (11890): Siano: smscore - remove redundant code V4L/DVB (11889): Siano: smsdvb - add DVB v3 events V4L/DVB (11888): Siano: smsusb - remove redundant ifdef V4L/DVB (11887): Siano: smscards - add board (target) events V4L/DVB (11886): Siano: smscore - fix some new GPIO definitions names V4L/DVB (11885): Siano: Add new GPIO management interface V4L/DVB (11884): Siano: smssdio - revert to stand alone module V4L/DVB (11883): Siano: cards - add two additional (USB) devices V4L/DVB (11824): Siano: smsusb - change exit func debug msg V4L/DVB (11823): Siano: smsusb - fix typo in module description V4L/DVB (11822): Siano: smscore - bug fix at get_device_mode V4L/DVB (11821): Siano: smscore - fix isdb-t firmware name V4L/DVB (11820): Siano: smscore - fix byte ordering bug V4L/DVB (11819): Siano: smscore - fix get_common_buffer bug V4L/DVB (11818): Siano: smscards - assign gpio to HPG targets ...
Diffstat (limited to 'include')
-rw-r--r--include/linux/mmc/sdio_ids.h8
-rw-r--r--include/linux/videodev2.h3
-rw-r--r--include/media/adv7343.h23
-rw-r--r--include/media/ir-kbd-i2c.h10
-rw-r--r--include/media/soc_camera.h10
-rw-r--r--include/media/tuner.h2
-rw-r--r--include/media/v4l2-chip-ident.h6
-rw-r--r--include/media/v4l2-device.h23
-rw-r--r--include/media/v4l2-subdev.h5
9 files changed, 85 insertions, 5 deletions
diff --git a/include/linux/mmc/sdio_ids.h b/include/linux/mmc/sdio_ids.h
index c7211ab6dd4b..39751c8cde9c 100644
--- a/include/linux/mmc/sdio_ids.h
+++ b/include/linux/mmc/sdio_ids.h
@@ -28,4 +28,12 @@
28#define SDIO_DEVICE_ID_MARVELL_8688WLAN 0x9104 28#define SDIO_DEVICE_ID_MARVELL_8688WLAN 0x9104
29#define SDIO_DEVICE_ID_MARVELL_8688BT 0x9105 29#define SDIO_DEVICE_ID_MARVELL_8688BT 0x9105
30 30
31#define SDIO_VENDOR_ID_SIANO 0x039a
32#define SDIO_DEVICE_ID_SIANO_NOVA_B0 0x0201
33#define SDIO_DEVICE_ID_SIANO_NICE 0x0202
34#define SDIO_DEVICE_ID_SIANO_VEGA_A0 0x0300
35#define SDIO_DEVICE_ID_SIANO_VENICE 0x0301
36#define SDIO_DEVICE_ID_SIANO_NOVA_A0 0x1100
37#define SDIO_DEVICE_ID_SIANO_STELLAR 0x5347
38
31#endif 39#endif
diff --git a/include/linux/videodev2.h b/include/linux/videodev2.h
index ebb2ea6b4995..f24eceecc5a6 100644
--- a/include/linux/videodev2.h
+++ b/include/linux/videodev2.h
@@ -347,7 +347,8 @@ struct v4l2_pix_format {
347#define V4L2_PIX_FMT_MR97310A v4l2_fourcc('M', '3', '1', '0') /* compressed BGGR bayer */ 347#define V4L2_PIX_FMT_MR97310A v4l2_fourcc('M', '3', '1', '0') /* compressed BGGR bayer */
348#define V4L2_PIX_FMT_SQ905C v4l2_fourcc('9', '0', '5', 'C') /* compressed RGGB bayer */ 348#define V4L2_PIX_FMT_SQ905C v4l2_fourcc('9', '0', '5', 'C') /* compressed RGGB bayer */
349#define V4L2_PIX_FMT_PJPG v4l2_fourcc('P', 'J', 'P', 'G') /* Pixart 73xx JPEG */ 349#define V4L2_PIX_FMT_PJPG v4l2_fourcc('P', 'J', 'P', 'G') /* Pixart 73xx JPEG */
350#define V4L2_PIX_FMT_YVYU v4l2_fourcc('Y', 'V', 'Y', 'U') /* 16 YVU 4:2:2 */ 350#define V4L2_PIX_FMT_YVYU v4l2_fourcc('Y', 'V', 'Y', 'U') /* 16 YVU 4:2:2 */
351#define V4L2_PIX_FMT_OV518 v4l2_fourcc('O', '5', '1', '8') /* ov518 JPEG */
351 352
352/* 353/*
353 * F O R M A T E N U M E R A T I O N 354 * F O R M A T E N U M E R A T I O N
diff --git a/include/media/adv7343.h b/include/media/adv7343.h
new file mode 100644
index 000000000000..d6f8a4e1a1fc
--- /dev/null
+++ b/include/media/adv7343.h
@@ -0,0 +1,23 @@
1/*
2 * ADV7343 header file
3 *
4 * Copyright (C) 2009 Texas Instruments Incorporated - http://www.ti.com/
5 *
6 * This program is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU General Public License as
8 * published by the Free Software Foundation version 2.
9 *
10 * This program is distributed .as is. WITHOUT ANY WARRANTY of any
11 * kind, whether express or implied; without even the implied warranty
12 * of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 */
15
16#ifndef ADV7343_H
17#define ADV7343_H
18
19#define ADV7343_COMPOSITE_ID (0)
20#define ADV7343_COMPONENT_ID (1)
21#define ADV7343_SVIDEO_ID (2)
22
23#endif /* End of #ifndef ADV7343_H */
diff --git a/include/media/ir-kbd-i2c.h b/include/media/ir-kbd-i2c.h
index 07963d705400..3ad4ed5402fb 100644
--- a/include/media/ir-kbd-i2c.h
+++ b/include/media/ir-kbd-i2c.h
@@ -7,7 +7,7 @@ struct IR_i2c;
7 7
8struct IR_i2c { 8struct IR_i2c {
9 IR_KEYTAB_TYPE *ir_codes; 9 IR_KEYTAB_TYPE *ir_codes;
10 struct i2c_client c; 10 struct i2c_client *c;
11 struct input_dev *input; 11 struct input_dev *input;
12 struct ir_input_state ir; 12 struct ir_input_state ir;
13 13
@@ -15,7 +15,15 @@ struct IR_i2c {
15 unsigned char old; 15 unsigned char old;
16 16
17 struct delayed_work work; 17 struct delayed_work work;
18 char name[32];
18 char phys[32]; 19 char phys[32];
19 int (*get_key)(struct IR_i2c*, u32*, u32*); 20 int (*get_key)(struct IR_i2c*, u32*, u32*);
20}; 21};
22
23/* Can be passed when instantiating an ir_video i2c device */
24struct IR_i2c_init_data {
25 IR_KEYTAB_TYPE *ir_codes;
26 const char *name;
27 int (*get_key)(struct IR_i2c*, u32*, u32*);
28};
21#endif 29#endif
diff --git a/include/media/soc_camera.h b/include/media/soc_camera.h
index 37013688af44..23ecead35e7a 100644
--- a/include/media/soc_camera.h
+++ b/include/media/soc_camera.h
@@ -60,7 +60,7 @@ struct soc_camera_file {
60 60
61struct soc_camera_host { 61struct soc_camera_host {
62 struct list_head list; 62 struct list_head list;
63 struct device dev; 63 struct device *dev;
64 unsigned char nr; /* Host number */ 64 unsigned char nr; /* Host number */
65 void *priv; 65 void *priv;
66 const char *drv_name; 66 const char *drv_name;
@@ -92,11 +92,16 @@ struct soc_camera_host_ops {
92#define SOCAM_SENSOR_INVERT_VSYNC (1 << 3) 92#define SOCAM_SENSOR_INVERT_VSYNC (1 << 3)
93#define SOCAM_SENSOR_INVERT_DATA (1 << 4) 93#define SOCAM_SENSOR_INVERT_DATA (1 << 4)
94 94
95struct i2c_board_info;
96
95struct soc_camera_link { 97struct soc_camera_link {
96 /* Camera bus id, used to match a camera and a bus */ 98 /* Camera bus id, used to match a camera and a bus */
97 int bus_id; 99 int bus_id;
98 /* Per camera SOCAM_SENSOR_* bus flags */ 100 /* Per camera SOCAM_SENSOR_* bus flags */
99 unsigned long flags; 101 unsigned long flags;
102 int i2c_adapter_id;
103 struct i2c_board_info *board_info;
104 const char *module_name;
100 /* Optional callbacks to power on or off and reset the sensor */ 105 /* Optional callbacks to power on or off and reset the sensor */
101 int (*power)(struct device *, int); 106 int (*power)(struct device *, int);
102 int (*reset)(struct device *); 107 int (*reset)(struct device *);
@@ -107,6 +112,7 @@ struct soc_camera_link {
107 */ 112 */
108 int (*set_bus_param)(struct soc_camera_link *, unsigned long flags); 113 int (*set_bus_param)(struct soc_camera_link *, unsigned long flags);
109 unsigned long (*query_bus_param)(struct soc_camera_link *); 114 unsigned long (*query_bus_param)(struct soc_camera_link *);
115 void (*free_bus)(struct soc_camera_link *);
110}; 116};
111 117
112static inline struct soc_camera_device *to_soc_camera_dev(struct device *dev) 118static inline struct soc_camera_device *to_soc_camera_dev(struct device *dev)
@@ -116,7 +122,7 @@ static inline struct soc_camera_device *to_soc_camera_dev(struct device *dev)
116 122
117static inline struct soc_camera_host *to_soc_camera_host(struct device *dev) 123static inline struct soc_camera_host *to_soc_camera_host(struct device *dev)
118{ 124{
119 return container_of(dev, struct soc_camera_host, dev); 125 return dev_get_drvdata(dev);
120} 126}
121 127
122extern int soc_camera_host_register(struct soc_camera_host *ici); 128extern int soc_camera_host_register(struct soc_camera_host *ici);
diff --git a/include/media/tuner.h b/include/media/tuner.h
index 7d4e2db78076..cbf97f45fbec 100644
--- a/include/media/tuner.h
+++ b/include/media/tuner.h
@@ -124,6 +124,8 @@
124#define TUNER_XC5000 76 /* Xceive Silicon Tuner */ 124#define TUNER_XC5000 76 /* Xceive Silicon Tuner */
125#define TUNER_TCL_MF02GIP_5N 77 /* TCL MF02GIP_5N */ 125#define TUNER_TCL_MF02GIP_5N 77 /* TCL MF02GIP_5N */
126#define TUNER_PHILIPS_FMD1216MEX_MK3 78 126#define TUNER_PHILIPS_FMD1216MEX_MK3 78
127#define TUNER_PHILIPS_FM1216MK5 79
128#define TUNER_PHILIPS_FQ1216LME_MK3 80 /* Active loopthrough, no FM */
127 129
128/* tv card specific */ 130/* tv card specific */
129#define TDA9887_PRESENT (1<<0) 131#define TDA9887_PRESENT (1<<0)
diff --git a/include/media/v4l2-chip-ident.h b/include/media/v4l2-chip-ident.h
index 1be461a29077..4d7e2272c42f 100644
--- a/include/media/v4l2-chip-ident.h
+++ b/include/media/v4l2-chip-ident.h
@@ -137,6 +137,12 @@ enum {
137 /* module saa7191: just ident 7191 */ 137 /* module saa7191: just ident 7191 */
138 V4L2_IDENT_SAA7191 = 7191, 138 V4L2_IDENT_SAA7191 = 7191,
139 139
140 /* module ths7303: just ident 7303 */
141 V4L2_IDENT_THS7303 = 7303,
142
143 /* module adv7343: just ident 7343 */
144 V4L2_IDENT_ADV7343 = 7343,
145
140 /* module wm8739: just ident 8739 */ 146 /* module wm8739: just ident 8739 */
141 V4L2_IDENT_WM8739 = 8739, 147 V4L2_IDENT_WM8739 = 8739,
142 148
diff --git a/include/media/v4l2-device.h b/include/media/v4l2-device.h
index 0dd3e8e8653e..5d5d550e63ad 100644
--- a/include/media/v4l2-device.h
+++ b/include/media/v4l2-device.h
@@ -30,7 +30,7 @@
30 basic V4L2 device-level support. 30 basic V4L2 device-level support.
31 */ 31 */
32 32
33#define V4L2_DEVICE_NAME_SIZE (BUS_ID_SIZE + 16) 33#define V4L2_DEVICE_NAME_SIZE (20 + 16)
34 34
35struct v4l2_device { 35struct v4l2_device {
36 /* dev->driver_data points to this struct. 36 /* dev->driver_data points to this struct.
@@ -53,10 +53,31 @@ struct v4l2_device {
53 dev may be NULL in rare cases (ISA devices). In that case you 53 dev may be NULL in rare cases (ISA devices). In that case you
54 must fill in the v4l2_dev->name field before calling this function. */ 54 must fill in the v4l2_dev->name field before calling this function. */
55int __must_check v4l2_device_register(struct device *dev, struct v4l2_device *v4l2_dev); 55int __must_check v4l2_device_register(struct device *dev, struct v4l2_device *v4l2_dev);
56
57/* Optional function to initialize the name field of struct v4l2_device using
58 the driver name and a driver-global atomic_t instance.
59 This function will increment the instance counter and returns the instance
60 value used in the name.
61
62 Example:
63
64 static atomic_t drv_instance = ATOMIC_INIT(0);
65
66 ...
67
68 instance = v4l2_device_set_name(&v4l2_dev, "foo", &drv_instance);
69
70 The first time this is called the name field will be set to foo0 and
71 this function returns 0. If the name ends with a digit (e.g. cx18),
72 then the name will be set to cx18-0 since cx180 looks really odd. */
73int v4l2_device_set_name(struct v4l2_device *v4l2_dev, const char *basename,
74 atomic_t *instance);
75
56/* Set v4l2_dev->dev to NULL. Call when the USB parent disconnects. 76/* Set v4l2_dev->dev to NULL. Call when the USB parent disconnects.
57 Since the parent disappears this ensures that v4l2_dev doesn't have an 77 Since the parent disappears this ensures that v4l2_dev doesn't have an
58 invalid parent pointer. */ 78 invalid parent pointer. */
59void v4l2_device_disconnect(struct v4l2_device *v4l2_dev); 79void v4l2_device_disconnect(struct v4l2_device *v4l2_dev);
80
60/* Unregister all sub-devices and any other resources related to v4l2_dev. */ 81/* Unregister all sub-devices and any other resources related to v4l2_dev. */
61void v4l2_device_unregister(struct v4l2_device *v4l2_dev); 82void v4l2_device_unregister(struct v4l2_device *v4l2_dev);
62 83
diff --git a/include/media/v4l2-subdev.h b/include/media/v4l2-subdev.h
index 17856081c809..a503e1cee78b 100644
--- a/include/media/v4l2-subdev.h
+++ b/include/media/v4l2-subdev.h
@@ -230,12 +230,16 @@ struct v4l2_subdev_ops {
230 230
231#define V4L2_SUBDEV_NAME_SIZE 32 231#define V4L2_SUBDEV_NAME_SIZE 32
232 232
233/* Set this flag if this subdev is a i2c device. */
234#define V4L2_SUBDEV_FL_IS_I2C (1U << 0)
235
233/* Each instance of a subdev driver should create this struct, either 236/* Each instance of a subdev driver should create this struct, either
234 stand-alone or embedded in a larger struct. 237 stand-alone or embedded in a larger struct.
235 */ 238 */
236struct v4l2_subdev { 239struct v4l2_subdev {
237 struct list_head list; 240 struct list_head list;
238 struct module *owner; 241 struct module *owner;
242 u32 flags;
239 struct v4l2_device *v4l2_dev; 243 struct v4l2_device *v4l2_dev;
240 const struct v4l2_subdev_ops *ops; 244 const struct v4l2_subdev_ops *ops;
241 /* name must be unique */ 245 /* name must be unique */
@@ -264,6 +268,7 @@ static inline void v4l2_subdev_init(struct v4l2_subdev *sd,
264 BUG_ON(!ops || !ops->core); 268 BUG_ON(!ops || !ops->core);
265 sd->ops = ops; 269 sd->ops = ops;
266 sd->v4l2_dev = NULL; 270 sd->v4l2_dev = NULL;
271 sd->flags = 0;
267 sd->name[0] = '\0'; 272 sd->name[0] = '\0';
268 sd->grp_id = 0; 273 sd->grp_id = 0;
269 sd->priv = NULL; 274 sd->priv = NULL;