All of lore.kernel.org
 help / color / mirror / Atom feed
From: Aaro Koskinen <aaro.koskinen@iki.fi>
To: Tomi Valkeinen <tomi.valkeinen@ti.com>,
	linux-omap@vger.kernel.org, linux-fbdev@vger.kernel.org
Cc: Eduardo Valentin <eduardo.valentin@ti.com>,
	Aaro Koskinen <aaro.koskinen@iki.fi>,
	stable@vger.kernel.org
Subject: [PATCH] ARM: OMAPFB: panel-sony-acx565akm: fix bad unlock balance
Date: Wed, 06 Nov 2013 21:24:30 +0000	[thread overview]
Message-ID: <1383773070-15114-1-git-send-email-aaro.koskinen@iki.fi> (raw)

When booting Nokia N900 smartphone with v3.12 + omap2plus_defconfig
(LOCKDEP enabled) and CONFIG_DISPLAY_PANEL_SONY_ACX565AKM enabled,
the following BUG is seen during the boot:

[    7.302154] ==================[    7.307128] [ BUG: bad unlock balance detected! ]
[    7.312103] 3.12.0-los.git-2093492-00120-g5e01dc7 #3 Not tainted
[    7.318450] -------------------------------------
[    7.323425] kworker/u2:1/12 is trying to release lock (&ddata->mutex) at:
[    7.330657] [<c031b760>] acx565akm_enable+0x12c/0x18c
[    7.335998] but there are no more locks to release!

Fix by removing the extra mutex_unlock().

Reported-by: Eduardo Valentin <eduardo.valentin@ti.com>
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Cc: stable@vger.kernel.org
---
 drivers/video/omap2/displays-new/panel-sony-acx565akm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/video/omap2/displays-new/panel-sony-acx565akm.c b/drivers/video/omap2/displays-new/panel-sony-acx565akm.c
index e6d56f7..72fe2a8 100644
--- a/drivers/video/omap2/displays-new/panel-sony-acx565akm.c
+++ b/drivers/video/omap2/displays-new/panel-sony-acx565akm.c
@@ -616,7 +616,7 @@ static int acx565akm_enable(struct omap_dss_device *dssdev)
 
 	mutex_lock(&ddata->mutex);
 	r = acx565akm_panel_power_on(dssdev);
-	mutex_unlock(&ddata->mutex);
+	/* NOTE: acx565akm_panel_power_on() will unlock the mutex. */
 
 	if (r)
 		return r;
-- 
1.8.4.2


WARNING: multiple messages have this Message-ID (diff)
From: Aaro Koskinen <aaro.koskinen@iki.fi>
To: Tomi Valkeinen <tomi.valkeinen@ti.com>,
	linux-omap@vger.kernel.org, linux-fbdev@vger.kernel.org
Cc: Eduardo Valentin <eduardo.valentin@ti.com>,
	Aaro Koskinen <aaro.koskinen@iki.fi>,
	stable@vger.kernel.org
Subject: [PATCH] ARM: OMAPFB: panel-sony-acx565akm: fix bad unlock balance
Date: Wed,  6 Nov 2013 23:24:30 +0200	[thread overview]
Message-ID: <1383773070-15114-1-git-send-email-aaro.koskinen@iki.fi> (raw)

When booting Nokia N900 smartphone with v3.12 + omap2plus_defconfig
(LOCKDEP enabled) and CONFIG_DISPLAY_PANEL_SONY_ACX565AKM enabled,
the following BUG is seen during the boot:

[    7.302154] =====================================
[    7.307128] [ BUG: bad unlock balance detected! ]
[    7.312103] 3.12.0-los.git-2093492-00120-g5e01dc7 #3 Not tainted
[    7.318450] -------------------------------------
[    7.323425] kworker/u2:1/12 is trying to release lock (&ddata->mutex) at:
[    7.330657] [<c031b760>] acx565akm_enable+0x12c/0x18c
[    7.335998] but there are no more locks to release!

