mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 19:21:31 -04:00
drivers/macintosh/smu.c: fix locking snafu
It got its lock and unlock backwards. Fixes http://bugzilla.kernel.org/show_bug.cgi?id=8334 (obviously, this code could be using plain old spin_lock_irq(), too) Cc: <[email protected]> Cc: Benjamin Herrenschmidt <[email protected]> Cc: Paul Mackerras <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
This commit is contained in:
parent
07a0cfec30
commit
94256dd680
1 changed files with 2 additions and 2 deletions
|
|
@ -1259,9 +1259,9 @@ static int smu_release(struct inode *inode, struct file *file)
|
|||
set_current_state(TASK_UNINTERRUPTIBLE);
|
||||
if (pp->cmd.status != 1)
|
||||
break;
|
||||
spin_lock_irqsave(&pp->lock, flags);
|
||||
schedule();
|
||||
spin_unlock_irqrestore(&pp->lock, flags);
|
||||
schedule();
|
||||
spin_lock_irqsave(&pp->lock, flags);
|
||||
}
|
||||
set_current_state(TASK_RUNNING);
|
||||
remove_wait_queue(&pp->wait, &wait);
|
||||
|
|
|
|||
Loading…
Reference in a new issue