Skip to content

Commit

Permalink
[S390] sclp_vt220: set initial terminal window size
Browse files Browse the repository at this point in the history
When opening a SCLP VT220 terminal, the terminal window size is not
initialized (defaults to zero).
Since the SCLP VT220 terminal supports only 80x24, explicitly set
the window size to prevent (n)curses applications from guessing
the default setting.

Signed-off-by: Hendrik Brueckner <brueckner@linux.vnet.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
  • Loading branch information
Hendrik Brueckner authored and Martin Schwidefsky committed Jan 27, 2010
1 parent 0b4d789 commit 0b665d7
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions drivers/s390/char/sclp_vt220.c
Original file line number Diff line number Diff line change
Expand Up @@ -495,6 +495,10 @@ sclp_vt220_open(struct tty_struct *tty, struct file *filp)
if (tty->driver_data == NULL)
return -ENOMEM;
tty->low_latency = 0;
if (!tty->winsize.ws_row && !tty->winsize.ws_col) {
tty->winsize.ws_row = 24;
tty->winsize.ws_col = 80;
}
}
return 0;
}
Expand Down

0 comments on commit 0b665d7

Please sign in to comment.