summaryrefslogtreecommitdiffstats
path: root/drivers/media/dvb-frontends/si2165.c
Commit message (Collapse)AuthorAgeFilesLines
* [media] si2165: Refactoring for si2165_writereg_mask8()Markus Elfring2016-01-251-9/+5
| | | | | | | | | | | | | | | | | | | This issue was detected by using the Coccinelle software. 1. Let us return directly if a call of the si2165_readreg8() function failed. 2. Reduce the scope for the local variables "ret" and "tmp" to one branch of an if statement. 3. Delete the jump label "err" then. 4. Return the value from a call of the si2165_writereg8() function without using an extra assignment for the variable "ret" at the end. Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> Signed-off-by: Matthias Schwarzott <zzam@gentoo.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
* [media] si2165: Reject DVB-T bandwidth auto modeMatthias Schwarzott2016-01-251-7/+7
| | | | | | | | The si2165 does not support bandwidth auto-detection. Reject the request. Signed-off-by: Matthias Schwarzott <zzam@gentoo.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
* Merge branch 'for-linus' of ↵Linus Torvalds2016-01-141-2/+2
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial Pull trivial tree updates from Jiri Kosina. * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial: floppy: make local variable non-static exynos: fixes an incorrect header guard dt-bindings: fixes some incorrect header guards cpufreq-dt: correct dead link in documentation cpufreq: ARM big LITTLE: correct dead link in documentation treewide: Fix typos in printk Documentation: filesystem: Fix typo in fs/eventfd.c fs/super.c: use && instead of & for warn_on condition Documentation: fix sysfs-ptp lib: scatterlist: fix Kconfig description
| * treewide: Fix typos in printkMasanari Iida2015-12-081-2/+2
| | | | | | | | | | | | | | | | | | This patch fix multiple spelling typos found in various part of kernel. Signed-off-by: Masanari Iida <standby24x7@gmail.com> Acked-by: Randy Dunlap <rdunlap@infradead.org> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
* | [media] si2165: Add DVB-C support for HVR-4400/HVR-5500Matthias Schwarzott2015-12-031-5/+81
| | | | | | | | | | | | | | | | | | It works only for HVR-4400/HVR-5500. For WinTV-HVR-930C-HD it fails with bad/no reception for unknown reasons. Signed-off-by: Matthias Schwarzott <zzam@gentoo.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
* | [media] si2165: Prepare si2165_set_frontend() for future DVB-C supportMatthias Schwarzott2015-12-031-14/+37
| | | | | | | | | | | | | | | | The current si2165_set_frontend() function actually works only for DVB-T. Split it into two functions, preparing the code to support DVB-C. Signed-off-by: Matthias Schwarzott <zzam@gentoo.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
* | [media] si2165: set list of DVB-T registers togetherMatthias Schwarzott2015-12-031-47/+26
| | | | | | | | | | | | | | Use si2165_write_reg_list() to do the DVB-T mode initialization altogether. Signed-off-by: Matthias Schwarzott <zzam@gentoo.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
* | [media] si2165: Simplify si2165_set_if_freq_shift usageMatthias Schwarzott2015-12-031-13/+13
| | | | | | | | | | | | | | | | | | si2165_set_if_freq_shift() needs to call get_if_frequency() in order to do the right shift. Add such logic inside the function, simplifying the logic for the callers. Signed-off-by: Matthias Schwarzott <zzam@gentoo.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
* | [media] si2165: move setting ts config to initMatthias Schwarzott2015-12-031-13/+14
| | | | | | | | | | | | | | The TS config is fixed, so no need to write it for each tune. Signed-off-by: Matthias Schwarzott <zzam@gentoo.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
* | [media] si2165: only write agc registers after reset before start_syncroMatthias Schwarzott2015-12-031-17/+15
| | | | | | | | | | | | | | | | Datasheet says they must be rewritten after reset. But it only makes sense to write them when trying to tune afterwards. Signed-off-by: Matthias Schwarzott <zzam@gentoo.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
* | [media] si2165: create function si2165_write_reg_list for writing register listsMatthias Schwarzott2015-12-031-0/+21
| | | | | | | | | | | | | | | | It is common the need of writing a table of values. Add a function to provide a helper to address such case. This will allow further code cleanups. Signed-off-by: Matthias Schwarzott <zzam@gentoo.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
* | [media] si2165: rename si2165_set_parameters to si2165_set_frontendMatthias Schwarzott2015-12-031-2/+2
| | | | | | | | | | | | | | No functional changes. Signed-off-by: Matthias Schwarzott <zzam@gentoo.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
* | [media] si2165: rename frontend -> feMatthias Schwarzott2015-12-031-9/+9
| | | | | | | | | | | | | | No functional changes. Signed-off-by: Matthias Schwarzott <zzam@gentoo.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
* | [media] si2165: fix checkpatch issuesMatthias Schwarzott2015-11-191-30/+39
|/ | | | | Signed-off-by: Matthias Schwarzott <zzam@gentoo.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
* [media] dvb: Get rid of typedev usage for enumsMauro Carvalho Chehab2015-06-091-1/+1
| | | | | | | | | | | | | | | | | The DVB API was originally defined using typedefs. This is against Kernel CodingStyle, and there's no good usage here. While we can't remove its usage on userspace, we can avoid its usage in Kernelspace. So, let's do it. This patch was generated by this shell script: for j in $(grep typedef include/uapi/linux/dvb/frontend.h |cut -d' ' -f 3); do for i in $(find drivers/media -name '*.[ch]' -type f) $(find drivers/staging/media -name '*.[ch]' -type f); do sed "s,${j}_t,enum $j," <$i >a && mv a $i; done; done While here, make CodingStyle fixes on the affected lines. Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Acked-by: Stefan Richter <stefanr@s5r6.in-berlin.de> # for drivers/media/firewire/*
* [media] si2165: Fix possible leak in si2165_upload_firmware()Christian Engelmayer2015-04-081-1/+1
| | | | | | | | | | | | In case of an error function si2165_upload_firmware() releases the already requested firmware in the exit path. However, there is one deviation where the function directly returns. Use the correct cleanup so that the firmware memory gets freed correctly. Detected by Coverity CID 1269120. Signed-off-by: Christian Engelmayer <cengelma@gmx.at> Signed-off-by: Matthias Schwarzott <zzam@gentoo.org> Reviewed-by: Luis de Bethencourt <luis.bg@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
* [media] si2165: enable Si2161 supportMatthias Schwarzott2014-09-231-12/+27
| | | | | | | | | Additionally print chip name with revision symbolically. This is a preparation for supporting new Hauppauge WinTV-HVR-900-H based on cx231xx. Signed-off-by: Matthias Schwarzott <zzam@gentoo.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
* [media] si2165: Load driver for all hardware revisionsMatthias Schwarzott2014-09-231-9/+17
| | | | | | | Current firmware is only for revision D. Signed-off-by: Matthias Schwarzott <zzam@gentoo.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
* [media] si2165: fix sparse warningHans Verkuil2014-09-031-1/+1
| | | | | | | drivers/media/dvb-frontends/si2165.c:329:16: warning: odd constant _Bool cast (ffffffffffffffea becomes 1) Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
* [media] si2165: Add demod driver for DVB-T onlyMatthias Schwarzott2014-07-271-0/+1040
DVB-T was tested with 8MHz BW channels in germany This driver is the simplest possible, it uses automatic mode for all parameters (TPS). Added spectrum inversion support. Signed-off-by: Matthias Schwarzott <zzam@gentoo.org> Tested-by: Mauro Carvalho Chehab <m.chehab@samsung.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
OpenPOWER on IntegriCloud