Commit Graph

493 Commits

Author SHA1 Message Date
Tim Gardner 740a3ea20d [media] pvrusb2: Declare MODULE_FIRMWARE usage
Signed-off-by: Tim Gardner <tim.gardner@canonical.com>
Acked-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2012-07-31 00:12:20 -03:00
Hans Verkuil 4a085168b5 [media] v4l2-ioctl: remove v4l_(i2c_)print_ioctl
v4l_i2c_print_ioctl wasn't used and v4l_print_ioctl could be replaced by
v4l_printk_ioctl.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2012-07-06 17:26:46 -03:00
Mauro Carvalho Chehab 8cfd9dccf2 [media] media: Remove VIDEO_MEDIA Kconfig option
In the past, it was possible to have either DVB or V4L2 core
as module and the other as builtin. Such config never make much
sense, and created several issues in order to make the Kconfig
dependency to work, as all drivers that depend on both (most
TV drivers) would need to be compiled as 'm'. Due to that,
the VIDEO_MEDIA config option were added.

Instead of such weird approach, let's just use the MEDIA_SUPPORT
=y or =m to select if the media subsystem core will be either
builtin or module, simplifying the building system logic.

Also, fix the tuners configuration, by enabling them only if
a tuner is required. So, if just webcam/grabbers support is
selected, no tuner option will be selected. Also, if only digital
TV is selected, no analog tuner support is selected.

That removes the need of using EXPERT customise options, when
analog TV is not selected.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2012-07-05 18:21:53 -03:00
Peter Senna Tschudin 503d194956 [media] pvrusb2: Variables set but not used
Tested by compilation only.

Signed-off-by: Peter Senna Tschudin <peter.senna@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2012-06-21 17:07:08 -03:00
Mike Isely aeebb1b314 [media] pvrusb2: For querystd, start with list of hardware-supported standards
The V4L querystd implementation appears to want to narrow down the
list of available standards by starting with a hardware-supported list
and then attempting to detect which among those are actually
available.  Prior to this change in the pvrusb2 driver we started with
all possible standards.  With this change in place we instead narrow
to just the standards that we know the hardware can actually support.
For example, this removes the ATSC standards from the list if we
aren't dealing with a hybrid device...

Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2012-05-07 16:58:00 -03:00
Mike Isely c0bb609fdc [media] pvrusb2: Get rid of obsolete code for video standard enumeration
Get rid of pvrusb2-local implementation for enumeration of video
standards - with video_ioctl2 this happens automatically now in the
v4l core.

Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2012-05-07 16:57:05 -03:00
Mike Isely 598e978aad [media] pvrusb2: Trivial tweak to get rid of some redundant dereferences
Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2012-05-07 16:56:31 -03:00
Mike Isely d8329f8e17 [media] pvrusb2: Base available video standards on what hardware supports
With the transition to ioctl2, the pvrusb2 driver's own standards
enumeration is no longer used.  Instead a generic algorithm internal
to v4l is used (which is a great idea - since the pvrusb2
implementation itself was generic anyway).  This change ensures that
the v4l algorithm works with the correct set of hardware supported
standards.  This resolves a FIXME left behind from the videodev_ioctl2
transition.

Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2012-05-07 16:56:10 -03:00
Mike Isely 99ba1514ae [media][trival] pvrusb2: Fix truncated video standard names
Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2012-05-07 16:55:05 -03:00
Mike Isely ac04d00ed1 [media] pvrusb2: Transform video standard detection result into read-only control ID
Other aspects of the pvrusb2 driver - including in particular those
dealing with video standards - all use internal control IDs for
uniform access by the interfaces.  By exporting the querystd result as
another control ID, uniform access to it becomes available through the
sysfs interface.

Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2012-05-07 16:54:15 -03:00
Mike Isely 0927ee67dd [media] pvrusb2: Implement querystd for videodev_ioctl2
Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2012-05-07 16:53:23 -03:00
Mike Isely 7378c18421 [media] pvrusb2: Clean up pvr2_hdw_get_detected_std()
Move full implementation of pvr2_hdw_get_detected_std() actually
include pvr2_hdw_get_detected_std().

Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2012-05-07 16:50:27 -03:00
Hans Verkuil c6d26cfe26 [media] pvrusb2: convert to video_ioctl2
Note: there is one FIXME remaining: the tvnorms field of struct
video_device should be set up correctly. I have used V4L2_STD_ALL for
now, but I'm sure this can be improved. This field is used by
video_ioctl2 to implement ENUMSTD.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2012-05-07 16:49:09 -03:00
Mike Isely 5f1a12f5d0 [media] pvrusb2: Stop statically initializing reserved struct fields to zero
In any statically initialized data structure, the compiler is going to
zero any part which is not already explicitly initialized.  While we
can take that knowledge overboard and simply avoid initializing
anything that needs to be zero, it's at least a good idea not to
bother zeroing parts that we don't otherwise care about - like
"reserved" fields which may change in the future.  Avoiding
initialization of those fields now also avoids possible conflict down
the road.

Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2012-05-07 16:48:19 -03:00
Michael Krufky 9ab2393fc3 [media] pvrusb2: fix 7MHz & 8MHz DVB-T tuner support for HVR1900 rev D1F5
The D1F5 revision of the WinTV HVR-1900 uses a tda18271c2 tuner
instead of a tda18271c1 tuner as used in revision D1E9. To
account for this, we must hardcode the frontend configuration
to use the same IF frequency configuration for both revisions
of the device.

