提交 78dccb46 编写于 作者: A Arnd Bergmann 提交者: Jonathan Corbet

uml-harddog: BKL pushdown

Signed-off-by: NArnd Bergmann <arnd@arndb.de>
上级 87029658
......@@ -66,6 +66,7 @@ static int harddog_open(struct inode *inode, struct file *file)
int err = -EBUSY;
char *sock = NULL;
lock_kernel();
spin_lock(&lock);
if(timer_alive)
goto err;
......@@ -82,9 +83,11 @@ static int harddog_open(struct inode *inode, struct file *file)
timer_alive = 1;
spin_unlock(&lock);
unlock_kernel();
return nonseekable_open(inode, file);
err:
spin_unlock(&lock);
unlock_kernel();
return err;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册