X.Org/Dual Monitors/ATI

From Gentoo Linux Wiki
Jump to: navigation, search


X.Org TOC


[edit] Open-Source 'radeon' Driver

Install the radeon driver, then follow the general X.Org/Dual Monitors guide.


[edit] Proprietary 'ati-drivers' Binary Driver

Warning: This information is probably out of date. Update it!

As of the 8.19.10 ati-drivers release, Xinerama is natively supported inside the official ati-drivers themselves. Here are some tips for getting ATI "Big Desktop", the ATI Xinerama extension, and hardware DRI all working together. This configuration allows auto-detection of the presence of the secondary display.

Newer ati-drivers come with a handy aticonfig script that actually produces a working dual-head setup. This is the quick-and-easy way. Log out of X, backup your xorg.conf and run something akin to the following line:

Warning: currently the --iagp option doesn't exist (I think it was removed in v8.25.18)
aticonfig --initial=dual-head --dtop=horizontal --screen-layout=right --iagp=off -v /etc/init.d/xdm restart

On one setup (amd64), KDE would instantly work with a streched desktop, when the monitors were the same size. On another setup (x86), KDE would only use one screen, when the monitors were of different size. Both systems did NOT use the xinerama flag. On this second system, all other tried window managers (Gnome and Fluxbox) would operate with no problems on both screens. In one occasion with a setup using gnome and monitors of different size, the bigger monitor was not completely filled.

If you would like to avoid butchering your xorg.conf file with aticonfig, here are the sections that will need to be added/modified. Note this example will setup a cloned screen for use with a laptop. To stretch across 2 monitors try Option "DesktopSetup" "horizontal". Also if you have more than one video card the BusID will probably need to be added somewhere.

File: xorg.conf
Section "Monitor"
	Identifier	"Monitor1"
	VendorName	"Generic"
	ModelName	"Flat Panel"
	#HorizSync	31.5 - 90.0
	#VertRefresh	75
	#DisplaySize	314 234
	#DisplaySize	285 214
	DisplaySize	339 271
EndSection

Section "Monitor"
	Identifier	"Monitor2"
	Option		"VendorName"	"ATI Proprietary Driver"
	Option		"ModelName"	"Generic Autodetecting Monitor"
	Option		"DPMS"		"true"
EndSection

Section "Device"
	Identifier	"ATI Graphics Adapter1"
	Driver		"fglrx"
	BoardName	"ATI Radeon Mobility x300"
	Option		"no_accel"		"no"
	Option		"no_dri"		"no"
	Option		"mtrr"			"no"  # disable DRI mtrr mapper, driver has its own code for mtrr
	Option		"MonitorLayout"		"LVDS, AUTO" #"LVDS, NONE" #"AUTO, NONE"
	Option		"IgnoreEDID"		"off"
	Option		"HSync2"		"unspecified" #"31.5 - 90.0"
	Option		"VRefresh2"		"unspecified" #"75"
	Option		"ScreenOverlap"		"0"
	Option		"NoTV"			"yes"
	Option		"TVStandard"		"NTSC-M"
	Option		"TVHSizeAdj"		"0"
	Option		"TVVSizeAdj"		"0"
	Option		"TVHPosAdj"		"0"
	Option		"TVVPosAdj"		"0"
	Option		"TVHStartAdj"		"0"
	Option		"TVColorAdj"		"0"
	Option		"GammaCorrectionI"	"0x00000000"
	Option		"GammaCorrectionII"	"0x00000000"
	Option		"Capabilities"		"0x00000000"
	Option		"VideoOverlay"		"on"
	Option		"OpenGLOverlay"		"off"
	Option		"CenterMode"		"off"
	Option		"PseudoColorVisuals"	"off"
	Option		"Stereo"		"off"
	Option		"StereoSyncEnable"	"1"
	Option		"FSAAEnable"		"no"
	Option		"FSAAScale"		"1"
	Option		"FSAADisableGamma"	"no"
	Option		"FSAACustomizeMSPos"	"no"
	Option		"FSAAMSPosX0"		"0.000000"
	Option		"FSAAMSPosY0"		"0.000000"
	Option		"FSAAMSPosX1"		"0.000000"
	Option		"FSAAMSPosY1"		"0.000000"
	Option		"FSAAMSPosX2"		"0.000000"
	Option		"FSAAMSPosY2"		"0.000000"
	Option		"FSAAMSPosX3"		"0.000000"
	Option		"FSAAMSPosY3"		"0.000000"
	Option		"FSAAMSPosX4"		"0.000000"
	Option		"FSAAMSPosY4"		"0.000000"
	Option		"FSAAMSPosX5"		"0.000000"
	Option		"FSAAMSPosY5"		"0.000000"
	Option		"UseFastTLS"		"0"
	Option		"BlockSignalsOnLock"	"on"
	Option		"UseInternalAGPGART"	"yes"
	Option		"ForceGenericCPU"	"no"
	Option		"DesktopSetup"		"clone" #or horizontal to stretch
	BusID		"PCI:1:0:0"    # vendor=1002, device=5460
