Commit 78dccb46 authored by Arnd Bergmann's avatar Arnd Bergmann Committed by Jonathan Corbet

uml-harddog: BKL pushdown

Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
parent 87029658
...@@ -66,6 +66,7 @@ static int harddog_open(struct inode *inode, struct file *file) ...@@ -66,6 +66,7 @@ static int harddog_open(struct inode *inode, struct file *file)
int err = -EBUSY; int err = -EBUSY;
char *sock = NULL; char *sock = NULL;
lock_kernel();
spin_lock(&lock); spin_lock(&lock);
if(timer_alive) if(timer_alive)
goto err; goto err;
...@@ -82,9 +83,11 @@ static int harddog_open(struct inode *inode, struct file *file) ...@@ -82,9 +83,11 @@ static int harddog_open(struct inode *inode, struct file *file)
timer_alive = 1; timer_alive = 1;
spin_unlock(&lock); spin_unlock(&lock);
unlock_kernel();
return nonseekable_open(inode, file); return nonseekable_open(inode, file);
err: err:
spin_unlock(&lock); spin_unlock(&lock);
unlock_kernel();
return err; return err;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment