diff options
author | Shaohua Li <shli@fb.com> | 2017-08-28 13:49:31 -0700 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2017-08-28 15:06:17 -0600 |
commit | 060fd198a3e113047da456f15889579067e6b75f (patch) | |
tree | d8f30e5d2a57291b8e62071cbbd0cc5df0c3aebd | |
parent | e9a823fb34a8b0fcba6e112aa1003258a1a5af50 (diff) | |
download | linux-060fd198a3e113047da456f15889579067e6b75f.tar.bz2 |
block/nullb: delete unnecessary memory free
Commit 2984c86(nullb: factor disk parameters) has a typo. The
nullb_device allocation/free is done outside of null_add_dev. The commit
accidentally frees the nullb_device in error code path.
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Shaohua Li <shli@fb.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
-rw-r--r-- | drivers/block/null_blk.c | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/drivers/block/null_blk.c b/drivers/block/null_blk.c index 647213525549..3b5cabe374d2 100644 --- a/drivers/block/null_blk.c +++ b/drivers/block/null_blk.c @@ -1909,7 +1909,6 @@ out_cleanup_queues: out_free_nullb: kfree(nullb); out: - null_free_dev(dev); return rv; } |