summaryrefslogtreecommitdiffstats
path: root/fs/ocfs2/super.c
diff options
context:
space:
mode:
authorTiger Yang <tiger.yang@oracle.com>2011-05-27 18:34:19 +0200
committerJoel Becker <jlbec@evilplan.org>2011-06-01 04:03:44 +0200
commit03efed8a2a1b8e00164eb4720a82a7dd5e368a8e (patch)
treeefe713ba18680a1ccedecfbff2d81d83f048fdb0 /fs/ocfs2/super.c
parentMerge git://git.kernel.org/pub/scm/linux/kernel/git/rusty/linux-2.6-for-linus (diff)
downloadlinux-03efed8a2a1b8e00164eb4720a82a7dd5e368a8e.tar.xz
linux-03efed8a2a1b8e00164eb4720a82a7dd5e368a8e.zip
ocfs2: Bugfix for hard readonly mount
ocfs2 cannot currently mount a device that is readonly at the media ("hard readonly"). Fix the broken places. see detail: http://oss.oracle.com/bugzilla/show_bug.cgi?id=1322 [ Description edited -- Joel ] Signed-off-by: Tiger Yang <tiger.yang@oracle.com> Reviewed-by: Sunil Mushran <sunil.mushran@oracle.com> Signed-off-by: Joel Becker <jlbec@evilplan.org>
Diffstat (limited to 'fs/ocfs2/super.c')
-rw-r--r--fs/ocfs2/super.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/ocfs2/super.c b/fs/ocfs2/super.c
index cdbaf5e97308..029c4cd8a691 100644
--- a/fs/ocfs2/super.c
+++ b/fs/ocfs2/super.c
@@ -1974,7 +1974,8 @@ static void ocfs2_dismount_volume(struct super_block *sb, int mnt_err)
* If we failed before we got a uuid_str yet, we can't stop
* heartbeat. Otherwise, do it.
*/
- if (!mnt_err && !ocfs2_mount_local(osb) && osb->uuid_str)
+ if (!mnt_err && !ocfs2_mount_local(osb) && osb->uuid_str &&
+ !ocfs2_is_hard_readonly(osb))
hangup_needed = 1;
if (osb->cconn)