diff options
Diffstat (limited to 'fs/ext4/super.c')
-rw-r--r-- | fs/ext4/super.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/fs/ext4/super.c b/fs/ext4/super.c index 2ede7e2c7019..486a641ca71b 100644 --- a/fs/ext4/super.c +++ b/fs/ext4/super.c | |||
@@ -1321,6 +1321,12 @@ static void ext4_orphan_cleanup (struct super_block * sb, | |||
1321 | return; | 1321 | return; |
1322 | } | 1322 | } |
1323 | 1323 | ||
1324 | if (bdev_read_only(sb->s_bdev)) { | ||
1325 | printk(KERN_ERR "EXT4-fs: write access " | ||
1326 | "unavailable, skipping orphan cleanup.\n"); | ||
1327 | return; | ||
1328 | } | ||
1329 | |||
1324 | if (EXT4_SB(sb)->s_mount_state & EXT4_ERROR_FS) { | 1330 | if (EXT4_SB(sb)->s_mount_state & EXT4_ERROR_FS) { |
1325 | if (es->s_last_orphan) | 1331 | if (es->s_last_orphan) |
1326 | jbd_debug(1, "Errors on filesystem, " | 1332 | jbd_debug(1, "Errors on filesystem, " |