History log of /linux-master/drivers/media/usb/au0828/au0828-cards.c
Revision Date Author Comments
# c942fddf 27-May-2019 Thomas Gleixner <tglx@linutronix.de>

treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 157

Based on 3 normalized pattern(s):

this program is free software you can redistribute it and or modify
it under the terms of the gnu general public license as published by
the free software foundation either version 2 of the license or at
your option any later version this program is distributed in the
hope that it will be useful but without any warranty without even
the implied warranty of merchantability or fitness for a particular
purpose see the gnu general public license for more details

this program is free software you can redistribute it and or modify
it under the terms of the gnu general public license as published by
the free software foundation either version 2 of the license or at
your option any later version [author] [kishon] [vijay] [abraham]
[i] [kishon]@[ti] [com] this program is distributed in the hope that
it will be useful but without any warranty without even the implied
warranty of merchantability or fitness for a particular purpose see
the gnu general public license for more details

this program is free software you can redistribute it and or modify
it under the terms of the gnu general public license as published by
the free software foundation either version 2 of the license or at
your option any later version [author] [graeme] [gregory]
[gg]@[slimlogic] [co] [uk] [author] [kishon] [vijay] [abraham] [i]
[kishon]@[ti] [com] [based] [on] [twl6030]_[usb] [c] [author] [hema]
[hk] [hemahk]@[ti] [com] this program is distributed in the hope
that it will be useful but without any warranty without even the
implied warranty of merchantability or fitness for a particular
purpose see the gnu general public license for more details

extracted by the scancode license scanner the SPDX license identifier

GPL-2.0-or-later

has been chosen to replace the boilerplate/reference in 1105 file(s).

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Allison Randal <allison@lohutok.net>
Reviewed-by: Richard Fontana <rfontana@redhat.com>
Reviewed-by: Kate Stewart <kstewart@linuxfoundation.org>
Cc: linux-spdx@vger.kernel.org
Link: https://lkml.kernel.org/r/20190527070033.202006027@linutronix.de
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>


# 446aba66 03-Mar-2017 Mauro Carvalho Chehab <mchehab@kernel.org>

[media] tveeprom: get rid of unused arg on tveeprom_hauppauge_analog()

