fbcon: fix locking harder
authorDave Airlie <airlied@gmail.com>
Fri, 25 Jan 2013 01:38:56 +0000 (11:38 +1000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 26 Apr 2013 04:19:56 +0000 (21:19 -0700)
commit726cc91ed26521f3e678346e5745203a70edd456
tree499c4469d19b686025457586bdff9832bdd19c81
parent6b48c21afcf0f9f01bb37144a5da3274a3590404
fbcon: fix locking harder

commit 054430e773c9a1e26f38e30156eff02dedfffc17 upstream.

Okay so Alan's patch handled the case where there was no registered fbcon,
however the other path entered in set_con2fb_map pit.

In there we called fbcon_takeover, but we also took the console lock in a couple
of places. So push the console lock out to the callers of set_con2fb_map,

this means fbmem and switcheroo needed to take the lock around the fb notifier
entry points that lead to this.

This should fix the efifb regression seen by Maarten.

Tested-by: Maarten Lankhorst <maarten.lankhorst@canonical.com>
Tested-by: Lu Hua <huax.lu@intel.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/gpu/vga/vga_switcheroo.c
drivers/video/console/fbcon.c
drivers/video/fbmem.c