个人工具

“UbuntuHelp:RadeonHD”的版本间的差异

来自Ubuntu中文

跳转至: 导航, 搜索
第2行: 第2行:
 
{{Languages|UbuntuHelp:RadeonHD}}
 
{{Languages|UbuntuHelp:RadeonHD}}
 
== Introduction ==
 
== Introduction ==
This document details building the open-source "radeonhd" driver. This shouldn't be necessary unless you're having problems with the open-source "ati/radeon" driver that comes pre-installed with Ubuntu. If you were looking for instructions on installing the proprietary ATI Catalyst/fglrx Linux drivers, see: http://wiki.cchtml.com/index.php/Ubuntu_Jaunty_Installation_Guide
+
This document explains how to build and use the open-source "radeonhd" driver on Ubuntu (for pre-built packages see the PPA link at the end of this guide). '''This shouldn't be necessary... unless''' you're having problems with the open-source "ati/radeon" driver that comes pre-installed with Ubuntu. If you were looking for instructions on installing the proprietary ATI Catalyst/fglrx Linux drivers, see: http://wiki.cchtml.com/index.php/Ubuntu_Jaunty_Installation_Guide
The radeonhd driver, or xf86-video-radeonhd is an X.org video driver for R500 and newer ATI graphics devices. It is being developed by Novell/SuSE for AMD, with the free documentation provided by AMD. At the time of this writing, the radeonhd driver offers accelerated 2D/3D/Xv for R5x0 (X1k cards & 690G IGP) and accelerated 2D/Xv support for R6x0/R7x0 (Radeon HD series). 3D acceleration for RadeonHD cards is under development at the time of this writing.  You can keep track of when acceleration and other features are supported here: http://www.x.org/wiki/RadeonFeature
+
The radeonhd driver, or xf86-video-radeonhd is an X.org video driver for R500 and newer ATI graphics devices. It is being developed by Novell/SuSE for AMD, with the free documentation provided by AMD. At the time of this writing, the radeonhd driver offers accelerated 2D/3D/Xv for R5x0 (X1xxx cards & 690G IGP) and accelerated 2D/Xv support for R6x0/R7x0 (Radeon HD series). 3D acceleration for RadeonHD cards is under development at the time of this writing.  You can keep track of when acceleration and other features are supported here: http://www.x.org/wiki/RadeonFeature
 
== Preparation ==
 
== Preparation ==
 
Previous or current installations of ATI's proprietary Catalyst/fglrx drivers are known to interfere with the installation of the open-source drivers.
 
Previous or current installations of ATI's proprietary Catalyst/fglrx drivers are known to interfere with the installation of the open-source drivers.
If you've installed the proprietary drivers through Ubuntu:
+
If you have installed proprietary drivers downloaded from ATI/AMD's website:
 
<pre><nowiki>
 
<pre><nowiki>
sudo apt-get purge xorg-driver-fglrx fglrx-amdcccle fglrx-kernel-source xorg-driver-fglrx-dev
+
sudo sh /usr/share/ati/fglrx-uninstall.sh
 
</nowiki></pre>
 
</nowiki></pre>
If you've installed proprietary drivers downloaded from ATI/AMD's website:
+
If you've installed the proprietary drivers through Ubuntu (i.e. Synaptic or Jockey/Restricted Hardware Drivers):
 
<pre><nowiki>
 
<pre><nowiki>
sudo sh /usr/share/ati/fglrx-uninstall.sh
+
sudo apt-get purge xorg-driver-fglrx fglrx-amdcccle fglrx-kernel-source xorg-driver-fglrx-dev
 
</nowiki></pre>
 
</nowiki></pre>
To make sure you have the correct version of libGL:
+
To make sure you have the correct version of libGL.so and libglx.so:
 
<pre><nowiki>
 
<pre><nowiki>
sudo apt-get --reinstall install libgl1-mesa-glx
+
sudo apt-get --reinstall install libgl1-mesa-glx xserver-xorg-core
 
</nowiki></pre>
 
</nowiki></pre>
 +
For more information on this topic, see: https://wiki.ubuntu.com/X/Troubleshooting/FglrxInteferesWithRadeonDriver
 
== Prerequisite Packages ==
 
== Prerequisite Packages ==
Using the following commands will get all the packages you'll need:
+
The following command will install all the packages needed:
=== Ubuntu 9.04/Jaunty or 8.10/Intrepid ===
+
 
<pre><nowiki>
 
