diff options
author | James Meyer <james.meyer@operamail.com> | 2010-09-08 07:33:44 (GMT) |
---|---|---|
committer | James Meyer <james.meyer@operamail.com> | 2010-09-08 07:33:44 (GMT) |
commit | 525753e4a1a139e088d8ac120b19fbab6c0aaaa6 (patch) | |
tree | 35cef28abb613da4f58e83f6abbe4bd4cfa244bf /abs/core-testing/hal/handle-input-touchpad.patch | |
parent | 592e3cad43ef12c53f523145d0fd981b54f2a049 (diff) | |
parent | b172f79fadb565ecfbcec9508f9377d8618a4f4c (diff) | |
download | linhes_pkgbuild-525753e4a1a139e088d8ac120b19fbab6c0aaaa6.zip linhes_pkgbuild-525753e4a1a139e088d8ac120b19fbab6c0aaaa6.tar.gz linhes_pkgbuild-525753e4a1a139e088d8ac120b19fbab6c0aaaa6.tar.bz2 |
Merge branch 'HEAD' of ssh://jams@knoppmyth.net/mount/repository/LinHES-PKGBUILD
Diffstat (limited to 'abs/core-testing/hal/handle-input-touchpad.patch')
-rw-r--r-- | abs/core-testing/hal/handle-input-touchpad.patch | 101 |
1 files changed, 101 insertions, 0 deletions
diff --git a/abs/core-testing/hal/handle-input-touchpad.patch b/abs/core-testing/hal/handle-input-touchpad.patch new file mode 100644 index 0000000..9cd6464 --- /dev/null +++ b/abs/core-testing/hal/handle-input-touchpad.patch @@ -0,0 +1,101 @@ +From 6dccf8e3ad181e8f56b1d2a994ec50a1953a1c2d Mon Sep 17 00:00:00 2001 +From: Michael Witten <mfwitten@gmail.com> +Date: Wed, 06 Jan 2010 00:53:17 +0000 +Subject: Policy: handle `input.touchpad' explicitly + +This commit essentially duplicates the policy for: + + <match key="info.capabilities" contains="input.mouse"> + +and then changes `input.mouse' to `input.touchpad'. This +is necessary because in Linus Torvalds's Linux repo: + + git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6.git + +the following commit: + + commit 7105d2ea73e1391b681d0e1212c42f561c64d429 + Author: Dmitry Torokhov <dmitry.torokhov@gmail.com> + Date: Fri Dec 11 23:54:54 2009 -0800 + + Input: ALPS - do not set REL_X/REL_Y capabilities on the touchpad + + Relative events are only reported via secondary device therefore device + associated with the touchpad should not advertise these capabilities. + + Signed-off-by: Dmitry Torokhov <dtor@mail.ru> + +made these few changes: + + diff --git a/drivers/input/mouse/alps.c b/drivers/input/mouse/alps.c + index a3f492a..b03e7e0 100644 + /--- a/drivers/input/mouse/alps.c + /+++ b/drivers/input/mouse/alps.c + /@@ -487,6 +487,17 @@ int alps_init(struct psmouse *psmouse) + if (alps_hw_init(psmouse)) + goto init_fail; + + + /* + + * Undo part of setup done for us by psmouse core since touchpad + + * is not a relative device. + + */ + + __clear_bit(EV_REL, dev1->evbit); + + __clear_bit(REL_X, dev1->relbit); + + __clear_bit(REL_Y, dev1->relbit); + + + + /* + + * Now set up our capabilities. + + */ + dev1->evbit[BIT_WORD(EV_KEY)] |= BIT_MASK(EV_KEY); + dev1->keybit[BIT_WORD(BTN_TOUCH)] |= BIT_MASK(BTN_TOUCH); + dev1->keybit[BIT_WORD(BTN_TOOL_FINGER)] |= BIT_MASK(BTN_TOOL_FINGER); + +so that HAL no longer adds: + + input.mouse + +to an ALPS touchpad's: + + info.capabilities + +so that HAL no longer marks the ALPS touchpad with: + + input.x11_driver = 'evdev' + +because the policy file: + + fdi/policy/10osvendor/10-x11-input.fdi + +doesn't define the policy for: + + <match key="info.capabilities" contains="input.touchpad"> + +which was previous unnecessary because everything used to +be caught by the policy for: + + <match key="info.capabilities" contains="input.mouse"> + +Signed-off-by: Michael Witten <mfwitten@gmail.com> +Signed-off-by: Martin Pitt <martin.pitt@ubuntu.com> +--- +diff --git a/fdi/policy/10osvendor/10-x11-input.fdi b/fdi/policy/10osvendor/10-x11-input.fdi +index cff8fc5..8bbe263 100644 +--- a/fdi/policy/10osvendor/10-x11-input.fdi ++++ b/fdi/policy/10osvendor/10-x11-input.fdi +@@ -16,6 +16,14 @@ + </match> + </match> + ++ <match key="info.capabilities" contains="input.touchpad"> ++ <merge key="input.x11_driver" type="string">mouse</merge> ++ <match key="/org/freedesktop/Hal/devices/computer:system.kernel.name" ++ string="Linux"> ++ <merge key="input.x11_driver" type="string">evdev</merge> ++ </match> ++ </match> ++ + <match key="info.capabilities" contains="input.tablet"> + <match key="/org/freedesktop/Hal/devices/computer:system.kernel.name" + string="Linux"> +-- +cgit v0.8.3-6-g21f6 |