The Funtoo Linux project has transitioned to "Hobby Mode" and this wiki is now read-only.
Difference between revisions of "Uvesafb"
(Removed ugly white boxes inside the tip and note templates on the page.) |
m (Updated the <code> and <console> tags on the page to {{c}} and {{console}} templates. Changed the wording in a few places.) |
||
Line 4: | Line 4: | ||
== Kernel configuration == | == Kernel configuration == | ||
Before we emerge the required packages for uvesafb functionality, we have to configure the kernel properly. | Before we emerge the required packages for uvesafb functionality, we have to configure the kernel properly. | ||
{{Kernelop|title= |desc= | {{Kernelop|title=|desc= | ||
Device Drivers ---> | Device Drivers ---> | ||
<*> Connector - unified userspace <-> kernelspace linker ---> | <*> Connector - unified userspace <-> kernelspace linker ---> | ||
Line 15: | Line 15: | ||
}} | }} | ||
{{Note|Build the kernel ( | {{Note|Build the kernel {{c|make}} from the kernel sources directory ({{c|/usr/src/linux}}. Do not install the kernel and modules ({{c|make install modules_install}}). You can choose uvesafb as a module, unlike vesa.}} | ||
== Install required packages == | == Install required packages == | ||
Emerge {{Package|dev-libs/klibc}}. Klibc has to be compiled against a kernel that includes uvesafb support. This only has to be done once: | Emerge {{Package|dev-libs/klibc}}. Klibc has to be compiled against a kernel that includes uvesafb support. This only has to be done once: | ||
{{console|body= | |||
###i## emerge klibc | ###i## emerge klibc | ||
}} | |||
{{Package|sys-apps/v86d}} is the userspace helper that runs x86 code in emulated environment. Uvesafb will not work without v86d. Emerge | {{Package|sys-apps/v86d}} is the userspace helper that runs x86 code in emulated environment. Uvesafb will not work without v86d. Emerge {{c|v86d}}: | ||
{{console|body= | |||
###i## emerge v86d | ###i## emerge v86d | ||
}} | |||
== Back to kernel configuration == | == Back to kernel configuration == | ||
Reconfigure the kernel to include | Reconfigure the kernel to include {{c|/usr/share/v86d/initramfs}} as an initramfs source file: | ||
{{Kernelop | {{Kernelop|title=|desc= | ||
|title= | |||
|desc= | |||
General Setup---> | General Setup---> | ||
[*] Initial RAM filesystem and RAM disk (initramfs/initrd) support | [*] Initial RAM filesystem and RAM disk (initramfs/initrd) support | ||
Line 40: | Line 38: | ||
== Bootloader configuration == | == Bootloader configuration == | ||
If you compiled uvesafb into the kernel (not as a module), you can configure its behavior by editing the | If you compiled uvesafb into the kernel (not as a module), you can configure its behavior by editing the {{c|params +=}} line in {{c|/etc/boot.conf}}. Below, some of the more common switches used with uvesafb are explained: | ||
* < | * <code>video=uvesafb:<screen y-res>x<screen x-res>-<color depth></code>: Tells the kernel that you want to use the uvesafb driver for console output. Also specifies that you will be using uvesafb at a set x-screen resolution, y screen-resolution, and color depth. Set the first part to the size of your screen (in pixels). For example, if I had a 1920x1080 screen and wanted a color depth of 32, I would add the following: <code>video=uvesafb:1920x1080-32</code> | ||
* | * {{c|mtrr:x}}: X represents the number 0 or 3. This option allows you to set up the memory type range registers for uvesafb. Setting x=0 disables mtrr and setting x=3 enables mtrr. x=3 is the default setting for this switch. mtrr:3 is recommended. | ||
* | * {{c|ywrap}}: Add support for display panning. Recommended. | ||
{{Tip|For more information regarding these switches, check out http://www.mjmwired.net/kernel/Documentation/fb/uvesafb.txt}} | {{Tip|For more information regarding these switches, check out http://www.mjmwired.net/kernel/Documentation/fb/uvesafb.txt}} | ||
Now that you have a basic understanding of a few of the different switches, configure your | Now that you have a basic understanding of a few of the different switches, you can configure your {{c|/etc/boot.conf}} to allow booting with the uvesafb framebuffer: | ||
{{file|name=/etc/boot.conf|desc= |body= | {{file|name=/etc/boot.conf|desc= |body= | ||
Line 65: | Line 63: | ||
After you have finished editing your <tt>/etc/boot.conf</tt>, run the following: | After you have finished editing your <tt>/etc/boot.conf</tt>, run the following: | ||
{{console|body= | |||
###i## boot-update | ###i## boot-update | ||
}} | |||
Finally, reboot your computer so that you can test out uvesafb: | |||
{{console|body= | |||
###i## reboot | ###i## reboot | ||
}} | |||
[[Category:HOWTO]] | [[Category:HOWTO]] |
Revision as of 13:18, June 30, 2015
How to : Framebuffer: Userspace VESA VGA graphics support
Uvesafb is an improved framebuffer driver for Linux systems with some enhancements compared to vesa. Uvesafb can allow you to get a full-resolution console, even if you have installed a graphics driver that does not support full-resolution consoles. Examples of drivers like these: ati-drivers and NVidia-drivers.
Kernel configuration
Before we emerge the required packages for uvesafb functionality, we have to configure the kernel properly.
Device Drivers ---> <*> Connector - unified userspace <-> kernelspace linker ---> Graphics support ---> Frame buffer devices ---> [*] Support for frame buffer devices ---> [*] Enable firmware EDID <*> Userspace VESA VGA graphics support
Build the kernel make
from the kernel sources directory (/usr/src/linux
. Do not install the kernel and modules (make install modules_install
). You can choose uvesafb as a module, unlike vesa.
Install required packages
Emerge No results. Klibc has to be compiled against a kernel that includes uvesafb support. This only has to be done once:
root # emerge klibc
No results is the userspace helper that runs x86 code in emulated environment. Uvesafb will not work without v86d. Emerge v86d
:
root # emerge v86d
Back to kernel configuration
Reconfigure the kernel to include /usr/share/v86d/initramfs
as an initramfs source file:
General Setup---> [*] Initial RAM filesystem and RAM disk (initramfs/initrd) support (/usr/share/v86d/initramfs) Initramfs source file(s)
Rebuild the kernel: make and install it, install the modules
Bootloader configuration
If you compiled uvesafb into the kernel (not as a module), you can configure its behavior by editing the {{{1}}}
line in /etc/boot.conf
. Below, some of the more common switches used with uvesafb are explained:
video=uvesafb:<screen y-res>x<screen x-res>-<color depth>
: Tells the kernel that you want to use the uvesafb driver for console output. Also specifies that you will be using uvesafb at a set x-screen resolution, y screen-resolution, and color depth. Set the first part to the size of your screen (in pixels). For example, if I had a 1920x1080 screen and wanted a color depth of 32, I would add the following:video=uvesafb:1920x1080-32
mtrr:x
: X represents the number 0 or 3. This option allows you to set up the memory type range registers for uvesafb. Setting x=0 disables mtrr and setting x=3 enables mtrr. x=3 is the default setting for this switch. mtrr:3 is recommended.
ywrap
: Add support for display panning. Recommended.
For more information regarding these switches, check out http://www.mjmwired.net/kernel/Documentation/fb/uvesafb.txt
Now that you have a basic understanding of a few of the different switches, you can configure your /etc/boot.conf
to allow booting with the uvesafb framebuffer:
/etc/boot.conf
boot {
generate grub
default "Funtoo Linux: uvesafb"
timeout 3
}
"Funtoo Linux: uvesafb" {
kernel bzImage[-v]
params += video=uvesafb:1920x1080-32,mtrr:3,ywrap
}
Realize that the configuration in the above file will not work on every computer. You must change the resolution (and possibly other switches) to best suite your needs.
After you have finished editing your /etc/boot.conf, run the following:
root # boot-update
Finally, reboot your computer so that you can test out uvesafb:
root # reboot