<pre><nowiki>
sudo apt-get install x11proto* xutils-dev autoconf libltdl7-dev libpciaccess-dev libdrm-dev git-core gawk xorg-dev libgl1-mesa-dev pciutils-dev
+
sudo apt-get build-dep xserver-xorg-video-radeonhd
</nowiki></pre>
+
== Getting DRM Kernel Modules ==
+
'''Notes: The commands in this section are unnecessary for people running Ubuntu 9.04 Jaunty or Radeon X1k/690G users. These commands assume you're running the kernel provided by Ubuntu.'''
+
<pre><nowiki>
+
cd ~/
+
git clone git://anongit.freedesktop.org/mesa/drm
+
cd drm
+
git checkout -b r6xx-r7xx-support origin/r6xx-r7xx-support
+
./autogen.sh
+
cd linux-core
+
make radeon.o drm.o
+
sudo cp drm.ko /lib/modules/`uname -r`/kernel/drivers/gpu/drm/
+
sudo cp radeon.ko /lib/modules/`uname -r`/kernel/drivers/gpu/drm/radeon/
+
 
</nowiki></pre>
 
</nowiki></pre>
 
== Building radeonhd ==
 
== Building radeonhd ==
Note: Make sure you're connected to the internet when running the git command
+
Note: Make sure you are connected to the internet when running git commands
 
<pre><nowiki>
 
<pre><nowiki>
 
cd ~/
 
cd ~/
 
git clone git://anongit.freedesktop.org/git/xorg/driver/xf86-video-radeonhd
 
git clone git://anongit.freedesktop.org/git/xorg/driver/xf86-video-radeonhd
 
cd xf86-video-radeonhd
 
cd xf86-video-radeonhd
 +
./autogen.sh --prefix=/usr
 +
make
 +
sudo make install
 +
</nowiki></pre>
 +
=== Updating radeonhd ===
 +
Check the following link to see if the driver has been updated since you've installed it:
 +
http://cgit.freedesktop.org/xorg/driver/xf86-video-radeonhd/
 +
If so, you can pull the updates and recompile the driver to update it:
 +
<pre><nowiki>
 +
cd ~/xf86-video-radeonhd
 +
git pull
 +
make clean
 
./autogen.sh --prefix=/usr
 
./autogen.sh --prefix=/usr
 
make
 
make
第48行: 第47行:
 
</nowiki></pre>
 
</nowiki></pre>
 
== Configuration ==
 
== Configuration ==
=== Configuring xorg.conf for radeonhd ===
+
=== xorg.conf Basics ===
Open your xorg.conf for editing:
+
Open your xorg.conf for editing in any text editor (gedit is used in this example):
 
<pre><nowiki>
 
<pre><nowiki>
gksudo gedit /etc/X11/xorg.conf
+
gksu gedit /etc/X11/xorg.conf
 
</nowiki></pre>
 
</nowiki></pre>
Now change/add the Driver line in the Device section. You can also add the option for Direct Rendering here.
+
Now change/add the Driver line in the Device section.
 
<pre><nowiki>
 
<pre><nowiki>
 
Section "Device"
 
Section "Device"
...
+
... #Other directives here
 
Driver  "radeonhd"
 
Driver  "radeonhd"
Option  "DRI"
+
Option  "DRI" "on"
        Option  "AccelMethod"  "EXA"
+
 
EndSection
 
EndSection
 
</nowiki></pre>
 
</nowiki></pre>
Also, add this section to give non-root applications access to DRI services
+
=== Compiz ===
 +
Note: Compiz requires 3D hardware acceleration, so it will only work for Radeon X1xxx and 690G-based graphics units at the time of this writing.
 +
Add radeonhd to the driver whitelist for your user:
 
<pre><nowiki>
 
<pre><nowiki>
Section "DRI"
+
mkdir -p $HOME/.config/compiz
Mode        0666
+
echo 'WHITELIST="$WHITELIST radeonhd"' >> $HOME/.config/compiz/compiz-manager
EndSection
+
 
</nowiki></pre>
 
