From ArchWiki
Revision as of 11:12, 5 February 2008 by Patroclo7 (Talk | contribs) (first stub, mostly focused on the interaction with 915resolution)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Tango-document-new.pngThis article is a stub.Tango-document-new.png

Notes: please use the first argument of the template to provide more detailed indications. (Discuss in Talk:Uvesafb#)

A new framebuffer driver has been added to kernel 2.6.24. It has many more features than the standard vesafb, including: 1) proper blanking and hardware suspension after delay; 2) support for custom resolutions as in the system BIOS.

However, it needs a userspace regulating daemon, called v86d. There is a package in the AUR for it, which includes an initpcio HOOK, with which you can use uvesafb with the custom archlinux kernel: the v86d will be included in the initramfs.

If you compile your own kernel, then you can also compile uvesafb into the kernel and run v86d later, e.g. from /etc/rc.local.

Uvesafb and 915resolution

In the following, we address a more complex scenario. Many intel video chipsets for widescreen laptops are known to have a buggish bios, which does not support the main, native resolution of the wide screen! For this reasom, 915resolution was created to patch the bios at boot time and allow the x server to use the widescreen resolution. Nowadays, the xserver is able to do this without the help of 915resolution. However, 915resolution can be combined with uvesafb in order to obtain a widescreen framebuffer, without any need to launch X at all. In this case, we need to load uvesafb after having run 915resolution, so that uvesafb can resort to the proper resolution.

915resolution static

Compile 915 resolution statically (since it is going to be in an initramfs, it can not be linked to external libraries), with the following PKGBUILD:

pkgdesc="A tool to modify the video BIOS of the 800 and 900 series Intel graphics chipsets"
arch=('i686' 'x86_64')
source=(http://www.geocities.com/stomljen/$pkgname-$pkgver.tar.gz 915resolution.rc.d 915resolution.conf.d)
md5sums=('ed287778a53d02c31a7a6a52bc146291' '4a5e9f60ba800883b361c9bb64ee0220'\
build() {
 cd $startdir/src/$pkgname-$pkgver
 export LDFLAGS="-s -static"
 make clean
 make || return 1
 unset LDFLAGS
 install -D -m755 915resolution $startdir/pkg/usr/sbin/915resolution
 install -m755 dump_bios $startdir/pkg/usr/sbin
 install -D -m755 ../915resolution.rc.d $startdir/pkg/etc/rc.d/915resolution
 install -D -m644 ../915resolution.conf.d $startdir/pkg/etc/conf.d/915resolution
 install -D -m644 LICENSE.txt $startdir/pkg/usr/share/licenses/915resolution/LICENSE.txt

915resolution hook

Write an initcpio hook for 915resolution. The following is /lib/initcpio/install/915resolution:

install ()
help ()
 This hook patches the video BIOS for widescreen displays

The following is /lib/initcpio/hooks/915resolution (adapt to your widescreen resolution):

run_hook ()
   msg -n ":: Patching the VBIOS..."
   /usr/sbin/915resolution 5c 1280 800
   msg "done."

Uvesafb hook

Write an hook to load uvesafb. The following is /lib/initcpio/install/uvesafb

install ()
help ()
 echo "This hook loads uvesafb"

The following is /lib/initcpio/hooks/uvesafb:

/sbin/modprobe uvesafb


Install v86d from the AUR

Modify modprobe.conf

Add to /etc/modprobe.conf the options for uvesafb, so that it uses the resolution you have added to the bios with 915resolution:

options uvesafb mode=1280x800-32 scroll=ywrap

Binaries and files in mkinitcpio.conf

In mkinitcpio.conf, leave MODULES empty, and write:

BINARIES="/sbin/modprobe /sbin/v86d"

List the hooks

Add the 915resolution hook and, after it, the uvesafb hook to HOOKS in mkinitcpio.conf. Put them after the hooks of the hard disk and before those for the keymap, the resume from suspension and the filesystems


Regenerate your initcpio, reboot and enjoy your widescreen framebuffer.