[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20111005055326.GA32187@elgon.mountain>
Date: Wed, 5 Oct 2011 08:53:26 +0300
From: Dan Carpenter <dan.carpenter@...cle.com>
To: Nathan Fontenot <nfont@...tin.ibm.com>
Cc: linux-kernel@...r.kernel.org, Greg Kroah-Hartman <gregkh@...e.de>,
kernel-janitors@...r.kernel.org
Subject: [patch] memory hotplug: release lock on an error path
We need to release the mutex here before returning.
Signed-off-by: Dan Carpenter <dan.carpenter@...cle.com>
diff --git a/drivers/base/memory.c b/drivers/base/memory.c
index ca8bfe5..164c8a2 100644
--- a/drivers/base/memory.c
+++ b/drivers/base/memory.c
@@ -299,7 +299,7 @@ static int memory_block_change_state(struct memory_block *mem,
for (i = 0; i < sections_per_block; i++) {
ret = check_page_reservations(mem->start_section_nr + i);
if (ret)
- return ret;
+ goto out;
}
}
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists