public inbox for cluster-cvs@sourceware.org help / color / mirror / Atom feed
From: Bob Peterson <rpeterso@fedoraproject.org> To: cluster-cvs-relay@redhat.com Subject: cluster: STABLE3 - Write out changes when fixing EA corruption Date: Wed, 29 Apr 2009 21:32:00 -0000 [thread overview] Message-ID: <20090429213233.87324120209@lists.fedorahosted.org> (raw) Gitweb: http://git.fedorahosted.org/git/cluster.git?p=cluster.git;a=commitdiff;h=e793a85a83fb9e6a0ecfce33a1a9883abfe6c177 Commit: e793a85a83fb9e6a0ecfce33a1a9883abfe6c177 Parent: eab924426b6cdd84cb1ac3d2d976d56437c0b3e3 Author: Bob Peterson <rpeterso@redhat.com> AuthorDate: Tue Apr 28 09:37:20 2009 -0500 Committer: Bob Peterson <rpeterso@redhat.com> CommitterDate: Tue Apr 28 15:05:39 2009 -0500 Write out changes when fixing EA corruption bz 495774 The previous patch for bz 495774 failed to actually write the changes to disk. This patch adds that ability. --- gfs/gfs_fsck/metawalk.c | 10 +++++----- gfs/gfs_fsck/pass1.c | 6 ++++++ 2 files changed, 11 insertions(+), 5 deletions(-) diff --git a/gfs/gfs_fsck/metawalk.c b/gfs/gfs_fsck/metawalk.c index b1b1de9..64bd519 100644 --- a/gfs/gfs_fsck/metawalk.c +++ b/gfs/gfs_fsck/metawalk.c @@ -362,6 +362,7 @@ static int check_eattr_entries(struct fsck_inode *ip, osi_buf_t *bh, /* Endianness doesn't matter in this case because it's a single byte. */ + write_buf(sdp, bh, 0); return -1; } log_err("The bad EA was not fixed.\n"); @@ -410,12 +411,11 @@ static int check_leaf_eattr(struct fsck_inode *ip, uint64_t block, relse_buf(ip->i_sbd, bh); return 1; } - } - - check_eattr_entries(ip, bh, pass); + check_eattr_entries(ip, bh, pass); - if (bh) - relse_buf(ip->i_sbd, bh); + if (bh) + relse_buf(ip->i_sbd, bh); + } return 0; } diff --git a/gfs/gfs_fsck/pass1.c b/gfs/gfs_fsck/pass1.c index d5578c9..3768ebf 100644 --- a/gfs/gfs_fsck/pass1.c +++ b/gfs/gfs_fsck/pass1.c @@ -246,6 +246,12 @@ static int clear_eas(struct fsck_inode *ip, struct block_count *bc, return 0; } gfs_dinode_out(&ip->i_di, BH_DATA(dibh)); + if (write_buf(sdp, dibh, 0) < 0) { + stack; + log_crit("Bad EA reference remains.\n"); + } else { + log_warn("Bad EA reference cleared.\n"); + } relse_buf(sdp, dibh); return 1; } else {
reply other threads:[~2009-04-29 21:32 UTC|newest] Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20090429213233.87324120209@lists.fedorahosted.org \ --to=rpeterso@fedoraproject.org \ --cc=cluster-cvs-relay@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: linkBe 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 read-only IMAP folder(s) and NNTP newsgroup(s).