ipmi: fasync BKL pushdown
This driver really needs it to avoid races against open() Signed-off-by: Jonathan Corbet <corbet@lwn.net>
This commit is contained in:
@@ -101,7 +101,9 @@ static int ipmi_fasync(int fd, struct file *file, int on)
|
|||||||
struct ipmi_file_private *priv = file->private_data;
|
struct ipmi_file_private *priv = file->private_data;
|
||||||
int result;
|
int result;
|
||||||
|
|
||||||
|
lock_kernel(); /* could race against open() otherwise */
|
||||||
result = fasync_helper(fd, file, on, &priv->fasync_queue);
|
result = fasync_helper(fd, file, on, &priv->fasync_queue);
|
||||||
|
unlock_kernel();
|
||||||
|
|
||||||
return (result);
|
return (result);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user