XorgHalsectomy

Differences between revisions 1 and 2
Revision 1 as of 2009-11-25 09:50:17
Size: 1252
Editor: pD9EB5127
Comment:
Revision 2 as of 2009-11-25 10:22:42
Size: 3258
Editor: pD9EB5127
Comment:
Deletions are marked like this. Additions are marked like this.
Line 7: Line 7:
In our vendetta to move away from hal, handling X.org input devices is one of the last items. (See https://wiki.ubuntu.com/Halsectomy). In our vendetta to move away from hal, handling X.org input devices is one of the last items.
Line 15: Line 15:
This should cover the _why_: why is this change being proposed, what justifies it, where we see this justified.

== User stories ==

== Assumptions ==
Hal is being [[https://wiki.ubuntu.com/Halsectomy|deprecated]] and is not
maintained upstream any more. It has a lot of design and maintenance problems,
takes extra time on boot, and most things in Ubuntu's default installation do
not use it any more. Applications should use udev directly nowadays, which also
has all the information about devices, and similar customization mechanisms
(through udev rules).
Line 23: Line 24:
You can have subsections that better describe specific parts of the issue.  * Switch X.org to detect input devices from udev instead of hal.
 * Create udev rules to set proper attributes (driver, keyboard layout, touchpad quirks, etc.) to input devices, corresponding to the current hal fdi files.
 * Upgrade to new wacom tablet driver which [[http://lists.x.org/archives/xorg-devel/2009-October/002603.html|does not rely on faking multi-device devices]] in hal
 * Test other less common input devices (like touch screens); drivers which rely on an one-to-one correspondence to physical input/eventX devices should just require fdi → udev rules adaptions
 * If there are insurmountable regressions, make the call before beta-1 whether to keep this, or revert to hal
Line 27: Line 32:
This section should describe a plan of action (the "how") to implement the changes discussed. Could include subsections like: === X.org ===
Line 29: Line 34:
=== UI Changes === Julian Cristau, an X.org Debian maintainer, created a
[[http://cgit.freedesktop.org/~jcristau/xserver/|branch]] for using udev for
input device detection, and
[[http://thread.gmane.org/gmane.comp.freedesktop.xorg.devel/2108|discussed it
upstream]]. It now became an official 1.8 goal, and the branch was generally
well received.
Line 31: Line 41:
Should cover changes required to the UI, or specific UI that is required to implement this We need to backport this branch to 1.7, which is the planned X.org server
version for Lucid.
Line 33: Line 44:
=== Code Changes === === udev rules ===
Line 35: Line 46:
Code changes should include an overview of what needs to change, and in some cases even the specific details.  * '''Keyboards''': The main thing that needs to be configured here is the keyboard layout/model/variant/options. This was previously done with `/usr/share/hal/fdi/policy/10osvendor/10-x11-input.fdi` and `/usr/lib/hal/debian-setup-keyboard`. MartinPitt wrote an [[http://people.canonical.com/~pitti/tmp/65-xorg-evdev.rules|udev rule]] to replace those and use -evdev by default for all input devices and apply the configured system keyboard layout. Later udev rules can then overwrite the driver for particular devices (similar to what happened with hal).
Line 37: Line 48:
=== Migration ===  * '''Mice''': Real mice do not generally need configuration and should work with -evdev without any special udev rules. There were no specific hal fdi rules either.
Line 39: Line 50:
Include:
 * data migration, if any
 * redirects from old URLs to new ones, if any
 * how users will be pointed to the new way of doing things, if necessary.
 * '''synaptics touchpads:''': These need to be identified as such, and switched to use the `synaptics` driver. On some models they also need particular quirks applied. MartinPitt wrote [[http://people.canonical.com/~pitti/tmp/66-xorg-synaptics.rules|udev rules]] for those which correspond to the hal fdi files.

 * '''wacom''': The latest upstream version dropped the requirement for faking multiple devices in hal with fdi files and instead does the detection all by itself. We need to upgrade to that version, and test it.

Summary

In our vendetta to move away from hal, handling X.org input devices is one of the last items.

Release Note

TODO when spec is beta.

Rationale

Hal is being deprecated and is not maintained upstream any more. It has a lot of design and maintenance problems, takes extra time on boot, and most things in Ubuntu's default installation do not use it any more. Applications should use udev directly nowadays, which also has all the information about devices, and similar customization mechanisms (through udev rules).

Design

  • Switch X.org to detect input devices from udev instead of hal.
  • Create udev rules to set proper attributes (driver, keyboard layout, touchpad quirks, etc.) to input devices, corresponding to the current hal fdi files.
  • Upgrade to new wacom tablet driver which does not rely on faking multi-device devices in hal

  • Test other less common input devices (like touch screens); drivers which rely on an one-to-one correspondence to physical input/eventX devices should just require fdi → udev rules adaptions
  • If there are insurmountable regressions, make the call before beta-1 whether to keep this, or revert to hal

Implementation

X.org

Julian Cristau, an X.org Debian maintainer, created a branch for using udev for input device detection, and [[http://thread.gmane.org/gmane.comp.freedesktop.xorg.devel/2108|discussed it upstream]]. It now became an official 1.8 goal, and the branch was generally well received.

We need to backport this branch to 1.7, which is the planned X.org server version for Lucid.

udev rules

  • Keyboards: The main thing that needs to be configured here is the keyboard layout/model/variant/options. This was previously done with /usr/share/hal/fdi/policy/10osvendor/10-x11-input.fdi and /usr/lib/hal/debian-setup-keyboard. MartinPitt wrote an udev rule to replace those and use -evdev by default for all input devices and apply the configured system keyboard layout. Later udev rules can then overwrite the driver for particular devices (similar to what happened with hal).

  • Mice: Real mice do not generally need configuration and should work with -evdev without any special udev rules. There were no specific hal fdi rules either.

  • synaptics touchpads:: These need to be identified as such, and switched to use the synaptics driver. On some models they also need particular quirks applied. MartinPitt wrote udev rules for those which correspond to the hal fdi files.

  • wacom: The latest upstream version dropped the requirement for faking multiple devices in hal with fdi files and instead does the detection all by itself. We need to upgrade to that version, and test it.

Test/Demo Plan

TODO when spec is beta.


CategorySpec

DesktopTeam/Specs/Lucid/XorgHalsectomy (last edited 2009-11-26 14:14:01 by e180071123)