summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorAkinbou Mita <akinobu.mita@gmail.com>2007-03-26 23:43:10 +0200
committerAdrian Bunk <bunk@stusta.de>2007-03-26 23:43:10 +0200
commit25c72f37099c2f32e8e6c7311735e7a3a036b178 (patch)
tree35199d69df0a212df4e8a466ca5af073c9cac869 /drivers
parent36c8a3d3ac8b0157ea4ebc54926d40309787a865 (diff)
downloadlwn-25c72f37099c2f32e8e6c7311735e7a3a036b178.tar.gz
lwn-25c72f37099c2f32e8e6c7311735e7a3a036b178.zip
md: fix /proc/mdstat refcounting
I have seen mdadm oops after successfully unloading md module. This patch privents from unloading md module while mdadm is polling /proc/mdstat. Signed-off-by: Akinbou Mita <akinobu.mita@gmail.com> Signed-off-by: Adrian Bunk <bunk@stusta.de>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/md/md.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/md/md.c b/drivers/md/md.c
index 0471ebff482f..1b1fae8b58b6 100644
--- a/drivers/md/md.c
+++ b/drivers/md/md.c
@@ -4325,6 +4325,7 @@ static unsigned int mdstat_poll(struct file *filp, poll_table *wait)
}
static struct file_operations md_seq_fops = {
+ .owner = THIS_MODULE,
.open = md_seq_open,
.read = seq_read,
.llseek = seq_lseek,