</nowiki></pre>
Save the file and quit. The changes will take place the next time you restart X.
+
This step will be unnecessary in Ubuntu 9.10 and later (https://bugs.launchpad.net/bugs/399577)
=== Configuring Compiz ===
+
=== HDMI Audio ===
Note: Compiz requires 3D acceleration, so it will only work for Radeon X1k and 690G-based graphics units at the time of this writing:
+
By default, HDMI audio is disabled. In the Device section of your xorg.conf, you'll need to add the following lines:
 
<pre><nowiki>
 
<pre><nowiki>
gksudo gedit /usr/bin/compiz
+
Option "Audio" "true"
 +
Option "HDMI" "all"
 
</nowiki></pre>
 
</nowiki></pre>
Now find the WHITELIST= line and add radeonhd so it looks like:
+
To test this, figure out the card and device number of your HDMI device and send a sound there:
 
<pre><nowiki>
 
<pre><nowiki>
WHITELIST="nvidia intel ati radeon i810 fglrx radeonhd"
+
aplay -l
 +
aplay -D plughw:<CARD NUMBER>,<DEVICE NUMBER> <PATH TO SOME SOUND FILE>
 
</nowiki></pre>
 
</nowiki></pre>
== Diagnostic Commands ==
+
For example, if aplay -l returns "card 1: HDMI [HDA ATI HDMI], device 3: ATI HDMI [ATI HDMI]", then:
=== Radeon X1k and RS6x0 ===
+
 
<pre><nowiki>
 
<pre><nowiki>
glxinfo | grep "renderer string"
+
aplay -D plughw:1,3 /usr/share/gnome-power-manager/gpm-critical-power.wav
 
</nowiki></pre>
 
</nowiki></pre>
This command should return a line that looks like "OpenGL renderer string: Mesa DRI R300..." If it returns "software rasterizing" then it would be a good idea to have an expert look through your /var/log/Xorg.0.log file to see what's wrong.
+
Further configuration of ALSA and Pulse``Audio may be required, but that's outside the scope of this document.
=== RadeonHD 2k-4k ===
+
=== Power Management ===
 +
The GPU should automatically drop to low-power mode when the video signal is disabled (i.e. when the monitor turns itself off using DPMS after a specified amount of idle time). You can check/change your DPMS settings on-the-fly with the xset command and you can statically set the appropriate options in xorg.conf. Please read the appropriate man pages (xset and xorg.conf) for more information on that topic. At this time, full dynamic control of clocks and voltages (i.e. ATI Power``Play) is not implemented in the open-source drivers. However, one can force the GPU to low-power mode at all times by adding the following line in the Device section of xorg.conf:
 
<pre><nowiki>
 
<pre><nowiki>
cat /var/log/Xorg.0.log | grep "Direct rendering enabled"
+
Option "ForceLowPowerMode" "true"
 
</nowiki></pre>
 
</nowiki></pre>
This command should return "(II) RADEONHD(0): Direct rendering enabled" if the DRM module loaded properly.
+
Note that this may decrease performance under GPU load.
== Updating The Driver/Source ==
+
== Diagnostic Commands ==
Check the following link to see if the driver has been updated since you've installed it:
+
=== Radeon X1xxx and RS6x0 ===
http://cgit.freedesktop.org/xorg/driver/xf86-video-radeonhd/
+
If so, you can pull the updates and recompile the driver to update it:
+
 
<pre><nowiki>
 
<pre><nowiki>
cd ~/xf86-video-radeonhd
+
glxinfo | grep "renderer string"
git pull
+
./autogen.sh --prefix=/usr
+
make
+
sudo make install
+
 
</nowiki></pre>
 
</nowiki></pre>
 +
This command should return a line that looks like "OpenGL renderer string: Mesa DRI R300..." If it returns "software rasterizing" then it would be a good idea to have an expert look through your /var/log/Xorg.0.log file to see what's wrong.
 +
=== RadeonHD ===
 +
Look through your /var/log/Xorg.0.log and verify EXA and direct rendering are working. AIGLX will probably report that it is using software rasterizing. This is normal for RadeonHD cards at this time.
 
== Pre-built .deb packages ==
 
== Pre-built .deb packages ==
Unofficial test packages updated from git can also be found at https://launchpad.net/~tormodvolden/+archive
+
Unofficial test packages updated from git can be found in the PPA https://launchpad.net/~tormodvolden/+archive
 
== Additional Help ==
 
== Additional Help ==
 
The developers of this driver often respond to technical support requests at: http://www.phoronix.com/forums/forumdisplay.php?f=43
 
The developers of this driver often respond to technical support requests at: http://www.phoronix.com/forums/forumdisplay.php?f=43
 
For IRC, the developers can be found at #radeonhd on freenode.net
 
For IRC, the developers can be found at #radeonhd on freenode.net
 
----
 
----
[[category:CategoryCleanup]] [[category:CategoryHardware]]
+
[[category:CategoryHardware]]
  
 
[[category:UbuntuHelp]]
 
[[category:UbuntuHelp]]

2009年11月17日 (二) 20:27的版本

Introduction

This document explains how to build and use the open-source "radeonhd" driver on Ubuntu (for pre-built packages see the PPA link at the end of this guide). This shouldn't be necessary... unless you're having problems with the open-source "ati/radeon" driver that comes pre-installed with Ubuntu. If you were looking for instructions on installing the proprietary ATI Catalyst/fglrx Linux drivers, see: http://wiki.cchtml.com/index.php/Ubuntu_Jaunty_Installation_Guide The radeonhd driver, or xf86-video-radeonhd is an X.org video driver for R500 and newer ATI graphics devices. It is being developed by Novell/SuSE for AMD, with the free documentation provided by AMD. At the time of this writing, the radeonhd driver offers accelerated 2D/3D/Xv for R5x0 (X1xxx cards & 690G IGP) and accelerated 2D/Xv support for R6x0/R7x0 (Radeon HD series). 3D acceleration for RadeonHD cards is under development at the time of this writing. You can keep track of when acceleration and other features are supported here: http://www.x.org/wiki/RadeonFeature

Preparation

Previous or current installations of ATI's proprietary Catalyst/fglrx drivers are known to interfere with the installation of the open-source drivers. If you have installed proprietary drivers downloaded from ATI/AMD's website:

sudo sh /usr/share/ati/fglrx-uninstall.sh

If you've installed the proprietary drivers through Ubuntu (i.e. Synaptic or Jockey/Restricted Hardware Drivers):

sudo apt-get purge xorg-driver-fglrx fglrx-amdcccle fglrx-kernel-source xorg-driver-fglrx-dev

To make sure you have the correct version of libGL.so and libglx.so:

sudo apt-get --reinstall install libgl1-mesa-glx xserver-xorg-core

For more information on this topic, see: https://wiki.ubuntu.com/X/Troubleshooting/FglrxInteferesWithRadeonDriver

Prerequisite Packages

The following command will install all the packages needed:

sudo apt-get build-dep xserver-xorg-video-radeonhd

Building radeonhd

Note: Make sure you are connected to the internet when running git commands

cd ~/
git clone git://anongit.freedesktop.org/git/xorg/driver/xf86-video-radeonhd
cd xf86-video-radeonhd
./autogen.sh --prefix=/usr
make
sudo make install

Updating radeonhd

Check the following link to see if the driver has been updated since you've installed it: http://cgit.freedesktop.org/xorg/driver/xf86-video-radeonhd/ If so, you can pull the updates and recompile the driver to update it:

cd ~/xf86-video-radeonhd
git pull
make clean
./autogen.sh --prefix=/usr
make
sudo make install

Configuration

xorg.conf Basics

Open your xorg.conf for editing in any text editor (gedit is used in this example):

gksu gedit /etc/X11/xorg.conf

Now change/add the Driver line in the Device section.

Section "Device"
	...	#Other directives here
	Driver   "radeonhd"
	Option   "DRI" "on"
EndSection

Compiz

Note: Compiz requires 3D hardware acceleration, so it will only work for Radeon X1xxx and 690G-based graphics units at the time of this writing. Add radeonhd to the driver whitelist for your user:

mkdir -p $HOME/.config/compiz
echo 'WHITELIST="$WHITELIST radeonhd"' >> $HOME/.config/compiz/compiz-manager

This step will be unnecessary in Ubuntu 9.10 and later (https://bugs.launchpad.net/bugs/399577)

HDMI Audio

By default, HDMI audio is disabled. In the Device section of your xorg.conf, you'll need to add the following lines:

	Option "Audio" "true"
	Option "HDMI" "all"

To test this, figure out the card and device number of your HDMI device and send a sound there:

aplay -l
aplay -D plughw:<CARD NUMBER>,<DEVICE NUMBER> <PATH TO SOME SOUND FILE>

For example, if aplay -l returns "card 1: HDMI [HDA ATI HDMI], device 3: ATI HDMI [ATI HDMI]", then:

aplay -D plughw:1,3 /usr/share/gnome-power-manager/gpm-critical-power.wav

Further configuration of ALSA and Pulse``Audio may be required, but that's outside the scope of this document.

Power Management

The GPU should automatically drop to low-power mode when the video signal is disabled (i.e. when the monitor turns itself off using DPMS after a specified amount of idle time). You can check/change your DPMS settings on-the-fly with the xset command and you can statically set the appropriate options in xorg.conf. Please read the appropriate man pages (xset and xorg.conf) for more information on that topic. At this time, full dynamic control of clocks and voltages (i.e. ATI Power``Play) is not implemented in the open-source drivers. However, one can force the GPU to low-power mode at all times by adding the following line in the Device section of xorg.conf:

	Option "ForceLowPowerMode" "true"

Note that this may decrease performance under GPU load.

Diagnostic Commands

Radeon X1xxx and RS6x0

glxinfo | grep "renderer string"

This command should return a line that looks like "OpenGL renderer string: Mesa DRI R300..." If it returns "software rasterizing" then it would be a good idea to have an expert look through your /var/log/Xorg.0.log file to see what's wrong.

RadeonHD

Look through your /var/log/Xorg.0.log and verify EXA and direct rendering are working. AIGLX will probably report that it is using software rasterizing. This is normal for RadeonHD cards at this time.

Pre-built .deb packages

Unofficial test packages updated from git can be found in the PPA https://launchpad.net/~tormodvolden/+archive

Additional Help

The developers of this driver often respond to technical support requests at: http://www.phoronix.com/forums/forumdisplay.php?f=43 For IRC, the developers can be found at #radeonhd on freenode.net