mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-27 19:29:37 +00:00
i2o: fasync BKL pushdown
This driver appears to really need the BKL to protect open_files. Signed-off-by: Jonathan Corbet <corbet@lwn.net>
This commit is contained in:
parent
b7e3e1fbf6
commit
743115ee05
1 changed files with 6 additions and 4 deletions
|
@ -1084,15 +1084,17 @@ static int cfg_fasync(int fd, struct file *fp, int on)
|
|||
{
|
||||
ulong id = (ulong) fp->private_data;
|
||||
struct i2o_cfg_info *p;
|
||||
int ret = -EBADF;
|
||||
|
||||
lock_kernel();
|
||||
for (p = open_files; p; p = p->next)
|
||||
if (p->q_id == id)
|
||||
break;
|
||||
|
||||
if (!p)
|
||||
return -EBADF;
|
||||
|
||||
return fasync_helper(fd, fp, on, &p->fasync);
|
||||
if (p)
|
||||
ret = fasync_helper(fd, fp, on, &p->fasync);
|
||||
unlock_kernel();
|
||||
return ret;
|
||||
}
|
||||
|
||||
static int cfg_release(struct inode *inode, struct file *file)
|
||||
|
|
Loading…
Reference in a new issue