6MHz DVB-T is unaffected by this issue, as the recommended
IF Frequency configuration for 6MHz DVB-T is the same on both
c1 and c2 revisions of the tda18271 tuner.

Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Cc: Mike Isely <isely@pobox.com>
Cc: stable@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2012-03-19 22:26:01 -03:00
Hans Verkuil 583aa3a9b5 [media] V4L2: Add per-device-node capabilities
If V4L2_CAP_DEVICE_CAPS is set, then the new device_caps field is filled with
the capabilities of the opened device node.

The capabilities field traditionally contains the capabilities of the physical
device, being a superset of all capabilities available at the several device
nodes. E.g., if you open /dev/video0, then if it contains VBI caps then that means
that there is a corresponding vbi node as well. And the capabilities field of
both the video and vbi nodes should contain identical caps.

However, it would be very useful to also have a capabilities field that contains
just the caps for the currently open device, hence the new CAP bit and field.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2012-01-23 16:34:27 -02:00
Thomas Meyer e79c70e6e5 [media] pvrusb2: Use kcalloc instead of kzalloc to allocate array
The advantage of kcalloc is, that will prevent integer overflows which could
result from the multiplication of number of elements and size and it is also
a bit nicer to read.

The semantic patch that makes this change is available
in https://lkml.org/lkml/2011/11/25/107

Signed-off-by: Thomas Meyer <thomas@m3y3r.de>
Acked-By: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-12-12 14:51:11 -02:00
Linus Torvalds 32aaeffbd4 Merge branch 'modsplit-Oct31_2011' of git://git.kernel.org/pub/scm/linux/kernel/git/paulg/linux
* 'modsplit-Oct31_2011' of git://git.kernel.org/pub/scm/linux/kernel/git/paulg/linux: (230 commits)
  Revert "tracing: Include module.h in define_trace.h"
  irq: don't put module.h into irq.h for tracking irqgen modules.
  bluetooth: macroize two small inlines to avoid module.h
  ip_vs.h: fix implicit use of module_get/module_put from module.h
  nf_conntrack.h: fix up fallout from implicit moduleparam.h presence
  include: replace linux/module.h with "struct module" wherever possible
  include: convert various register fcns to macros to avoid include chaining
  crypto.h: remove unused crypto_tfm_alg_modname() inline
  uwb.h: fix implicit use of asm/page.h for PAGE_SIZE
  pm_runtime.h: explicitly requires notifier.h
  linux/dmaengine.h: fix implicit use of bitmap.h and asm/page.h
  miscdevice.h: fix up implicit use of lists and types
  stop_machine.h: fix implicit use of smp.h for smp_processor_id
  of: fix implicit use of errno.h in include/linux/of.h
  of_platform.h: delete needless include <linux/module.h>
  acpi: remove module.h include from platform/aclinux.h
  miscdevice.h: delete unnecessary inclusion of module.h
  device_cgroup.h: delete needless include <linux/module.h>
  net: sch_generic remove redundant use of <linux/module.h>
  net: inet_timewait_sock doesnt need <linux/module.h>
  ...

