wtorek, czerwca 09, 2009

Catalyst on Archlinux

Recently I bought myself a laptop - Acer Aspire 5670 - with a ATI Radeon Mobility x1400 graphic card. Although the open-source drivers radeon and radeonhd worked I was still unsatisfied with their performance. So I had to go the long, stony road of installing ATI's proprietary Catalyst driver. Why long and stony? Because ATI dropped support for my graphic card (I think since Catalyst 9.4). As a long-time NVIDIA user on a Linux box I was used to that regardless if it was an old GeForce 3 or an GeForce 9600 GSO that I'm currently using on my pc the drivers worked perfectly. All that TV-out, cloning, TwinView etc. worked on the fly. On this laptop however, everything xorg & drivers related that you could possibly imagine to go wrong, went wrong since the beginning. But finally I managed to make everything to work as I wanted. Here's how I did it. I encountered two major problems so I had to ask myself:
  1. How do I fix the wrong DPI settings?
  2. How do I install a working for my card catalyst driver?
What do I mean by "wrong DPI"? It's better I explain It by showing a screenshot of my desktop. Those really big fonts are actually icon labels. And yes, that thing that takes more then the half of the panel is the clock. Well, actually it's only 1/8 of the clock... I experienced this with both the proprietary and the open-source drivers. To fix this I followed the ArchWiki entry on Xorg. First I modified /etc/X11/xinit/xserverrc so it now looks so: exec /usr/bin/X -nolisten tcp -dpi 96 This didn't help. After adding this two entries to xorg.conf
Section "Device"
 Identifier "Card1"
        ...
        Option   "NoDDC" "true"
        ...
EndSection

Section "Monitor"
        Identifier "Monitor0"
        ...
        DisplaySize 336 210 # 96 DPI @ 1280x800
        ...
EndSection
and restarting X my desktop finally looked normal again. Now for the difficult part - installation of catalyst. There are two packages in the AUR I've downloaded - catalyst-old and catalyst-utils-old. The problem is they depend on xorg-server-1.5, but currently there is a newer version, xorg-server-1.6, in the repositories. I tried to figure out how to downgrade when I stumbled on the Project ARM site. ARM stands for Arch Rollback Machine. It's a mirror that syncs every day with other mirrors but keeps the old packages so a rollback can be made very easy. Package snapshots are ordered by date. I wanted to revert my xorg packages to the state of this years April's Fools Day and because xorg packages are in the extra repo all I had to do was make some temporary changes in /etc/pacman.conf.
#[extra]
# Add your preferred servers here, they will be used first
#Include = /etc/pacman.d/mirrorlist

[extra::2009-4-1]
Server = http://arm.kh.nu/$repo/os/i686/
After that I had to remove the xorg-server package # pacman -Rd xorg-server and synchronize with the new mirror # pacman -Sy xorg-server xf86-input-keyboard xf86-input-mouse xf86-video-v4l After that I restored the original pacman.conf file and added xorg-server to the list of ignored packages
# Pacman won't upgrade packages listed in IgnorePkg and members of IgnoreGroup
IgnorePkg   = xorg-server libgl                                                   
IgnoreGroup = xorg
Then I builded the two packages from AUR and was almost ready to go. Just a quick new Device section entry in /etc/X11/xorg.conf
Section "Device"
        Identifier  "Card0"
        Driver      "radeonhd"
        VendorName  "All"
        BoardName   "All"
EndSection

Section "Device"
        Identifier  "Card1"
        Driver      "fglrx"
        VendorName  "ATI Technologies Inc"
        BoardName   "Radeon Mobility X1400"
        BusID       "PCI:1:0:0"
        Option      "NoDDC" "true"
        Option      "Centermode" "off"
        Option      "VideoOverlay" "on"
        Option      "OpenGLOverlay" "off"
        Option      "OverlayOnCRTC2" "0"
        Option      "PseudoColorVisuals" "off"
        Option      "UseFastTLS" "off"
EndSection

Section "Screen"
        Identifier "Screen0"
        Device     "Card1"
        ...
EndSection
With all that trouble with the drivers I decided to have two Device sections - one for the proprietary and one for the open-source driver - just in case something goes wrong again. Ok, here is a summary of the performance of those 3 drivers: radeon (xf86-video-ati)
[lightnir@chochlik2 ~]$ glxgears
Xlib:  extension "Generic Event Extension" missing on display ":0.0".
Xlib:  extension "Generic Event Extension" missing on display ":0.0".
3990 frames in 5.0 seconds = 797.868 FPS
4216 frames in 5.0 seconds = 843.131 FPS
4220 frames in 5.0 seconds = 843.895 FPS
4437 frames in 5.0 seconds = 887.220 FPS
4117 frames in 5.0 seconds = 823.276 FPS
4162 frames in 5.0 seconds = 832.351 FPS
radeonhd (xf86-video-radeonhd)
[lightnir@chochlik2 ~]$ glxgears
Xlib:  extension "Generic Event Extension" missing on display ":0.0".
493 frames in 5.0 seconds = 98.524 FPS
567 frames in 5.0 seconds = 113.289 FPS
564 frames in 5.0 seconds = 112.653 FPS
561 frames in 5.0 seconds = 112.165 FPS
567 frames in 5.0 seconds = 113.364 FPS
566 frames in 5.0 seconds = 113.013 FPS
583 frames in 5.0 seconds = 116.580 FPS
564 frames in 5.0 seconds = 112.645 FPS
fglrx (catalyst-old)
[lightnir@chochlik2 ~]$ glxgears
Xlib:  extension "Generic Event Extension" missing on display ":0.0".
Xlib:  extension "Generic Event Extension" missing on display ":0.0".
Xlib:  extension "Generic Event Extension" missing on display ":0.0".
Xlib:  extension "Generic Event Extension" missing on display ":0.0".
Xlib:  extension "Generic Event Extension" missing on display ":0.0".
Xlib:  extension "Generic Event Extension" missing on display ":0.0".
Xlib:  extension "Generic Event Extension" missing on display ":0.0".
Running synchronized to the vertical refresh.  The frame rate should be
approximately 1/1103892 the monitor refresh rate.
5782 frames in 5.0 seconds = 1155.215 FPS
5648 frames in 5.0 seconds = 1129.482 FPS
5983 frames in 5.0 seconds = 1196.399 FPS
6010 frames in 5.0 seconds = 1201.413 FPS
6024 frames in 5.0 seconds = 1204.585 FPS
5910 frames in 5.0 seconds = 1181.958 FPS
I also tested the catalyst driver performance with Neverwinter Nights Diamond Edition running in wine. The frame rate was about 25 FPS with full-screen and all graphic options set to max.

2 komentarze:

MVK pisze...

Thanks for Project ARM link! I've looking hard for old input modules to xorg-server 1.5. Yesterday I downgraded xorg-server to 1.5 (i had one in my local archive) and installed catalyst-old. On my radeon-mobile 9600 FGLRX works better then open-sources ati driver. The last one got me problems with compiz. But on FGLRX this work fine.
I hope open-source driver be better then fglrx in some days

Anonimowy pisze...
Ten komentarz został usunięty przez administratora bloga.