Skip to content

Commit

Permalink
Merge tag 'hwspinlock-3.5-fixes' of git://git.kernel.org/pub/scm/linu…
Browse files Browse the repository at this point in the history
…x/kernel/git/ohad/hwspinlock

Pull hwspinlock fix from Ohad Ben-Cohen:
 "A single hwspinlock core fix for multiple hwspinlock devices
  scenarios, from Shinya Kuribayashi."

* tag 'hwspinlock-3.5-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/ohad/hwspinlock:
  hwspinlock/core: use global ID to register hwspinlocks on multiple devices
  • Loading branch information
Linus Torvalds committed Jul 9, 2012
2 parents 17fae1c + 476a7ee commit 17cda20
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/hwspinlock/hwspinlock_core.c
Original file line number Diff line number Diff line change
Expand Up @@ -345,7 +345,7 @@ int hwspin_lock_register(struct hwspinlock_device *bank, struct device *dev,
spin_lock_init(&hwlock->lock);
hwlock->bank = bank;

ret = hwspin_lock_register_single(hwlock, i);
ret = hwspin_lock_register_single(hwlock, base_id + i);
if (ret)
goto reg_failed;
}
Expand All @@ -354,7 +354,7 @@ int hwspin_lock_register(struct hwspinlock_device *bank, struct device *dev,

reg_failed:
while (--i >= 0)
hwspin_lock_unregister_single(i);
hwspin_lock_unregister_single(base_id + i);
return ret;
}
EXPORT_SYMBOL_GPL(hwspin_lock_register);
Expand Down

0 comments on commit 17cda20

Please sign in to comment.