From: Mingming Cao <cmm@us.ibm.com>
To: Solofo.Ramangalahy@bull.net
Cc: linux-ext4@vger.kernel.org, Szabolcs Szakacsits <szaka@ntfs-3g.com>
Subject: Re: [PATCH] ext4: update ctime and mtime for truncate with extents.
Date: Wed, 09 Apr 2008 21:39:57 -0700 [thread overview]
Message-ID: <1207802397.3616.4.camel@localhost.localdomain> (raw)
In-Reply-To: <18425.57003.125097.61814@frecb006361.adech.frec.bull.fr>
On Mon, 2008-04-07 at 10:43 +0200, Solofo.Ramangalahy@bull.net wrote:
> ext4: update ctime and mtime for truncate with extents.
>
> From: Solofo Ramangalahy <Solofo.Ramangalahy@bull.net>
>
> The recently announced "Linux POSIX file system test suite"
> catched a truncate issue when using extents:
> mtime and ctime are not updated when truncate is successful.
>
> This is the single issue catched with "default" ext4 (mkfs and mount
> with minimal options).
> The testsuite does not report failure with -o noextents.
>
> With the following patch, all tests of the testsuite passes.
>
Thanks for the fix.
> Signed-off-by: Solofo Ramangalahy <Solofo.Ramangalahy@bull.net>
>
> ---
> fs/ext4/extents.c | 1 +
> 1 file changed, 1 insertion(+)
>
> Index: linux-2.6.25-rc8-git5-ext4-52c7a8013ad2c452551a68ff4daab4bacbe28f9d/fs/ext4/extents.c
> ===================================================================
> --- linux-2.6.25-rc8-git5-ext4-52c7a8013ad2c452551a68ff4daab4bacbe28f9d.orig/fs/ext4/extents.c
> +++ linux-2.6.25-rc8-git5-ext4-52c7a8013ad2c452551a68ff4daab4bacbe28f9d/fs/ext4/extents.c
> @@ -2947,6 +2947,7 @@ out_stop:
> ext4_orphan_del(handle, inode);
>
> up_write(&EXT4_I(inode)->i_data_sem);
> + inode->i_mtime = inode->i_ctime = ext4_current_time(inode);
Shouldn't we mark inode dirty after the ctime and and mtime is changed?
> ext4_journal_stop(handle);
> }
>
Regards,
Mingming
> --
> To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2008-04-10 4:40 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-04-02 21:47 [ANNOUNCEMENT] Linux POSIX file system test suite (fwd) Szabolcs Szakacsits
2008-04-07 8:43 ` [PATCH] ext4: update ctime and mtime for truncate with extents Solofo.Ramangalahy
2008-04-10 4:39 ` Mingming Cao [this message]
2008-04-10 13:11 ` Solofo.Ramangalahy
2008-04-10 14:14 ` Mingming Cao
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=1207802397.3616.4.camel@localhost.localdomain \
--to=cmm@us.ibm.com \
--cc=Solofo.Ramangalahy@bull.net \
--cc=linux-ext4@vger.kernel.org \
--cc=szaka@ntfs-3g.com \
/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