diff options
author | Dave Airlie <airlied@gmail.com> | 2013-01-24 20:38:56 -0500 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2013-02-07 21:02:43 -0500 |
commit | 054430e773c9a1e26f38e30156eff02dedfffc17 (patch) | |
tree | 9866f12c399f63de3ac285624226b19c0501b191 /drivers/video/fbmem.c | |
parent | e93a9a868792ad71cdd09d75e5a02d8067473c4e (diff) |
fbcon: fix locking harder
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>
Diffstat (limited to 'drivers/video/fbmem.c')
-rw-r--r-- | drivers/video/fbmem.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/video/fbmem.c b/drivers/video/fbmem.c index 070b9a13d892..dc61c12ecf8c 100644 --- a/drivers/video/fbmem.c +++ b/drivers/video/fbmem.c | |||
@@ -1177,8 +1177,10 @@ static long do_fb_ioctl(struct fb_info *info, unsigned int cmd, | |||
1177 | event.data = &con2fb; | 1177 | event.data = &con2fb; |
1178 | if (!lock_fb_info(info)) | 1178 | if (!lock_fb_info(info)) |
1179 | return -ENODEV; | 1179 | return -ENODEV; |
1180 | console_lock(); | ||
1180 | event.info = info; | 1181 | event.info = info; |
1181 | ret = fb_notifier_call_chain(FB_EVENT_SET_CONSOLE_MAP, &event); | 1182 | ret = fb_notifier_call_chain(FB_EVENT_SET_CONSOLE_MAP, &event); |
1183 | console_unlock(); | ||
1182 | unlock_fb_info(info); | 1184 | unlock_fb_info(info); |
1183 | break; | 1185 | break; |
1184 | case FBIOBLANK: | 1186 | case FBIOBLANK: |