summaryrefslogtreecommitdiff
path: root/drivers/media
AgeCommit message (Collapse)Author
2013-03-21[media] siano: add two missing fields to ISDB-T stats debugfsMauro Carvalho Chehab
Those fields help to identify the version of the ISDB stats. Useful while debuging the driver. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: split debugfs code into a separate fileMauro Carvalho Chehab
To avoid mixing two different things at the same place, move the debugfs code into a separate file. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: allow showing the complete statistics via debugfsMauro Carvalho Chehab
Outputs the result of the statistics responses via debugfs. That can help to track bugs at the stats filling. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: fix start of statisticsMauro Carvalho Chehab
It seems that the first u32 after the header for some stats are used by something not documented. The stats struct starts after it. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: Convert it to report DVBv5 statsMauro Carvalho Chehab
While this frontend provides a nice set of statistics, the way it is currently reported to userspace is poor. Worse than that, instead of using quality indicators that range from 0 to 65535, as expected by userspace, most indicators range from 0 to 100. Improve it by using DVBv5 statistics API. The legacy indicators are still reported using the very same old way, but they're now using a proper range (0 to 65535 for quality indicadors; 0.1 dB for SNR). Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: split debug logic from the status update routineMauro Carvalho Chehab
It is confusing to merge both status updates with debug stuff. Also, it is a better idea to move those status updates to debugfs, instead of doing a large amount of printk's like that. So, break them into a separate block of routines. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: split get_frontend into per-std functionsMauro Carvalho Chehab
Instead of handling both DVB-T and ISDB-T at the same get_frontend function, break it intow one function per-delivery system. That makes the code clearer as we start to add support for DVBv5 statistics, and for ISDB-T get frontend stuff. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: simplify message endianness logicMauro Carvalho Chehab
Currently, every time a message is sent or received, the endiannes need to be fixed on big endian machines. This is currently done on every call to the send API, and on every msg reception logic. Instead of doing that, move it to the send/receive functions. That simplifies the logic and avoids the risk of forgetting to fix it somewhere. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: call MSG_SMS_INIT_DEVICE_REQMauro Carvalho Chehab
Newer firmwares seem to require an init device message. Apply such change from Doron Cohen's patch: http://patchwork.linuxtv.org/patch/7889/ Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: Configure board's mtu and xtalMauro Carvalho Chehab
Backported from Doron Cohen's patch: http://patchwork.linuxtv.org/patch/7889/ Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: add new devices to the Siano DriverMauro Carvalho Chehab
This patch is based on Doron Cohen's patches: http://patchwork.linuxtv.org/patch/7881/ http://patchwork.linuxtv.org/patch/7888/ http://patchwork.linuxtv.org/patch/7883/ It basically merges the above patches, rebasing them to the macro definitions used upstream, with are different than the ones used by them internally. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: use the newer stats message for recent firmwaresMauro Carvalho Chehab
The old statistics request don't work with newer firmwares. Add a logic to use the newer stats if firmware major is 8. Note that I have only 2 devices here, one with firmware 2.1 (Hauppauge model 55009 Rev B1F7) and another one with firmware 8.1. We may need to adjust the firmware minimal version for the *_EX message variants, as we start finding firmware versions between 2.x and 8.x. This patch was based on Doron Cohen patch: http://patchwork.linuxtv.org/patch/7886/ Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: add support for LNA on ISDB-TMauro Carvalho Chehab
The very same code also exists for DVB-T. Add it for ISDB-T. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: add support for ISDB-T full-segMauro Carvalho Chehab
Fix the DVBv5 API handling for ISDB-T and add support for 13 segments. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: use a separate completion for statsMauro Carvalho Chehab
Instead of re-use tune_done also for stats, the better is to use a different completion. Also, it was noticed that sometimes, the driver answers with MSG_SMS_SIGNAL_DETECTED_IND for status request. Fix the code to also handle those other signal indicators. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: add some new messages to the smscoreapiMauro Carvalho Chehab
Based on Doron Cohen's patch: http://patchwork.linuxtv.org/patch/7887/ Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: cleanups at smscoreapi.cMauro Carvalho Chehab
Some cleanups at smscoreapi. Most are just CodingStyle. Also, use kzalloc when allocating a new buffer, as it initializes the allocated space with zero. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: always load smsdvbMauro Carvalho Chehab
Without smsdvb, the driver actually does nothing, as it lacks the userspace API. While I wrote it independently, in order to make a sms2270 board I have here to work, this patch is functionally identical to this patch from Doron Cohen: http://patchwork.linuxtv.org/patch/7894/ Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: fix the debug messageMauro Carvalho Chehab
Instead of displaying this: [ 61.869415] smscore_load_firmware_family2: rc=0, postload=0x (null) Display, instead: [ 1348.441160] smscore_load_firmware_family2: rc=0 Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: report the choosed firmware in debugMauro Carvalho Chehab
Don't keep in the dark: report the firmware file name after lookup. That helps to debug what's happening when a firmware is not found. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: make load firmware logic to work with newer firmwaresMauro Carvalho Chehab
There are new firmwares for sms2xxx devices. Change the firmware load logic to handle those newer firmwares and devices. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: store firmware versionMauro Carvalho Chehab
As there are some changes that seem to be firmware-dependent, we need to store the firmware version, as we don't want to break support for existing cards that use a legacy (and sometimes custom) firmware. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: use USB endpoint descriptors for in/out endpMauro Carvalho Chehab
Instead of using hardcoded descriptors, detect them from the USB descriptors. This patch is rebased form Doron Cohen's patch: http://patchwork.linuxtv.org/patch/7883/ Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: add additional attributes to cards entriesMauro Carvalho Chehab
Those attributes will be used by the newer sms2xxx cards. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: Properly initialize board informationMauro Carvalho Chehab
Board #0 is an existing one. Instead of initializing the driver with it, use a different value to detect if board is unknown. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: add the remaining new defines from new driverMauro Carvalho Chehab
Add the remaining new defines/enums from Doron Cohen's patch: http://patchwork.linuxtv.org/patch/7882/ Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: better debug send/receive messagesMauro Carvalho Chehab
Instead of printing a message for some random messages, print it for all sent/received ones. That helps a lot to debug what's going on. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: update message macrosMauro Carvalho Chehab
Convert from #define into an enum and add the newer message macros as found on this patch from Doron Cohen: http://patchwork.linuxtv.org/patch/7882/ No messages got supressed. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: remove a duplicated structure definitionMauro Carvalho Chehab
The same GPIO config struct was declared twice at the driver, with different names and different macros: struct smscore_config_gpio struct smscore_config_gpio Remove the one that uses CamelCase and fix the references to its attributes/macros. No functional changes. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: Add the new voltage definitions for GPIOMauro Carvalho Chehab
Those new definitions came from this patch, from Doron Cohen: http://patchwork.linuxtv.org/patch/7882/ Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-21[media] siano: Change GPIO voltage setting namesMauro Carvalho Chehab
Siano changed the namespace on more recent API, and re-used some of the old names. In order to be able to update the API to support newer chips, the better is to follow this change. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-19[media] davinci: vpbe: fix module buildLad, Prabhakar
add a null entry in platform_device_id {}. This patch fixes following error: drivers/media/platform/davinci/vpbe_venc: struct platform_device_id is 24 bytes. The last of 3 is: 0x64 0x6d 0x33 0x35 0x35 0x2c 0x76 0x70 0x62 0x65 0x2d 0x76 0x65 0x6e 0x63 0x00 0x00 0x00 0x00 0x00 0x03 0x00 0x00 0x00 FATAL: drivers/media/platform/davinci/vpbe_venc: struct platform_device_id is not terminated with a NULL entry! make[1]: *** [__modpost] Error 1 Reported-by: Sekhar Nori <nsekhar@ti.com> Signed-off-by: Lad, Prabhakar <prabhakar.csengg@gmail.com> Tested-by: Sekhar Nori <nsekhar@ti.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-19[media] blackfin: replace V4L2_IN/OUT_CAP_CUSTOM_TIMINGS by DV_TIMINGSHans Verkuil
The use of V4L2_IN/OUT_CAP_CUSTOM_TIMINGS is obsolete, use DV_TIMINGS instead. Note that V4L2_IN/OUT_CAP_CUSTOM_TIMINGS is just a #define for V4L2_IN/OUT_CAP_DV_TIMINGS. At some point in the future these CUSTOM_TIMINGS defines might be removed. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Scott Jiang <scott.jiang.linux@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-19[media] davinci: more gama -> gamma typo fixesHans Verkuil
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Lad, Prabhakar <prabhakar.lad@ti.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-19[media] davinci/dm644x_ccdc: fix compiler warningHans Verkuil
drivers/media/platform/davinci/dm644x_ccdc.c: In function ‘validate_ccdc_param’: drivers/media/platform/davinci/dm644x_ccdc.c:233:32: warning: comparison between ‘enum ccdc_gama_width’ and ‘enum ccdc_data_size’ [-Wenum-compare] It took a bit of work, see this thread of an earlier attempt to fix this: https://patchwork.kernel.org/patch/1923091/ I've chosen not to follow the suggestions in that thread since gamma_width is really a different property from data_size. What you really want is to know if gamma_width fits inside data_size and for that you need to translate each enum into a maximum bit number so you can safely compare the two. So I put in two static inline translation functions instead, keeping the rest of the code the same (except for fixing the 'gama' typo). Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Lad, Prabhakar <prabhakar.lad@ti.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-19[media] davinci/vpfe_capture: remove current_normHans Verkuil
Since vpfe_capture already provided a g_std op setting current_norm does not actually do anything. Remove it. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Lad, Prabhakar <prabhakar.lad@ti.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-19[media] davinci/vpbe_display: remove deprecated current_normHans Verkuil
Since vpbe_display already provides a g_std op setting current_norm didn't do anything. Remove that code. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Lad, Prabhakar <prabhakar.lad@ti.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-19[media] davinci/vpfe_capture: convert to the control frameworkHans Verkuil
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Lad, Prabhakar <prabhakar.lad@ti.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-19[media] davinci: remove VPBE_ENC_DV_PRESET and rename VPBE_ENC_CUSTOM_TIMINGSHans Verkuil
Remove VPBE_ENC_DV_PRESET (the DV_PRESET API is no longer supported) and VPBE_ENC_CUSTOM_TIMINGS is renamed to VPBE_ENC_DV_TIMINGS since the old "CUSTOM_TIMINGS" name is deprecated in favor of "DV_TIMINGS". Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Lad, Prabhakar <prabhakar.lad@ti.com> Acked-by: Sekhar Nori <nsekhar@ti.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-19[media] tvp7002: remove dv_preset supportHans Verkuil
Finally remove the dv_preset support from this driver. Note that dv_preset support was already removed from any bridge drivers that use this i2c driver, so the dv_preset ops were no longer called and can be removed safely. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Lad, Prabhakar <prabhakar.lad@ti.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-19[media] tvp7002: use dv_timings structs instead of presetsHans Verkuil
In the functions tvp7002_mbus_fmt(), tvp7002_log_status and tvp7002_probe() we should use the dv_timings data structures instead of dv_preset data structures and functions. This is the second step towards removing the deprecated preset support of this driver. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Lad, Prabhakar <prabhakar.lad@ti.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-19[media] tvp7002: replace 'preset' by 'timings' in various structs/variablesHans Verkuil
This is the first step towards removing the deprecated preset support of this driver. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Acked-by: Lad, Prabhakar <prabhakar.lad@ti.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-19[media] [1/1,dvb-usb] GOTVIEW SatelliteHD card supportAndrey Pavlenko
Added support for the GOTVIEW SatelliteHD card which is based on Montage M88DS3000 and works very well with this driver. Signed-off-by: Andrey Pavlenko <andrey.a.pavlenko@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-19[media] rc-core: rename ir_input_class to rc_classDavid Härdeman
The name is already misleading and will be more so in the future as the connection to the input subsystem is obscured away further. Signed-off-by: David Härdeman <david@hardeman.nu> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-19[media] rc-core: initialize rc-core earlier if built-inDavid Härdeman
rc-core is a subsystem so it should be registered earlier if built into the kernel. Signed-off-by: David Härdeman <david@hardeman.nu> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-19[media] lmedm04: Remove redundant NULL check before kfreeSyam Sidhardhan
kfree on NULL pointer is a no-op. Signed-off-by: Syam Sidhardhan <s.syam@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-19[media] dvb_demux: Transport stream continuity check fixJohn Smith
This patch avoids incrementing continuity counter demux->cnt_storage[pid] for TS packets without payload in accordance with ISO /IEC 13818-1. [mchehab@redhat.com: unmangle whitespacing and fix CodingStyle. Also checked ISO/IEC spec: patch is according with it] Reviewed-by: Mauro Carvalho Chehab <mchehab@redhat.com> Signed-off-by: John Smith <johns90812@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-19[media] redrat3: missing endian conversions and warningsSean Young
Spotted by sparse. Signed-off-by: Sean Young <sean@mess.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-19[media] redrat3: remove memcpys and fix unaligned memory accessSean Young
In stead of doing a memcpy from #defined offset, declare structs which describe the incoming and outgoing data accurately. Tested on first generation RedRat. Signed-off-by: Sean Young <sean@mess.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2013-03-19[media] redrat3: limit periods to hardware limitsSean Young
The redrat hardware cannot handle periods of larger than 32767us, limit appropriately. Also fix memory leak in redrat3_get_timeout. Signed-off-by: Sean Young <sean@mess.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>