Fix up trivial conflicts (other header files, and  removal of the ab3550 mfd driver) in
 - drivers/media/dvb/frontends/dibx000_common.c
 - drivers/media/video/{mt9m111.c,ov6650.c}
 - drivers/mfd/ab3550-core.c
 - include/linux/dmaengine.h
2011-11-06 19:44:47 -08:00
Paul Gortmaker 7a707b8920 drivers/media: Add module.h to all files using it implicitly
A pending cleanup will mean that module.h won't be implicitly
everywhere anymore.  Make sure the modular drivers in clocksource
are actually calling out for <module.h> explicitly in advance.

Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
2011-10-31 19:31:51 -04:00
Mauro Carvalho Chehab a5abdb6044 [media] pvrusb2: initialize standards mask before detecting standard
Acked-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-10-08 08:00:54 -03:00
Mauro Carvalho Chehab 7383a47395 [media] pvrusb2: implement VIDIOC_QUERYSTD
Acked-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-10-08 08:00:26 -03:00
Arnaud Lacombe 3f5c14d3d3 [media] drivers/media: do not use EXTRA_CFLAGS
Usage of these flags has been deprecated for nearly 4 years by:

    commit f77bf01425
    Author: Sam Ravnborg <sam@neptun.(none)>
    Date:   Mon Oct 15 22:25:06 2007 +0200

        kbuild: introduce ccflags-y, asflags-y and ldflags-y

Moreover, these flags (at least EXTRA_CFLAGS) have been documented for command
line use. By default, gmake(1) do not override command line setting, so this is
likely to result in build failure or unexpected behavior.

Replace their usage by Kbuild's `{as,cc,ld}flags-y'.

Cc: Sam Ravnborg <sam@ravnborg.org>
Cc: Mauro Carvalho Chehab <mchehab@infradead.org>
Cc: linux-media@vger.kernel.org
Signed-off-by: Arnaud Lacombe <lacombar@gmail.com>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-09-03 18:50:59 -03:00
Mauro Carvalho Chehab 7a286cc188 [media] return -ENOTTY for unsupported ioctl's at legacy drivers
Those drivers are not relying at the V4L2 core to handle the ioctl's.
So, we need to manually patch them every time a change goes to the
core.

Acked-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-By: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-07-27 17:53:38 -03:00
Mauro Carvalho Chehab 083774d8b1 [media] pvrusb2: Use LINUX_VERSION_CODE for VIDIOC_QUERYCAP
pvrusb2 doesn't use vidioc_ioctl2. As the API is changing to use
a common version for all drivers, we need to expliticly fix this
driver.

Acked-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-07-27 17:53:15 -03:00
Hans Verkuil 50e9efd60b [media] pvrusb2: fix g/s_tuner support
The tuner-core subdev requires that the type field of v4l2_tuner is
filled in correctly. This is done in v4l2-ioctl.c, but pvrusb2 doesn't
use that yet, so we have to do it manually based on whether the current
input is radio or not.

Tested with my pvrusb2.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Mike Isely <isely@pobox.com>
Cc: stable@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-07-07 15:02:40 -03:00
Dan Carpenter 92f6ed71ca [media] pvrusb2: delete generic_standards_cnt
The generic_standards_cnt define is only used in one place and it's
more readable to just call ARRAY_SIZE(generic_standards) directly.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-05-20 09:28:25 -03:00
Dan Carpenter 0cff593732 [media] pvrusb2: check for allocation failures
This function returns NULL on failure so lets do that if kzalloc()
fails.  There is a separate problem that the caller for this function
doesn't check for errors...

