summaryrefslogtreecommitdiffstats
path: root/drivers/media/usb/cx231xx
Commit message (Collapse)AuthorAgeFilesLines
* media: usb: cx231xx-417: include linux/slab.h headerAnders Roxell2018-05-111-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | cx231-417 uses kmalloc/kfree functions, so slab header needs to be included in order to fix the following build errors: drivers/media/usb/cx231xx/cx231xx-417.c: In function ‘cx231xx_bulk_copy’: CC drivers/media/platform/qcom/venus/firmware.o drivers/media/usb/cx231xx/cx231xx-417.c:1389:11: error: implicit declaration of function ‘kmalloc’; did you mean ‘vmalloc’? [-Werror=implicit-function-declaration] buffer = kmalloc(buffer_size, GFP_ATOMIC); ^~~~~~~ vmalloc drivers/media/usb/cx231xx/cx231xx-417.c:1389:9: warning: assignment makes pointer from integer without a cast [-Wint-conversion] buffer = kmalloc(buffer_size, GFP_ATOMIC); ^ drivers/media/usb/cx231xx/cx231xx-417.c:1400:2: error: implicit declaration of function ‘kfree’; did you mean ‘vfree’? [-Werror=implicit-function-declaration] kfree(buffer); ^~~~~ vfree drivers/media/usb/cx231xx/cx231xx-417.c: In function ‘mpeg_open’: drivers/media/usb/cx231xx/cx231xx-417.c:1713:7: error: implicit declaration of function ‘kzalloc’; did you mean ‘vzalloc’? [-Werror=implicit-function-declaration] fh = kzalloc(sizeof(*fh), GFP_KERNEL); ^~~~~~~ vzalloc drivers/media/usb/cx231xx/cx231xx-417.c:1713:5: warning: assignment makes pointer from integer without a cast [-Wint-conversion] fh = kzalloc(sizeof(*fh), GFP_KERNEL); ^ Signed-off-by: Anders Roxell <anders.roxell@linaro.org> Signed-off-by: Hans Verkuil <hansverk@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
* media: cx231xx: Fix spelling mistake: "senario" -> "scenario"Colin Ian King2018-05-111-1/+1
| | | | | | | | Trivial fix to spelling mistake in dev_err message. Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Hans Verkuil <hansverk@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
* media: cx231xx: Fix recursive dependencyBrad Love2018-05-051-1/+0
| | | | | | | | | | 0day build bot reported an unnoticed recursive dependency, fix it by removing the select statement. fixes: c66d4d99a8fb ("cx231xx: Add I2C_MUX dependency") Signed-off-by: Brad Love <brad@nextdimension.cc> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
* media: cx231xx: remove a now unused varMauro Carvalho Chehab2018-05-051-1/+0
| | | | | | | | | | drivers/media/usb/cx231xx/cx231xx-dvb.c: In function 'unregister_dvb': drivers/media/usb/cx231xx/cx231xx-dvb.c:607:21: warning: unused variable 'client' [-Wunused-variable] struct i2c_client *client; ^~~~~~ Fixes: a12481354656 ("media: cx231xx: Switch to using new dvb i2c helpers") Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
* media: cx231xx: Add I2C_MUX dependencyBrad Love2018-05-051-1/+1
| | | | | | | cx231xx requires i2c mux adapter capability. Signed-off-by: Brad Love <brad@nextdimension.cc> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
* media: cx231xx: Remove RC_CORE dependencyBrad Love2018-05-051-1/+0
| | | | | | | | VIDEO_CX231XX_RC requires RC_CORE, but VIDEO_CX231XX does not require RC to compile or function. Signed-off-by: Brad Love <brad@nextdimension.cc> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
* media: cx231xx: Remove unnecessary parameter clearBrad Love2018-05-051-1/+0
| | | | | | | The default is now 0, no need to override Signed-off-by: Brad Love <brad@nextdimension.cc> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
* media: cx231xx: Update 955Q from dvb attach to i2c deviceBrad Love2018-05-051-10/+11
| | | | | | | | Trim out some unused config params. Use the i2c mux adapter returned by frontend with the tuner. Signed-off-by: Brad Love <brad@nextdimension.cc> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
* media: cx231xx: Switch to using new dvb i2c helpersBrad Love2018-05-051-252/+78
| | | | | | | | | Mostly very straight forward replace of blocks with equivalent code. Cleanup added at end of dvb_init in case of failure. Signed-off-by: Brad Love <brad@nextdimension.cc> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
* media: cx231xx: Ignore an i2c mux adapterBrad Love2018-05-051-1/+1
| | | | | | | | | | Hauppauge 935C cannot communicate with the si2157 when using the mux adapter returned by the si2168, so disable it to fix the device. Signed-off-by: Brad Love <brad@nextdimension.cc> Cc: stable@vger.kernel.org Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
* media: cx231xx: Style fix for struct zero initBrad Love2018-05-051-8/+4
| | | | | | | | Replace zero fill memset inits with equivalent {} in declaration Signed-off-by: Brad Love <brad@nextdimension.cc> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
* media: cx231xx: Use board profile values for addressesBrad Love2018-05-051-10/+9
| | | | | | | | Replace all usage of hard coded values with the proper field from the board profile. Signed-off-by: Brad Love <brad@nextdimension.cc> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
* media: cx231xx: Fix several incorrect demod addressesBrad Love2018-05-051-3/+3
| | | | | | | | Now the board values match the hard coded constants used in the dvb initialization. Signed-off-by: Brad Love <brad@nextdimension.cc> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
* media: cx231xx: get rid of videobuf-dvb dependencyMauro Carvalho Chehab2018-05-043-5/+5
| | | | | | | | This driver doesn't use videobuf-dvb. So, stop adding an unused struct and unused header on it. Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
* media: cx231xx: Add support for AverMedia DVD EZMaker 7Kai-Heng Feng2018-04-201-0/+3
| | | | | | | | | | | | User reports AverMedia DVD EZMaker 7 can be driven by VIDEO_GRABBER. Add the device to the id_table to make it work. BugLink: https://bugs.launchpad.net/bugs/1620762 Cc: stable@vger.kernel.org Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com> Signed-off-by: Hans Verkuil <hansverk@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
* media: cx231xx: Increase USB bridge bandwidthBrad Love2018-04-041-1/+1
| | | | | | | | | | | | | | The cx231xx USB bridge has issue streaming QAM256 DVB-C channels. QAM64 channels were fine, but QAM256 channels produced corrupted transport streams. cx231xx alt mode 4 does not provide enough bandwidth to acommodate QAM256 DVB-C channels, most likely DVB-T2 channels would break up as well. Alt mode 5 increases bridge bandwidth to 90Mbps, and fixes QAM256 DVB-C streaming. Signed-off-by: Brad Love <brad@nextdimension.cc> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
* media: add tuner standby op, use where neededHans Verkuil2018-03-211-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The v4l2_subdev core s_power op was used for two different things: power on/off sensors or video decoders/encoders and to put a tuner in standby (and only the tuner!). There is no 'tuner wakeup' op, that's done automatically when the tuner is accessed. The danger with calling (s_power, 0) to put a tuner into standby is that it is usually broadcast for all subdevs. So a video receiver subdev that supports s_power will also be powered off, and since there is no corresponding (s_power, 1) they will never be powered on again. In addition, this is specifically meant for tuners only since they draw the most current. This patch adds a new tuner op called 'standby' and replaces all calls to (core, s_power, 0) by (tuner, standby). This prevents confusion between the two uses of s_power. Note that there is no overlap: bridge drivers either just want to put the tuner into standby, or they deal with powering on/off sensors. Never both. This also makes it easier to replace s_power for the remaining bridge drivers with some PM code later. Whether we want something cleaner for tuners in the future is a separate topic. There is a lot of legacy code surrounding tuners, and I am very hesitant about making changes there. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
* media: cx231xx: Add second i2c demod to Hauppauge 975Brad Love2018-03-072-3/+50
| | | | | | | | | | | | Hauppauge HVR-975 is a hybrid, dual frontend, single tuner USB device. It contains lgdt3306a and si2168 frontends and one si2157 tuner. The lgdt3306a frontend is currently enabled. This creates the second demodulator and attaches it to the tuner. Enables lgdt3306a|si2168 + si2157 Signed-off-by: Brad Love <brad@nextdimension.cc> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
* media: cx231xx: Use constant instead of hard code for maxBrad Love2018-03-071-1/+2
| | | | | | | Nit regarding hard coded value. Signed-off-by: Brad Love <brad@nextdimension.cc> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
* media: cx231xx: Set mfe_shared if second frontend foundBrad Love2018-03-071-0/+3
| | | | | | | If frontend[1] exists, then enable the dvb adapter mfe lock system. Signed-off-by: Brad Love <brad@nextdimension.cc> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
* media: cx231xx: Use frontend i2c adapter with tunerBrad Love2018-03-071-1/+1
| | | | | | | Utilize the i2c mux adapter returned by the frontend. Signed-off-by: Brad Love <brad@nextdimension.cc> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
* media: usb: don't initialize vars if not neededMarkus Elfring2018-03-062-2/+2
| | | | | | | | | Some local variables will be set to an appropriate value before usage. Thus omit explicit initialisations at the beginning of these functions. Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> Acked-by: Alexey Klimov <klimov.linux@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
* media: cx231xx: Add second i2c demod clientBrad Love2018-03-062-20/+26
| | | | | | | | | Include ability to add a i2c device style frontend to cx231xx USB bridge. All current boards set to use frontend[0]. Changes are backwards compatible with current behaviour. Signed-off-by: Brad Love <brad@nextdimension.cc> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
* media: cx231xx: Add second frontend optionBrad Love2018-03-061-76/+97
| | | | | | | | | | Include ability to add a second dvb attach style frontend to cx231xx USB bridge. All current boards set to use frontend[0]. Changes are backwards compatible with current behaviour. [mchehab@s-opensource.com: fix some coding style issues] Signed-off-by: Brad Love <brad@nextdimension.cc> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
* media: cx231xx: Add support for Hauppauge HVR-975Brad Love2018-03-063-0/+117
| | | | | | | | | | | | | | | Hauppauge HVR-975 is hybrid NTSC/PAL, QAM/ATSC, and DVB-C/T/T2 usb device. Only ATSC/QAM front end is initially active. Second frontend support is work in progress. CX23102 + LG3306A/Si2168(WiP) + Si2157 Changes since v1: - removed double semicolon Signed-off-by: Brad Love <brad@nextdimension.cc> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
* media: cx231xx: Add support for Hauppauge HVR-935CBrad Love2018-03-063-0/+118
| | | | | | | | | HVR-935C is hybrid PAL, DVB-C/T/T2 usb device. CX23102 + Si2168 + Si2157 Signed-off-by: Brad Love <brad@nextdimension.cc> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
* media: s5h14*.h: fix typos for CONTINUOUSMauro Carvalho Chehab2018-03-061-3/+3
| | | | | | | | | | | | | | There is a typo at the several s5h14*.h headers: continuous were spelled incorrectly. Fix it with this script: for i in $(git grep -l S5H1409_MPEGTIMING_CONTINOUS_NONINVERTING_CLOCK); do sed s,S5H1409_MPEGTIMING_CONTINOUS_NONINVERTING_CLOCK,S5H1409_MPEGTIMING_CONTINUOUS_NONINVERTING_CLOCK,g -i $i done for i in $(git grep -l -i continous drivers/media); do sed s,CONTINOUS,CONTINUOUS,g -i $i; done Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
* vfs: do bulk POLL* -> EPOLL* replacementLinus Torvalds2018-02-112-7/+7
| | | | | | | | | | | | | | | | | | | | | | | This is the mindless scripted replacement of kernel use of POLL* variables as described by Al, done by this script: for V in IN OUT PRI ERR RDNORM RDBAND WRNORM WRBAND HUP RDHUP NVAL MSG; do L=`git grep -l -w POLL$V | grep -v '^t' | grep -v /um/ | grep -v '^sa' | grep -v '/poll.h$'|grep -v '^D'` for f in $L; do sed -i "-es/^\([^\"]*\)\(\<POLL$V\>\)/\\1E\\2/" $f; done done with de-mangling cleanups yet to come. NOTE! On almost all architectures, the EPOLL* constants have the same values as the POLL* constants do. But they keyword here is "almost". For various bad reasons they aren't the same, and epoll() doesn't actually work quite correctly in some cases due to this on Sparc et al. The next patch from Al will sort out the final differences, and we should be all done. Scripted-by: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* Merge tag 'media/v4.16-2' of ↵Linus Torvalds2018-02-0612-45/+64
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media Pull media updates from Mauro Carvalho Chehab: - videobuf2 was moved to a media/common dir, as it is now used by the DVB subsystem too - Digital TV core memory mapped support interface - new sensor driver: ov7740 - several improvements at ddbridge driver - new V4L2 driver: IPU3 CIO2 CSI-2 receiver unit, found on some Intel SoCs - new tuner driver: tda18250 - finally got rid of all LIRC staging drivers - as we don't have old lirc drivers anymore, restruct the lirc device code - add support for UVC metadata - add a new staging driver for NVIDIA Tegra Video Decoder Engine - DVB kAPI headers moved to include/media - synchronize the kAPI and uAPI for the DVB subsystem, removing the gap for non-legacy APIs - reduce the kAPI gap for V4L2 - lots of other driver enhancements, cleanups, etc. * tag 'media/v4.16-2' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media: (407 commits) media: v4l2-compat-ioctl32.c: make ctrl_is_pointer work for subdevs media: v4l2-compat-ioctl32.c: refactor compat ioctl32 logic media: v4l2-compat-ioctl32.c: don't copy back the result for certain errors media: v4l2-compat-ioctl32.c: drop pr_info for unknown buffer type media: v4l2-compat-ioctl32.c: copy clip list in put_v4l2_window32 media: v4l2-compat-ioctl32.c: fix ctrl_is_pointer media: v4l2-compat-ioctl32.c: copy m.userptr in put_v4l2_plane32 media: v4l2-compat-ioctl32.c: avoid sizeof(type) media: v4l2-compat-ioctl32.c: move 'helper' functions to __get/put_v4l2_format32 media: v4l2-compat-ioctl32.c: fix the indentation media: v4l2-compat-ioctl32.c: add missing VIDIOC_PREPARE_BUF media: v4l2-ioctl.c: don't copy back the result for -ENOTTY media: v4l2-ioctl.c: use check_fmt for enum/g/s/try_fmt media: vivid: fix module load error when enabling fb and no_error_inj=1 media: dvb_demux: improve debug messages media: dvb_demux: Better handle discontinuity errors media: cxusb, dib0700: ignore XC2028_I2C_FLUSH media: ts2020: avoid integer overflows on 32 bit machines media: i2c: ov7740: use gpio/consumer.h instead of gpio.h media: entity: Add a nop variant of media_entity_cleanup ...
| * media: replace all <spaces><tab> occurrencesMauro Carvalho Chehab2018-01-046-17/+17
| | | | | | | | | | | | | | There are a lot of places where sequences of space/tabs are found. Get rid of all spaces before tabs. Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
| * media: fix usage of whitespaces and on indentationMauro Carvalho Chehab2018-01-041-1/+1
| | | | | | | | | | | | | | | | | | On several places, whitespaces are being used for indentation, or even at the end of the line. Fix them. Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
| * media: don't include drivers/media/i2c at cflagsMauro Carvalho Chehab2017-12-281-1/+0
| | | | | | | | | | | | | | Most of the I2C headers got moved a long time ago to include/media/i2c. Stop including them at the patch. Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
| * media: move dvb kAPI headers to include/mediaMauro Carvalho Chehab2017-12-283-3/+2
| | | | | | | | | | | | | | | | Except for DVB, all media kAPI headers are at include/media. Move the headers to it. Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
| * media: v4l2-dev: convert VFL_TYPE_* into an enumMauro Carvalho Chehab2017-12-181-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | Using enums makes easier to document, as it can use kernel-doc markups. It also allows cross-referencing, with increases the kAPI readability. Please notice that now cx88_querycap() has to have a default for the VFL type, as there are more types than supported by the driver. Acked-By: Mike Isely <isely@pobox.com> Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
| * media: cx231xx: Use semicolon after assignment instead of commaMatthias Schwarzott2017-12-121-4/+4
| | | | | | | | | | | | | | End assignments by semicolon instead of comma. Signed-off-by: Matthias Schwarzott <zzam@gentoo.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
| * media: si2165: Make checkpatch happyMatthias Schwarzott2017-12-121-2/+2
| | | | | | | | | | | | | | | | | | | | | | Fix almost all of checkpatch --strict warnings. The remaining warnings are about: * macro REG16 (should be enclosed in parentheses) * macro REG16 (Macro argument reuse) Signed-off-by: Matthias Schwarzott <zzam@gentoo.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
| * media: usb: add SPDX identifiers to some code I wroteMauro Carvalho Chehab2017-12-111-19/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | As we're now using SPDX identifiers, on several media drivers I wrote, add the proper SPDX, identifying the license I meant. As we're now using the short license, it doesn't make sense to keep the original license text. Also, fix MODULE_LICENSE to properly identify GPL v2. Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com> Reviewed-by: Philippe Ombredanne <pombredanne@nexb.com> Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
| * media: cx231xx: Add support for The Imaging Source DFG/USB2proRomain Reignier2017-12-082-0/+29
| | | | | | | | | | | | | | | | Note that the inputs for the Composite and S-Video are inverted in regard to most of the other boards using a cx231xx chip. Signed-off-by: Romain Reignier <r.reignier@robopec.com> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
* | media: annotate ->poll() instancesAl Viro2017-11-272-4/+4
| | | | | | | | Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* | annotate poll_table_struct ->_keyAl Viro2017-11-272-2/+2
|/ | | | | | | Only POLL... bitmaps ever end up there and their only use is checking for POLL... bits in them. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* Merge tag 'media/v4.15-1' of ↵Linus Torvalds2017-11-155-10/+11
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ssh://gitolite.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media Pull media updates from Mauro Carvalho Chehab: - Documentation for digital TV (both kAPI and uAPI) are now in sync with the implementation (except for legacy/deprecated ioctls). This is a major step, as there were always a gap there - New sensor driver: imx274 - New cec driver: cec-gpio - New platform driver for rockship rga and tegra CEC - New RC driver: tango-ir - Several cleanups at atomisp driver - Core improvements for RC, CEC, V4L2 async probing support and DVB - Lots of drivers cleanup, fixes and improvements. * tag 'media/v4.15-1' of ssh://gitolite.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media: (332 commits) dvb_frontend: don't use-after-free the frontend struct media: dib0700: fix invalid dvb_detach argument media: v4l2-ctrls: Don't validate BITMASK twice media: s5p-mfc: fix lockdep warning media: dvb-core: always call invoke_release() in fe_free() media: usb: dvb-usb-v2: dvb_usb_core: remove redundant code in dvb_usb_fe_sleep media: au0828: make const array addr_list static media: cx88: make const arrays default_addr_list and pvr2000_addr_list static media: drxd: make const array fastIncrDecLUT static media: usb: fix spelling mistake: "synchronuously" -> "synchronously" media: ddbridge: fix build warnings media: av7110: avoid 2038 overflow in debug print media: Don't do DMA on stack for firmware upload in the AS102 driver media: v4l: async: fix unregister for implicitly registered sub-device notifiers media: v4l: async: fix return of unitialized variable ret media: imx274: fix missing return assignment from call to imx274_mode_regs media: camss-vfe: always initialize reg at vfe_set_xbar_cfg() media: atomisp: make function calls cleaner media: atomisp: get rid of storage_class.h media: atomisp: get rid of wrong stddef.h include ...
| * media: usb: fix spelling mistake: "synchronuously" -> "synchronously"Colin Ian King2017-11-073-6/+6
| | | | | | | | | | | | | | | | Trivial fix to spelling mistake in error message text [mchehab@s-opensource.org: folded all similar patches into one] Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
| * media: cx231xx: make cx231xx_vbi_qops constBhumika Goyal2017-10-312-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | Make this const as it is only passed to the const argument of the function videobuf_queue_vmalloc_init in the file referencing it. Also, make the declaration in the header const. Structure found using Coccienlle and changes done by hand. Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
| * media: cx231xx: Fix NTSC/PAL on Astrometa T2hybridOleh Kravchenko2017-10-311-0/+1
| | | | | | | | | | | | Signed-off-by: Oleh Kravchenko <oleg@kaa.org.ua> Signed-off-by: Sean Young <sean@mess.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
| * media: cx231xx: Fix NTSC/PAL on Evromedia USB Full Hybrid Full HDOleh Kravchenko2017-10-311-0/+1
| | | | | | | | | | | | Signed-off-by: Oleh Kravchenko <oleg@kaa.org.ua> Signed-off-by: Sean Young <sean@mess.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
| * media: rc: mceusb: add support for 1b80:d3b2Oleh Kravchenko2017-10-311-1/+0
| | | | | | | | | | | | | | | | | | | | Evromedia USB Full Hybrid Full HD (1b80:d3b2) has IR on Interface 0. Remote controller supplied with this tuner fully compatible with RC_MAP_MSI_DIGIVOX_III. Signed-off-by: Oleh Kravchenko <oleg@kaa.org.ua> Signed-off-by: Sean Young <sean@mess.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
| * [media] cx231xx-cards: fix NULL-deref on missing association descriptorJohan Hovold2017-10-041-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Make sure to check that we actually have an Interface Association Descriptor before dereferencing it during probe to avoid dereferencing a NULL-pointer. Fixes: e0d3bafd0258 ("V4L/DVB (10954): Add cx231xx USB driver") Cc: stable <stable@vger.kernel.org> # 2.6.30 Reported-by: Andrey Konovalov <andreyknvl@google.com> Signed-off-by: Johan Hovold <johan@kernel.org> Tested-by: Andrey Konovalov <andreyknvl@google.com> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
* | License cleanup: add SPDX GPL-2.0 license identifier to files with no licenseGreg Kroah-Hartman2017-11-021-0/+1
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Many source files in the tree are missing licensing information, which makes it harder for compliance tools to determine the correct license. By default all files without license information are under the default license of the kernel, which is GPL version 2. Update the files which contain no license information with the 'GPL-2.0' SPDX license identifier. The SPDX identifier is a legally binding shorthand, which can be used instead of the full boiler plate text. This patch is based on work done by Thomas Gleixner and Kate Stewart and Philippe Ombredanne. How this work was done: Patches were generated and checked against linux-4.14-rc6 for a subset of the use cases: - file had no licensing information it it. - file was a */uapi/* one with no licensing information in it, - file was a */uapi/* one with existing licensing information, Further patches will be generated in subsequent months to fix up cases where non-standard license headers were used, and references to license had to be inferred by heuristics based on keywords. The analysis to determine which SPDX License Identifier to be applied to a file was done in a spreadsheet of side by side results from of the output of two independent scanners (ScanCode & Windriver) producing SPDX tag:value files created by Philippe Ombredanne. Philippe prepared the base worksheet, and did an initial spot review of a few 1000 files. The 4.13 kernel was the starting point of the analysis with 60,537 files assessed. Kate Stewart did a file by file comparison of the scanner results in the spreadsheet to determine which SPDX license identifier(s) to be applied to the file. She confirmed any determination that was not immediately clear with lawyers working with the Linux Foundation. Criteria used to select files for SPDX license identifier tagging was: - Files considered eligible had to be source code files. - Make and config files were included as candidates if they contained >5 lines of source - File already had some variant of a license header in it (even if <5 lines). All documentation files were explicitly excluded. The following heuristics were used to determine which SPDX license identifiers to apply. - when both scanners couldn't find any license traces, file was considered to have no license information in it, and the top level COPYING file license applied. For non */uapi/* files that summary was: SPDX license identifier # files ---------------------------------------------------|------- GPL-2.0 11139 and resulted in the first patch in this series. If that file was a */uapi/* path one, it was "GPL-2.0 WITH Linux-syscall-note" otherwise it was "GPL-2.0". Results of that was: SPDX license identifier # files ---------------------------------------------------|------- GPL-2.0 WITH Linux-syscall-note 930 and resulted in the second patch in this series. - if a file had some form of licensing information in it, and was one of the */uapi/* ones, it was denoted with the Linux-syscall-note if any GPL family license was found in the file or had no licensing in it (per prior point). Results summary: SPDX license identifier # files ---------------------------------------------------|------ GPL-2.0 WITH Linux-syscall-note 270 GPL-2.0+ WITH Linux-syscall-note 169 ((GPL-2.0 WITH Linux-syscall-note) OR BSD-2-Clause) 21 ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause) 17 LGPL-2.1+ WITH Linux-syscall-note 15 GPL-1.0+ WITH Linux-syscall-note 14 ((GPL-2.0+ WITH Linux-syscall-note) OR BSD-3-Clause) 5 LGPL-2.0+ WITH Linux-syscall-note 4 LGPL-2.1 WITH Linux-syscall-note 3 ((GPL-2.0 WITH Linux-syscall-note) OR MIT) 3 ((GPL-2.0 WITH Linux-syscall-note) AND MIT) 1 and that resulted in the third patch in this series. - when the two scanners agreed on the detected license(s), that became the concluded license(s). - when there was disagreement between the two scanners (one detected a license but the other didn't, or they both detected different licenses) a manual inspection of the file occurred. - In most cases a manual inspection of the information in the file resulted in a clear resolution of the license that should apply (and which scanner probably needed to revisit its heuristics). - When it was not immediately clear, the license identifier was confirmed with lawyers working with the Linux Foundation. - If there was any question as to the appropriate license identifier, the file was flagged for further research and to be revisited later in time. In total, over 70 hours of logged manual review was done on the spreadsheet to determine the SPDX license identifiers to apply to the source files by Kate, Philippe, Thomas and, in some cases, confirmation by lawyers working with the Linux Foundation. Kate also obtained a third independent scan of the 4.13 code base from FOSSology, and compared selected files where the other two scanners disagreed against that SPDX file, to see if there was new insights. The Windriver scanner is based on an older version of FOSSology in part, so they are related. Thomas did random spot checks in about 500 files from the spreadsheets for the uapi headers and agreed with SPDX license identifier in the files he inspected. For the non-uapi files Thomas did random spot checks in about 15000 files. In initial set of patches against 4.14-rc6, 3 files were found to have copy/paste license identifier errors, and have been fixed to reflect the correct identifier. Additionally Philippe spent 10 hours this week doing a detailed manual inspection and review of the 12,461 patched files from the initial patch version early this week with: - a full scancode scan run, collecting the matched texts, detected license ids and scores - reviewing anything where there was a license detected (about 500+ files) to ensure that the applied SPDX license was correct - reviewing anything where there was no detection but the patch license was not GPL-2.0 WITH Linux-syscall-note to ensure that the applied SPDX license was correct This produced a worksheet with 20 files needing minor correction. This worksheet was then exported into 3 different .csv files for the different types of files to be modified. These .csv files were then reviewed by Greg. Thomas wrote a script to parse the csv files and add the proper SPDX tag to the file, in the format that the file expected. This script was further refined by Greg based on the output to detect more types of files automatically and to distinguish between header and source .c files (which need different comment types.) Finally Greg ran the script using the .csv files to generate the patches. Reviewed-by: Kate Stewart <kstewart@linuxfoundation.org> Reviewed-by: Philippe Ombredanne <pombredanne@nexb.com> Reviewed-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* media: cx231xx: fix use-after-free when unregistering the i2c_client for the ↵Matthias Schwarzott2017-08-271-3/+3
| | | | | | | | | | | | | | | | | | | | | | dvb demod Calling i2c_unregister_device for a demod driver destroys the frontend object. Later it is accessed by calling dvb_unregister_frontend and dvb_frontend_detach. In some cases this leads to a general protection fault with this callstack: dvb_unregister_frontend+0x25/0x50 [dvb_core] dvb_fini+0xdb/0x160 [cx231xx_dvb] cx231xx_unregister_extension+0x3d/0xb0 [cx231xx] cx231xx_dvb_unregister+0x10/0x809 [cx231xx_dvb] SyS_delete_module+0x18a/0x240 ? exit_to_usermode_loop+0x7b/0x80 entry_SYSCALL_64_fastpath+0x17/0x98 Signed-off-by: Matthias Schwarzott <zzam@gentoo.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
* media: usb: make i2c_adapter constBhumika Goyal2017-08-261-1/+1
| | | | | | | | | | Make these const as they are only used in a copy operation. Done using Coccinelle Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Acked-by: Mike Isely <isely@pobox.com> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
OpenPOWER on IntegriCloud