Fix by removing the extra mutex_unlock().

Reported-by: Eduardo Valentin <eduardo.valentin@ti.com>
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Cc: stable@vger.kernel.org
---
 drivers/video/omap2/displays-new/panel-sony-acx565akm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/video/omap2/displays-new/panel-sony-acx565akm.c b/drivers/video/omap2/displays-new/panel-sony-acx565akm.c
index e6d56f7..72fe2a8 100644
--- a/drivers/video/omap2/displays-new/panel-sony-acx565akm.c
+++ b/drivers/video/omap2/displays-new/panel-sony-acx565akm.c
@@ -616,7 +616,7 @@ static int acx565akm_enable(struct omap_dss_device *dssdev)
 
 	mutex_lock(&ddata->mutex);
 	r = acx565akm_panel_power_on(dssdev);
-	mutex_unlock(&ddata->mutex);
+	/* NOTE: acx565akm_panel_power_on() will unlock the mutex. */
 
 	if (r)
 		return r;
-- 
1.8.4.2

             reply	other threads:[~2013-11-06 21:24 UTC|newest]

Thread overview: 33+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-11-06 21:24 Aaro Koskinen [this message]
2013-11-06 21:24 ` [PATCH] ARM: OMAPFB: panel-sony-acx565akm: fix bad unlock balance Aaro Koskinen
2013-11-11 13:37 ` Tomi Valkeinen
2013-11-11 13:37   ` Tomi Valkeinen
2013-11-11 18:37   ` Aaro Koskinen
2013-11-11 18:37     ` Aaro Koskinen
2013-12-06 12:55 ` [PATCH] ARM: OMAPFB: panel-sony-acx565akm: fix missing unlock in acx565akm_panel_power_on() Wei Yongjun
2013-12-06 12:55   ` Wei Yongjun
2013-12-11 14:29   ` Tomi Valkeinen
2013-12-11 14:29     ` Tomi Valkeinen
2013-12-30 16:17 [PATCH] ARM: OMAPFB: panel-sony-acx565akm: fix missing mutex unlocks Ivaylo Dimitrov
2013-12-30 16:17 ` Ivaylo Dimitrov
2014-01-04 12:51 ` Pavel Machek
2014-01-04 12:51   ` Pavel Machek
2014-01-05 12:58   ` Ivaylo Dimitrov
2014-01-05 12:58     ` Ivaylo Dimitrov
2014-01-05 13:13     ` [PATCH v2] " Ivaylo Dimitrov
2014-01-05 13:13       ` Ivaylo Dimitrov
2014-01-10 10:56       ` Tomi Valkeinen
2014-01-10 10:56         ` Tomi Valkeinen
2014-01-10 10:56         ` Tomi Valkeinen
2014-01-11  9:39         ` Ivaylo Dimitrov
2014-01-11  9:39           ` Ivaylo Dimitrov
2014-01-13 10:20           ` Tomi Valkeinen
2014-01-13 10:20             ` Tomi Valkeinen
2014-01-13 10:20             ` Tomi Valkeinen
2015-12-25 13:29             ` Ivaylo Dimitrov
2015-12-25 13:29               ` Ivaylo Dimitrov
2015-12-29  7:46               ` Tomi Valkeinen
2015-12-29  7:46                 ` Tomi Valkeinen
2015-12-29  7:46                 ` Tomi Valkeinen
2016-01-01 12:25                 ` Ivaylo Dimitrov
2016-01-01 12:25                   ` Ivaylo Dimitrov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1383773070-15114-1-git-send-email-aaro.koskinen@iki.fi \
    --to=aaro.koskinen@iki.fi \
    --cc=eduardo.valentin@ti.com \
    --cc=linux-fbdev@vger.kernel.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=stable@vger.kernel.org \
    --cc=tomi.valkeinen@ti.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.