summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Input: synaptics - refactor agm packet parsingDaniel Kurtz2011-08-242-6/+19
| | | | | | | | | | | | | | | | | When a Synaptics touchpad is in "AGM" mode, and multiple fingers are detected, the touchpad sends alternating "Advanced Gesture Mode" (AGM) and "Simple Gesture Mode" (SGM) packets. The AGM packets have w=2, and contain reduced resolution finger data. The SGM packets have w={0,1} and contain full resolution finger data. Refactor the parsing of agm packets to its own function, and rename the synaptics_data.mt field to .agm to indicate that it contains the contents of the last agm packet. Signed-off-by: Daniel Kurtz <djkurtz@chromium.org> Acked-by: Chase Douglas <chase.douglas@canonical.com> Acked-by: Henrik Rydberg <rydberg@euromail.se> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: synaptics - refactor y inversionDaniel Kurtz2011-08-241-3/+12
| | | | | | | | | | | | | Synaptics touchpads report increasing y from bottom to top. This is inverted from normal userspace "top of screen is 0" coordinates. Thus, the kernel driver reports inverted y coordinates to userspace. This patch refactors this inversion. Signed-off-by: Daniel Kurtz <djkurtz@chromium.org> Acked-by: Chase Douglas <chase.douglas@canonical.com> Acked-by: Henrik Rydberg <rydberg@euromail.se> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: wacom_w8001 - simplify w8001_removeDmitry Torokhov2011-08-241-4/+4
| | | | | | | | Since touchscreen driver does not handle any events to be sent to the device we can close serio port first and then unregister the input device. Tested-by: Ping Cheng <pingc@wacom.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: wacom_w8001 - implement open and closeDmitry Torokhov2011-08-241-1/+20
| | | | | | | | | Implement open() and close() methods for the input device so that we do not start the device unless there are users listening to the events. Acked-by: Chris Bagwell <chris@cnpbagwell.com> Tested-by: Ping Cheng <pingc@wacom.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: add driver for Bosch Sensortec's BMA150 accelerometerEric Andersson2011-08-094-0/+749
| | | | | | | | Signed-off-by: Albert Zhang <xu.zhang@bosch-sensortec.com> Signed-off-by: Eric Andersson <eric.andersson@unixphere.com> Acked-by: Jonathan Cameron <jic23@cam.ac.uk> Reviewed-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: polldev - immediately poll device upon openingDmitry Torokhov2011-08-091-2/+4
| | | | | | | | | | To allow open/ioctl(EVIOCGABS)/close use pattern for polled devices read the device in context of open() call instead of offloading the first read to a workqueue. This will ensure that once call to open() returns device would have cached reasonably recent axis values that can be retrieved via appropriate ioctl. Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: add support for pm8xxx based vibrator driverAmy Maloche2011-08-033-12/+321
| | | | | | | | | | Add support for pm8xx based vibrator to facilitate haptics. This module uses the ff-memless framework. Signed-off-by: Amy Maloche <amaloche@codeaurora.org> Signed-off-by: Anirudh Ghayal <aghayal@codeaurora.org> Reviewed-by: Wanlong Gao <gaowanlong@cn.fujitsu.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: synaptics - fix reporting of min coordinatesDmitry Torokhov2011-07-251-1/+1
| | | | | | | We were testing wrong bit in the extended capability query. Reported-by: Daniel Kurtz <djkurtz@chromium.org> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: tegra-kbc - enable key autorepeatRakesh Iyer2011-07-251-1/+1
| | | | | | | | To support key repeats, keyboard needs to be setup as an autorepeating device. Signed-off-by: Rakesh Iyer <riyer@nvidia.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: kxtj9 - fix locking typo in kxtj9_set_poll()Dan Carpenter2011-07-201-1/+1
| | | | | | | | According to the comments we want to call mutex_lock() here instead of mutex_unlock(). That makes more sense. Signed-off-by: Dan Carpenter <error27@gmail.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: kxtj9 - fix bug in probe()Dan Carpenter2011-07-201-1/+1
| | | | | | | | We are testing the wrong variable here. I believe tj9->input_dev is always NULL at this point, so probe() will fail. Signed-off-by: Dan Carpenter <error27@gmail.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: intel-mid-touch - remove pointless checking for variable 'found'Axel Lin2011-07-191-10/+5Star
| | | | | | | | The implementation does break from the for loop after we assign 'i' to variable 'found'. Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: hp_sdc - staticize hp_sdc_kicker()Axel Lin2011-07-191-1/+1
| | | | | | | | It's not referenced outside this file so there's no need for it to be in the global name space. Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: pmic8xxx-keypad - fix a leak of the IRQ during init failureAxel Lin2011-07-191-4/+4
| | | | | | | | Make sure we are passing the same cookie in all calls to request_any_context_irq() and free_irq(). Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: cy8ctmg110_ts - set reset_pin and irq_pin from platform dataAxel Lin2011-07-191-0/+2
| | | | | | | | The implementation in cy8ctmg110_probe() does not properly set reset_pin and irq_pin from platform data. Let's fix it. Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: cy8ctmg110_ts - constify i2c_device_id tableAxel Lin2011-07-131-1/+1
| | | | | Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: cy8ctmg110_ts - fix checking return value of i2c_master_sendAxel Lin2011-07-131-2/+2
| | | | | | | i2c_master_send returns negative errno, or else the number of bytes written. Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: lifebook - make dmi callback functions return 1Axel Lin2011-07-131-2/+2
| | | | | | | | | We only care about if there is a successful match from the table (or no match at all), so let's make dmi_check_system return immediately instead of iterating thorough the whole table. Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: atkbd - make dmi callback functions return 1Axel Lin2011-07-131-2/+2
| | | | | | | | | | | | We only care about if there is a successful match from the table (or no match at all), so let's make dmi_check_system return immediately instead of iterating thorough the whole table. Make the dmi callback function return 1 then dmi_check_system will return immediately if we have a successful match. Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: gpio_keys - switch to using SIMPLE_DEV_PM_OPSDmitry Torokhov2011-07-111-8/+3Star
| | | | | | This reduces amount #ifdeds in the code. Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: gpio_keys - add support for device-tree platform dataDavid Jander2011-07-112-16/+168
| | | | | | | | | | | | | This patch enables fetching configuration data, which is normally provided via platform_data, from the device-tree instead. If the device is configured from device-tree data, the platform_data struct is not used, and button data needs to be allocated dynamically. Big part of this patch deals with confining pdata usage to the probe function, to make this possible. Signed-off-by: David Jander <david@protonic.nl> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: aiptek - remove double defineEdwin van Vliet2011-07-111-1/+0Star
| | | | | | | | Constant AIPTEK_TOOL_BUTTON_PEN_MODE was defined twice. Signed-off-by: Edwin van Vliet <edwin@cheatah.nl> Reviewed-by: Jesper Juhl <jj@chaosbits.net> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: synaptics - set minimum coordinates as reported by firmwareDmitry Torokhov2011-07-092-21/+43
| | | | | | | | | Newer Synaptics firmware allows to query minimum coordinates reported by the device, let's use this data. Acked-by: Chase Douglas <chase.douglas@canonical.com> Acked-by: Henrik Rydberg <rydberg@euromail.se> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: synaptics - process button bits in AGM packetsDaniel Kurtz2011-07-071-16/+16
| | | | | | | | | | | | | AGM packets contain valid button bits, too. This patch refactors packet processing to parse button bits in AGM packets. However, they aren't actually used or reported. The point is to more completely process AGM packets, and prepare for future patches that may actually use AGM packet button bits. Signed-off-by: Daniel Kurtz <djkurtz@chromium.org> Acked-by: Chase Douglas <chase.douglas@canonical.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: synaptics - rename set_slot to be more descriptiveDaniel Kurtz2011-07-071-7/+10
| | | | | | Signed-off-by: Daniel Kurtz <djkurtz@chromium.org> Acked-by: Chase Douglas <chase.douglas@canonical.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: synaptics - fuzz position for touchpad with reduced filteringDaniel Kurtz2011-07-072-10/+15
| | | | | | | | | | | Synaptics touchpads indicate via a capability bit when they perform reduced filtering on position data. In such a case, use a non-zero fuzz value. Fuzz = 8 was chosen empirically by observing the raw position data reported by a clickpad indicating it had reduced filtering. Signed-off-by: Daniel Kurtz <djkurtz@chromium.org> Acked-by: Chase Douglas <chase.douglas@canonical.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: synaptics - set resolution for MT_POSITION_X/Y axesDaniel Kurtz2011-07-071-0/+3
| | | | | | | | | Set resolution for MT_POSITION_X and MT_POSITION_Y to match ABS_X and ABS_Y, respectively. Signed-off-by: Daniel Kurtz <djkurtz@chromium.org> Acked-by: Chase Douglas <chase.douglas@canonical.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: wacom - cleanup a return value for the old BambooPing Cheng2011-07-071-1/+1
| | | | | | | | | | | The old code may call input_sync() without sending any other events. While it will be suppressed by the input core not calling it at all is still cheaper. Signed-off-by: Ping Cheng <pingc@wacom.com> Reviewed-by: Chris Bagwell <chris@cnpbagwell.com> Reviewed-by: Henrik Rydberg <rydberg@euromail.se> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: wacom - update Graphire4 and old Bamboo tablet buttonsPing Cheng2011-07-071-11/+8Star
| | | | | | | | | | | Bamboo touch sets BTN_BACK, BTN_FORWARD, BTN_LEFT, and BTN_RIGHT as the default button events for tablet buttons. Change Graphire4 and old Bamboo to the same settings. Signed-off-by: Ping Cheng <pingc@wacom.com> Reviewed-by: Chris Bagwell <chris@cnpbagwell.com> Reviewed-by: Henrik Rydberg <rydberg@euromail.se> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: wacom - add serial number for Graphire4 and old BambooPing Cheng2011-07-071-0/+1
| | | | | | | | | | | | | | With the removal of BTN_TOOL_FINGER for tablet buttons and expresskeys, serial number is needed to distingush if the events were from a regular tool (stylus, eraser, or mouse) or the attribures (buttons, strips, or wheels) on the tablet since there are overlapped events between the tools and the tablet attributes. Signed-off-by: Ping Cheng <pingc@wacom.com> Reviewed-by: Chris Bagwell <chris@cnpbagwell.com> Reviewed-by: Henrik Rydberg <rydberg@euromail.se> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: wacom - remove BTN_TOOL_FINGER for padPing Cheng2011-07-071-11/+0Star
| | | | | | | | | BTN_TOOL_FINGER was designed to indicate a single finger touch. Remove the lines that borrowed this type for expresskeys and tablet buttons. Signed-off-by: Ping Cheng <pingc@wacom.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: add support for Kionix KXTJ9 accelerometerChris Hudson2011-07-074-0/+759
| | | | | Signed-off-by: Chris Hudson <chudson@kionix.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: add guarding parentheses to macrosSimon Budig2011-07-051-3/+3
| | | | | | | | | | | Put parentheses around macro argument uses. This avoids pitfalls for the programmer, where the argument expansion does not give the expected result, for example: ioctl (fd, EVIOCGABS (have_mt ? ABS_MT_POSITION_X : ABS_X), &abs); Signed-off-by: Simon Budig <simon.budig@kernelconcepts.de> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: wm97xx - mark channels which need pen_downWolfram Sang2011-07-053-15/+20
| | | | | | | | | | | | Currently, battery drivers also use poll_sample() provided by the wm97xx-core but this code always checks if the pen is down. Mark the channels which really need this (i.e. for the touchscreen) with the PEN_DOWN bit, and skip the checks otherwise. Now, the battery channels can always be read. Signed-off-by: Wolfram Sang <w.sang@pengutronix.de> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: wm97xx - refactor channel selection in poll_sample()Wolfram Sang2011-07-054-31/+25Star
| | | | | | | | | | | | | | | | The current implementation of poll_sample() has the problem that one of its arguments, the channel to be selected, differs from wm9713 to other variants. This parameter gets passed to the (currently unused) mach-specific functions pre_sample() and post_sample() which thus have to deal with codec-specific differences. Refactor the routine so that the argument to poll_sample() is generic for all codecs and do necessary conversions only in the codec-specific driver. The outcome even uses less code and removes the non-standard use of the PEN_DOWN bit to mark the AUX-channels. Signed-off-by: Wolfram Sang <w.sang@pengutronix.de> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: wm97xx - remove redundant defineWolfram Sang2011-07-055-11/+10Star
| | | | | | Signed-off-by: Wolfram Sang <w.sang@pengutronix.de> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: xen-kbdfront - enable driver for HVM guestsStefano Stabellini2011-07-051-1/+1
| | | | | | Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com> Acked-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: xpad - enable rumble support for XBox360 Wireless ControllersChris Moeller2011-07-051-4/+21
| | | | | | | This patch implements rumble support for XBox360 Wireless Controllers. Signed-off-by: Chris Moeller <kode54@gmail.c> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: atmel_mxt_ts - handle objects with multiple instances correctlyIiro Valkonen2011-07-041-2/+4
| | | | | | | | Handle the objects with multiple instances correctly when the configuration data is loaded. Signed-off-by: Iiro Valkonen <iiro.valkonen@atmel.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: atmel_mxt_ts - update object listIiro Valkonen2011-07-041-82/+102
| | | | | | | | Update the object list to include new objects, and add unique identifiers so we can distinguish between old & new generation of the same object. Signed-off-by: Iiro Valkonen <iiro.valkonen@atmel.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: mpr121 - improve sensibility of touch keyJiejing Zhang2011-06-291-4/+12
| | | | | | | | | | | | | The Quick Charge bit in Electrode conf register should be set in init function. This bit was missed in chip's document, which may cause touch controller charge too slow to generate an interrupt. Also, adjust the default vlaue of touch and release threshold to make touch key more sensitive, this fix touch may not sensitive after setup with plastic case. Signed-off-by: Jiejing Zhang <jiejing.zhang@freescale.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: add a driver to support InvenSense mpu3050 gyroscope chipJoseph Lai2011-06-293-0/+387
| | | | | | | | | | | This driver is registered as an input device. An IRQ is required in this basic driver configuration. Signed-off-by: Joseph Lai <joseph_lai@wistron.com> [Cleaned up PM_RUNTIME defines] Signed-off-by: Alan Cox <alan@linux.intel.com> [dtor@mail.ru: consolidated PM methods, some code rearrangement] Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: update author email for gpio_mouse, at32psif, and atmel-wm97xxHans-Christian Egtvedt2011-06-293-3/+3
| | | | | | | | | This patch updates the email address of the gpio_mouse, at32psif, and atmel-wm97xx drivers supported by me to an email account I will use on a more regular basis in the future. Signed-off-by: Hans-Christian Egtvedt <hans-christian.egtvedt@atmel.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: gpio_keys - fix a memory leakAxel Lin2011-06-291-0/+1
| | | | | Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: ads7846 - cleanup GPIO initializationIgor Grinberg2011-06-271-10/+5Star
| | | | | | | | Use gpio_request_one() instead of multiple gpiolib calls. This also simplifies error handling a bit. Signed-off-by: Igor Grinberg <grinberg@compulab.co.il> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: wacom - add 3 new models - 6A, 6B, and 97Ping Cheng2011-06-271-0/+12
| | | | | | | Tested-by: Alex Tervoort <alex.tervoort@gmail.com> for 6A Signed-off-by: David Foley <favux.is@gmail.com> Signed-off-by: Ping Cheng <pingc@wacom.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: wacom - Wacom Bamboo Pen D4 has 1024 pressure levelsPing Cheng2011-06-271-1/+1
| | | | | | | | D4 has 1024, not 512, pressure levels. Reported-by: David Foley <favux.is@gmail.com> Signed-off-by: Ping Cheng <pingc@wacom.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: gpio_keys - move to late_initcallDavid Jander2011-06-271-1/+1
| | | | | | | | | | | | | Initialize gpio_keys driver at late_initcall level, to give it a chance to work with GPIO expanders that might not be ready yet if we initialize the driver at module_init time. This is strictly a band-aid until there is a better way to specify inter-device dependencies. Signed-off-by: David Jander <david@protonic.nl> Acked-by: Grant Likely <grant.likely@secretlab.ca> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: tnetv107x-ts - fix MODULE_ALIASAxel Lin2011-06-271-1/+1
| | | | | | | Remove the space between "platform:" prefix and the driver name. Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
* Input: tnetv107x-keypad - fix MODULE_ALIASAxel Lin2011-06-271-1/+1
| | | | | | | Remove the space between "platform:" prefix and the driver name. Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>