cluster-devel.redhat.com archive mirror
 help / color / mirror / Atom feed
From: Steven Whitehouse <swhiteho@redhat.com>
To: cluster-devel.redhat.com
Subject: [Cluster-devel] [GFS2 Patch] GFS2: O_TRUNC not working on stuffed files across cluster
Date: Fri, 25 Jun 2010 10:54:18 +0100	[thread overview]
Message-ID: <1277459658.2507.5.camel@localhost> (raw)
In-Reply-To: <956990027.894591277421309643.JavaMail.root@zmail06.collab.prod.int.phx2.redhat.com>

Hi,

Now in the -nmw tree. Thanks,

Steve.

On Thu, 2010-06-24 at 19:15 -0400, Bob Peterson wrote:
> Hi,
> 
> This patch replaces a statement that got dropped out by accident.
> Without the patch, truncates on stuffed (very small) files cause
> those files to have an unpredictable size.
> 
> Regards,
> 
> Bob Peterson
> Red Hat File Systems
> 
> 
> Signed-off-by: Bob Peterson <rpeterso@redhat.com>
> --
>  fs/gfs2/bmap.c |    1 +
>  1 files changed, 1 insertions(+), 0 deletions(-)
> 
> diff --git a/fs/gfs2/bmap.c b/fs/gfs2/bmap.c
> index 0db0cd9..a7b1c7c 100644
> --- a/fs/gfs2/bmap.c
> +++ b/fs/gfs2/bmap.c
> @@ -1042,6 +1042,7 @@ static int trunc_start(struct gfs2_inode *ip, u64 size)
>  
>  	if (gfs2_is_stuffed(ip)) {
>  		u64 dsize = size + sizeof(struct gfs2_inode);
> +		ip->i_disksize = size;
>  		ip->i_inode.i_mtime = ip->i_inode.i_ctime = CURRENT_TIME;
>  		gfs2_trans_add_bh(ip->i_gl, dibh, 1);
>  		gfs2_dinode_out(ip, dibh->b_data);




      reply	other threads:[~2010-06-25  9:54 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-06-24 23:15 [Cluster-devel] [GFS2 Patch] GFS2: O_TRUNC not working on stuffed files across cluster Bob Peterson
2010-06-25  9:54 ` Steven Whitehouse [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=1277459658.2507.5.camel@localhost \
    --to=swhiteho@redhat.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;
as well as URLs for NNTP newsgroup(s).