Signed-off-by: Dan Carpenter <error27@gmail.com>
Acked-By: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-05-20 09:28:24 -03:00
Lucas De Marchi 25985edced Fix common misspellings
Fixes generated by 'codespell' and manually reviewed.

Signed-off-by: Lucas De Marchi <lucas.demarchi@profusion.mobi>
2011-03-31 11:26:23 -03:00
Mauro Carvalho Chehab af86ce79f0 [media] remove the old RC_MAP_HAUPPAUGE_NEW RC map
The rc-hauppauge-new map is a messy thing, as it bundles 3

different remote controllers as if they were just one,
discarding the address byte. Also, some key maps are wrong.

With the conversion to the new rc-core, it is likely that
most of the devices won't be working properly, as the i2c
driver and the raw decoders are now providing 16 bits for
the remote, instead of just 8.

 delete mode 100644 drivers/media/rc/keymaps/rc-hauppauge-new.c

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Jarod Wilson <jarod@redhat.com>
2011-03-22 19:24:16 -03:00
Xiaochen Wang c05df8b32a [media] pvrusb2: check kmalloc return value
allows the driver to proceed and initialize the below two values
 even if the kmalloc() fails.
        hdw->std_info_enum.def.type_enum.value_names
        hdw->std_info_enum.def.type_enum.count

Signed-off-by: Xiaochen Wang <wangxiaochen0@gmail.com>
Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-03-22 04:54:37 -03:00
Mike Isely 228ee5928b [media] pvrusb2: Remove dead code
This was caught via a compiler warning.  Amazingly enough this bit of
benign dreck dates all the way back to 2008.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-03-22 04:54:36 -03:00
Mike Isely 43823c0224 [media] pvrusb2: Implement support for Terratec Grabster AV400
Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-03-22 04:54:35 -03:00
Mike Isely 19a0a296f2 [media] pvrusb2: Use sysfs_attr_init() where appropriate
Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-03-21 20:32:22 -03:00
Mike Isely 058caa8784 [media] pvrusb2: Minor VBI tweak to help potential CC support
pvrusb2: Declare closed-caption setup for line 21 - this is needed for
sliced VBI capture support.  (However none of that works right now
anyway.)

Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-03-21 20:32:22 -03:00
Servaas Vandenberghe 6188a0f151 [media] pvrusb2: width and height maximum values
pvrusb2: The origin of the capability bounds rectangle may differ from
(left=0,top=0) so the calculation should use absolute coordinates,
here below, or use relative coordinates like
cropl_val-cap->bounds.left and cropt_val-cap->bounds.top.

Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-03-21 20:32:22 -03:00
Mike Isely 35fa5d4c48 [media] pvrusb2: Fix a few missing default control values, for cropping
Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-03-21 20:32:22 -03:00
Mike Isely 4cfe3319a1 [media] pvrusb2: Minor cosmetic code tweak
Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-03-21 20:32:21 -03:00
Mike Isely 9bf98321b4 [media] pvrusb2: Handle change of mode before handling change of video standard
pvrusb2: Recognize and handle mode change before dealing with changes
related to the video standard.  Even though the video standard should
only matter when in analog mode, doing this way is technically cleaner
in case there's other stuff that might depend on both.

Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-03-21 20:32:21 -03:00
Jarod Wilson 8df59918b5 [media] ir-kbd-i2c: improve remote behavior with z8 behind usb
Add the same "are you ready?" i2c_master_send() poll command to
get_key_haup_xvr found in lirc_zilog, which is apparently seen in
the Windows driver for the PVR-150 w/a z8. This stabilizes what is
received from both the HD-PVR and HVR-1950, even with their polling
intervals at the default of 100, thus the removal of the custom
260ms polling_interval in pvrusb2-i2c-core.c.

