vt_ioctl: Revert VT_RESIZEX parameter handling removal
authorMaciej W. Rozycki <macro@orcam.me.uk>
Thu, 13 May 2021 09:51:45 +0000 (11:51 +0200)
committerLinus Torvalds <torvalds@linux-foundation.org>
Thu, 13 May 2021 18:00:18 +0000 (11:00 -0700)
commita90c275eb144c1b755f04769e1f29d832d6daeaf
tree516264dcdc571f1c7ee84025b46ce1deed221299
parentd4d0ad57b3865795c4cde2fb5094c594c2e8f469
vt_ioctl: Revert VT_RESIZEX parameter handling removal

Revert the removal of code handling extra VT_RESIZEX ioctl's parameters
beyond those that VT_RESIZE supports, fixing a functional regression
causing `svgatextmode' not to resize the VT anymore.

As a consequence of the reverted change when the video adapter is
reprogrammed from the original say 80x25 text mode using a 9x16
character cell (720x400 pixel resolution) to say 80x37 text mode and the
same character cell (720x592 pixel resolution), the VT geometry does not
get updated and only upper two thirds of the screen are used for the VT,
and the lower part remains blank.  The proportions change according to
text mode geometries chosen.

Revert the change verbatim then, bringing back previous VT resizing.

Signed-off-by: Maciej W. Rozycki <macro@orcam.me.uk>
Fixes: 988d0763361b ("vt_ioctl: make VT_RESIZEX behave like VT_RESIZE")
Cc: stable@vger.kernel.org # v5.10+
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
drivers/tty/vt/vt_ioctl.c