s390/tty3270: add support for diag 8c
authorSven Schnelle <svens@linux.ibm.com>
Thu, 17 Nov 2022 21:02:01 +0000 (22:02 +0100)
committerHeiko Carstens <hca@linux.ibm.com>
Mon, 9 Jan 2023 13:33:56 +0000 (14:33 +0100)
commitfbaee7464fbb61a4cb484d9c41f14517738c80c7
tree84d4f4624a40ce6e2659c51e960168c2dd63d11d
parent9603cb334a7dc30fb544a3579bcbf23ae5b04f8f
s390/tty3270: add support for diag 8c

The current code uses diag210 to infer the 3270 geometry from the
model number when running on z/VM. This doesn't work well as almost
all 3270 software clients report as 3279-2 with a custom resolution.
tty3270 assumes it has a 80x24 terminal connected because of the -2
suffix. Use diag 8c to fetch the realy geometry from z/VM.

Note that this doesn't allow dynamic resizing, i.e. reconnecting to
a z/VM session with a different geometry.

Signed-off-by: Sven Schnelle <svens@linux.ibm.com>
Acked-by: Heiko Carstens <hca@linux.ibm.com>
Tested-by: Niklas Schnelle <schnelle@linux.ibm.com>
Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
arch/s390/include/asm/diag.h
arch/s390/kernel/diag.c
arch/s390/kernel/text_amode31.S
drivers/s390/char/raw3270.c