5 ms·
I think what is going on these days is that the font change coincide with the GPU driver kicking in, as much of what was done with GPUs are now done in the kern
by digi_owl 9y ago
I think what is going on these days is that the font change coincide with the GPU driver kicking in, as much of what was done with GPUs are now done in the kernel, rather than X, via the DRI sub-system.
- shmerl 9y agoSo kernel GPU driver uses some special bitmap font to render in framebuffer? And how is it working before the GPU driver kicks in and where is that older font coming from?
- digi_owl 9y agoLikely the graphics card ROM. https://en.wikipedia.org/wiki/VGA-compatible_text_mode https://en.wikipedia.org/wiki/VGA-compatible_text_mode
- slededit 9y agoWhen a PC first starts it's essentially an origina IBM PC from the 80s including the original text mode and built in fonts. You can write text in this mode literally by copying ascii characters to a specific memory address. The hardware handles the job of actually putting characters on the screen.
- rbanffy 9y ago> When a PC first starts it's essentially an origina IBM PC from the 80s including the original text mode and built in fonts. Thanks. Now I feel dirty for touching my modern MacBook and imagining that IBM horror inside it.
- slededit 9y agoI believe macs are UEFI only and so may not contain most of the old peripherals. This is only required for legacy BIOS booting.
- dfox 9y agoModern kernel GPU driver knows enough about the GPU to switch video modes (and usually also enough to detect connected monitors) and setup some kind of linear framebuffer mode. The first font used for FB-emulated console is statically linked into relevant module and usually gets replaced with more complete font by initramfs code. IIRC on my desktop the switch to graphical mode happens about 300ms after loading the kernel. Funnily enough grub2 before that also runs in 4k graphics mode, which given the 8x16px font is somewhat absurd (and the screen redraw is slow enough that you can see that it for some reason happens from bottom to top) Edit: this is with amdgpu, but both intel, nouveau and ATI rage XL on server motherboards (which is somehow suboptimal :)) behave similarly on debian. Maybe with nvidia driver you still get native text mode on consoles (for a long time nvidia driver was known to interfere with operation of linux framebuffer infrastructure, but I don't known how this works today).
- shmerl 9y ago> IIRC on my desktop the switch to graphical mode happens about 300ms after loading the kernel. Funnily enough grub2 before that also runs in 4k graphics mode, which given the 8x16px font is somewhat absurd (and the screen redraw is slow enough that you can see that it for some reason happens from bottom to top) Yeah, I noticed that. GRUB font looks similar to the one that's rendered after the kernel GPU driver takes over. I also noticed during boot (when systemd messages are showing up) a transition with amdgpu (RX 480, Polaris) where it displays a color mess for a split moment, and redraws the screen in new font after that. Never saw that with Intel. I haven't used Nvidia in a while, but their blob doesn't support proper framebuffer if I remember correctly, so it causes an ugly resolution during boot.
- dfox 9y agoOn Bonaire (no idea what the card is as I bought it on the basis of being supported by amdgpu and having right combination of outputs and nothing else) I don't get mess for split second, but after the switch to graphical mode first two lines are partialy replaced by randomly colored special characters.
- 9y ago
- kevin_thibedeau 9y agoNo. It's just loading a new bitmap font. The console is still in legacy text mode on standard PCs. That's why you see the clean transition because the text in memory and video mode remains unchanged (unless you've altered the init) so all the character cells line up.
- shmerl 9y ago> That's why you see the clean transition because the text in memory and video mode remains unchanged It's not so with amdgpu (Polaris at least). Looks like there some glitch that makes color noise appear in between, and screen is reset.
- dfox 9y agoThis depends on a lot of things and often linux switches to graphical mode quite early. Another thing is that some new-ish BIOSes leave the VGA card in non-standard videomode that is 80x25 text mode, but has 8 pixel wide font and same timing as 640x480 graphics mode. The difference is clearly visible on CRT monitor (lower refresh rate but no horizontal black lines between scanlines that are typical for PC text modes). I believe this has to do with fact that some LCD monitors are not capable of reliably maintaining synchronisation in 400-line VGA modes when using VGA input and many TVs and similar HDMI-connected devices simply don't support 400-line modes at all.