From 78a3c3d7c6b89085610edfe86f7790144afc737e Mon Sep 17 00:00:00 2001 From: Jonathan Corbet Date: Thu, 15 May 2008 16:39:03 -0600 Subject: sound: cdev lock_kernel() pushdown Signed-off-by: Jonathan Corbet --- sound/sound_core.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'sound/sound_core.c') diff --git a/sound/sound_core.c b/sound/sound_core.c index 46daca175502..dcfc1d5ce631 100644 --- a/sound/sound_core.c +++ b/sound/sound_core.c @@ -37,6 +37,7 @@ #include #include #include +#include #include #include #include @@ -464,6 +465,8 @@ int soundcore_open(struct inode *inode, struct file *file) struct sound_unit *s; const struct file_operations *new_fops = NULL; + lock_kernel (); + chain=unit&0x0F; if(chain==4 || chain==5) /* dsp/audio/dsp16 */ { @@ -511,9 +514,11 @@ int soundcore_open(struct inode *inode, struct file *file) file->f_op = fops_get(old_fops); } fops_put(old_fops); + unlock_kernel(); return err; } spin_unlock(&sound_loader_lock); + unlock_kernel(); return -ENODEV; } -- cgit v1.2.3