Linux ocfs2 filesystem development
 help / color / mirror / Atom feed
From: jiangyiwen <jiangyiwen@huawei.com>
To: ocfs2-devel@oss.oracle.com
Subject: [Ocfs2-devel] [PATCH] ocfs2: do not set filesystem readonly if link down
Date: Tue, 18 Nov 2014 14:57:45 +0800	[thread overview]
Message-ID: <546AEDE9.90304@huawei.com> (raw)

Do not set filesystem readonly if storage link down.
In this case, metadata is not corrupted and only -EIO is returned.
And if it is indeed a corrputed meatadata, it has already called
ocfs2_error in ocfs2_validate_inode_block.

Signed-off-by: Yiwen Jiang <jiangyiwen@huawei.com>
---
 aops.c | 2 +-
 dir.c  | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/aops.c b/aops.c
index 1ef547e..d9f2229 100644
--- a/aops.c
+++ b/aops.c
@@ -1251,7 +1251,7 @@ static int ocfs2_write_cluster(struct address_space *mapping,
 	ret = ocfs2_extent_map_get_blocks(inode, v_blkno, &p_blkno, NULL,
 					  NULL);
 	if (ret < 0) {
-		ocfs2_error(inode->i_sb, "Corrupting extend for inode %llu, "
+		mlog(ML_ERROR, "Get physical blkno failed for inode %llu, "
 			    "at logical block %llu",
 			    (unsigned long long)OCFS2_I(inode)->ip_blkno,
 			    (unsigned long long)v_blkno);
diff --git a/dir.c b/dir.c
index 0717662..e6dc028 100644
--- a/dir.c
+++ b/dir.c
@@ -744,7 +744,7 @@ restart:
 		if (ocfs2_read_dir_block(dir, block, &bh, 0)) {
 			/* read error, skip block & hope for the best.
 			 * ocfs2_read_dir_block() has released the bh. */
-			ocfs2_error(dir->i_sb, "reading directory %llu, "
+			mlog(ML_ERROR, "reading directory %llu, "
 				    "offset %lu\n",
 				    (unsigned long long)OCFS2_I(dir)->ip_blkno,
 				    block);
-- 
1.8.3.4

                 reply	other threads:[~2014-11-18  6:57 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=546AEDE9.90304@huawei.com \
    --to=jiangyiwen@huawei.com \
    --cc=ocfs2-devel@oss.oracle.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