aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohannes Stezenbach <js@linuxtv.org>2005-05-17 00:54:17 -0400
committerLinus Torvalds <torvalds@ppc970.osdl.org>2005-05-17 10:59:26 -0400
commitc6ee197ccf4af454638c044706f0ba7ef6c1bb76 (patch)
treea23c1dc5fc5fda9ce5a3c11b026688add04ec452
parent59a7ad6c1ed3a058d375d2e679d73805e4f851ac (diff)
[PATCH] dvb: flexcop: readme update
readme update Signed-off-by: Patrick Boettcher <pb@linuxtv.org> Signed-off-by: Johannes Stezenbach <js@linuxtv.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-rw-r--r--Documentation/dvb/README.flexcop121
1 files changed, 21 insertions, 100 deletions
diff --git a/Documentation/dvb/README.flexcop b/Documentation/dvb/README.flexcop
index 8036faa1ead9..a50c70f9ca72 100644
--- a/Documentation/dvb/README.flexcop
+++ b/Documentation/dvb/README.flexcop
@@ -2,26 +2,20 @@ This README escorted the skystar2-driver rewriting procedure. It describes the
2state of the new flexcop-driver set and some internals are written down here 2state of the new flexcop-driver set and some internals are written down here
3too. 3too.
4 4
5How to do something in here?
6============================
7
8make -f Makefile.t
9make -C ../build-2.6
10./in.sh # load the drivers
11./rm.sh # unload the drivers
12
13Please read this file, if you want to contribute.
14
15This document hopefully describes things about the flexcop and its 5This document hopefully describes things about the flexcop and its
16device-offsprings. Goal is to write a easy-to-write and easy-to-read set of 6device-offsprings. Goal was to write an easy-to-write and easy-to-read set of
17drivers based on the skystar2.c and other information. 7drivers based on the skystar2.c and other information.
18 8
19This directory is temporary. It is used for rewriting the skystar2.c and to
20create shared code, which then can be used by the usb box as well.
21
22Remark: flexcop-pci.c was a copy of skystar2.c, but every line has been 9Remark: flexcop-pci.c was a copy of skystar2.c, but every line has been
23touched and rewritten. 10touched and rewritten.
24 11
12History & News
13==============
14 2005-04-01 - correct USB ISOC transfers (thanks to Vadim Catana)
15
16
17
18
25General coding processing 19General coding processing
26========================= 20=========================
27 21
@@ -81,16 +75,15 @@ non-static where possible, moved code to proper places)
81 75
822) Search for errors in the leftover of flexcop-pci.c (partially done) 762) Search for errors in the leftover of flexcop-pci.c (partially done)
835a) add MAC address reading 775a) add MAC address reading
785c) feeding of ISOC data to the software demux (format of the isochronous data
79and speed optimization, no real error) (thanks to Vadim Catana)
84 80
85What to do in the near future? 81What to do in the near future?
86-------------------------------------- 82--------------------------------------
87(no special order here) 83(no special order here)
88 84
89
905) USB driver 855) USB driver
915b) optimize isoc-transfer (submitting/killing isoc URBs when transfer is starting) 865b) optimize isoc-transfer (submitting/killing isoc URBs when transfer is starting)
925c) feeding of ISOC data to the software demux (format of the isochronous data
93and speed optimization, no real error)
94 87
95Testing changes 88Testing changes
96--------------- 89---------------
@@ -118,7 +111,7 @@ item | mt352 | nxt2002 | stv0299 | mt312 | mt352 | nxt2002 | stv0299 | mt312
1182) | O | N 1112) | O | N
1195a) | N | O 1125a) | N | O
1205b)* | N | 1135b)* | N |
1215c)* | N | 1145c) | N | O
122 115
123* - not done yet 116* - not done yet
124 117
@@ -155,17 +148,21 @@ working)
155SOLUTION: also index 0 was affected, because net_translation is done for 148SOLUTION: also index 0 was affected, because net_translation is done for
156these indexes by default 149these indexes by default
157 150
1585b) isochronous transfer does only work in the first attempt (for the Sky2PC USB, 1515b) isochronous transfer does only work in the first attempt (for the Sky2PC
159Air2PC is working) 152USB, Air2PC is working) SOLUTION: the flexcop was going asleep and never really
160SOLUTION: the flexcop was going asleep and never really woke up again (don't 153woke up again (don't know if this need fixes, see
161know if this need fixes, see flexcop-fe-tuner.c:flexcop_sleep) 154flexcop-fe-tuner.c:flexcop_sleep)
155
156NEWS: when the driver is loaded and unloaded and loaded again (w/o doing
157anything in the while the driver is loaded the first time), no transfers take
158place anymore.
162 159
163Improvements when rewriting (refactoring) is done 160Improvements when rewriting (refactoring) is done
164================================================= 161=================================================
165 162
166- split sleeping of the flexcop (misc_204.ACPI3_sig = 1;) from lnb_control 163- split sleeping of the flexcop (misc_204.ACPI3_sig = 1;) from lnb_control
167 (enable sleeping for other demods than dvb-s) 164 (enable sleeping for other demods than dvb-s)
168- add support for CableStar (stv0297 Microtune 203x/ALPS) 165- add support for CableStar (stv0297 Microtune 203x/ALPS) (almost done, incompatibilities with the Nexus-CA)
169 166
170Debugging 167Debugging
171--------- 168---------
@@ -192,82 +189,6 @@ Sram destinations: accessing registers
192Tuner/Demod: I2C bus 189Tuner/Demod: I2C bus
193DVB-stuff: can be written for common use 190DVB-stuff: can be written for common use
194 191
195Restrictions:
196============
197
198We need to create a bus-specific-struct and a flexcop-struct.
199
200bus-specific-struct:
201
202struct flexcop_pci
203...
204
205struct flexcop_usb
206...
207
208
209struct flexcop_device {
210 void *bus_specific; /* container for bus-specific struct */
211...
212}
213
214PCI i2c can read/write max 4 bytes at a time, USB can more
215
216Functions
217=========
218
219Syntax
220------
221
222- Flexcop functions will be called "flexcop(_[a-z0-9]+)+" and exported as such
223 if needed.
224- Flexcop-device functions will be called "flexcop_device(_[a-z0-9]+)+" and
225 exported as such if needed.
226- Both will be compiled to b2c2-flexcop.ko and their source can be found in the
227 flexcop*.[hc]
228
229Callbacks and exports
230---------------------
231
232Bus-specific functions will be given as callbacks (function pointers) to the
233flexcop-module. (within the flexcop_device-struct)
234
235Initialization process
236======================
237
238b2c2-flexcop.ko is loaded
239b2c2-flexcop-<bus>.ko is loaded
240
241suppose a device is found:
242malloc flexcop and the bus-specific variables (via flexcop_device_malloc)
243fill the bus-specific variable
244fill the flexcop variable (especially the bus-specific callbacks)
245bus-specific initialization
246 - ...
247do the common initialization (via flexcop_device_initialize)
248 - reset the card
249 - determine flexcop type (II, IIB, III)
250 - hw_filters (bus dependent)
251 - 0x204
252 - set sram size
253 - create the dvb-stuff
254 - create i2c stuff
255 - frontend-initialization
256done
257bus specific:
258 - media_destination (this and the following 3 are bus specific)
259 - cai_dest
260 - cao_dest
261 - net_destination
262
263Bugs fixed while rewriting the driver
264=====================================
265
266- EEPROM access (to read the MAC address) was fixed to death some time last
267 year. (fixed here and in skystar2.c) (Bjarne, this was the piece of code
268 (fix-chipaddr) we were wondering about)
269
270
271Acknowledgements (just for the rewriting part) 192Acknowledgements (just for the rewriting part)
272================ 193================
273 194
@@ -281,4 +202,4 @@ Boleslaw Ciesielski for pointing out a problem with firmware loader.
281 202
282Vadim Catana for correcting the USB transfer. 203Vadim Catana for correcting the USB transfer.
283 204
284comments, critics and ideas to linux-dvb@linuxtv.org or patrick.boettcher@desy.de 205comments, critics and ideas to linux-dvb@linuxtv.org.