summaryrefslogtreecommitdiffstats
path: root/arch/parisc
diff options
context:
space:
mode:
authorArnd Bergmann <arnd@arndb.de>2008-05-20 19:16:31 +0200
committerJonathan Corbet <corbet@lwn.net>2008-07-02 15:06:24 -0600
commitb691750098f830b748540cd955f5ac56545bab25 (patch)
treea45a75a55bd508fe72f2479d2f0e3dcf1b7782f8 /arch/parisc
parent6044c319d11051f3462dafd0e7a900ef121d7bc7 (diff)
downloadop-kernel-dev-b691750098f830b748540cd955f5ac56545bab25.zip
op-kernel-dev-b691750098f830b748540cd955f5ac56545bab25.tar.gz
parisc-kernel-perf: BKL pushdown
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Diffstat (limited to 'arch/parisc')
-rw-r--r--arch/parisc/kernel/perf.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/arch/parisc/kernel/perf.c b/arch/parisc/kernel/perf.c
index 89d6d5a..f696f57 100644
--- a/arch/parisc/kernel/perf.c
+++ b/arch/parisc/kernel/perf.c
@@ -46,6 +46,7 @@
#include <linux/init.h>
#include <linux/proc_fs.h>
#include <linux/miscdevice.h>
+#include <linux/smp_lock.h>
#include <linux/spinlock.h>
#include <asm/uaccess.h>
@@ -260,13 +261,16 @@ printk("Preparing to start counters\n");
*/
static int perf_open(struct inode *inode, struct file *file)
{
+ lock_kernel();
spin_lock(&perf_lock);
if (perf_enabled) {
spin_unlock(&perf_lock);
+ unlock_kernel();
return -EBUSY;
}
perf_enabled = 1;
spin_unlock(&perf_lock);
+ unlock_kernel();
return 0;
}
OpenPOWER on IntegriCloud