Comment 0 for bug 1299002

Revision history for this message
Heikki Berg (heikki-berg) wrote :

This is a bug report against gpu-manager.c in ubuntu-drivers-common.

~/Documents/VC/ubu/ubuntu-drivers-common/share/hybrid$ bzr log
------------------------------------------------------------
revno: 56
tags: 1:0.2.91.1
author: Alberto Milone
committer: Package Import Robot
branch nick: trusty-proposed
timestamp: Fri 2014-03-21 20:03:20 +0100

I'm submitting this now manually due to urgency to 14.04 release as ubuntu-bug crashes too ;(

%sudo aticonfig --adapter=all --initial writes a xorg.conf which uses xorg.conf keywords in "text" fields searched by function
 static int check_vendor_bus_id_xorg_conf(struct device **devices, int cards_n,
                                         unsigned int vendor_id, char *driver)

In line 1072 of gpu-manager.c

"Driver" keyword is found from following lines xorg.conf written by aticonfig
Section "Monitor"
 Identifier "aticonfig-Monitor[0]-0"
 Option "VendorName" "ATI Proprietary Driver"
 Option "ModelName" "Generic Autodetecting Monitor"
 Option "DPMS" "true"
EndSection

Section "Monitor"
 Identifier "aticonfig-Monitor[1]-0"
 Option "VendorName" "ATI Proprietary Driver"
 Option "ModelName" "Generic Autodetecting Monitor"
 Option "DPMS" "true"
EndSection

Line 1119 of gpu-manager.c
            else if ((istrstr(line, "Driver") != NULL) &&
                     (strstr(line, driver) == NULL)) {
                failure = 1;
            }
Looks the xorg keyword "Driver" anywhere in the line and finds "ATI Proprietary Driver", but of course does not find correct drivername "fglrx" from the same line => Keywords should be searched from the beginning of the line, not all over.

Second issue in same function the format "PCI:%d@%d:%d:%d" which is different to format "PCI:%d:%d:%d" used by aticonfig, which causes misdetection of correct BusID in xorg.conf

If routine "check_vendor_bus_id_xorg_conf()" reports "Check failed" completely valid xorg.conf is overwritten by gpu-manager.c in boot.

Quick workaround for users is to correct the xorg.conf after installation of ATI Catalyst proprietary drivers taking these into account.