From: Taesoo Kim <tsgatesv@gmail.com>
To: dushistov@mail.ru, linux-kernel@vger.kernel.org
Cc: taesoo@gatech.edu, changwoo@gatech.edu, sanidhya@gatech.edu,
blee@gatech.edu, csong84@gatech.edu,
Taesoo Kim <tsgatesv@gmail.com>
Subject: [PATCH 1/1] ufs: return correct errno for write_inode()
Date: Fri, 20 Mar 2015 17:47:24 -0400 [thread overview]
Message-ID: <1426888044-30479-1-git-send-email-tsgatesv@gmail.com> (raw)
Instead of -1, properly return -EIO upon write_inode()
error, similar/consistant to the rest of filesystems.
Signed-off-by: Taesoo Kim <tsgatesv@gmail.com>
---
fs/ufs/inode.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/fs/ufs/inode.c b/fs/ufs/inode.c
index be7d42c..9f910d8 100644
--- a/fs/ufs/inode.c
+++ b/fs/ufs/inode.c
@@ -836,13 +836,13 @@ static int ufs_update_inode(struct inode * inode, int do_sync)
if (inode->i_ino < UFS_ROOTINO ||
inode->i_ino > (uspi->s_ncg * uspi->s_ipg)) {
ufs_warning (sb, "ufs_read_inode", "bad inode number (%lu)\n", inode->i_ino);
- return -1;
+ return -EIO;
}
bh = sb_bread(sb, ufs_inotofsba(inode->i_ino));
if (!bh) {
ufs_warning (sb, "ufs_read_inode", "unable to read inode %lu\n", inode->i_ino);
- return -1;
+ return -EIO;
}
if (uspi->fs_magic == UFS2_MAGIC) {
struct ufs2_inode *ufs2_inode = (struct ufs2_inode *)bh->b_data;
--
2.3.3
reply other threads:[~2015-03-20 21:47 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=1426888044-30479-1-git-send-email-tsgatesv@gmail.com \
--to=tsgatesv@gmail.com \
--cc=blee@gatech.edu \
--cc=changwoo@gatech.edu \
--cc=csong84@gatech.edu \
--cc=dushistov@mail.ru \
--cc=linux-kernel@vger.kernel.org \
--cc=sanidhya@gatech.edu \
--cc=taesoo@gatech.edu \
/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
all inboxes | Powered by JetHome®