info->var.yoffset = info->var.xoffset = p->yscroll = 0; 
var.yoffset = info->var.yoffset; var.xoffset = info->var.xoffset; var.vmode = info->var.vmode; 
static int fbcon_switch(struct vc_data *vc){	struct fb_info *info, *old_info = NULL;	struct display *p = &fb_display[vc->vc_num];	struct fb_var_screeninfo var;	int i, prev_console;	info = registered_fb[con2fb_map[vc->vc_num]];	if (softback_top) {		if (softback_lines)			fbcon_set_origin(vc);		softback_top = softback_curr = softback_in = softback_buf;		softback_lines = 0;		fbcon_update_softback(vc);	}	if (logo_shown >= 0) {		struct vc_data *conp2 = vc_cons[logo_shown].d;		if (conp2->vc_top == logo_lines		    && conp2->vc_bottom == conp2->vc_rows)			conp2->vc_top = 0;		logo_shown = FBCON_LOGO_CANSHOW;	}	prev_console = ((struct fbcon_ops *)info->fbcon_par)->currcon;	if (prev_console != -1)		old_info = registered_fb[con2fb_map[prev_console]];	/*	 * FIXME: If we have multiple fbdev's loaded, we need to	 * update all info->currcon.  Perhaps, we can place this	 * in a centralized structure, but this might break some	 * drivers.	 *	 * info->currcon = vc->vc_num;	 */	for (i = 0; i < FB_MAX; i++) {		if (registered_fb[i] != NULL && registered_fb[i]->fbcon_par) {			struct fbcon_ops *ops = registered_fb[i]->fbcon_par;			ops->currcon = vc->vc_num;		}	}	memset(&var, 0, sizeof(struct fb_var_screeninfo));	display_to_var(&var, p);	var.activate = FB_ACTIVATE_NOW;	/*	 * make sure we don't unnecessarily trip the memcmp()	 * in fb_set_var()	 */	info->var.activate = var.activate;	info->var.yoffset = info->var.xoffset = p->yscroll = 0;	fb_set_var(info, &var);	if (old_info != NULL && old_info != info) {		if (info->fbops->fb_set_par)			info->fbops->fb_set_par(info);		fbcon_del_cursor_timer(old_info);		fbcon_add_cursor_timer(info);	}	set_blitting_type(vc, info, p);	((struct fbcon_ops *)info->fbcon_par)->cursor_reset = 1;	vc->vc_can_do_color = (fb_get_color_depth(&info->var, &info->fix)!=1);	vc->vc_complement_mask = vc->vc_can_do_color ? 0x7700 : 0x0800;	updatescrollmode(p, info, vc);	switch (p->scrollmode) {	case SCROLL_WRAP_MOVE:		scrollback_phys_max = p->vrows - vc->vc_rows;		break;	case SCROLL_PAN_MOVE:	case SCROLL_PAN_REDRAW:		scrollback_phys_max = p->vrows - 2 * vc->vc_rows;		if (scrollback_phys_max < 0)			scrollback_phys_max = 0;		break;	default:		scrollback_phys_max = 0;		break;	}	scrollback_max = 0;	scrollback_current = 0;	update_var(vc->vc_num, info);	fbcon_set_palette(vc, color_table); 		fbcon_clear_margins(vc, 0);	if (logo_shown == FBCON_LOGO_DRAW) {		logo_shown = fg_console;		/* This is protected above by initmem_freed */		fb_show_logo(info);		update_region(vc,			      vc->vc_origin + vc->vc_size_row * vc->vc_top,			      vc->vc_size_row * (vc->vc_bottom -						 vc->vc_top) / 2);		return 0;	}	return 1;}
10457	/local/tlutelli/issta_data/temp/c/2005_temp/2005/10457/e4fc27618b75234b721c4a13d0e0d9d07e75e641/fbcon.c/clean/drivers/video/console/fbcon.c