Skip to contentSkip to conversation

Patch "lightnvm: put bio before return" has been added to the 4.4-stable tree

PATCH [email protected] 1 participant 1 message Sep 20, 2016 Stable branch

lore
Share & tools
lore

[email protected]

author maintainer Applied
#0 lore raw

This is a note to let you know that I've just added the patch titled

lightnvm: put bio before return

to the 4.4-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
lightnvm-put-bio-before-return.patch
and it can be found in the queue-4.4 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.

Quoted 1 line

From 16c6d048d7b74249a4387700887e8adb13028866 Mon Sep 17 00:00:00 2001

From: Wenwei Tao <[email protected]>
Date: Thu, 4 Feb 2016 15:13:23 +0100
Subject: lightnvm: put bio before return
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

From: Wenwei Tao <[email protected]>

commit 16c6d048d7b74249a4387700887e8adb13028866 upstream.

The bio is not returned if the data page cannot be allocated.

---
 drivers/lightnvm/rrpc.c |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/lightnvm/rrpc.c +3 -1
@@ -287,8 +287,10 @@ static int rrpc_move_valid_pages(struct
 	}
 
 	page = mempool_alloc(rrpc->page_pool, GFP_NOIO);
-	if (!page)
+	if (!page) {
+		bio_put(bio);
 		return -ENOMEM;
+	}
 
 	while ((slot = find_first_zero_bit(rblk->invalid_pages,
 					    nr_pgs_per_blk)) < nr_pgs_per_blk) {

Patches currently in stable-queue which might be from [email protected] are

queue-4.4/lightnvm-put-bio-before-return.patch