Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 206509 - x11-base/xorg-server compiled w/ USE=hal crashes and distorts image on dbus/hal restart
Summary: x11-base/xorg-server compiled w/ USE=hal crashes and distorts image on dbus/h...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: High critical (vote)
Assignee: Gentoo X packagers
URL:
Whiteboard:
Keywords: Inclusion
Depends on:
Blocks:
 
Reported: 2008-01-18 10:47 UTC by Sascha Hlusiak
Modified: 2008-12-17 16:48 UTC (History)
6 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Sascha Hlusiak 2008-01-18 10:47:01 UTC
Using xorg-server-1.4.0.90-r1 and using hal to automatically add devices which is working fine.

Just emerged dbus-1.1.4 and right when it was done emerging, my running X-Server crashes horribly. KDM comes up again but the keyboard is not working and the terminals (vt1-vt6) show red lines from top to bottom but no image. I'm using xf86-video-i810 on the 855gm chipset.

The dbus ebuild seems not to reload dbus but I can reproduce that crash by simply running /etc/init.d/dbus restart!

These seem to be two bugs because it crashes and then I can't even recover after the crash and need to reboot.

The /var/log/kdm.log contains this after the crash:

libhal.c 3506 : Error unsubscribing to signals, error=Connection is closed
process 2003: arguments to dbus_connection_get_dispatch_status() were incorrect, assertion "connection != NULL" fail
ed in file dbus-connection.c line 4049.
This is normally a bug in some application using the D-Bus library.
  D-Bus not built with -rdynamic so unable to print a backtrace

Sascha


Reproducible: Always

Steps to Reproduce:
1. Have a running X (probably with hal adding devices enabled)
2. Restart dbus with /etc/init.d/dbus restart
3. See X crashing
Comment 1 Jakub Moc (RETIRED) gentoo-dev 2008-01-18 10:50:34 UTC
Yeah, that's the 'progress'. You'll have to take this upstream, not a Gentoo-specific issue at all, also not specific to any video driver at all (reproducible w/ both nvidia drivers).

As a workaround, you can recompile xorg-server w/ USE="-hal".
Comment 2 Matt Whitlock 2008-01-18 13:39:25 UTC
I had the same weird thing happen.  dbus was in my set of packages that Portage was to be upgrading.  I set that in motion, and when I came back to my machine, it was at the KDM login screen.  I rebooted the machine, and when I logged in after the reboot, some of my keyboard keys are doing strange things.  For example, the Up Arrow key is being interpreted as Print Screen.  Someone upstream really screwed something up.
Comment 3 Matt Whitlock 2008-01-18 14:14:03 UTC
Funny, I went into "KDE Settings > Regional & Accessibility > Keyboard Layout" and unchecked "Enable keyboard layouts", clicked OK, and logged out.  Restarted X and logged back in, and now all my keys are working, even the special ones like XF86Back and XF86AudioPlay.  Go figure.

$ fgrep -i xkb /etc/X11/xorg.conf
[..no output..] (I have no Xkb options specified in my xorg.conf)
(and yet..)
$ setxkbmap -print
xkb_keymap {
        xkb_keycodes  { include "evdev+aliases(qwerty)" };
        xkb_types     { include "complete"      };
        xkb_compat    { include "complete"      };
        xkb_symbols   { include "pc+us+inet(evdev)"     };
        xkb_geometry  { include "pc(pc104)"     };
};
(somehow it automatically activated the inet symbols)

