Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1350417 > unrolled thread

[PATCH] null_blk: add lightnvm null_blk device to the nullb_list

Started byWenwei Tao <ww.tao0320@gmail.com>
First post2016-03-04 17:30 +0100
Last post2016-03-04 17:40 +0100
Articles 2 — 2 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH] null_blk: add lightnvm null_blk device to the nullb_list Wenwei Tao <ww.tao0320@gmail.com> - 2016-03-04 17:30 +0100
    Re: [PATCH] null_blk: add lightnvm null_blk device to the nullb_list Jens Axboe <axboe@fb.com> - 2016-03-04 17:40 +0100

#1350417 — [PATCH] null_blk: add lightnvm null_blk device to the nullb_list

FromWenwei Tao <ww.tao0320@gmail.com>
Date2016-03-04 17:30 +0100
Subject[PATCH] null_blk: add lightnvm null_blk device to the nullb_list
Message-ID<r90M3-Y1-45@gated-at.bofh.it>
After register null_blk devices into lightnvm, we forget
to add these devices to the the nullb_list, makes them
invisible to the null_blk driver.

Signed-off-by: Wenwei Tao <ww.tao0320@gmail.com>
---
 drivers/block/null_blk.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/block/null_blk.c b/drivers/block/null_blk.c
index 64a7b59..cab9759 100644
--- a/drivers/block/null_blk.c
+++ b/drivers/block/null_blk.c
@@ -742,10 +742,11 @@ static int null_add_dev(void)
 
 	add_disk(disk);
 
+done:
 	mutex_lock(&lock);
 	list_add_tail(&nullb->list, &nullb_list);
 	mutex_unlock(&lock);
-done:
+
 	return 0;
 
 out_cleanup_lightnvm:
-- 
1.8.3.1

[toc] | [next] | [standalone]


#1350432

FromJens Axboe <axboe@fb.com>
Date2016-03-04 17:40 +0100
Message-ID<r90VH-14h-1@gated-at.bofh.it>
In reply to#1350417
On 03/04/2016 09:27 AM, Wenwei Tao wrote:
> After register null_blk devices into lightnvm, we forget
> to add these devices to the the nullb_list, makes them
> invisible to the null_blk driver.
>
> Signed-off-by: Wenwei Tao <ww.tao0320@gmail.com>
> ---
>   drivers/block/null_blk.c | 3 ++-
>   1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/block/null_blk.c b/drivers/block/null_blk.c
> index 64a7b59..cab9759 100644
> --- a/drivers/block/null_blk.c
> +++ b/drivers/block/null_blk.c
> @@ -742,10 +742,11 @@ static int null_add_dev(void)
>
>   	add_disk(disk);
>
> +done:
>   	mutex_lock(&lock);
>   	list_add_tail(&nullb->list, &nullb_list);
>   	mutex_unlock(&lock);
> -done:
> +
>   	return 0;
>
>   out_cleanup_lightnvm:

Thanks, that looks like a regression caused by a514379b0c77, I'll add a 
Fixes tag.

-- 
Jens Axboe

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web