-
Notifications
You must be signed in to change notification settings - Fork 41
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Crash when setting a font larger than 32x32 #109
Comments
The |
It is a file from this Arch Linux package : https://archlinux.org/packages/extra/any/terminus-font/ |
It also crashes when using the solar24x32 font:
|
The problem occurs if the font height becomes greater than 32 when doubling. Another problem is that if the height is greater than 32 then the vpitch value becomes incorrect and cannot be loaded into the kernel. As a solution, we need to adjust vpitch before buffer allocation. Link: #109 Co-developed-by: Oleg Bulatov <oleg@bulatov.me> Signed-off-by: Alexey Gladkov <legion@kernel.org>
I see what you're talking about. I pushed a fix for this. Try it. |
Thank you. However it still doesn't work.
Does it require some kernel options to be enabled to use the fonts with height>32? |
@oldherl I did some research. Yes, modern kernels support tall fonts, but the text console does not support such fonts. As far as I understand, you need to use a framebuffer to use large fonts. |
Sad to hear about that. Do you have any reference links for it? Also, is it possible for |
At the time when tall fonts were added to the kernel [1], fbdev was considered where support should be.
But later a check was added [2] that prohibits fonts larger than 32. The fbcon does not support such fonts [3]. The vgacon does not support such fonts [4]. As far as I see, other consoles do not support either.
Unfortunately, the kernel returns EINVAL if the console does not support tall fonts. The kernel returns the same error in a lot of other cases. Basically, the kernel returns EINVAL if it does not like the font based on some criteria. I don't yet know how to distinguish this error from other errors with EINVAL. [1] torvalds/linux@ffc1e08 |
Thank you very much for the explanation. I'm closing this issue now. |
I'm trying the new feature of setting a font larger than 32x32.
Specifically, I am trying "setfont ter-132n -d" which sets a doubled 32x16 font, on archiso. It coredumped.
The text was updated successfully, but these errors were encountered: