aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation
diff options
context:
space:
mode:
Diffstat (limited to 'Documentation')
-rw-r--r--Documentation/SubmittingPatches26
-rw-r--r--Documentation/feature-removal-schedule.txt24
-rw-r--r--Documentation/i2c/upgrading-clients281
-rw-r--r--Documentation/video4linux/CARDLIST.au08281
-rw-r--r--Documentation/video4linux/CARDLIST.em28xx45
-rw-r--r--Documentation/video4linux/gspca.txt2
6 files changed, 375 insertions, 4 deletions
diff --git a/Documentation/SubmittingPatches b/Documentation/SubmittingPatches
index 118ca6e9404..f79ad9ff603 100644
--- a/Documentation/SubmittingPatches
+++ b/Documentation/SubmittingPatches
@@ -528,7 +528,33 @@ See more details on the proper patch format in the following
528references. 528references.
529 529
530 530
53116) Sending "git pull" requests (from Linus emails)
531 532
533Please write the git repo address and branch name alone on the same line
534so that I can't even by mistake pull from the wrong branch, and so
535that a triple-click just selects the whole thing.
536
537So the proper format is something along the lines of:
538
539 "Please pull from
540
541 git://jdelvare.pck.nerim.net/jdelvare-2.6 i2c-for-linus
542
543 to get these changes:"
544
545so that I don't have to hunt-and-peck for the address and inevitably
546get it wrong (actually, I've only gotten it wrong a few times, and
547checking against the diffstat tells me when I get it wrong, but I'm
548just a lot more comfortable when I don't have to "look for" the right
549thing to pull, and double-check that I have the right branch-name).
550
551
552Please use "git diff -M --stat --summary" to generate the diffstat:
553the -M enables rename detection, and the summary enables a summary of
554new/deleted or renamed files.
555
556With rename detection, the statistics are rather different [...]
557because git will notice that a fair number of the changes are renames.
532 558
533----------------------------------- 559-----------------------------------
534SECTION 2 - HINTS, TIPS, AND TRICKS 560SECTION 2 - HINTS, TIPS, AND TRICKS
diff --git a/Documentation/feature-removal-schedule.txt b/Documentation/feature-removal-schedule.txt
index 721c71b86e0..c23955404bf 100644
--- a/Documentation/feature-removal-schedule.txt
+++ b/Documentation/feature-removal-schedule.txt
@@ -47,6 +47,30 @@ Who: Mauro Carvalho Chehab <mchehab@infradead.org>
47 47
48--------------------------- 48---------------------------
49 49
50What: old tuner-3036 i2c driver
51When: 2.6.28
52Why: This driver is for VERY old i2c-over-parallel port teletext receiver
53 boxes. Rather then spending effort on converting this driver to V4L2,
54 and since it is extremely unlikely that anyone still uses one of these
55 devices, it was decided to drop it.
56Who: Hans Verkuil <hverkuil@xs4all.nl>
57 Mauro Carvalho Chehab <mchehab@infradead.org>
58
59 ---------------------------
60
61What: V4L2 dpc7146 driver
62When: 2.6.28
63Why: Old driver for the dpc7146 demonstration board that is no longer
64 relevant. The last time this was tested on actual hardware was
65 probably around 2002. Since this is a driver for a demonstration
66 board the decision was made to remove it rather than spending a
67 lot of effort continually updating this driver to stay in sync
68 with the latest internal V4L2 or I2C API.
69Who: Hans Verkuil <hverkuil@xs4all.nl>
70 Mauro Carvalho Chehab <mchehab@infradead.org>
71
72---------------------------
73
50What: PCMCIA control ioctl (needed for pcmcia-cs [cardmgr, cardctl]) 74What: PCMCIA control ioctl (needed for pcmcia-cs [cardmgr, cardctl])
51When: November 2005 75When: November 2005
52Files: drivers/pcmcia/: pcmcia_ioctl.c 76Files: drivers/pcmcia/: pcmcia_ioctl.c
diff --git a/Documentation/i2c/upgrading-clients b/Documentation/i2c/upgrading-clients
new file mode 100644
index 00000000000..9a45f9bb6a2
--- /dev/null
+++ b/Documentation/i2c/upgrading-clients
@@ -0,0 +1,281 @@
1Upgrading I2C Drivers to the new 2.6 Driver Model
2=================================================
3
4Ben Dooks <ben-linux@fluff.org>
5
6Introduction
7------------
8
9This guide outlines how to alter existing Linux 2.6 client drivers from
10the old to the new new binding methods.
11
12
13Example old-style driver
14------------------------
15
16
17struct example_state {
18 struct i2c_client client;
19 ....
20};
21
22static struct i2c_driver example_driver;
23
24static unsigned short ignore[] = { I2C_CLIENT_END };
25static unsigned short normal_addr[] = { OUR_ADDR, I2C_CLIENT_END };
26
27I2C_CLIENT_INSMOD;
28
29static int example_attach(struct i2c_adapter *adap, int addr, int kind)
30{
31 struct example_state *state;
32 struct device *dev = &adap->dev; /* to use for dev_ reports */
33 int ret;
34
35 state = kzalloc(sizeof(struct example_state), GFP_KERNEL);
36 if (state == NULL) {
37 dev_err(dev, "failed to create our state\n");
38 return -ENOMEM;
39 }
40
41 example->client.addr = addr;
42 example->client.flags = 0;
43 example->client.adapter = adap;
44
45 i2c_set_clientdata(&state->i2c_client, state);
46 strlcpy(client->i2c_client.name, "example", I2C_NAME_SIZE);
47
48 ret = i2c_attach_client(&state->i2c_client);
49 if (ret < 0) {
50 dev_err(dev, "failed to attach client\n");
51 kfree(state);
52 return ret;
53 }
54
55 dev = &state->i2c_client.dev;
56
57 /* rest of the initialisation goes here. */
58
59 dev_info(dev, "example client created\n");
60
61 return 0;
62}
63
64static int __devexit example_detach(struct i2c_client *client)
65{
66 struct example_state *state = i2c_get_clientdata(client);
67
68 i2c_detach_client(client);
69 kfree(state);
70 return 0;
71}
72
73static int example_attach_adapter(struct i2c_adapter *adap)
74{
75 return i2c_probe(adap, &addr_data, example_attach);
76}
77
78static struct i2c_driver example_driver = {
79 .driver = {
80 .owner = THIS_MODULE,
81 .name = "example",
82 },
83 .attach_adapter = example_attach_adapter,
84 .detach_client = __devexit_p(example_detach),
85 .suspend = example_suspend,
86 .resume = example_resume,
87};
88
89
90Updating the client
91-------------------
92
93The new style binding model will check against a list of supported
94devices and their associated address supplied by the code registering
95the busses. This means that the driver .attach_adapter and
96.detach_adapter methods can be removed, along with the addr_data,
97as follows:
98
99- static struct i2c_driver example_driver;
100
101- static unsigned short ignore[] = { I2C_CLIENT_END };
102- static unsigned short normal_addr[] = { OUR_ADDR, I2C_CLIENT_END };
103
104- I2C_CLIENT_INSMOD;
105
106- static int example_attach_adapter(struct i2c_adapter *adap)
107- {
108- return i2c_probe(adap, &addr_data, example_attach);
109- }
110
111 static struct i2c_driver example_driver = {
112- .attach_adapter = example_attach_adapter,
113- .detach_client = __devexit_p(example_detach),
114 }
115
116Add the probe and remove methods to the i2c_driver, as so:
117
118 static struct i2c_driver example_driver = {
119+ .probe = example_probe,
120+ .remove = __devexit_p(example_remove),
121 }
122
123Change the example_attach method to accept the new parameters
124which include the i2c_client that it will be working with:
125
126- static int example_attach(struct i2c_adapter *adap, int addr, int kind)
127+ static int example_probe(struct i2c_client *client,
128+ const struct i2c_device_id *id)
129
130Change the name of example_attach to example_probe to align it with the
131i2c_driver entry names. The rest of the probe routine will now need to be
132changed as the i2c_client has already been setup for use.
133
134The necessary client fields have already been setup before
135the probe function is called, so the following client setup
136can be removed:
137
138- example->client.addr = addr;
139- example->client.flags = 0;
140- example->client.adapter = adap;
141-
142- strlcpy(client->i2c_client.name, "example", I2C_NAME_SIZE);
143
144The i2c_set_clientdata is now:
145
146- i2c_set_clientdata(&state->client, state);
147+ i2c_set_clientdata(client, state);
148
149The call to i2c_attach_client is no longer needed, if the probe
150routine exits successfully, then the driver will be automatically
151attached by the core. Change the probe routine as so:
152
153- ret = i2c_attach_client(&state->i2c_client);
154- if (ret < 0) {
155- dev_err(dev, "failed to attach client\n");
156- kfree(state);
157- return ret;
158- }
159
160
161Remove the storage of 'struct i2c_client' from the 'struct example_state'
162as we are provided with the i2c_client in our example_probe. Instead we
163store a pointer to it for when it is needed.
164
165struct example_state {
166- struct i2c_client client;
167+ struct i2c_client *client;
168
169the new i2c client as so:
170
171- struct device *dev = &adap->dev; /* to use for dev_ reports */
172+ struct device *dev = &i2c_client->dev; /* to use for dev_ reports */
173
174And remove the change after our client is attached, as the driver no
175longer needs to register a new client structure with the core:
176
177- dev = &state->i2c_client.dev;
178
179In the probe routine, ensure that the new state has the client stored
180in it:
181
182static int example_probe(struct i2c_client *i2c_client,
183 const struct i2c_device_id *id)
184{
185 struct example_state *state;
186 struct device *dev = &i2c_client->dev;
187 int ret;
188
189 state = kzalloc(sizeof(struct example_state), GFP_KERNEL);
190 if (state == NULL) {
191 dev_err(dev, "failed to create our state\n");
192 return -ENOMEM;
193 }
194
195+ state->client = i2c_client;
196
197Update the detach method, by changing the name to _remove and
198to delete the i2c_detach_client call. It is possible that you
199can also remove the ret variable as it is not not needed for
200any of the core functions.
201
202- static int __devexit example_detach(struct i2c_client *client)
203+ static int __devexit example_remove(struct i2c_client *client)
204{
205 struct example_state *state = i2c_get_clientdata(client);
206
207- i2c_detach_client(client);
208
209And finally ensure that we have the correct ID table for the i2c-core
210and other utilities:
211
212+ struct i2c_device_id example_idtable[] = {
213+ { "example", 0 },
214+ { }
215+};
216+
217+MODULE_DEVICE_TABLE(i2c, example_idtable);
218
219static struct i2c_driver example_driver = {
220 .driver = {
221 .owner = THIS_MODULE,
222 .name = "example",
223 },
224+ .id_table = example_ids,
225
226
227Our driver should now look like this:
228
229struct example_state {
230 struct i2c_client *client;
231 ....
232};
233
234static int example_probe(struct i2c_client *client,
235 const struct i2c_device_id *id)
236{
237 struct example_state *state;
238 struct device *dev = &client->dev;
239
240 state = kzalloc(sizeof(struct example_state), GFP_KERNEL);
241 if (state == NULL) {
242 dev_err(dev, "failed to create our state\n");
243 return -ENOMEM;
244 }
245
246 state->client = client;
247 i2c_set_clientdata(client, state);
248
249 /* rest of the initialisation goes here. */
250
251 dev_info(dev, "example client created\n");
252
253 return 0;
254}
255
256static int __devexit example_remove(struct i2c_client *client)
257{
258 struct example_state *state = i2c_get_clientdata(client);
259
260 kfree(state);
261 return 0;
262}
263
264static struct i2c_device_id example_idtable[] = {
265 { "example", 0 },
266 { }
267};
268
269MODULE_DEVICE_TABLE(i2c, example_idtable);
270
271static struct i2c_driver example_driver = {
272 .driver = {
273 .owner = THIS_MODULE,
274 .name = "example",
275 },
276 .id_table = example_idtable,
277 .probe = example_probe,
278 .remove = __devexit_p(example_remove),
279 .suspend = example_suspend,
280 .resume = example_resume,
281};
diff --git a/Documentation/video4linux/CARDLIST.au0828 b/Documentation/video4linux/CARDLIST.au0828
index 86d1c8e7b18..eedc399e8de 100644
--- a/Documentation/video4linux/CARDLIST.au0828
+++ b/Documentation/video4linux/CARDLIST.au0828
@@ -2,3 +2,4 @@
2 1 -> Hauppauge HVR950Q (au0828) [2040:7200,2040:7210,2040:7217,2040:721b,2040:721f,2040:7280,0fd9:0008] 2 1 -> Hauppauge HVR950Q (au0828) [2040:7200,2040:7210,2040:7217,2040:721b,2040:721f,2040:7280,0fd9:0008]
3 2 -> Hauppauge HVR850 (au0828) [2040:7240] 3 2 -> Hauppauge HVR850 (au0828) [2040:7240]
4 3 -> DViCO FusionHDTV USB (au0828) [0fe9:d620] 4 3 -> DViCO FusionHDTV USB (au0828) [0fe9:d620]
5 4 -> Hauppauge HVR950Q rev xxF8 (au0828) [2040:7201,2040:7211,2040:7281]
diff --git a/Documentation/video4linux/CARDLIST.em28xx b/Documentation/video4linux/CARDLIST.em28xx
index 10591467ef1..89c7f32abf9 100644
--- a/Documentation/video4linux/CARDLIST.em28xx
+++ b/Documentation/video4linux/CARDLIST.em28xx
@@ -1,11 +1,11 @@
1 0 -> Unknown EM2800 video grabber (em2800) [eb1a:2800] 1 0 -> Unknown EM2800 video grabber (em2800) [eb1a:2800]
2 1 -> Unknown EM2750/28xx video grabber (em2820/em2840) [eb1a:2750,eb1a:2820,eb1a:2821,eb1a:2860,eb1a:2861,eb1a:2870,eb1a:2881,eb1a:2883] 2 1 -> Unknown EM2750/28xx video grabber (em2820/em2840) [eb1a:2820,eb1a:2821,eb1a:2860,eb1a:2861,eb1a:2870,eb1a:2881,eb1a:2883]
3 2 -> Terratec Cinergy 250 USB (em2820/em2840) [0ccd:0036] 3 2 -> Terratec Cinergy 250 USB (em2820/em2840) [0ccd:0036]
4 3 -> Pinnacle PCTV USB 2 (em2820/em2840) [2304:0208] 4 3 -> Pinnacle PCTV USB 2 (em2820/em2840) [2304:0208]
5 4 -> Hauppauge WinTV USB 2 (em2820/em2840) [2040:4200,2040:4201] 5 4 -> Hauppauge WinTV USB 2 (em2820/em2840) [2040:4200,2040:4201]
6 5 -> MSI VOX USB 2.0 (em2820/em2840) 6 5 -> MSI VOX USB 2.0 (em2820/em2840)
7 6 -> Terratec Cinergy 200 USB (em2800) 7 6 -> Terratec Cinergy 200 USB (em2800)
8 7 -> Leadtek Winfast USB II (em2800) 8 7 -> Leadtek Winfast USB II (em2800) [0413:6023]
9 8 -> Kworld USB2800 (em2800) 9 8 -> Kworld USB2800 (em2800)
10 9 -> Pinnacle Dazzle DVC 90/DVC 100 (em2820/em2840) [2304:0207,2304:021a] 10 9 -> Pinnacle Dazzle DVC 90/DVC 100 (em2820/em2840) [2304:0207,2304:021a]
11 10 -> Hauppauge WinTV HVR 900 (em2880) [2040:6500] 11 10 -> Hauppauge WinTV HVR 900 (em2880) [2040:6500]
@@ -14,7 +14,46 @@
14 13 -> Terratec Prodigy XS (em2880) [0ccd:0047] 14 13 -> Terratec Prodigy XS (em2880) [0ccd:0047]
15 14 -> Pixelview Prolink PlayTV USB 2.0 (em2820/em2840) 15 14 -> Pixelview Prolink PlayTV USB 2.0 (em2820/em2840)
16 15 -> V-Gear PocketTV (em2800) 16 15 -> V-Gear PocketTV (em2800)
17 16 -> Hauppauge WinTV HVR 950 (em2880) [2040:6513,2040:6517,2040:651b,2040:651f] 17 16 -> Hauppauge WinTV HVR 950 (em2883) [2040:6513,2040:6517,2040:651b,2040:651f]
18 17 -> Pinnacle PCTV HD Pro Stick (em2880) [2304:0227] 18 17 -> Pinnacle PCTV HD Pro Stick (em2880) [2304:0227]
19 18 -> Hauppauge WinTV HVR 900 (R2) (em2880) [2040:6502] 19 18 -> Hauppauge WinTV HVR 900 (R2) (em2880) [2040:6502]
20 19 -> PointNix Intra-Oral Camera (em2860) 20 19 -> PointNix Intra-Oral Camera (em2860)
21 20 -> AMD ATI TV Wonder HD 600 (em2880) [0438:b002]
22 21 -> eMPIA Technology, Inc. GrabBeeX+ Video Encoder (em2800) [eb1a:2801]
23 22 -> Unknown EM2750/EM2751 webcam grabber (em2750) [eb1a:2750,eb1a:2751]
24 23 -> Huaqi DLCW-130 (em2750)
25 24 -> D-Link DUB-T210 TV Tuner (em2820/em2840) [2001:f112]
26 25 -> Gadmei UTV310 (em2820/em2840)
27 26 -> Hercules Smart TV USB 2.0 (em2820/em2840)
28 27 -> Pinnacle PCTV USB 2 (Philips FM1216ME) (em2820/em2840)
29 28 -> Leadtek Winfast USB II Deluxe (em2820/em2840)
30 29 -> Pinnacle Dazzle DVC 100 (em2820/em2840)
31 30 -> Videology 20K14XUSB USB2.0 (em2820/em2840)
32 31 -> Usbgear VD204v9 (em2821)
33 32 -> Supercomp USB 2.0 TV (em2821)
34 33 -> SIIG AVTuner-PVR/Prolink PlayTV USB 2.0 (em2821)
35 34 -> Terratec Cinergy A Hybrid XS (em2860) [0ccd:004f]
36 35 -> Typhoon DVD Maker (em2860)
37 36 -> NetGMBH Cam (em2860)
38 37 -> Gadmei UTV330 (em2860)
39 38 -> Yakumo MovieMixer (em2861)
40 39 -> KWorld PVRTV 300U (em2861) [eb1a:e300]
41 40 -> Plextor ConvertX PX-TV100U (em2861) [093b:a005]
42 41 -> Kworld 350 U DVB-T (em2870) [eb1a:e350]
43 42 -> Kworld 355 U DVB-T (em2870) [eb1a:e355,eb1a:e357]
44 43 -> Terratec Cinergy T XS (em2870) [0ccd:0043]
45 44 -> Terratec Cinergy T XS (MT2060) (em2870)
46 45 -> Pinnacle PCTV DVB-T (em2870)
47 46 -> Compro, VideoMate U3 (em2870) [185b:2870]
48 47 -> KWorld DVB-T 305U (em2880) [eb1a:e305]
49 48 -> KWorld DVB-T 310U (em2880)
50 49 -> MSI DigiVox A/D (em2880) [eb1a:e310]
51 50 -> MSI DigiVox A/D II (em2880) [eb1a:e320]
52 51 -> Terratec Hybrid XS Secam (em2880) [0ccd:004c]
53 52 -> DNT DA2 Hybrid (em2881)
54 53 -> Pinnacle Hybrid Pro (em2881)
55 54 -> Kworld VS-DVB-T 323UR (em2882) [eb1a:e323]
56 55 -> Terratec Hybrid XS (em2882) (em2882) [0ccd:005e]
57 56 -> Pinnacle Hybrid Pro (2) (em2882) [2304:0226]
58 57 -> Kworld PlusTV HD Hybrid 330 (em2883) [eb1a:a316]
59 58 -> Compro VideoMate ForYou/Stereo (em2820/em2840) [185b:2041]
diff --git a/Documentation/video4linux/gspca.txt b/Documentation/video4linux/gspca.txt
index 0c4880af57a..bcaf4ab383b 100644
--- a/Documentation/video4linux/gspca.txt
+++ b/Documentation/video4linux/gspca.txt
@@ -1,4 +1,4 @@
1List of the webcams know by gspca. 1List of the webcams known by gspca.
2 2
3The modules are: 3The modules are:
4 gspca_main main driver 4 gspca_main main driver