public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: "Matias Bjørling" <mb@lightnvm.io>
To: Chao Yu <chao2.yu@samsung.com>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH] lightnvm: fix incorrect nr_free_blocks stat
Date: Mon, 14 Dec 2015 12:42:15 +0100	[thread overview]
Message-ID: <566EAB17.8010200@lightnvm.io> (raw)
In-Reply-To: <006401d13659$8f89ff70$ae9dfe50$@samsung.com>

On 12/14/2015 11:23 AM, Chao Yu wrote:
> When initing bad block list in gennvm_block_bb, once we move bad block
> from free_list to bb_list, we should maintain both stat info
> nr_free_blocks and nr_bad_blocks. So this patch fixes to add missing
> operation related to nr_free_blocks.
>
> Signed-off-by: Chao Yu <chao2.yu@samsung.com>
> ---
>   drivers/lightnvm/gennvm.c | 1 +
>   1 file changed, 1 insertion(+)
>
> diff --git a/drivers/lightnvm/gennvm.c b/drivers/lightnvm/gennvm.c
> index 35dde84..6b504a2 100644
> --- a/drivers/lightnvm/gennvm.c
> +++ b/drivers/lightnvm/gennvm.c
> @@ -89,6 +89,7 @@ static int gennvm_block_bb(struct ppa_addr ppa, int nr_blocks, u8 *blks,
>
>   		list_move_tail(&blk->list, &lun->bb_list);
>   		lun->vlun.nr_bad_blocks++;
> +		lun->vlun.nr_free_blocks--;
>   	}
>
>   	return 0;
>
Thanks Yu, Applied.

      reply	other threads:[~2015-12-14 11:42 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-12-14 10:23 [PATCH] lightnvm: fix incorrect nr_free_blocks stat Chao Yu
2015-12-14 11:42 ` Matias Bjørling [this message]

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=566EAB17.8010200@lightnvm.io \
    --to=mb@lightnvm.io \
    --cc=chao2.yu@samsung.com \
    --cc=linux-kernel@vger.kernel.org \
    /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