rc = raw3270_add_view(&tp->view, &tty3270_fn, tty->index); 
rc = raw3270_add_view(&tp->view, &tty3270_fn, tty->index + RAW3270_FIRSTMINOR); 
tty3270_open(struct tty_struct *tty, struct file * filp){	struct tty3270 *tp;	int i, rc;	if (tty->count > 1)		return 0;	/* Check if the tty3270 is already there. */	tp = (struct tty3270 *) raw3270_find_view(&tty3270_fn, tty->index);	if (!IS_ERR(tp)) {		tty->driver_data = tp;		tty->winsize.ws_row = tp->view.rows - 2;		tty->winsize.ws_col = tp->view.cols;		tty->low_latency = 0;		tp->tty = tty;		tp->kbd->tty = tty;		tp->inattr = TF_INPUT;		return 0;	}	if (tty3270_max_index < tty->index + 1)		tty3270_max_index = tty->index + 1;	/* Quick exit if there is no device for tty->index. */	if (PTR_ERR(tp) == -ENODEV)		return -ENODEV;	/* Allocate tty3270 structure on first open. */	tp = tty3270_alloc_view();	if (IS_ERR(tp))		return PTR_ERR(tp);	INIT_LIST_HEAD(&tp->lines);	INIT_LIST_HEAD(&tp->update);	INIT_LIST_HEAD(&tp->rcl_lines);	tp->rcl_max = 20;	init_timer(&tp->timer);	tasklet_init(&tp->readlet, 		     (void (*)(unsigned long)) tty3270_read_tasklet,		     (unsigned long) tp->read);	rc = raw3270_add_view(&tp->view, &tty3270_fn, tty->index);	if (rc) {		tty3270_free_view(tp);		return rc;	}	rc = tty3270_alloc_screen(tp);	if (rc) {		raw3270_del_view(&tp->view);		raw3270_put_view(&tp->view);		return rc;	}	tp->tty = tty;	tty->low_latency = 0;	tty->driver_data = tp;	tty->winsize.ws_row = tp->view.rows - 2;	tty->winsize.ws_col = tp->view.cols;	tty3270_create_prompt(tp);	tty3270_create_status(tp);	tty3270_update_status(tp);	/* Create blank line for every line in the tty output area. */	for (i = 0; i < tp->view.rows - 2; i++)		tty3270_blank_line(tp);	tp->kbd->tty = tty;	tp->kbd->fn_handler[KVAL(K_INCRCONSOLE)] = tty3270_exit_tty;	tp->kbd->fn_handler[KVAL(K_SCROLLBACK)] = tty3270_scroll_backward;	tp->kbd->fn_handler[KVAL(K_SCROLLFORW)] = tty3270_scroll_forward;	tp->kbd->fn_handler[KVAL(K_CONS)] = tty3270_rcl_backward;	kbd_ascebc(tp->kbd, tp->view.ascebc);	raw3270_activate_view(&tp->view);	return 0;}
10457	/local/tlutelli/issta_data/temp/c/2005_temp/2005/10457/ed3cb6f039bb296457bfd2877cba6ad0287d8d54/tty3270.c/buggy/drivers/s390/char/tty3270.c