[3.16.y-ckt stable] Patch "rbd: fix error return code in rbd_dev_device_setup()" has been added to staging queue
Luis Henriques
luis.henriques at canonical.com
Mon Nov 17 14:32:17 UTC 2014
This is a note to let you know that I have just added a patch titled
rbd: fix error return code in rbd_dev_device_setup()
to the linux-3.16.y-queue branch of the 3.16.y-ckt extended stable tree
which can be found at:
http://kernel.ubuntu.com/git?p=ubuntu/linux.git;a=shortlog;h=refs/heads/linux-3.16.y-queue
This patch is scheduled to be released in version 3.16.7-ckt2.
If you, or anyone else, feels it should not be added to this tree, please
reply to this email.
For more information about the 3.16.y-ckt tree, see
https://wiki.ubuntu.com/Kernel/Dev/ExtendedStable
Thanks.
-Luis
------
>From 0a62c31b440cd95358cc7c2490b78ac2453835ec Mon Sep 17 00:00:00 2001
From: Wei Yongjun <yongjun_wei at trendmicro.com.cn>
Date: Wed, 13 Aug 2014 20:49:52 -0700
Subject: rbd: fix error return code in rbd_dev_device_setup()
commit 255939e783d8f45f8c58487dfc18957c44ea9871 upstream.
Fix to return -ENOMEM from the workqueue alloc error handling
case instead of 0, as done elsewhere in this function.
Reviewed-by: Alex Elder <elder at linaro.org>
Signed-off-by: Wei Yongjun <yongjun_wei at trendmicro.com.cn>
Cc: Ilya Dryomov <ilya.dryomov at inktank.com>
Signed-off-by: Luis Henriques <luis.henriques at canonical.com>
---
drivers/block/rbd.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/block/rbd.c b/drivers/block/rbd.c
index 453afd257530..5c38fe1f4b85 100644
--- a/drivers/block/rbd.c
+++ b/drivers/block/rbd.c
@@ -5104,8 +5104,10 @@ static int rbd_dev_device_setup(struct rbd_device *rbd_dev)
set_disk_ro(rbd_dev->disk, rbd_dev->mapping.read_only);
rbd_dev->rq_wq = alloc_workqueue("%s", 0, 0, rbd_dev->disk->disk_name);
- if (!rbd_dev->rq_wq)
+ if (!rbd_dev->rq_wq) {
+ ret = -ENOMEM;
goto err_out_mapping;
+ }
ret = rbd_bus_add_dev(rbd_dev);
if (ret)
--
2.1.0
More information about the kernel-team
mailing list