Acked-by: Andy Walls <awalls@md.metrocast.net>
Acked-by: Mike Isely <isely@isely.net>
Signed-off-by: Jarod Wilson <jarod@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-01-31 12:19:15 -02:00
Andy Walls 4999e27a62 [media] pvrusb2: Provide more information about IR units to lirc_zilog and ir-kbd-i2c
When registering an IR Rx device with the I2C subsystem, provide more detailed
information about the IR device and default remote configuration for the IR
driver modules.

Also explicitly register any IR Tx device with the I2C subsystem.

Signed-off-by: Andy Walls <awalls@md.metrocast.net>
Acked-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2011-01-19 11:46:13 -02:00
Hans Verkuil 513521eaee [media] v4l2-ctrls: use const char * const * for the menu arrays
This prevents checkpatch warnings generated when defining
'static const char *foo[]' arrays. It makes sense to use
const char * const * anyway since the pointers in the array
are indeed const.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2010-12-30 08:02:14 -02:00
Vasiliy Kulikov a519d70e0c [media] media: video: pvrusb2: fix memory leak
Use put_device() instead of kfree() because of device name leak.

Signed-off-by: Vasiliy Kulikov <segoon@openwall.com>
Acked-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2010-12-29 08:17:18 -02:00
Hans Verkuil 08af245de0 [media] V4L: remove V4L1 compatibility mode
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2010-12-29 08:17:07 -02:00
Laurent Pinchart 9a1f8b34aa [media] v4l: Remove module_name argument to the v4l2_i2c_new_subdev* functions
The argument isn't used anymore by the functions, remove it.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2010-11-22 11:56:26 -02:00
Laurent Pinchart d4c0312363 [media] pvrusb2: Don't use module names to load I2C modules
With the v4l2_i2c_new_subdev* functions now supporting loading modules
based on modaliases, replace the hardcoded module name passed to those
functions by NULL.

All corresponding I2C modules have been checked, and all of them include
a module aliases table with names corresponding to what the pvrusb2
driver uses.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Acked-By: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2010-10-22 21:53:15 -02:00
Dan Carpenter d5337966ce V4L/DVB: pvrusb2: remove unneeded NULL checks
We dereference "maskptr" unconditionally at the start of the function
and also inside the call to parse_tlist() towards the end of the
function.  This function is called from store_val_any() and it always
passes a non-NULL pointer.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Acked-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2010-09-27 22:21:48 -03:00
Andy Shevchenko e03b9843dc V4L/DVB: media: video: pvrusb2: remove custom hex_to_bin()
Signed-off-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Acked-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2010-08-08 23:43:06 -03:00
Julia Lawall 4c61f678a4 V4L/DVB: drivers/media/video/pvrusb2: Add missing mutex_unlock
Add a mutex_unlock missing on the error path.  In the other functions in
the same file the locks and unlocks of this mutex appear to be balanced,
so it would seem that the same should hold in this case.

The semantic match that finds this problem is as follows:
(http://coccinelle.lip6.fr/)

// <smpl>
@@
expression E1;
@@

* mutex_lock(E1,...);
  <+... when != E1
  if (...) {
    ... when != E1
*   return ...;
  }
  ...+>
* mutex_unlock(E1,...);
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Douglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2010-08-02 15:01:02 -03:00
Hans Verkuil fa190ee91f V4L/DVB: pvrusb2: convert to s_mbus_fmt
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2010-06-01 01:21:27 -03:00
Mike Isely e3a5ee73e7 V4L/DVB: pvrusb2: Fix kernel oops on device tear-down
pvrusb2: Delete sysfs class device as the _very_ last step, after
we're sure that all driver contexts have gone away first.  This is
important because it appears that there isn't any protection from a
struct device instance reference a deleted struct class instance.  The
assumption in the kernel code appears to be that the class instance is
assumed to be around for the life of the device.  So we can't let the
class instance go away until all referencing device instances are
gone; this is ensured by delaying removal of the class instance until
after the driver contexts have all gone away.  This bug has been
present for a very long time but it didn't apparently become malignant
until recently (probably because of other changes in the kernel).

Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
2010-06-01 01:19:58 -03:00