aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/dvb/dvb-usb/af9015.c
Commit message (Collapse)AuthorAgeFilesLines
* more driver stuff from 3.2.72Wolfgang Wiedmeyer2015-10-231-102/+81
|
* [media] af9015: reimplement firmware downloadAntti Palosaari2011-03-221-15/+10
| | | | | | | | | | | | Split FW download packages smarter way and bug free. Implementation is based of Andrea Merello's example he provided for tda18218 driver. Count remaining FW bytes down in loop instead of division and modulo combination used earlier. Thanks-to: Andrea Merello <andrea.merello@gmail.com> Signed-off-by: Antti Palosaari <crope@iki.fi> Cc: Andrea Merello <andrea.merello@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] af9015: map remote for TerraTec Cinergy T Stick RCAntti Palosaari2011-03-221-0/+2
| | | | | | | | | Map rc-terratec-slim-2 for TerraTec Cinergy T Stick RC device. Signed-off-by: Antti Palosaari <crope@iki.fi> Cc: Martin Groszhauser <mgroszhauser@gmail.com> Cc: TerraTux <TerraTux@terratec.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] af9015: small RC changeAntti Palosaari2011-03-221-5/+12
| | | | | Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] af9015: enhance RCIan Armstrong2011-03-221-11/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Patch from Ian Armstrong. I've encountered a couple of problems with the current af9015 driver as supplied with the 2.6.37 kernel, that the attached patch appears to fix. (I've generated this patch against the current v4l-dvb git). Some key-presses are lost. A key-press is only generated upon 'valid' data (buf[14] == (u8) ~buf[15]), but the buffer is wiped before this check. Sometimes the 15th byte has not been set at the time of read, so the data isn't valid & ignored. On the next poll the 15th byte has been set, but the rest of the data was wiped previously, so the data is still invalid & the key is lost. Weird repeat error, where an old key press is sometimes repeated in error. ie. button sequence '1 (pause) 2 (pause) 3 (pause) 4' generates output like '1 (pause) 2 (pause) 23 (pause) 4'. The current driver zeroes the data for the key pushed, but sometimes this data is already zero but with other bytes set suggesting a repeat code. This results in the last key being incorrectly repeated. This patch attempts to reduce the risk of a missed key-press & also stop the random repeat of an old key-press when a new key is pressed. Signed-off-by: Ian Armstrong <ian@iarmst.demon.co.uk> Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] rc: Rename remote controller type to rc_type instead of ir_typeMauro Carvalho Chehab2010-12-291-6/+6
| | | | | | | for i in `find drivers/staging -type f -name *.[ch]` `find include/media -type f -name *.[ch]` `find drivers/media -type f -name *.[ch]`; do sed s,IR_TYPE,RC_TYPE,g <$i >a && mv a $i; done for i in `find drivers/staging -type f -name *.[ch]` `find include/media -type f -name *.[ch]` `find drivers/media -type f -name *.[ch]`; do sed s,ir_type,rc_type,g <$i >a && mv a $i; done Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] Rename all public generic RC functions from ir_ to rc_Mauro Carvalho Chehab2010-12-291-2/+2
| | | | | | | Those functions are not InfraRed specific. So, rename them to properly reflect it. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] ir-core: make struct rc_dev the primary interfaceDavid Härdeman2010-12-291-11/+5
| | | | | | | | | | | | | | | | | | | | | | This patch merges the ir_input_dev and ir_dev_props structs into a single struct called rc_dev. The drivers and various functions in rc-core used by the drivers are also changed to use rc_dev as the primary interface when dealing with rc-core. This means that the input_dev is abstracted away from the drivers which is necessary if we ever want to support multiple input devs per rc device. The new API is similar to what the input subsystem uses, i.e: rc_device_alloc() rc_device_free() rc_device_register() rc_device_unregister() [mchehab@redhat.com: Fix compilation on mceusb and cx231xx, due to merge conflicts] Signed-off-by: David Härdeman <david@hardeman.nu> Acked-by: Jarod Wilson <jarod@redhat.com> Tested-by: Jarod Wilson <jarod@redhat.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] af9015: Fix max I2C message size when used with tda18271Mauro Carvalho Chehab2010-10-271-1/+1
| | | | | | | | | | | | | | | | | | | | | Changeset 1724c8fa7eb33d68898e060a08a8e6a88348b62f added an option to change the maximum I2C size to 8 bytes. However, it forgot to replace the previous usage at af9015 to use the newly defined macro value (TDA18271_16_BYTE_CHUNK_INIT). A latter changeset (e350d44fed8eb86a7192a579e3687fcd76a4645b) extended the possible values for .small_i2c field and, instead of using a random sequence of numbers, it used a number that makes more sense (e. g. the actual limit, in terms of bytes). However, as af9015 were using .small_i2c = 1, this become undefined, and the restriction of a max size of 16 was gone. While here, fix the reported msg size at tda18271-common.c. Reported-by: Jiri Slaby <jirislaby@gmail.com> Tested-by: Jiri Slaby <jirislaby@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] af9015: support for DigitalNow TinyTwin v3 [1f4d:9016]Antti Palosaari2010-10-231-1/+5
| | | | | | | | | | | It is AF9015+AF9013+2xMXL5007T. Tanks to Bernard Giannetti and DigitalNow for the help! Signed-off-by: Antti Palosaari <crope@iki.fi> Cc: Renura Enterprises Pty Ltd <renura@digitalnow.com.au> Cc: Bernard Giannetti <thebernmeister@hotmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] af9015: map DigitalNow TinyTwin v2 remoteAntti Palosaari2010-10-231-0/+2
| | | | | | Signed-off-by: Antti Palosaari <crope@iki.fi> Cc: Renura Enterprises Pty Ltd <renura@digitalnow.com.au> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] af9015: RC fixes and improvementsAntti Palosaari2010-10-231-47/+33
| | | | | | | | Read all remote controller registers at once to reduce USB remote polling traffic. Use .rc_codes() to disable / enable remote polling instead of .rc_query(). Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] i2c: Stop using I2C_CLASS_TV_DIGITALJean Delvare2010-10-211-5/+0
| | | | | | | | | | Detection class I2C_CLASS_TV_DIGITAL is set by many adapters but no I2C device driver is setting it anymore, which means it can be dropped. I2C devices on digital TV adapters are instantiated explicitly these days, which is much better. Signed-off-by: Jean Delvare <khali@linux-fr.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] af9015: move remote controllers to new RC coreAntti Palosaari2010-10-211-107/+120
| | | | | | | Use new RC core instead of old legacy RC implementation. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] af9015: remove needless variable setAntti Palosaari2010-10-211-2/+2
| | | | | | | Variable is don't care in that case. No need to set value. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] af9015: make checkpatch.pl happyAntti Palosaari2010-10-211-5/+7
| | | | | Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* [media] v4l/dvb: add support for AVerMedia AVerTV Red HD+ (A850T)Yann E. MORIN2010-10-211-3/+11
| | | | | | | | | | | | | | | | The AVerTV Red HD+ (A850T) is basically the same as the existing AVerTV Volar Black HD (A850), but is specific to the french market. The A850T identifies itself as a A850, but has its own PID. It even suffers from the same EEPROM deficiencies. This is based off a collection of information gathered from the french support forums for Ubuntu, which I tried to properly format into this patch: http://forum.ubuntu-fr.org/viewtopic.php?pid=3322825 Signed-off-by: "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr> Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB: af9015: use value from config instead hardcoded oneAntti Palosaari2010-10-211-1/+2
| | | | | | | Replace 2nd demod default address 0x3a with value got from eeprom config. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB: af9015: reimplement remote controllerAntti Palosaari2010-10-211-110/+84
| | | | | | | | | | | Remove HID and polling via firmware API. Implement direct access to remote codes via memory read and write. HID and polling via firmware api never worked 100% well and there was also some limitations which tied used remote and device together. After that it is possible to use upcoming kernel remote controller core. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB: af9015: map TerraTec Cinergy T Stick Dual RC remote to device IDAntti Palosaari2010-10-211-3/+3
| | | | | | | | | Detect TerraTec Cinergy T Stick Dual RC remote config using device USB ID instead of device EEPROM hash. It was found that there is devices with slightly different EEPROM content... Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB: af9015: add remote support for TerraTec Cinergy T Stick Dual RCAntti Palosaari2010-10-211-0/+3
| | | | | | | Thanks to the TerraTec! Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB: af9015: add support for TerraTec Cinergy T Stick Dual RCAntti Palosaari2010-10-211-1/+19
| | | | | | | | | | Add USB ID [0ccd:0099] for TerraTec Cinergy T Stick Dual RC. Device is based for AF9015 + AF9013 + 2 x MxL5007T chips. Thanks to the TerraTec! Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB: af9015: fix bug introduced by commit ↵Antti Palosaari2010-10-211-19/+6
| | | | | | | | | | 490ade7e3f4474f626a8f5d778ead4e599b94fbc Commit 490ade7e3f4474f626a8f5d778ead4e599b94fbc merge conflict fix leads situation where last nine device definitions were overridden mistakenly. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB: af9015: simple comment updateAntti Palosaari2010-10-211-4/+4
| | | | | Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB: af9015: add USB ID for Terratec Cinergy T Stick RC MKIIStefan Lippers-Hollmann2010-10-211-0/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Adding the USB ID for my TerraTec Electronic GmbH Cinergy T RC MKII [0ccd:0097] and hooking it up into af9015, on top of your new NXP TDA18218 patches, makes it work for me. Just the shipped IR remote control doesn't seem to create keycode events yet (tested with different remote=%d parameters), are there any hints to add support for that? [ 2.250022] usb 1-10: new high speed USB device using ehci_hcd and address 5 [ 2.369287] usb 1-10: New USB device found, idVendor=0ccd, idProduct=0097 [ 2.369290] usb 1-10: New USB device strings: Mfr=1, Product=2, SerialNumber=3 [ 2.369293] usb 1-10: Product: USB2.0 DVB-T TV Stick [ 2.369294] usb 1-10: Manufacturer: NEWMI [ 2.369296] usb 1-10: SerialNumber: 010101010600001 [ 2.534023] usbcore: registered new interface driver hiddev [ 2.537235] input: NEWMI USB2.0 DVB-T TV Stick as /devices/pci0000:00/0000:00:02.1/usb1/1-10/1-10:1.1/input/input0 [ 2.537323] generic-usb 0003:0CCD:0097.0001: input,hidraw0: USB HID v1.01 Keyboard [NEWMI USB2.0 DVB-T TV Stick] on usb-0000:00:02.1-10/input1 [ 2.537349] usbcore: registered new interface driver usbhid [ 2.537351] usbhid: USB HID core driver [ 3.263177] generic-usb 0003:04D9:1603.0002: input,hidraw1: USB HID v1.10 Keyboard [ USB Keyboard] on usb-0000:00:02.0-8.1/input0 [ 3.286946] generic-usb 0003:04D9:1603.0003: input,hidraw2: USB HID v1.10 Device [ USB Keyboard] on usb-0000:00:02.0-8.1/input1 [ 3.467136] generic-usb 0003:046D:C050.0004: input,hidraw3: USB HID v1.10 Mouse [Logitech USB-PS/2 Optical Mouse] on usb-0000:00:02.0-8.2/input0 [ 3.660890] generic-usb 0003:10D5:000D.0005: input,hidraw4: USB HID v1.10 Keyboard [No brand SP02-A1] on usb-0000:00:02.0-8.3/input0 [ 5.567632] dvb-usb: found a 'TerraTec Cinergy T Stick RC' in cold state, will try to load a firmware [ 5.693497] dvb-usb: downloading firmware from file 'dvb-usb-af9015.fw' [ 5.773109] dvb-usb: found a 'TerraTec Cinergy T Stick RC' in warm state. [ 5.773168] dvb-usb: will pass the complete MPEG2 transport stream to the software demuxer. [ 5.774290] DVB: registering new adapter (TerraTec Cinergy T Stick RC) [ 6.007696] af9013: firmware version:5.1.0 [ 6.010843] DVB: registering adapter 0 frontend 0 (Afatech AF9013 DVB-T)... [ 6.032697] tda18218: NXP TDA18218HN successfully identified. [ 6.034442] dvb-usb: TerraTec Cinergy T Stick RC successfully initialized and connected. [ 6.040612] usbcore: registered new interface driver dvb_usb_af9015 [mchehab@redhat.com: Fix merge conflict with another board addition] Signed-off-by: Stefan Lippers-Hollmann <s.l-h@gmx.de> Acked-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB: af9015: add support for tda18218 silicon tunerAntti Palosaari2010-10-211-3/+11
| | | | | Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB: dvb-usb: prepare drivers for using rc-coreMauro Carvalho Chehab2010-08-021-12/+18
| | | | | | | | | | | | This is a big patch, yet trivial. It just move the RC properties to a separate struct, in order to prepare the dvb-usb drivers to use rc-core. There's no change on the behavior of the drivers. With this change, it is possible to have both legacy and rc-core based code inside the dvb-usb-remote, allowing a gradual migration to rc-core, driver per driver. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB: dvb-usb: get rid of struct dvb_usb_rc_keyMauro Carvalho Chehab2010-08-021-3/+3
| | | | | | | | | | | dvb-usb has its own IR handle code. Now that we have a Remote Controller subsystem, we should start using it. So, remove this struct, in favor of the similar struct defined at the RC subsystem. This is a big, but trivial patch. It is a 3 line delect, plus lots of rename on several dvb-usb files. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB: af9015: support for AverMedia AVerTV Volar M (A815Mac)Antti Palosaari2010-08-021-1/+7
| | | | | | | Add USB ID 07ca:815a for AverMedia AVerTV Volar M (A815Mac). Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB: rename all *_rc_keys to ir_codes_*_nec_tableMauro Carvalho Chehab2010-05-191-15/+15
| | | | | | | Several DVB drivers use a different name convention. As we're moving the keytables, we need to use the same convention on all places. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB: af9015: support for KWorld TV Stick II (395UR)Antti Palosaari2010-05-181-1/+3
| | | | | | | Add USB ID 1b80:e39a for KWorld TV Stick II (395UR). Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB: af9015: support for KWorld USB DVB-T Stick Mobile (UB383-T)Antti Palosaari2010-05-181-1/+8
| | | | | | | Add USB ID 1b80:e383 for KWorld USB DVB-T Stick Mobile (UB383-T). Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* include cleanup: Update gfp.h and slab.h includes to prepare for breaking ↵Tejun Heo2010-03-301-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | implicit slab.h inclusion from percpu.h percpu.h is included by sched.h and module.h and thus ends up being included when building most .c files. percpu.h includes slab.h which in turn includes gfp.h making everything defined by the two files universally available and complicating inclusion dependencies. percpu.h -> slab.h dependency is about to be removed. Prepare for this change by updating users of gfp and slab facilities include those headers directly instead of assuming availability. As this conversion needs to touch large number of source files, the following script is used as the basis of conversion. http://userweb.kernel.org/~tj/misc/slabh-sweep.py The script does the followings. * Scan files for gfp and slab usages and update includes such that only the necessary includes are there. ie. if only gfp is used, gfp.h, if slab is used, slab.h. * When the script inserts a new include, it looks at the include blocks and try to put the new include such that its order conforms to its surrounding. It's put in the include block which contains core kernel includes, in the same order that the rest are ordered - alphabetical, Christmas tree, rev-Xmas-tree or at the end if there doesn't seem to be any matching order. * If the script can't find a place to put a new include (mostly because the file doesn't have fitting include block), it prints out an error message indicating which .h file needs to be added to the file. The conversion was done in the following steps. 1. The initial automatic conversion of all .c files updated slightly over 4000 files, deleting around 700 includes and adding ~480 gfp.h and ~3000 slab.h inclusions. The script emitted errors for ~400 files. 2. Each error was manually checked. Some didn't need the inclusion, some needed manual addition while adding it to implementation .h or embedding .c file was more appropriate for others. This step added inclusions to around 150 files. 3. The script was run again and the output was compared to the edits from #2 to make sure no file was left behind. 4. Several build tests were done and a couple of problems were fixed. e.g. lib/decompress_*.c used malloc/free() wrappers around slab APIs requiring slab.h to be added manually. 5. The script was run on all .h files but without automatically editing them as sprinkling gfp.h and slab.h inclusions around .h files could easily lead to inclusion dependency hell. Most gfp.h inclusion directives were ignored as stuff from gfp.h was usually wildly available and often used in preprocessor macros. Each slab.h inclusion directive was examined and added manually as necessary. 6. percpu.h was updated not to include slab.h. 7. Build test were done on the following configurations and failures were fixed. CONFIG_GCOV_KERNEL was turned off for all tests (as my distributed build env didn't work with gcov compiles) and a few more options had to be turned off depending on archs to make things build (like ipr on powerpc/64 which failed due to missing writeq). * x86 and x86_64 UP and SMP allmodconfig and a custom test config. * powerpc and powerpc64 SMP allmodconfig * sparc and sparc64 SMP allmodconfig * ia64 SMP allmodconfig * s390 SMP allmodconfig * alpha SMP allmodconfig * um on x86_64 SMP allmodconfig 8. percpu.h modifications were reverted so that it could be applied as a separate patch and serve as bisection point. Given the fact that I had only a couple of failures from tests on step 6, I'm fairly confident about the coverage of this conversion patch. If there is a breakage, it's likely to be something in one of the arch headers which should be easily discoverable easily on most builds of the specific arch. Signed-off-by: Tejun Heo <tj@kernel.org> Guess-its-ok-by: Christoph Lameter <cl@linux-foundation.org> Cc: Ingo Molnar <mingo@redhat.com> Cc: Lee Schermerhorn <Lee.Schermerhorn@hp.com>
* V4L/DVB: af901x: inform NXP TDA18218 tuner as know but not supportedAntti Palosaari2010-02-261-0/+3
| | | | | | | | | There is no driver for new NXP TDA18218 tuner which is used by few recent af9015 designs. af9015 uses number 179 as ID for that tuner. Inform this tuner is not supported when device using that tuner is meet. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB: af9015: MYGICTV U718 remote autodetectionAntti Palosaari2010-02-261-7/+4
| | | | | | | | Autodetect MYGICTV U718 from eeprom hash and select remote automatically. Remove old iManufacturer string compare based remote selection logic. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB: af9015: A-Link DTU(m) remote autodetectionAntti Palosaari2010-02-261-0/+3
| | | | | | | Autodetect A-Link DTU(m) based eeprom hash and select correct remote. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB: af9015: support for Leadtek WinFast DTV2000DSAntti Palosaari2010-02-261-1/+7
| | | | | | | | | Add USB ID 0413:6a04 for Leadtek WinFast DTV2000DS. Thanks to Gavin Ramm <gavin_ramm@hotmail.com> for reporting this. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB: af9015: support for DigitalNow TinyTwin v2Antti Palosaari2010-02-261-1/+3
| | | | | | | | | Add USB ID 1b80:e402 for DigitalNow TinyTwin version 2. Thanks to Trevor Phillips <trevor.phillips@gmail.com> for reporting this. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB: media: dvb/af9015, add hashes supportJiri Slaby2010-02-261-2/+12
| | | | | | | | | | | | | | So as a final patch, add support for hash and one hash entry for MSI digi vox mini II: iManufacturer 1 Afatech iProduct 2 DVB-T 2 iSerial 3 010101010600001 It is now handled with proper IR and key map tables. Signed-off-by: Jiri Slaby <jslaby@suse.cz> Acked-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB: media: dvb/af9015, refactor remote settingJiri Slaby2010-02-261-133/+89
| | | | | | | | | | | | | | | Add af9015_setup structure to hold (right now only remote) setup of distinct receivers. Add af9015_setup_match for matching ids against tables. This is for easier matching different kind of ids against tables to obtain setups. Currently module parameters and usb vendor ids are switched into and matched against tables. Hashes will follow. Signed-off-by: Jiri Slaby <jslaby@suse.cz> Acked-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB: media: dvb/af9015, factor out remote settingJiri Slaby2010-02-261-148/+157
| | | | | | | | | This is just a code shuffle without functional changes. For easier review of later changes, i.e. preparation. Signed-off-by: Jiri Slaby <jslaby@suse.cz> Acked-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB: media: dvb/af9015, implement eeprom hashingJiri Slaby2010-02-261-22/+43
| | | | | | | | | | | | | | | | | | | This will be useful for matching of IR tables later. We read the eeprom anyway for dumping. Switch the dumping to print_hex_dump_bytes and compute hash above that by hash = 0; for (u32 VAL) in (eeprom): hash *= GOLDEN_RATIO_PRIME_32 hash += VAL; // while preserving endinaness The computation is moved earlier to the flow, namely from af9015_af9013_frontend_attach to af9015_read_config, so that we can access the sum in af9015_read_config already. Signed-off-by: Jiri Slaby <jslaby@suse.cz> Acked-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB (13368): af9015: support for Sveon STV20 Tuner USB DVB-T HDTVIgnacio de Miguel Diaz2009-12-051-1/+7
| | | | | | | | Add USB ID 1b80:e39d for Sveon STV20 Tuner USB DVB-T HDTV. Signed-off-by: Ignacio de Miguel Diaz <imigueldiaz@gmail.com> Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB (13058): af9015: enable remote polling when eeprom contains 0x04Antti Palosaari2009-12-051-1/+1
| | | | | | | | Looks like eeprom IR mode byte value 0x04 means there is remote which should be polled. Patch enables polling also in case of 0x04. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB (13057): af9015: add MSI DIGIVOX mini III remoteAntti Palosaari2009-12-051-0/+10
| | | | | | | | | | | Support for MSI DIGIVOX mini III remote. Thanks to Aleksandr V. Piskunov <aleksandr.v.piskunov@gmail.com> Thanks to Roman <lists@hasnoname.de> Cc: Aleksandr V. Piskunov <aleksandr.v.piskunov@gmail.com> Cc: Roman <lists@hasnoname.de> Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB (13055): af9015: fix few typosAntti Palosaari2009-12-051-3/+3
| | | | | Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB (13054): af9015: add USB ID for KWorld PlusTV DVB-T PCI Pro Card ↵Antti Palosaari2009-12-051-1/+8
| | | | | | | | | | | (DVB-T PC160-T) Add USB ID 1b80:c161 for KWorld PlusTV DVB-T PCI Pro Card (DVB-T PC160-T). Thanks to Andrew Cruickshank <atcrank@gmail.com> for reporting this. Cc: Andrew Cruickshank <atcrank@gmail.com> Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB (12756): af9015: fix typo in register compareAntti Palosaari2009-09-181-1/+1
| | | | | | | | | | And mask should be 0xff00 instead of 0xae00. Thanks to Jochen Friedrich <jochen@scram.de> for pointing this. Cc: Jochen Friedrich <jochen@scram.de> Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB (12755): af9015: improve usb control message function slightlyAntti Palosaari2009-09-181-8/+24
| | | | | | | | | | | | * define names for few values * decrease buffer len by one byte which was not used * add check for buffer overflow for sure * indentation fixes * remove useless 0 len check from memcpy It should not happen and if it happens memcpy should not do anything. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
* V4L/DVB (12754): af9015: [2/2] fix USB TS configurationAntti Palosaari2009-09-181-3/+5
| | | | | | | | | | | Fix wrongly configured USB1.1 TS EP. Patch serie also increases USB URB size to reduce wakeups. USB1.1 URB size from 64 to 940 bytes USB2.0 URB size from 512 to 16356 bytes Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>