aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/video
diff options
context:
space:
mode:
authorAntonino A. Daplas <adaplas@gmail.com>2005-12-13 01:17:18 -0500
committerLinus Torvalds <torvalds@g5.osdl.org>2005-12-13 01:31:17 -0500
commit4e1567d3aad9bae0ecc5bb047179cd026bfb035c (patch)
treeb3e8820b236c62da6cdbcefbe2850c9cd0158489 /drivers/video
parent1207069f6f8f3d1b71641fdaa6cc04fca6fff9f5 (diff)
[PATCH] fbcon: Avoid illegal display panning
Avoid calls to fb_pan_display when driver is suspended or not in text mode. Signed-off-by: Antonino Daplas <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/video')
-rw-r--r--drivers/video/console/fbcon.c25
1 files changed, 19 insertions, 6 deletions
diff --git a/drivers/video/console/fbcon.c b/drivers/video/console/fbcon.c
index bd4500a8992e..8068d2f7efe6 100644
--- a/drivers/video/console/fbcon.c
+++ b/drivers/video/console/fbcon.c
@@ -2146,8 +2146,12 @@ static int fbcon_switch(struct vc_data *vc)
2146 2146
2147 scrollback_max = 0; 2147 scrollback_max = 0;
2148 scrollback_current = 0; 2148 scrollback_current = 0;
2149 ops->var.xoffset = ops->var.yoffset = p->yscroll = 0; 2149
2150 ops->update_start(info); 2150 if (!fbcon_is_inactive(vc, info)) {
2151 ops->var.xoffset = ops->var.yoffset = p->yscroll = 0;
2152 ops->update_start(info);
2153 }
2154
2151 fbcon_set_palette(vc, color_table); 2155 fbcon_set_palette(vc, color_table);
2152 fbcon_clear_margins(vc, 0); 2156 fbcon_clear_margins(vc, 0);
2153 2157
@@ -2746,8 +2750,12 @@ static void fbcon_modechanged(struct fb_info *info)
2746 updatescrollmode(p, info, vc); 2750 updatescrollmode(p, info, vc);
2747 scrollback_max = 0; 2751 scrollback_max = 0;
2748 scrollback_current = 0; 2752 scrollback_current = 0;
2749 ops->var.xoffset = ops->var.yoffset = p->yscroll = 0; 2753
2750 ops->update_start(info); 2754 if (!fbcon_is_inactive(vc, info)) {
2755 ops->var.xoffset = ops->var.yoffset = p->yscroll = 0;
2756 ops->update_start(info);
2757 }
2758
2751 fbcon_set_palette(vc, color_table); 2759 fbcon_set_palette(vc, color_table);
2752 update_screen(vc); 2760 update_screen(vc);
2753 if (softback_buf) 2761 if (softback_buf)
@@ -2784,8 +2792,13 @@ static void fbcon_set_all_vcs(struct fb_info *info)
2784 updatescrollmode(p, info, vc); 2792 updatescrollmode(p, info, vc);
2785 scrollback_max = 0; 2793 scrollback_max = 0;
2786 scrollback_current = 0; 2794 scrollback_current = 0;
2787 ops->var.xoffset = ops->var.yoffset = p->yscroll = 0; 2795
2788 ops->update_start(info); 2796 if (!fbcon_is_inactive(vc, info)) {
2797 ops->var.xoffset = ops->var.yoffset =
2798 p->yscroll = 0;
2799 ops->update_start(info);
2800 }
2801
2789 fbcon_set_palette(vc, color_table); 2802 fbcon_set_palette(vc, color_table);
2790 update_screen(vc); 2803 update_screen(vc);
2791 if (softback_buf) 2804 if (softback_buf)