mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Su Yue <Damenly_Su@gmx.com>
To: Kangjie Lu <kjlu@umn.edu>
Cc: pakki001@umn.edu, Chris Mason <clm@fb.com>,
	Josef Bacik <josef@toxicpanda.com>,
	David Sterba <dsterba@suse.com>,
	linux-btrfs@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2] btrfs: add a check for sysfs_create_group
Date: Wed, 26 Dec 2018 13:51:16 +0800	[thread overview]
Message-ID: <a840f129-9626-9b96-be2c-173b3e9371fe@gmx.com> (raw)
In-Reply-To: <20181226053744.74740-1-kjlu@umn.edu>



On 12/26/18 1:37 PM, Kangjie Lu wrote:
> In case sysfs_create_group fails, let's check its return value and
> issues an error message.
> 
> Signed-off-by: Kangjie Lu <kjlu@umn.edu>
> ---
>   fs/btrfs/sysfs.c | 2 ++
>   1 file changed, 2 insertions(+)
> 
> diff --git a/fs/btrfs/sysfs.c b/fs/btrfs/sysfs.c
> index 3717c864ba23..24ef416e700b 100644
> --- a/fs/btrfs/sysfs.c
> +++ b/fs/btrfs/sysfs.c
> @@ -889,6 +889,8 @@ void btrfs_sysfs_feature_update(struct btrfs_fs_info *fs_info,
>   	 */
>   	sysfs_remove_group(fsid_kobj, &btrfs_feature_attr_group);
>   	ret = sysfs_create_group(fsid_kobj, &btrfs_feature_attr_group);
> +	if (ret)
> +		btrfs_err(fs_info, "failed to create btrfs_feature_attr_group.\n");

NIT: ".\n" is unnecessary.

---
Su
>   }
>   
>   static int btrfs_init_debugfs(void)
> 

  parent reply	other threads:[~2018-12-26  5:43 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-12-26  5:37 Kangjie Lu
2018-12-26  5:48 ` Qu Wenruo
2018-12-26  5:51 ` Su Yue [this message]
2019-01-08 15:50 ` David Sterba

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=a840f129-9626-9b96-be2c-173b3e9371fe@gmx.com \
    --to=damenly_su@gmx.com \
    --cc=clm@fb.com \
    --cc=dsterba@suse.com \
    --cc=josef@toxicpanda.com \
    --cc=kjlu@umn.edu \
    --cc=linux-btrfs@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=pakki001@umn.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®