Intel GMA

From Gentoo Linux Wiki

Jump to: navigation, search

This guide is about Intel's onboard graphic adapter called 'Graphic Media Accelerator'.

Contents

[edit] X11 Configuration

If you find yourself needing to tell X11 to use the intel driver, set Driver to "intel" in /etc/X11/xorg.conf as in the example below,

File: /etc/X11/xorg.conf
...
Section "Device"
        Identifier           "My Intel Video Card"
        Driver "intel"
EndSection
...

For further options see the intel man pages,

man intel

[edit] Troubleshooting

[edit] i810 and intel Naming

Since 22 Oct 2008, Gentoo switched all ebuilds to the upstream naming: x11-drivers/xf86-video-intel. The ebuild xf86-video-i810 no longer exists. To switch, set the VIDEO_CARDS variable to intel in your /etc/make.conf. See VIDEO_CARDS for further instructions.

[edit] Kernel Modesetting

Warning: Make sure you disable framebuffer drivers in Device Drivers ---> Graphics support ---> Support for frame buffer devices, like intelfb, vesafb or uvesafb. KMS won't work with them and you'll end up with a black console screen or possibly other graphical artifacts.

You will need >=sys-kernel/gentoo-sources-2.6.29, >=x11-base/xorg-server-1.6 and >=x11-drivers/xf86-video-intel-2.6.1 for Kernel Mode Settings to work. Recommended software versions: >=kernel-2.6.31, >=x11-base/xorg-server-1.6 and >=x11-drivers/xf86-video-intel-2.8.0. Better yet to use versions listed in the latest Intel graphics package (2009Q3).

Note: Due to a bug in the kernel you'll need to disable PAE(CONFIG_HIGHMEM64G). This is fixed in >=sys-kernel/gentoo-sources-2.6.31-r1.

In addition to Intel 440LX/BX/GX, I8xx and E7x05 chipset support and i915 driver, you should enable Enable modesetting on intel by default.

Linux Kernel Configuration: Enableing Intel KMS
Device Drivers  --->
    Graphics support  --->
        ...
        <*> Direct Rendering Manager (XFree86 4.1.0 and higher DRI support)  --->
            <*>   Intel 830M, 845G, 852GM, 855GM, 865G (i915 driver)  --->
                  <*> i915 driver
                    [*] Enable modesetting on intel by default

(Re)Compile and install to your new kernel. If you don't set Enable modesetting on intel by default you will need to pass i915.modeset=1 to the kernel when you boot. You must use >=x11-drivers/xf86-video-intel-2.6.1 when KMS is enabled for the X11 server to work. An example using GRUB where i915.modeset=1 gets passed to the kernel,

File: /boot/grub/grub.conf
title Example Linux
root (0,0)
kernel /example-kernel-2.6.29 root=/dev/root i915.modeset=1

Also edit your /etc/X11/xorg.conf and set AccelMethod method to UXA.

File: /etc/X11/xorg.conf
...
Section "Device"
    Driver "intel"
    Option "AccelMethod"   "UXA"
    Option "Tiling"        "False"
...
EndSection
...

If you use sys-kernel/gentoo-sources-2.6.32 you can set the desired console resolution with the video= kernel parameter(i.e video=1024x768@60). Read the commit log for further instructions. This also helps when KMS auto detection breaks on some mode from a noname LCD TV EDID and you get a black screen instead of console. Now you can force a resolution that you know your screen can show.

[edit] KDM Freeze

If your system freezes when logging out and you use kdm, add TerminateServer=true to [X-YOUR_DISPLAY-Core] section (or to [X-*-Core] section for all displays) in /usr/share/config/kdm/kdmrc. This should be fixed in x11-drivers/xf86-video-intel-2.9.0.

[edit] VT switching with Framebuffer

With kernel 2.6.30-gentoo-r4 the VT might show the wrong resolution and after starting X, switching to the VT might not work. Solve this by setting CONFIG_FRAMEBUFFER_CONSOLE_DETECT_PRIMARY=y in your kernel config. Adding fbcon=map:1 to the kernel command line as described in this thread [1] might work, too.

[edit] 2D Performance

[edit] >=xorg-server-1.6 and UXA

UXA is based on EXA and uses GEM. UXA should give best performance, but it works only with >=x11-base/xorg-server-1.6 (for UXA support), >=sys-kernel/gentoo-sources-2.6.29 (for GEM) and >=x11-drivers/xf86-video-intel-2.6.1 (for UXA acceleration). To enable UXA, edit your /etc/X11/xorg.conf and set AccelMethod method to UXA.

File: /etc/X11/xorg.conf
...
Section "Device"
    Driver "intel"
    Option "AccelMethod"   "UXA"
...
EndSection
...

[edit] <xorg-server-1.6 and EXA

EXA is best 2D acceleration method available in <x11-base/xorg-server-1.6. EXA enabled by default if it is available. In some situations 2D performance can be improved, tuning the "MigrationHeuristic" parameter (man exa). This includes scrolling performance (Firefox, Terminal).

File: /etc/X11/xorg.conf
...
Section "Device"
    Driver "intel"
    Option "AccelMethod"          "EXA"
    Option "MigrationHeuristic"   "greedy"
...
EndSection
...

[edit] TV-Out

The TV is just another screen to Xorg. So it can be configured like another monitor.

By default the TV format is set to NTSC. If you want to change it e.g. to PAL, add this to your /etc/X11/xorg.conf:

File: /etc/X11/xorg.conf
Section "Monitor"
        Identifier  "TV"
        Option      "TV Format" "PAL"
EndSection

Section "Device"
        ...
        Option      "Monitor-TV"   "TV"
        ...
EndSection

[edit] Mode Lines

See the Modelines article.

[edit] Calculating a value for VideoRam option

On 82852/855GM Integrated Graphics Device (rev 02), and on a number of more recent devices an increase to 2D/3D performance can be achieved by explicitly setting the amount of video memory. There seems to be a bug in Intel video driver, and I think that it shows itself only on systems with two DDR modules onboard.

Fix me: What bug? Link?

To set video memory size you should use the VideoRam device option, like this:

File: /etc/X11/xorg.conf
...
Section "Device"
 ...
 VideoRam    130560
 ...
EndSection
...

The value is in KB. To calculate it please follow the next steps:

1. Issue

lspci -vv

and look for the "VGA compatible controller" section, particularly the lines referring its memory, in my case they are:

Region 0: Memory at f0000000 (32-bit, prefetchable) [size=128M]
Region 1: Memory at feb80000 (32-bit, non-prefetchable) [size=512K]

2. Subtract non-prefetchable from prefetchable, but keep in mind that prefetchable needs to be converted from MB to KB For example in my case 128M * 1024 = 131072K, so: 131072 - 512 = 130560

[edit] Links

Personal tools
In other languages