On Thu 08-04-10 22:04:23, Dmitry Monakhov wrote: > Orphan cleanup procedure is complex task and may fail due to number > of reasons. Handle errors from orphan_cleanp according to > predefined per-sb errors behavior flags. > > Signed-off-by: Dmitry Monakhov <dmonakhov@xxxxxxxxxx> > --- > fs/ext3/super.c | 29 ++++++++++++++++++++--------- > 1 files changed, 20 insertions(+), 9 deletions(-) > > diff --git a/fs/ext3/super.c b/fs/ext3/super.c > index e844acc..72d979a 100644 > --- a/fs/ext3/super.c > +++ b/fs/ext3/super.c > @@ -1460,11 +1461,14 @@ static void ext3_orphan_cleanup (struct super_block * sb, > /* Turn on quotas so that they are updated correctly */ > for (i = 0; i < MAXQUOTAS; i++) { > if (EXT3_SB(sb)->s_qf_names[i]) { > - int ret = ext3_quota_on_mount(sb, i); > - if (ret < 0) > + ret = ext3_quota_on_mount(sb, i); > + if (ret < 0) { > ext3_msg(sb, KERN_ERR, > "error: cannot turn on journaled " > "quota: %d", ret); > + if (!test_opt (sb, ERRORS_CONT)) > + goto out; > + } I see two consistent approaches: a) consider the filesystem is mounted and use ext3_handle_error() b) consider this a part of mounting procedure and return error and fail the mount. I would prefer b) but if you have some good arguments for a)... > } > } > #endif ... > @@ -1507,6 +1511,9 @@ static void ext3_orphan_cleanup (struct super_block * sb, > if (nr_truncates) > ext3_msg(sb, KERN_INFO, "%d truncate%s cleaned up", > PLURAL(nr_truncates)); > + if (ret) > + ext3_msg(sb, KERN_ERR, "Error %d wile orphan cleanup", ret); ^^^ while Honza -- Jan Kara <jack@xxxxxxx> SUSE Labs, CR -- To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html