From: Theodore Ts'o <tytso@mit.edu>
To: "Darrick J. Wong" <darrick.wong@oracle.com>
Cc: Ext4 Developers List <linux-ext4@vger.kernel.org>,
Dan Jacobson <jidanni@jidanni.org>
Subject: Re: [PATCH] e2fsck: flush out the superblock and bitmaps before printing final messages
Date: Mon, 11 Aug 2014 13:27:39 -0400 [thread overview]
Message-ID: <20140811172739.GD6553@thunk.org> (raw)
In-Reply-To: <20140811170935.GC2808@birch.djwong.org>
On Mon, Aug 11, 2014 at 10:09:35AM -0700, Darrick J. Wong wrote:
>
> Looking at the strace output, it looks like a bunch of pwrite/write calls are
> returning -EBADF when it tries to write the group descriptors to a O_RDONLY
> file descriptor.
>
> The call to ext2fs_flush() needs to be guarded by a "if (fs->flags &
> EXT2_FLAG_DIRTY)" because ext2fs_flush() unconditionally writes out the group
> descriptors. We don't want to do that unless the FS is actually dirty, and we
> certainly don't want to do that for a RO check.
Oops, I had forgotten that we didn't have such a check inside
ext2fs_flush().
Thanks for catching this!
- Ted
prev parent reply other threads:[~2014-08-11 17:27 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-08-10 21:33 [PATCH] e2fsck: flush out the superblock and bitmaps before printing final messages Theodore Ts'o
2014-08-11 17:09 ` Darrick J. Wong
2014-08-11 17:27 ` Theodore Ts'o [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20140811172739.GD6553@thunk.org \
--to=tytso@mit.edu \
--cc=darrick.wong@oracle.com \
--cc=jidanni@jidanni.org \
--cc=linux-ext4@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).