PDA

View Full Version : 8.40.4 crash on X restart / 2.6.23.1 kernel


mbockol
10-16-2007, 05:47 PM
Hi Folks,

I'm running Debian 4 (etch) on an IBM T42 thinkpad. It's got tne Mobility Radeon 9600 M10 (rv350) video chipset built in.

Two days ago I upgraded the kernel to 2.6.23.1 (from 2.6.19.1 and the 8.32.5 -- which worked fine). I grabbed the 8.40.4 fglrx code from ATI and applied two patches (/forums/showthread.php?t=5675&highlight=patch&page=2) found in these forums. The code builds and I get acceleration as I did before. Cool.

Now the problem. If I quit out of X dmesg reports:

BUG: scheduling while atomic: Xorg/0x00000002/3321
[<c0304acf>] schedule+0x59/0x2cb
[<f8f52be1>] irqmgr_wrap_shutdown+0xe1/0x150 [fglrx]
[<f8f4009f>] firegl_release_helper+0x55f/0x7d0 [fglrx]
[<f8f439fb>] firegl_takedown+0x5b/0xc40 [fglrx]
[<f8f4308f>] firegl_release+0x12f/0x190 [fglrx]
[<f8f3764e>] ip_firegl_release+0xf/0x12 [fglrx]
[<c015421f>] __fput+0x96/0x15e
[<c0151d59>] filp_close+0x48/0x4f
[<c0152e9d>] sys_close+0x74/0xbf
[<c0103cfa>] sysenter_past_esp+0x5f/0x85
=======================

If I then try to restart X (even unloading and reloading the fglrx kernel module) the screen will lock up tight. I can ssh into the box and shut it down, but ... well, I'd like to be able to restart X without rebooting.

