diff options
author | Jonathan Corbet <corbet@lwn.net> | 2008-06-19 17:44:57 -0400 |
---|---|---|
committer | Jonathan Corbet <corbet@lwn.net> | 2008-07-02 17:06:27 -0400 |
commit | 743115ee05f09f356d86763316acf627a7f5a6b3 (patch) | |
tree | fbcf31862c77065d982dadf80b4c666aa0083aac /drivers/message/i2o | |
parent | b7e3e1fbf69d1b6abfd337460ea17d7230e3a6e5 (diff) |
i2o: fasync BKL pushdown
This driver appears to really need the BKL to protect open_files.
Signed-off-by: Jonathan Corbet <corbet@lwn.net>
Diffstat (limited to 'drivers/message/i2o')
-rw-r--r-- | drivers/message/i2o/i2o_config.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/drivers/message/i2o/i2o_config.c b/drivers/message/i2o/i2o_config.c index 95b4c108585c..4238de98d4a6 100644 --- a/drivers/message/i2o/i2o_config.c +++ b/drivers/message/i2o/i2o_config.c | |||
@@ -1084,15 +1084,17 @@ static int cfg_fasync(int fd, struct file *fp, int on) | |||
1084 | { | 1084 | { |
1085 | ulong id = (ulong) fp->private_data; | 1085 | ulong id = (ulong) fp->private_data; |
1086 | struct i2o_cfg_info *p; | 1086 | struct i2o_cfg_info *p; |
1087 | int ret = -EBADF; | ||
1087 | 1088 | ||
1089 | lock_kernel(); | ||
1088 | for (p = open_files; p; p = p->next) | 1090 | for (p = open_files; p; p = p->next) |
1089 | if (p->q_id == id) | 1091 | if (p->q_id == id) |
1090 | break; | 1092 | break; |
1091 | 1093 | ||
1092 | if (!p) | 1094 | if (p) |
1093 | return -EBADF; | 1095 | ret = fasync_helper(fd, fp, on, &p->fasync); |
1094 | 1096 | unlock_kernel(); | |
1095 | return fasync_helper(fd, fp, on, &p->fasync); | 1097 | return ret; |
1096 | } | 1098 | } |
1097 | 1099 | ||
1098 | static int cfg_release(struct inode *inode, struct file *file) | 1100 | static int cfg_release(struct inode *inode, struct file *file) |