Staging: vme: bridges: Add missing unlocks
authorJulia Lawall <julia@diku.dk>
Wed, 26 May 2010 15:59:11 +0000 (17:59 +0200)
committerGreg Kroah-Hartman <gregkh@suse.de>
Fri, 18 Jun 2010 22:16:21 +0000 (15:16 -0700)
commit7c0ace54887872ebd99fefdfe85d273295a09426
tree2464f7f639986bff887d795ca3b5e5787f8ad43b
parent45f9f018967c3fc112a03a99a8fdfad3621407a7
Staging: vme: bridges: Add missing unlocks

Add a spin_unlock and mutex_unlock missing on the error path.

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

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

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

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Martyn Welch <martyn.welch@ge.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/vme/bridges/vme_ca91cx42.c