I guess I won't complain again until something else breaks.
Comment 4 Jakub Moc (RETIRED) gentoo-dev 2008-01-18 14:33:43 UTC
Please, do NOT flood this bug with off-topic comments. There are other bug reports about keyboard layout issues w/ HAL, search bugzilla.
Comment 5 Jonathan Heaney 2008-01-18 15:28:01 UTC
I saw exactly the same issue when upgrading dbus last night (with similar log entries), however the OP doesn't make it clear if X works after a reboot - for me here, dbus-1.1.4 renders X unusable after a reboot.  It doesn't appear to even attempt to start (and the xorg and kdm log files do not get updated with any information.  All I get is a blinking cursor when I switch to VT7.

I don't know if dbus-1.1.3 also exhibited this behaviour, as it was only upgraded to that for 24 hours during which time my machine was not rebooted.

Masking dbus-1.1.4 in /etc/portage/package.mask end re-emerging dbus reverts to v1.0.2-r2 - fixes the problems here, X now works OK.
Comment 6 Sascha Hlusiak 2008-01-18 20:22:07 UTC
I did some testing. The crash happens on /etc/init.d/dbus restart. It does NOT crash when doing only /etc/init.d/hald restart.

Unlike said in my first report, Xorg is usable after the crash, just vt1-vt6 is distorted and unusable.
My keyboard did not work anymore after kdm came up again, because X crashed when restarting dbus, which was invoked by a terminal in X. Restarting dbus first stops hal, then stops dbus, then Xorg crashed. So no running dbus, no running hal and no hotplugging of my keyboard (I hotplug the keyboard through hal, but let not hotplug the mice; they are static in xorg.conf).

Xorg.0.log.old does not contain anything related to the crash, just kdm.log contains the lines mentioned in the first post.
Comment 7 Donnie Berkholz (RETIRED) gentoo-dev 2008-01-28 23:06:24 UTC
I just saw a patch go by on xorg-commit, id 975ab11799c819a81da1dfe83505194410dbcb95, so I'll check into it.
Comment 8 Donnie Berkholz (RETIRED) gentoo-dev 2008-05-07 03:52:39 UTC
I've got a local copy of the upstream git 1.4 branch with a few related patches in it. I'll see if I can get them merged upstream.
Comment 9 Donnie Berkholz (RETIRED) gentoo-dev 2008-05-09 07:23:14 UTC
Should be fixed in xorg-server-1.4.0.90-r4, which I expect to rekeyword as soon as a few last patches find their way in.
Comment 10 Christopher Friedt 2008-12-17 04:57:34 UTC
(In reply to comment #9)
> Should be fixed in xorg-server-1.4.0.90-r4, which I expect to rekeyword as soon
> as a few last patches find their way in.
> 

I ran into the same problem with my eee pc 702 (of course, running Gentoo). It seems that I also have the Up -> Print mapping, even with xorg-server-1.4.2 , a US layout and the following use flags:

$ cat /var/db/pkg/x11-base/xorg-server-1.4.2/USE 
dri elibc_glibc hal input_devices_evdev input_devices_keyboard input_devices_mouse input_devices_synaptics kernel_linux sdl userland_GNU video_cards_fglrx video_cards_i810 video_cards_radeon video_cards_vesa video_cards_vga x86 xorg xprint

$ setxkbmap -print
xkb_keymap {
	xkb_keycodes  { include "evdev+aliases(qwerty)"	};
	xkb_types     { include "complete"	};
	xkb_compat    { include "complete"	};
	xkb_symbols   { include "pc+us+inet(evdev)"	};
	xkb_geometry  { include "pc(pc104)"	};
};


xorg.conf
================
...
Section "InputDevice"
    Identifier	"Keyboard1"
    Driver	"kbd"
    Option "AutoRepeat" "500 30"
    Option "XkbRules"	"xorg"
    Option "XkbLayout"	"us"
EndSection
...

However, I also have some good news. With INPUT_DEVICES="-evdev" USE="-hal" I no longer suffered from the same keyboard remapping bugs. If evdev and hal are the root causes for this bug, I would suggest that a warning is added to the ebuild and that the revision is bumped.

In my case, I specifically wanted to use evdev with evtouch for my eGalax touchscreen, but I guess I'll have to wait for a later version (or compile it myself, I guess).
Comment 11 Matt Whitlock 2008-12-17 16:48:28 UTC
(In reply to comment #10)
> I ran into the same problem with my eee pc 702 (of course, running Gentoo). It
> seems that I also have the Up -> Print mapping

Since you're using the evdev keyboard layout, you also need to be using the evdev driver.  Don't use "kbd" anymore; it's obsolete.