All of lore.kernel.org
 help / color / mirror / Atom feed
* [to-be-updated] drivers-platform-x86-thinkpad_acpic-move-hotkey_thread_mutex-lock-after-set_freezable.patch removed from -mm tree
@ 2013-03-07 21:47 akpm
  0 siblings, 0 replies; only message in thread
From: akpm @ 2013-03-07 21:47 UTC (permalink / raw)
  To: artem.savkov, aaron.lu, ibm-acpi, maciej.rutecki,
	matthew.garrett, msb, oleg, rjw, tj, mm-commits


The patch titled
     Subject: drivers/platform/x86/thinkpad_acpi.c: move hotkey_thread_mutex lock after set_freezable()
has been removed from the -mm tree.  Its filename was
     drivers-platform-x86-thinkpad_acpic-move-hotkey_thread_mutex-lock-after-set_freezable.patch

This patch was dropped because an updated version will be merged

------------------------------------------------------
From: Artem Savkov <artem.savkov@gmail.com>
Subject: drivers/platform/x86/thinkpad_acpi.c: move hotkey_thread_mutex lock after set_freezable()

set_freezable() runs try_to_freeze() during which no locks should be held.
hotkey_thread_mutex lock should be moved closer to where it is actually
needed.

This fixes a boot-time lockdep warning which results from "lockdep: check
that no locks held at freeze time".

Signed-off-by: Artem Savkov <artem.savkov@gmail.com>
Cc: Henrique de Moraes Holschuh <ibm-acpi@hmh.eng.br>
Cc: Matthew Garrett <matthew.garrett@nebula.com>
Cc: "Rafael J. Wysocki" <rjw@sisk.pl>
Cc: Mandeep Singh Baines <msb@chromium.org>
Cc: Aaron Lu <aaron.lu@intel.com>
Cc: Tejun Heo <tj@kernel.org>
Cc: Oleg Nesterov <oleg@redhat.com>
Cc: Maciej Rutecki <maciej.rutecki@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---

 drivers/platform/x86/thinkpad_acpi.c |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff -puN drivers/platform/x86/thinkpad_acpi.c~drivers-platform-x86-thinkpad_acpic-move-hotkey_thread_mutex-lock-after-set_freezable drivers/platform/x86/thinkpad_acpi.c
--- a/drivers/platform/x86/thinkpad_acpi.c~drivers-platform-x86-thinkpad_acpic-move-hotkey_thread_mutex-lock-after-set_freezable
+++ a/drivers/platform/x86/thinkpad_acpi.c
@@ -2462,13 +2462,13 @@ static int hotkey_kthread(void *data)
 	unsigned int poll_freq;
 	bool was_frozen;
 
-	mutex_lock(&hotkey_thread_mutex);
-
 	if (tpacpi_lifecycle == TPACPI_LIFE_EXITING)
 		goto exit;
 
 	set_freezable();
 
+	mutex_lock(&hotkey_thread_mutex);
+
 	so = 0;
 	si = 1;
 	t = 0;
@@ -2522,8 +2522,8 @@ static int hotkey_kthread(void *data)
 		si ^= 1;
 	}
 
-exit:
 	mutex_unlock(&hotkey_thread_mutex);
+exit:
 	return 0;
 }
 
_

Patches currently in -mm which might be from artem.savkov@gmail.com are

thinkpad-acpi-kill-hotkey_thread_mutex.patch


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2013-03-07 21:47 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-03-07 21:47 [to-be-updated] drivers-platform-x86-thinkpad_acpic-move-hotkey_thread_mutex-lock-after-set_freezable.patch removed from -mm tree akpm

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.