This looks a lot like the bug reported here (http://ati.cchtml.com/show_bug.cgi?id=737), but maybe some folks here have an idea what else I can try.

More details. I'm running Xorg 7.1.1 .

LIBGL_DEBUG=verbose fglrxinfo reports:
libGL: XF86DRIGetClientDriverName: 8.40.4 fglrx (screen 0)
libGL: OpenDriver: trying /usr/X11R6/lib/modules/dri/fglrx_dri.so
libGL: XF86DRIGetClientDriverName: 8.40.4 fglrx (screen 0)
drmOpenByBusid: busid is PCI:1:0:0
drmOpenDevice: minor is 0
drmOpenDevice: node name is /dev/dri/card0
drmOpenDevice: open result is 5, (OK)
drmOpenByBusid: drmOpenMinor returns 5
drmOpenByBusid: drmGetBusid reports PCI:1:0:0
Can't open configuration file /etc/drirc: No such file or directory.
Can't open configuration file /home/roue/.drirc: No such file or directory.
display: :0.0 screen: 0
OpenGL vendor string: ATI Technologies Inc.
OpenGL renderer string: ATI MOBILITY RADEON 9600/9700 Series
OpenGL version string: 2.0.6747 (8.40.4)


and my xorg.conf is
# /etc/X11/xorg.conf (xorg X Window System server configuration file)
#
# This file was generated by dexconf, the Debian X Configuration tool, using
# values from the debconf database.
#
# Edit this file with caution, and see the /etc/X11/xorg.conf manual page.
# (Type "man /etc/X11/xorg.conf" at the shell prompt.)
#
# This file is automatically updated on xserver-xorg package upgrades *only*
# if it has not been modified since the last upgrade of the xserver-xorg
# package.
#
# If you have edited this file but would like it to be automatically updated
# again, run the following command:
# sudo dpkg-reconfigure -phigh xserver-xorg

Section "Files"
FontPath "/usr/share/fonts/X11/misc"
FontPath "/usr/X11R6/lib/X11/fonts/misc"
FontPath "/usr/share/fonts/X11/cyrillic"
FontPath "/usr/X11R6/lib/X11/fonts/cyrillic"
FontPath "/usr/share/fonts/X11/100dpi/:unscaled"
FontPath "/usr/X11R6/lib/X11/fonts/100dpi/:unscaled"
FontPath "/usr/share/fonts/X11/75dpi/:unscaled"
FontPath "/usr/X11R6/lib/X11/fonts/75dpi/:unscaled"
FontPath "/usr/share/fonts/X11/Type1"
FontPath "/usr/X11R6/lib/X11/fonts/Type1"
FontPath "/usr/share/fonts/X11/100dpi"
FontPath "/usr/X11R6/lib/X11/fonts/100dpi"
FontPath "/usr/share/fonts/X11/75dpi"
FontPath "/usr/X11R6/lib/X11/fonts/75dpi"
# path to defoma fonts
FontPath "/var/lib/defoma/x-ttcidfont-conf.d/dirs/TrueType"
EndSection

Section "Module"
Load "GLcore"
Load "glx"
Load "dri"
Load "i2c"
Load "bitmap"
Load "ddc"
Load "dri"
Load "extmod"
Load "freetype"
Load "glx"
Load "int10"
Load "vbe"
SubSection "extmod"
Option "omit xfree86-dga"
EndSubSection
EndSection

Section "InputDevice"
Identifier "Generic Keyboard"
Driver "kbd"
Option "CoreKeyboard"
Option "XkbRules" "xorg"
Option "XkbModel" "pc104"
Option "XkbLayout" "us"
EndSection

Section "InputDevice"
Identifier "Configured Mouse"
Driver "mouse"
Option "CorePointer"
Option "Device" "/dev/input/mice"
Option "Protocol" "ImPS/2"
Option "Emulate3Buttons" "true"
EndSection

Section "InputDevice"
Identifier "Synaptics Touchpad"
Driver "synaptics"
Option "SendCoreEvents" "true"
Option "Device" "/dev/psaux"
Option "Protocol" "auto-dev"
Option "HorizScrollDelta" "0"
EndSection

Section "Device"
Identifier "ATI Technologies Inc RV350 [Mobility Radeon 9600 M10]"
Driver "fglrx"
#Driver "radeon"
#Option "NoDDC"
Option "VideoOverlay" "on"
Option "OpenGLOverlay" "off"
Option "UseInternalAGPGART" "no"
EndSection

Section "Monitor"
Identifier "Generic Monitor"
Option "DPMS"
EndSection

Section "Screen"
Identifier "Default Screen"
Device "ATI Technologies Inc RV350 [Mobility Radeon 9600 M10]"
Monitor "Generic Monitor"
DefaultDepth 24
SubSection "Display"
Depth 1
Modes "1400x1050"
EndSubSection
SubSection "Display"
Depth 4
Modes "1400x1050"
EndSubSection
SubSection "Display"
Depth 8
Modes "1400x1050"
EndSubSection
SubSection "Display"
Depth 15
Modes "1400x1050"
EndSubSection
SubSection "Display"
Depth 16
Modes "1400x1050"
EndSubSection
SubSection "Display"
Depth 24
Modes "1400x1050"
EndSubSection
EndSection

Section "ServerLayout"
Identifier "Default Layout"
Screen "Default Screen"
InputDevice "Generic Keyboard"
InputDevice "Configured Mouse"
InputDevice "Synaptics Touchpad"
EndSection

Section "DRI"
Mode 0666
EndSection

# added for 2.6.23.1 and xorg 7 fglrx driver. Should be removed with later releases - mab 10.15.2007
Section "ServerFlags"
Option "AIGLX" "off"
EndSection
Section "Extensions"
Option "Composite" "Disable"
EndSection


The only errors in Xorg.0.log are:
(EE) Failed to load /usr/lib/xorg/modules/extensions/libGLcore.so
(EE) Failed to load module "GLcore" (loader failed, 7)
(EE) Synaptics Touchpad no synaptics touchpad detected and no repeater device
(EE) Synaptics Touchpad Unable to query/initialize Synaptics hardware.
(EE) PreInit failed for input device "Synaptics Touchpad"


Thanks for any help or suggestions.

Matt

mbockol
10-16-2007, 06:26 PM
I screwed up the link to the patches. They're here
http://phoronix.com/showthread.php?t=5675&highlight=patch&page=2 (http://phoronix.com/forums/showthread.php?t=5675&highlight=patch&page=2)

mbockol
10-17-2007, 10:21 AM
In reading about the "scheduling when atomic" bug it seemed to be related to running a preempt kernel. I rebuilt 2.6.23.1 to be non-preempt and the error messages when away (woot!). Unfortunately, they turned out to be a red herring -- X still freezes if I try to restart it.(sigh).

Matt

lone_wolf
10-17-2007, 11:18 PM
I am running OpenSuse 10.2 on a Compaq 6910p. I had to install the 2.6.23.1 kernel in order to get my wireless adapter working.

I was able to get the ATI fglx 8.40.4 latest drivers working. I initially did install both patches that you have listed here or on the link you showed. Which gave me the same results as you.

What I did was only install the "ati-drivers-8.40.4-warnings.patch"

And performed the custom build of the drive from the /lbi/modules/fglrx dir. It did give some warnings but everything worked fine. My fglrxinfo command prints the following now:

display: :0.0 screen: 0
OpenGL vendor string: ATI Technologies Inc.
OpenGL renderer string: ATI Mobility Radeon X2300
OpenGL version string: 2.0.6747 (8.40.4)

I did try the other patch ati-drivers-2.6.23.patch but it did not resolve anything. And combining both the patches was fruitless, as I stated above.

mbockol
10-18-2007, 12:20 AM
What I did was only install the "ati-drivers-8.40.4-warnings.patch"



You mean this patch (http://svn.sabayonlinux.org/filedetails.php?repname=overlay&path=%2Fx11-drivers%2Fati-drivers%2Ffiles%2Fati-drivers-8.40.4-warnings.patch) specifically, right?

When I try to build after applying just that patch I get:

afterthought:/home/roue/soft/system/ati/8.40/common/lib/modules/fglrx/build_mod# patch -i /home/roue/soft/system/ati/patches/ati-drivers-8.40.4-warnings.patch-2
patching file firegl_public.c
Hunk #3 FAILED at 1884.
Hunk #7 FAILED at 4352.
2 out of 9 hunks FAILED -- saving rejects to file firegl_public.c.rej
afterthought:/home/roue/soft/system/ati/8.40/common/lib/modules/fglrx/build_mod# sh make.sh
ATI module generator V 2.0
==========================
initializing...
cleaning...
patching 'highmem.h'...
assuming new VMA API since we do have kernel 2.6.x...
Assuming default VMAP API
Assuming default munmap API
doing Makefile based build for kernel 2.6.x and higher
make -C /lib/modules/2.6.23.1/build SUBDIRS=/home/roue/soft/system/ati/8.40/common/lib/modules/fglrx/build_mod/2.6.x modules
make[1]: Entering directory `/usr/src/linux-2.6.23.1'
CC [M] /home/roue/soft/system/ati/8.40/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.o
/home/roue/soft/system/ati/8.40/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c: In function ‘__ke_check_pci’:
/home/roue/soft/system/ati/8.40/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:1858: warning: ‘pci_find_slot’ is deprecated (declared at include/linux/pci.h:481)
/home/roue/soft/system/ati/8.40/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c: In function ‘__ke_pci_find_device’:
/home/roue/soft/system/ati/8.40/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:1887: warning: ‘pci_find_device’ is deprecated (declared at include/linux/pci.h:480)
/home/roue/soft/system/ati/8.40/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c: In function ‘__ke_vm_test_and_clear_dirty’:
/home/roue/soft/system/ati/8.40/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:2412: error: implicit declaration of function ‘ptep_test_and_clear_dirty’
/home/roue/soft/system/ati/8.40/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c: In function ‘__ke_pci_find_slot’:
/home/roue/soft/system/ati/8.40/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:2720: warning: ‘pci_find_slot’ is deprecated (declared at include/linux/pci.h:481)
/home/roue/soft/system/ati/8.40/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c: In function ‘__ke_pte_phys_addr_str’:
/home/roue/soft/system/ati/8.40/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:3402: error: implicit declaration of function ‘pte_read’
/home/roue/soft/system/ati/8.40/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:3404: error: implicit declaration of function ‘pte_exec’
/home/roue/soft/system/ati/8.40/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c: In function ‘KAS_SlabCache_Initialize’:
/home/roue/soft/system/ati/8.40/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:5351: error: too many arguments to function ‘kmem_cache_create’
make[2]: *** [/home/roue/soft/system/ati/8.40/common/lib/modules/fglrx/build_mod/2.6.x/firegl_public.o] Error 1
make[1]: *** [_module_/home/roue/soft/system/ati/8.40/common/lib/modules/fglrx/build_mod/2.6.x] Error 2
make[1]: Leaving directory `/usr/src/linux-2.6.23.1'
make: *** [kmod_build] Error 2
build failed with return value 2

Do I have the right one? Could you post a link to the one you used please?

Thanks,
Matt

lone_wolf
10-19-2007, 12:10 PM
Sorry, about the lateness of this replay.

Anyway, let me validate what I did.

mbockol
10-19-2007, 11:25 PM
Sorry, about the lateness of this replay.

Anyway, let me validate what I did.

Thanks, I appreciate it. My system works for the most part (X only crashed once in the first run -- it crashes every time on the second). I'm eager to get it stable again.

linuxhansl
10-20-2007, 01:38 AM
Hi Folks,

I'm running Debian 4 (etch) on an IBM T42 thinkpad. It's got tne Mobility Radeon 9600 M10 (rv350) video chipset built in.



I have the same chip.
This happens for me in all driver versions starting with 8.39.4 (i.e. 8.39.4, 8.40.4, and 8.41.7) regardless of the Kernel version.
I have found no way around this.

Kano
10-20-2007, 01:48 AM
How about using the default driver? 9600 is not really fast.

mbockol
10-20-2007, 08:34 AM
How about using the default driver? 9600 is not really fast.

I build a custom kernel and the r350 dri module provided in the glu/glut deb packages have symbols that don't match up. If that doesn't load I can't even play a simple video. I've looked into rebulding r350, but so far it looks like I'd have to rebuild a whole slew of packages (most of X), but I haven't really tried yet.

Kano
10-20-2007, 08:40 AM
You have to uninstall fglrx completely. When you used the standard installer use:

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

mbockol
10-20-2007, 10:26 AM
You have to uninstall fglrx completely. When you used the standard installer use:

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


I'm not using the installer since the fglrx.ko build fails unless the firegl_public.c code is first patched.

linuxhansl's note helped alot though. I down graded to 8.38.6 and rebuilt the module. Everything is working fine again -- no freeze on restarting of X and GL is accelerated.

I'll try 8.42 when it's released. By this point I've gotten really good at building everything from scratch :)

Thanks for your help, guys.

Matt

lone_wolf
10-23-2007, 07:40 PM
I am upgrading my distro to opensuse 10.3. I have other issue with the 2.6.23.1 kernel on my existing system. So I will see how that goes.

Also for the record my install does not appear to be entirely stable. on logoff x sometimes crash. If certain screen savers are active the system will lockup and require a hard reboot.

yelo3
10-23-2007, 08:28 PM
I have ubuntu 7.10 and fglrx 8.42. X crashes in my system too (I have a mobility 9700)
this problem might be only related to our old hardware! is there a way to notify this to ati? or to have additional information (error messages)?