tveeprom_hauppauge_analog() used to need the I2C adapter in
order to print debug messages. As it now uses pr_foo() facilities
since commit 6037b3ca28f4 ("[media] tveeprom: print log messages
using pr_foo()"), the first argument of the function is not
needed anymore.

So, get rid of it.

Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>


# bcb63314 28-Oct-2016 Sakari Ailus <sakari.ailus@linux.intel.com>

[media] media: Drop FSF's postal address from the source code files

Drop the FSF's postal address from the source code files that typically
contain mostly the license text. Of the 628 removed instances, 578 are
outdated.

The patch has been created with the following command without manual edits:

git grep -l "675 Mass Ave\|59 Temple Place\|51 Franklin St" -- \
drivers/media/ include/media|while read i; do i=$i perl -e '
open(F,"< $ENV{i}");
$a=join("", <F>);
$a =~ s/[ \t]*\*\n.*You should.*\n.*along with.*\n.*(\n.*USA.*$)?\n//m
&& $a =~ s/(^.*)Or, (point your browser to) /$1To obtain the license, $2\n$1/m;
close(F);
open(F, "> $ENV{i}");
print F $a;
close(F);'; done

Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>


# 2e208c64 11-Mar-2016 Mauro Carvalho Chehab <mchehab@kernel.org>

[media] au0828: disable tuner links and cache tuner/decoder

For au0828_enable_source() to work, the tuner links should be
disabled and the tuner/decoder should be cached at au0828 struct.

While here, put dev->decoder cache together with dev->tuner, as
it makes easier to drop both latter if/when we move the enable
routines to the V4L2 core.

Fixes: 9822f4173f84 ('[media] au0828: use v4l2_mc_create_media_graph()')

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Reviewed-by: Shuah Khan <shuahkh@osg.samsung.com>
Tested-by: Shuah Khan <shuahkh@osg.samsung.com>


# 0158e7b6 18-Jun-2015 Mauro Carvalho Chehab <mchehab@kernel.org>

[media] au0828: Cache the decoder info at au0828 dev structure

Instead of seeking for the decoder every time analog stream is
started, cache it. This simplifies the code a little bit.

Requested-by: Hans Verkuil <hverkuil@xs4all.nl>
Acked-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>


# e42c8c6e 08-Jun-2015 Rafael Lourenço de Lima Chehab <chehabrafael@gmail.com>

[media] au0828: move dev->boards atribuition to happen earlier

The attribution of dev->boards occured too late, which
would couse an OOPS in media controller registration.

Signed-off-by: Rafael Lourenço de Lima Chehab <chehabrafael@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>


# 9bc1022f 12-Jan-2015 Shuah Khan <shuah@kernel.org>

[media] media: fix au0828 compile error from au0828_boards initialization

au0828 picked up UNSET from videobuf-core.h and fails to compile
if videobuf-core.h isn't included. Change it to use -1U instead
to fix the problem.

drivers/media/usb/au0828/au0828-cards.c:47:17: error: ‘UNSET’ undeclared here (not in a function)
.tuner_type = UNSET,

Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
Acked-by: Lad, Prabhakar <prabhakar.csengg@gmail.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>


# 5d1f00a2 30-Oct-2014 Mauro Carvalho Chehab <mchehab@kernel.org>

[media] sound: simplify au0828 quirk table

Add a macro to simplify au0828 quirk table. That makes easier
to check it against the USB IDs at drivers/media/usb/au0828/au0828-cards.c.

Cc: stable@vger.kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>


# 5d400186 18-Aug-2014 Mauro Carvalho Chehab <mchehab@kernel.org>

[media] au0828: fill tuner type on all boards

This is used by the I2C code in order to slow down the
speed to 20 kHz on devices with xc5000 or xc5000c.

So, it needs to be filled for all devices that use either
xc5000 or xc5000c.

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>


# b13b47e0 18-Aug-2014 Mauro Carvalho Chehab <mchehab@kernel.org>

[media] au0828: explicitly identify boards with analog TV

Right now, the au0828 driver uses .tuner to detect if analog
tv is being used or not. By not filling .tuner fields at the
board struct, the I2C core can't do decisions based on it.

So, add a field to explicitly tell when analog TV is supported.

No functional changes.

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>


# 1ba3f927 22-Sep-2014 Mauro Carvalho Chehab <mchehab@kernel.org>

[media] au0828-cards: remove a comment about i2c clock stretching

This comment is already at the au0828-i2c where it belongs.
So, remove it from a board's entry. It doesn't make any sense
there, as we're setting the clock to 250kHz there, slowing it
down only at the au0828-i2c.

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>


# 83afb32a 09-Aug-2014 Mauro Carvalho Chehab <mchehab@kernel.org>

[media] au0828: use pr_foo macros

Instead of using printk(KERN_foo, use pr_foo() macros.

No functional changes.

Note: we should do the same for dprintk(), but that would
require to remove the dprintk levels. So, for now, let's
not touch on it.

Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>


# d84fdc77 07-Aug-2014 Mauro Carvalho Chehab <mchehab@kernel.org>

[media] au0828: Enable IR for HVR-850

HVR-850 also has a remote. Enable it.

Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>


# 2fcfd317 24-Jul-2014 Mauro Carvalho Chehab <mchehab@kernel.org>

[media] au0828: add support for IR on HVR-950Q

HVR-950Q uses an I2C remote controller at address 0x47 (7-bits
notation). Add support for it.

Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>


# cfd0c77d 25-Jul-2014 Mauro Carvalho Chehab <mchehab@kernel.org>

[media] au0828: improve I2C speed

Commits 21dc61d3c0a4 and 7a1dd50b89d4 reduced the board I2C
speed to 20 MHz by default, due to a I2C stretch issue:
while xc5000 uses i2c stretch when a command is sent to it,
au0828 doesn't support this feature.

However, this is needed only for Xceive tuners. The other
I2C devices can work at the max speed.

So, revert the workarounds at board level, handling it at
I2C level, only when talking with xc5000.

Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>


# 7a1dd50b 10-Feb-2014 Joonyoung Shim <jy0922.shim@samsung.com>

[media] au0828: fix i2c clock speed for DViCO FusionHDTV7

DViCO FusionHDTV7 device that use au0828 can fail to communicate with
xc5000 using i2c interface because of high i2c clock speed - i2c clock
stretching bug. It causes to fail xc5000 firmware loading normally at
the current driver.

Already this problem fixed as changing to low i2c clock speed at
HVR-950q device, also DViCO FusionHDTV7 device can solve it as using low
i2c clock speed - 20KHz.

Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>


# a06b429d 19-Aug-2013 Devin Heitmueller <dheitmueller@kernellabs.com>

[media] au0828: rework GPIO management for HVR-950q

Restructure the way we bring the various GPIOs out of reset. In particular:

1. we only need to setup the GPIOs as outputs once
2. there's no point in writing 0x40 to register 0x00 since that's the EEPROM
write protect and already it's configured as an input
3. Separate out the act of enabling the power supply and bringing the tuner
and demod out of reset. If you don't then the chip may not be properly
enabled (as the power supply is still ramping up when the chip comes
out of reset). This can result in probing failures.

Signed-off-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>


# f01e0ffd 23-Oct-2012 Ezequiel Garcia <elezegarcia@gmail.com>

[media] au0828: Replace memcpy with struct assignment

This kind of memcpy() is error-prone. Its replacement with a struct
assignment is prefered because it's type-safe and much easier to read.
Found by coccinelle. Hand patched and reviewed.
Tested by compilation only.
A simplified version of the semantic match that finds this problem is as
follows: (http://coccinelle.lip6.fr/)
// <smpl>
@@
identifier struct_name;
struct struct_name to;
struct struct_name from;
expression E;
@@
-memcpy(&(to), &(from), E);
+to = from;
// </smpl>

Signed-off-by: Peter Senna Tschudin <peter.senna@gmail.com>
Signed-off-by: Ezequiel Garcia <elezegarcia@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>


# 5b7d8de7 03-Dec-2012 Michael Krufky <mkrufky@linuxtv.org>

[media] au0828: break au0828_card_setup() down into smaller functions

Pull the analog frontend setup code out of au0828_card_setup into its
own seperate function, au0828_card_analog_fe_setup().

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>


# 8a4e7866 04-Dec-2012 Michael Krufky <mkrufky@linuxtv.org>

[media] au0828: remove forced dependency of VIDEO_AU0828 on VIDEO_V4L2

This patch removes the dependendency of VIDEO_AU0828 on VIDEO_V4L2 by
creating a new Kconfig option, VIDEO_AU0828_V4L2, which enables analog
video capture support and depends on VIDEO_V4L2 itself.
With VIDEO_AU0828_V4L2 disabled, the driver will only support digital
television and will not depend on the v4l2-core. With VIDEO_AU0828_V4L2
enabled, the driver will be built with the analog v4l2 support included.
By default, the VIDEO_AU0828_V4L2 option will be set to Y, so as to
preserve the original behavior.

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>


# c70ffd59 28-Nov-2012 Michael Krufky <mkrufky@linuxtv.org>

[media] au0828: update model matrix entries for 72261, 72271 & 72281

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>


# ffc80988 27-Nov-2012 Michael Krufky <mkrufky@linuxtv.org>

[media] au0828: add missing model 72281, usb id 2040:7270 to the model matrix

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>


# a094ca46 27-Oct-2012 Mauro Carvalho Chehab <mchehab@kernel.org>

[media] au0828: get rid of warning: no previous prototype

drivers/media/usb/au0828/au0828-cards.c:28:6: warning: no previous prototype for 'hvr950q_cs5340_audio' [-Wmissing-prototypes]
drivers/media/usb/au0828/au0828-video.c:161:6: warning: no previous prototype for 'au0828_uninit_isoc' [-Wmissing-prototypes]
drivers/media/usb/au0828/au0828-video.c:200:5: warning: no previous prototype for 'au0828_init_isoc' [-Wmissing-prototypes]
drivers/media/usb/au0828/au0828-video.c:786:5: warning: no previous prototype for 'au0828_analog_stream_enable' [-Wmissing-prototypes]
drivers/media/usb/au0828/au0828-video.c:813:6: warning: no previous prototype for 'au0828_analog_stream_reset' [-Wmissing-prototypes]
drivers/media/usb/au0828/au0828-video.c:916:6: warning: no previous prototype for 'au0828_vid_buffer_timeout' [-Wmissing-prototypes]
drivers/media/usb/au0828/au0828-video.c:940:6: warning: no previous prototype for 'au0828_vbi_buffer_timeout' [-Wmissing-prototypes]

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>


# 0c0d06ca 13-Aug-2012 Mauro Carvalho Chehab <mchehab@kernel.org>

[media] rename most media/video usb drivers to media/usb

Rename all USB drivers with their own directory under
drivers/media/video into drivers/media/usb and update the
building system.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>