From: jes.sorensen@gmail.com
To: Song Liu <songliubraving@fb.com>
Cc: linux-raid@vger.kernel.org, shli@fb.com, neilb@suse.com,
kernel-team@fb.com, dan.j.williams@intel.com, hch@infradead.org
Subject: Re: [PATCH v3] mdadm/r5cache: allow adding journal to array without journal
Date: Tue, 28 Mar 2017 13:52:57 -0400 [thread overview]
Message-ID: <wrfjpoh1gufa.fsf@gmail.com> (raw)
In-Reply-To: <20170317233111.2452831-2-songliubraving@fb.com> (Song Liu's message of "Fri, 17 Mar 2017 16:31:11 -0700")
Song Liu <songliubraving@fb.com> writes:
> Currently, --add-journal can be only used to recreate broken journal
> for arrays with journal since creation. As the kernel code getting
> more mature, this constraint is no longer necessary.
>
> This patch allows --add-journal to add journal to array without
> journal.
>
> Signed-off-by: Song Liu <songliubraving@fb.com>
> ---
> Manage.c | 9 ---------
> mdadm.8.in | 5 ++---
> 2 files changed, 2 insertions(+), 12 deletions(-)
>
> diff --git a/Manage.c b/Manage.c
> index 5c3d2b9..d038b68 100644
> --- a/Manage.c
> +++ b/Manage.c
> @@ -946,7 +946,6 @@ int Manage_add(int fd, int tfd, struct mddev_dev *dv,
>
> /* only add journal to array that supports journaling */
> if (dv->disposition == 'j') {
> - struct mdinfo mdi;
> struct mdinfo *mdp;
>
> mdp = sysfs_read(fd, NULL, GET_ARRAY_STATE);
> @@ -960,14 +959,6 @@ int Manage_add(int fd, int tfd, struct mddev_dev *dv,
> pr_err("%s is not readonly, cannot add journal.\n", devname);
> return -1;
> }
> -
> - sysfs_free(mdp);
> -
Song,
Sorry for nagging you again on this one, however removing
sysfs_free(mdp) means you are leaking mbp here.
Cheers,
Jes
next prev parent reply other threads:[~2017-03-28 17:52 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-17 23:31 [PATCH v3] mdadm: change in add-journal support Song Liu
2017-03-17 23:31 ` [PATCH v3] mdadm/r5cache: allow adding journal to array without journal Song Liu
2017-03-28 17:52 ` jes.sorensen [this message]
2017-03-28 18:05 ` Song 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=wrfjpoh1gufa.fsf@gmail.com \
--to=jes.sorensen@gmail.com \
--cc=dan.j.williams@intel.com \
--cc=hch@infradead.org \
--cc=kernel-team@fb.com \
--cc=linux-raid@vger.kernel.org \
--cc=neilb@suse.com \
--cc=shli@fb.com \
--cc=songliubraving@fb.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