Re: Console handling
Mon, 15 Dec 1997 18:28:09 +0100 (MET)

On 14 Dec 1997, H. Peter Anvin wrote:

> Linux has never had different number of lines on different VTs. answered:

> Are you sure? There used to be a comment about this in drivers/char/console.c.
> It said the feature was removed because `it's messy to have all consoles of
> potentially different sizes'.

hpa is correct, in the sense that no official Linux distribution
ever had consoles of potentially different sizes.

I wrote the dynamic console code a long time ago, and at first allowed this.
[To be precise: each virtual console that is not currently visible
has a screen buffer to hold its data, and this screen buffer is
dynamically allocated anyway, so in principle there is nothing against
each VC having its own size, and its own length of scroll-back buffer.]

But it was fairly useless - the kernel cannot change video modes,
so this has to be done by a user space program; making sure that there is
a program that gets a signal so that it knows that the video mode has to be
changed is messy. (This is what X does.) Moreover, changing mode is
unpleasant: a lot of flickering on the screen, strange noises from the
monitor, once in a while an accompanying system crash, as if the nearby
hardware was unhappy with the generated radiation.
Also, large scroll-back buffers seemed a bad idea for performance.

So, in the submitted version of this patch no scroll-back was saved,
and the source was simplified by letting all text-mode consoles have
the same size.

Now that people with >= 32MB are getting more common than people with <= 8MB
someone might add an ioctl for setting the amount of saved scroll-back
(per-VT). This is easy and straightforward and potentially useful.
Whoever wants this can then set scroll-back on some or all VTs in /etc/rc.local or so.

Concerning the sizes of VTs, we might reconsider if on other architectures
the change of video modes is easy, so that it could be done by the kernel
(without detailed per-video-card info).