fb: rework locking to fix lock ordering on takeover
authorAlan Cox <alan@linux.intel.com>
Fri, 25 Jan 2013 00:28:15 +0000 (10:28 +1000)
committerDave Airlie <airlied@redhat.com>
Fri, 8 Feb 2013 02:02:40 +0000 (12:02 +1000)
commit50e244cc793d511b86adea24972f3a7264cae114
treede59e5f228a256ad09521524639e1b5b6e49b8cc
parent84b603abd23300df8ee5fb1c23c83634c2aaedea
fb: rework locking to fix lock ordering on takeover

Adjust the console layer to allow a take over call where the caller
already holds the locks.  Make the fb layer lock in order.

This is partly a band aid, the fb layer is terminally confused about the
locking rules it uses for its notifiers it seems.

[akpm@linux-foundation.org: remove stray non-ascii char, tidy comment]
[akpm@linux-foundation.org: export do_take_over_console()]
[airlied: cleanup another non-ascii char]
Signed-off-by: Alan Cox <alan@linux.intel.com>
Cc: Florian Tobias Schandinat <FlorianSchandinat@gmx.de>
Cc: Stephen Rothwell <sfr@canb.auug.org.au>
Cc: Jiri Kosina <jkosina@suse.cz>
Cc: stable <stable@vger.kernel.org>
Tested-by: Sedat Dilek <sedat.dilek@gmail.com>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Dave Airlie <airlied@redhat.com>
drivers/tty/vt/vt.c
drivers/video/console/fbcon.c
drivers/video/fbmem.c
drivers/video/fbsysfs.c
include/linux/console.h