From a616cc171f7f614fe825a2fb69208e4078d4ed2a Mon Sep 17 00:00:00 2001 From: Arnd Bergmann Date: Tue, 20 May 2008 19:16:54 +0200 Subject: [PATCH] --- yaml --- r: 100388 b: refs/heads/master c: 78dccb46ddc2ff460c8b4d5ec0886964bd4b59e5 h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/arch/um/drivers/harddog_kern.c | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/[refs] b/[refs] index 363e9617e59e..c9aa0d704237 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 8702965848ed4bee27486a3e3d2ae34ebba6dd83 +refs/heads/master: 78dccb46ddc2ff460c8b4d5ec0886964bd4b59e5 diff --git a/trunk/arch/um/drivers/harddog_kern.c b/trunk/arch/um/drivers/harddog_kern.c index a9ad4bd6d953..d332503fa1be 100644 --- a/trunk/arch/um/drivers/harddog_kern.c +++ b/trunk/arch/um/drivers/harddog_kern.c @@ -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; }