Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f5a3ea6f authored by David Woodhouse's avatar David Woodhouse Committed by David S. Miller
Browse files

libertas: use spin_is_locked() instead of spin_trylock() in lbs_interrupt()



We get scary warnings on UP if we use spin_trylock() and find, as we
hoped, that the lock in question is already locked.

Signed-off-by: default avatarDavid Woodhouse <dwmw2@infradead.org>
Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
parent 86062134
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -1414,8 +1414,7 @@ void lbs_interrupt(struct lbs_private *priv)

	lbs_deb_thread("lbs_interrupt: intcounter=%d\n", priv->intcounter);

	if (spin_trylock(&priv->driver_lock)) {
		spin_unlock(&priv->driver_lock);
	if (!spin_is_locked(&priv->driver_lock)) {
		printk(KERN_CRIT "%s called without driver_lock held\n", __func__);
		WARN_ON(1);
	}