All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jeff Liu <jeff.liu@oracle.com>
To: jaegeuk@kernel.org, cm224.lee@samsung.com
Cc: linux-f2fs-devel@lists.sourceforge.net
Subject: [PATCH 21/24] f2fs: return actual error on init_f2fs_fs
Date: Tue, 17 Jun 2014 22:32:48 +0800	[thread overview]
Message-ID: <53A05190.60600@oracle.com> (raw)

From: Jie Liu <jeff.liu@oracle.com>

Return the actual error code if kset_create_and_add() failed

Cc: Jaegeuk Kim <jaegeuk@kernel.org>
Cc: Changman Lee <cm224.lee@samsung.com>
Signed-off-by: Jie Liu <jeff.liu@oracle.com>
---
 fs/f2fs/super.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/fs/f2fs/super.c b/fs/f2fs/super.c
index b2b1863..74470cb 100644
--- a/fs/f2fs/super.c
+++ b/fs/f2fs/super.c
@@ -1175,8 +1175,8 @@ static int __init init_f2fs_fs(void)
 	if (err)
 		goto free_gc_caches;
 	f2fs_kset = kset_create_and_add("f2fs", NULL, fs_kobj);
-	if (!f2fs_kset) {
-		err = -ENOMEM;
+	if (IS_ERR(f2fs_kset)) {
+		err = PTR_ERR(f2fs_kset);
 		goto free_checkpoint_caches;
 	}
 	err = register_filesystem(&f2fs_fs_type);
-- 
1.8.3.2

------------------------------------------------------------------------------
HPCC Systems Open Source Big Data Platform from LexisNexis Risk Solutions
Find What Matters Most in Your Big Data with HPCC Systems
Open Source. Fast. Scalable. Simple. Ideal for Dirty Data.
Leverages Graph Analysis for Fast Processing & Easy Data Exploration
http://p.sf.net/sfu/hpccsystems

             reply	other threads:[~2014-06-17 14:34 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-06-17 14:32 Jeff Liu [this message]
2014-06-18  1:50 ` [PATCH 21/24] f2fs: return actual error on init_f2fs_fs Jeff Liu

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=53A05190.60600@oracle.com \
    --to=jeff.liu@oracle.com \
    --cc=cm224.lee@samsung.com \
    --cc=jaegeuk@kernel.org \
    --cc=linux-f2fs-devel@lists.sourceforge.net \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.