From: Shaohua Li <shli@kernel.org>
To: Vishal Verma <vishal.l.verma@intel.com>
Cc: linux-nvdimm@lists.01.org, linux-block@vger.kernel.org,
linux-raid@vger.kernel.org, linux-scsi@vger.kernel.org,
Jens Axboe <axboe@fb.com>, NeilBrown <neilb@suse.com>,
Jeff Moyer <jmoyer@redhat.com>
Subject: Re: [PATCH v2 3/3] md: convert to use the generic badblocks code
Date: Tue, 1 Dec 2015 10:55:18 -0800 [thread overview]
Message-ID: <20151201185518.GA13926@kernel.org> (raw)
In-Reply-To: <1448477013-9174-4-git-send-email-vishal.l.verma@intel.com>
On Wed, Nov 25, 2015 at 11:43:33AM -0700, Vishal Verma wrote:
> Retain badblocks as part of rdev, but use the accessor functions from
> include/linux/badblocks for all manipulation.
>
> Signed-off-by: Vishal Verma <vishal.l.verma@intel.com>
> ---
> drivers/md/md.c | 507 +++-----------------------------------------------------
> drivers/md/md.h | 40 +----
> 2 files changed, 23 insertions(+), 524 deletions(-)
>
> diff --git a/drivers/md/md.c b/drivers/md/md.c
> index c702de1..63eab20 100644
> --- a/drivers/md/md.c
> +++ b/drivers/md/md.c
> @@ -34,6 +34,7 @@
>
> #include <linux/kthread.h>
> #include <linux/blkdev.h>
> +#include <linux/badblocks.h>
> #include <linux/sysctl.h>
> #include <linux/seq_file.h>
> #include <linux/fs.h>
> @@ -707,8 +708,7 @@ void md_rdev_clear(struct md_rdev *rdev)
> put_page(rdev->bb_page);
> rdev->bb_page = NULL;
> }
> - kfree(rdev->badblocks.page);
> - rdev->badblocks.page = NULL;
> + badblocks_free(&rdev->badblocks);
> }
why does rdev have extra badblocks? the gendisk already had one.
next prev parent reply other threads:[~2015-12-01 18:55 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-11-25 18:43 [PATCH v2 0/3] Badblock tracking for gendisks Vishal Verma
2015-11-25 18:43 ` [PATCH v2 1/3] badblocks: Add core badblock management code Vishal Verma
2015-12-04 23:30 ` James Bottomley
2015-12-04 23:58 ` Verma, Vishal L
2015-12-05 0:06 ` James Bottomley
2015-12-05 0:11 ` Verma, Vishal L
2015-12-08 21:03 ` NeilBrown
2015-12-08 21:08 ` Verma, Vishal L
2015-12-08 21:18 ` Dan Williams
2015-12-08 23:47 ` Verma, Vishal L
2015-12-22 5:34 ` NeilBrown
2015-12-22 22:13 ` Verma, Vishal L
2015-12-22 23:06 ` NeilBrown
2015-12-23 0:38 ` Verma, Vishal L
2015-11-25 18:43 ` [PATCH v2 2/3] block: Add badblock management for gendisks Vishal Verma
2015-12-04 23:33 ` James Bottomley
2015-12-05 0:17 ` Verma, Vishal L
2015-11-25 18:43 ` [PATCH v2 3/3] md: convert to use the generic badblocks code Vishal Verma
2015-12-01 18:55 ` Shaohua Li [this message]
2015-12-01 19:52 ` Verma, Vishal L
2015-12-04 22:53 ` [PATCH v2 0/3] Badblock tracking for gendisks Verma, Vishal L
-- strict thread matches above, loose matches on Subject: below --
2015-12-08 2:52 Vishal Verma
2015-12-08 2:52 ` [PATCH v2 3/3] md: convert to use the generic badblocks code Vishal Verma
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=20151201185518.GA13926@kernel.org \
--to=shli@kernel.org \
--cc=axboe@fb.com \
--cc=jmoyer@redhat.com \
--cc=linux-block@vger.kernel.org \
--cc=linux-nvdimm@lists.01.org \
--cc=linux-raid@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=neilb@suse.com \
--cc=vishal.l.verma@intel.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;
as well as URLs for NNTP newsgroup(s).