]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commit
V4L/DVB: drivers/media/video/pvrusb2: Add missing mutex_unlock
authorJulia Lawall <julia@diku.dk>
Tue, 29 Jun 2010 04:42:53 +0000 (01:42 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Mon, 2 Aug 2010 18:01:02 +0000 (15:01 -0300)
commit4c61f678a468768afd45c3d9ac697f8f55aa04eb
treef8888ca8a6098dfb051c8ef1d684d879b12ebfb7
parenta3b1dc95578fd0b524139689a9e0f148a622eb24
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>
drivers/media/video/pvrusb2/pvrusb2-ioread.c