EndSection

Section "Device"
	Identifier  "ATI Graphics Adapter2"
	Driver      "fglrx"
	BusID       "PCI:1:0:0"
	Screen      1
EndSection

Section "Screen"
	Identifier	"Screen1"
	#Device		"ATI OSS"
	Device		"ATI Graphics Adapter1"
	Monitor		"Monitor1"
	DefaultDepth	24

	Subsection "Display"
		Depth	8
		Modes	"1280x1024" "1024x768" "800x600" "640x480"
		ViewPort	0 0
	EndSubsection
	Subsection "Display"
		Depth	16
		Modes	"1280x1024" "1024x768" "800x600" "640x480"
		ViewPort	0 0
	EndSubsection
	Subsection "Display"
		Depth	24
		Modes	"1280x1024" "1024x768" "800x600" "640x480"
		ViewPort	0 0
	EndSubsection
EndSection

Section "Screen"
	Identifier	"Screen2"
        Device		"ATI Graphics Adapter2"
        Monitor		"Monitor2"
        DefaultDepth	24
        SubSection "Display"
		Depth	24
		Viewport   0 0
        EndSubSection
EndSection

Section "ServerLayout"
	Identifier	"Simple Layout"
	Screen		"Screen1"	0 0
	#InputDevice	"Mouse1"	"CorePointer"
	InputDevice	"Touchpad1"	"CorePointer"
	InputDevice	"Keyboard1"	"CoreKeyboard"
EndSection

Section "DRI"
	Mode	0666
EndSection

[edit] Troubleshooting fglrx setup

If the aticonfig method does not work, you need to tweak xorg.conf a bit.

  • Make sure your apps are compiled with Xinerama support - ( equery hasuse xinerama )
  • Make sure Xinerama is NOT loaded as a module in xorg.conf. The Ati-drivers will take care of this automatically.
  • Inside the ATI Device section of xorg.conf, check these settings
  • Option "MonitorLayout" "LVDS,AUTO" - This is for a laptop, it sets the first display to be in the internal LCD (LVDS), and to auto-detect the second display.
  • Option "HSync2" "65" - This sets the horizontal sync for the secondary display.
  • Option "VRefresh2" "60" - This sets the refresh rate of the secondary display.
  • Option "Mode2" "1280x1024" - This sets the resolution of the secondary display, by default it'll try to use the identical resolutions on both displays.
  • Option "EnablePrivateBackZ" "yes" - Might help get DRI and Big Desktop to work together.
  • Option "UseInternalAGPGART" "no" - If using the kernel AGP modules, disable the ATI AGP support.

The known options for use within the ATI Device section of xorg.conf are documented here:

This is a community generated man page created from public records, and is also available here via CVS.

  • In dual head mode, you can't move windows between the two screens, as there's no xinerama
  • In big desktop mode (with a single frame buffer), the two screens will be put into the same resolution, or as close to it as the driver can manage (eg 1440x900 and 1156x864)
  • In the 8.28.8 driver, you can use PairMode (Option "PairMode" "WxH+WxH") instead of Mode2 to request a different resolution for the second screen
    • It will still come up in whatever mode it fancies, but you can use xrandr to switch
    • You can only have one pairmode for now
    • You will need to use a Virtual line in your screen if the second screen is larger in any dimension than the first
File: xorg.conf
Section "Device"
        Identifier  "aticonfig-Device[0]"
        Driver      "fglrx"
        Option      "DesktopSetup" "horizontal"
        Option      "PairModes" "1440x900+1280x1024"
EndSection


Section "Screen"
        Identifier "aticonfig-Screen[0]"
        Device     "aticonfig-Device[0]"
        Monitor    "aticonfig-Monitor[0]"
        DefaultDepth     24
        SubSection "Display"
                Viewport   0 0
                #This virtual is for 2 monitors, a 1440x900 next
                # to a 1280x1024
                Virtual   1440 1024
                Depth     24
        EndSubSection
EndSection
Personal tools