Patchwork [3.5.yuz,extended,stable] Patch "pinctrl: fix missing unlock on error in" has been added to staging queue

mail settings
Submitter Herton Ronaldo Krzesinski
Date Nov. 22, 2012, 4:47 a.m.
Message ID <>
Download mbox | patch
Permalink /patch/200965/
State New
Headers show


Herton Ronaldo Krzesinski - Nov. 22, 2012, 4:47 a.m.
This is a note to let you know that I have just added a patch titled

    pinctrl: fix missing unlock on error in

to the linux-3.5.y-queue branch of the 3.5.yuz extended stable tree 
which can be found at:;a=shortlog;h=refs/heads/linux-3.5.y-queue

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.5.yuz tree, see



From 6de22ad1c6e57d333d45f7bf5ef561d22c366f33 Mon Sep 17 00:00:00 2001
From: Wei Yongjun <>
Date: Mon, 22 Oct 2012 12:58:09 +0800
Subject: [PATCH] pinctrl: fix missing unlock on error in

commit b4dd784ba8af03bf1f9ee5118c792d7abd4919bd upstream.

Add the missing unlock on the error handle path in function

Signed-off-by: Wei Yongjun <>
Signed-off-by: Linus Walleij <>
Signed-off-by: Herton Ronaldo Krzesinski <>
 drivers/pinctrl/core.c |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)



diff --git a/drivers/pinctrl/core.c b/drivers/pinctrl/core.c
index 0cc053a..5e59c45 100644
--- a/drivers/pinctrl/core.c
+++ b/drivers/pinctrl/core.c
@@ -1069,8 +1069,10 @@  static int pinctrl_groups_show(struct seq_file *s, void *what)
 			seq_printf(s, "group: %s\n", gname);
 			for (i = 0; i < num_pins; i++) {
 				pname = pin_get_name(pctldev, pins[i]);
-				if (WARN_ON(!pname))
+				if (WARN_ON(!pname)) {
+					mutex_unlock(&pinctrl_mutex);
 					return -EINVAL;
+				}
 				seq_printf(s, "pin %d (%s)\n", pins[i], pname);
 			seq_puts(s, "\n");