aboutsummaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)AuthorFilesLines
2010-07-15Input: change input handlers to use bool when possibleDmitry Torokhov5-16/+15
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-07-15Input: document the MT event slot protocolHenrik Rydberg1-69/+149
This patch adds documentation for the ABS_MT_SLOT event and gives examples of how to use the event slot protocol. Reviewed-by: Ping Cheng <pingc@wacom.com> Signed-off-by: Henrik Rydberg <rydberg@euromail.se> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-07-15Input: introduce MT event slotsHenrik Rydberg3-43/+129
With the rapidly increasing number of intelligent multi-contact and multi-user devices, the need to send digested, filtered information from a set of different sources within the same device is imminent. This patch adds the concept of slots to the MT protocol. The slots enumerate a set of identified sources, such that all MT events can be passed independently and selectively per identified source. The protocol works like this: Instead of sending a SYN_MT_REPORT event immediately after the contact data, one sends an ABS_MT_SLOT event immediately before the contact data. The input core will only emit events for slots with modified MT events. It is assumed that the same slot is used for the duration of an initiated contact. Acked-by: Ping Cheng <pingc@wacom.com> Acked-by: Chase Douglas <chase.douglas@canonical.com> Acked-by: Rafi Rubin <rafi@seas.upenn.edu> Signed-off-by: Henrik Rydberg <rydberg@euromail.se> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-07-15Input: usbtouchscreen - implement reset_resumeOliver Neukum1-32/+76
This implements reset_resume() by splitting init into allocations of private data structures and device initializations. Device initializations are repeated upon reset_resume. Signed-off-by: Oliver Neukum <oneukum@suse.de> Tested-by: Petr Štetiar <ynezz@true.cz> Tested-by: Ondrej Zary <linux@rainbow-software.org> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-07-15Input: usbtouchscreen - implement runtime power managementOliver Neukum1-3/+24
This implement USB autosuspend while the device is opened for devices that do remote wakeup with a fallback to open/close for those devices that don't. Devices that require the host to constantly poll them are never autosuspended. Signed-off-by: Oliver Neukum <oneukum@suse.de> Tested-by: Petr Štetiar <ynezz@true.cz> Tested-by: Ondrej Zary <linux@rainbow-software.org> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-07-15Input: usbtouchscreen - implement basic suspend/resumeOliver Neukum1-0/+25
This implements basic support for suspend & resume. Signed-off-by: Oliver Neukum <oneukum@suse.de> Tested-by: Petr Štetiar <ynezz@true.cz> Tested-by: Ondrej Zary <linux@rainbow-software.org> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-07-14Input: Add ATMEL QT602240 touchscreen driverJoonyoung Shim4-0/+1452
The chip's full name is AT42QT602240 or ATMXT224. This is a capacitive touchscreen supporting 10-contact multitouch and using I2C interface. Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com> Acked-by: Henrik Rydberg <rydberg@euromail.se> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-07-14Input: fix signedness warning in input_set_keycode()Dmitry Torokhov1-1/+1
The dev->getkeycode() method expects unsigned argument. Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-07-14Input: Add pwm beeper driverLars-Peter Clausen3-0/+211
This patch adds a simple driver which allows to use pwm based beepers (for example piezo elements) as a pcspkr-like device. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-07-13Input: xpad - remove mouse buttons and axes for dance padsChristoph Fritz1-44/+63
Dance pads don't have any axes/sticks, only buttons for directions. For example buttons like left+right will get triggered at once, an axis can't handle this anyway. So this patch adds a module parameter named "sticks_to_null" for unknown devices. A known dance pad makes use of it by changing to a new mapping-option named DANCEPAD_MAP_CONFIG. Other tested devices may follow by adding this mapping-option too. Some buttons of xpad-devices are addressing mouse-buttons instead of gamepad-buttons. This gets fixed too. Signed-off-by: Christoph Fritz <chf.fritz@googlemail.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-07-13Input: atlas_btns - switch to using pr_err() and friendsDmitry Torokhov1-15/+8
This ensures consistent prefixes on all messages emitted by the driver. Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-07-13Input: atlas_btns - fix mixing acpi_status and int for return valueAxel Lin1-8/+6
To improve readability, this patch fixes mixing acpi_status and int for return value. Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-07-13Input: atlas_btns - adds a missing owner field for atlas_acpi_driverAxel Lin1-0/+1
The owner field provides the link between drivers and modules in sysfs. After setting the owner field, we can see which module provides which driver and vice versa by looking at /sys/bus/acpi/drivers/Atlas ACPI/module and /sys/module/atlas_btns/drivers/acpi:Atlas ACPI Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-07-08Input: twl4030-pwrbutton - replace __devinit with __initMarkus Lehtonen1-6/+6
Power button is not hot-pluggable so we can save some memory by using __init. Signed-off-by: Markus Lehtonen <markus.lehtonen@nokia.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-07-04Input: mcs - Add MCS touchkey driverJoonyoung Shim6-27/+289
This adds support for MELPAS MCS5000/MSC5080 touch key controllers. Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-07-03Input: release pressed keys when resuming deviceOliver Neukum1-10/+29
As the kernel has no way to know whether a key was released while the system was asleep, keys need to be reported released as the system is resumed, lest autorepeat set in. Signed-off-by: Oliver Neukum <oneukum@suse.de> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-07-03Input: ads7846 - extend the driver for ads7845 controller supportAnatolij Gustschin1-37/+135
ADS7845 is a controller for 5-wire touch screens and somewhat different from 7846. It requires three serial communications to accomplish one complete conversion. Unlike 7846 it doesn't allow Z1-/Z2- position measurement. The patch extends the ads7846 driver to also support ads7845. The packet struct is extended to contain needed command and conversion buffers. ads7846_rx() and ads7846_rx_val() now differentiate between 7845 and 7846 case. ads7846_probe() is modified to setup ads7845 specific command and conversion messages and to switch ads7845 into power-down mode, since this is needed to be prepared to respond to pendown interrupts. Signed-off-by: Anatolij Gustschin <agust@denx.de> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-07-03Input: ads7846 - do not allow altering platform dataDmitry Torokhov2-17/+20
Tested-by: Anatolij Gustschin <agust@denx.de> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-07-03Input: adxl34 - make enable/disable separate from suspend/resumeDmitry Torokhov4-48/+70
Suspending and resuming the device should be separate from enabling and disabling it through sysfs attribute and thus should not alter ac->disabled flag. [michael.hennerich@analog.com: various fixups] Tested-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-07-03Input: ad7879 - report EV_KEY/BTN_TOUCH eventsMichael Hennerich1-3/+13
Some input events users such as Android require BTN_TOUCH events. Implement EV_KEY/BTN_TOUCH and make sure that the release event is not erroneous scheduled without a preceding valid touch. Avoid duplicated BTN_TOUCH events, even though input core filters them. Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-07-03Input: ad7879 - fix spi word size to 16 bitMichael Hennerich1-0/+8
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-07-03Input: ad7879 - use i2c_smbus_read_i2c_block_data() to lower overheadMichael Hennerich1-1/+4
Avoid additional addressing overhead incurred by word_data transfers. Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-07-03Input: ad7879 - add open and close methodsDmitry Torokhov4-39/+86
Tested-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-07-03Input: ad7879 - split bus logic outMike Frysinger6-415/+484
The ad7879 driver is using the old bus method of only supporting one at a time (I2C or SPI). So refactor it like the other input drivers that support multiple busses simultaneously. Signed-off-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-06-30Input: ad7879 - use threaded IRQDmitry Torokhov1-27/+9
Tested-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-06-30Merge commit 'v2.6.35-rc3' into nextDmitry Torokhov1029-7874/+83540
2010-06-28Input: lm8323 - fix error handling in lm8323_probe()Dan Carpenter1-5/+7
We reuse the "i" variable later on so if we goto fail3 or fail4 then "i" will be set to the wrong thing and cause a crash. Signed-off-by: Dan Carpenter <error27@gmail.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-06-28Input: gpio-keys - add gpiolib debounce supportGrazvydas Ignotas1-5/+14
gpiolib now has debounce support added in .35, so let's make use of it. This allows to use hardware GPIO debouncing on some platforms like OMAP. In case gpiolib debounce setup fails for some GPIO, the driver will fall back to timer based debouncing, which is what it used before. Signed-off-by: Grazvydas Ignotas <notasas@gmail.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-06-28HID - blacklist ET&T TC4UH touchscreen controllerPetr Štetiar2-0/+2
The device is handled by usbtouchscreen driver. Signed-off-by: Petr Štetiar <ynezz@true.cz> Acked-by: Jiri Kosina <jkosina@suse.cz> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-06-28Input: usbtouchscreen - add support for ET&T TC4UM touchscreen controllerPetr Štetiar2-11/+14
This patch adds support for the ET&T TC4UM 4-wire USB touchscreen controller and tries to reuse the bits for TC5UH controller in kernel already. Data interface is same. Tested-by: Roger Pueyo Centelles <rogerpueyo@rogerpueyo.com> Signed-off-by: Petr Štetiar <ynezz@true.cz> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-06-28Input: ads7846 - allow specifying irq trigger type in platform dataAnatolij Gustschin2-1/+5
On some platforms, for example with GPIO interrupts on mpc5121, it is not possible to configure falling edge interrupts. Specifying irq trigger type in platform data structure allows using ads7846 driver on such platforms. Signed-off-by: Anatolij Gustschin <agust@denx.de> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-06-28Input: wacom - add support for DTU2231 and DTU1631Ping Cheng2-0/+45
Add support for the two new devices: DTU2231 and DTU1631. Signed-off-by: Ping Cheng <pingc@wacom.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-06-28Input: wistron_btns - fix a memory leak in wb_module_init error pathAxel Lin1-1/+3
select_keymap() calls copy_keymap() to allocate a memory for keymap. This patch adds a missing kfree(keymap) in wb_module_init error path. Signed-off-by: Axel Lin <axel.lin@gmail.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-06-25Input: adxl34x - add support for ADXL346 orientation sensingMichael Hennerich2-4/+114
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-06-25Input: add driver for ADXL345/346 Digital AccelerometersMichael Hennerich7-0/+1511
This is a driver for the ADXL345/346 Three-Axis Digital Accelerometers. Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Chris Verges <chrisv@cyberswitching.com> Signed-off-by: Luotao Fu <l.fu@pengutronix.de> Signed-off-by: Barry Song <barry.song@analog.com> Signed-off-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-06-24Input: adp5588-keys - support GPI events for ADP5588 devicesXiaolong CHEN2-7/+163
A column or row configured as a GPI can be programmed to be part of the key event table and therefore also capable of generating a key event interrupt. A key event interrupt caused by a GPI follows the same process flow as a key event interrupt caused by a key press. GPIs configured as part of the key event table allow single key switches and other GPI interrupts to be monitored. As part of the event table, GPIs are represented by the decimal value 97 (0x61 or 1100001) through the decimal value 114 (0x72 or 1110010). See table below for GPI event number assignments for rows and columns. GPI Event Number Assignments for Rows Row0 Row1 Row2 Row3 Row4 Row5 Row6 Row7 97 98 99 100 101 102 103 104 GPI Event Number Assignments for Cols Col0 Col1 Col2 Col3 Col4 Col5 Col6 Col7 Col8 Col9 105 106 107 108 109 110 111 112 113 114 Signed-off-by: Xiaolong Chen <xiao-long.chen@motorola.com> Signed-off-by: Yuanbo Ye <yuan-bo.ye@motorola.com> Signed-off-by: Tao Hu <taohu@motorola.com> Acked-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-06-23Input: evdev - never leave the client buffer empty after writeHenrik Rydberg1-3/+7
When the client buffer is very small and wraps around a lot, it may well be that a write increases the head such that head == tail. If this happens between the point where a poll is triggered and the actual data is being read, there will be no data to read. This is confusing to applications, which might end up closing the file. This patch solves the problem by making sure the client buffer is never empty after writing to it. Signed-off-by: Henrik Rydberg <rydberg@euromail.se> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-06-23Input: hid-input - use a larger event buffer for MT devicesHenrik Rydberg1-0/+3
The MT devices produce a lot of data. Tell the underlying input device approximately how many events will be sent per synchronization, to allow for better buffering. The number is a template based on continuously reporting details for each finger on a single hand. Signed-off-by: Henrik Rydberg <rydberg@euromail.se> Acked-by: Jiri Kosina <jkosina@suse.cz> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-06-23Input: bcm5974 - set the average number of events per MT event packetHenrik Rydberg1-0/+2
The MT devices produce a lot of data. Tell the underlying input device approximately how many events will be sent per synchronization, to allow for better buffering. The number is a template based on continuously reporting details for each finger on a single hand. Signed-off-by: Henrik Rydberg <rydberg@euromail.se> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-06-23Input: evdev - use driver hint to compute size of event bufferHenrik Rydberg2-2/+28
Some devices, in particular MT devices, produce a lot of data. This may lead to overflowing of the event queues in evdev driver, which by default are fairly small. Let the drivers hint the average number of events per packet generated by the device, and use that information when computing the buffer size evdev should use for the device. Signed-off-by: Henrik Rydberg <rydberg@euromail.se> Acked-by: Chase Douglas <chase.douglas@canonical.com> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-06-23Input: evdev - convert to dynamic event bufferHenrik Rydberg1-5/+17
Allocate the event buffer dynamically, and prepare to compute the buffer size in a separate function. This patch defines the size computation to be identical to the current code, and does not contain any logical changes. Signed-off-by: Henrik Rydberg <rydberg@euromail.se> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-06-23Input: tps6507x-ts - remove unneeded NULL testJiri Slaby1-3/+0
Stanse found that tsc is dereferenced earlier than checked for being NULL in tps6507x_ts_remove. Remove the test because there is no way for tsc to be NULL there. Signed-off-by: Jiri Slaby <jslaby@suse.cz> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
2010-06-11Linux 2.6.35-rc3Linus Torvalds1-1/+1
2010-06-11Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6Linus Torvalds14-28/+103
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6: wimax/i2400m: fix missing endian correction read in fw loader net8139: fix a race at the end of NAPI pktgen: Fix accuracy of inter-packet delay. pkt_sched: gen_estimator: add a new lock net: deliver skbs on inactive slaves to exact matches ipv6: fix ICMP6_MIB_OUTERRORS r8169: fix mdio_read and update mdio_write according to hw specs gianfar: Revive the driver for eTSEC devices (disable timestamping) caif: fix a couple range checks phylib: Add support for the LXT973 phy. net: Print num_rx_queues imbalance warning only when there are allocated queues
2010-06-11Merge branch 'pm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/suspend-2.6Linus Torvalds3-0/+8
* 'pm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/suspend-2.6: PM / x86: Save/restore MISC_ENABLE register
2010-06-11Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/btrfs-unstableLinus Torvalds9-17/+41
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/btrfs-unstable: Btrfs: The file argument for fsync() is never null Btrfs: handle ERR_PTR from posix_acl_from_xattr() Btrfs: avoid BUG when dropping root and reference in same transaction Btrfs: prohibit a operation of changing acl's mask when noacl mount option used Btrfs: should add a permission check for setfacl Btrfs: btrfs_lookup_dir_item() can return ERR_PTR Btrfs: btrfs_read_fs_root_no_name() returns ERR_PTRs Btrfs: unwind after btrfs_start_transaction() errors Btrfs: btrfs_iget() returns ERR_PTR Btrfs: handle kzalloc() failure in open_ctree() Btrfs: handle error returns from btrfs_lookup_dir_item() Btrfs: Fix BUG_ON for fs converted from extN Btrfs: Fix null dereference in relocation.c Btrfs: fix remap_file_pages error Btrfs: uninitialized data is check_path_shared() Btrfs: fix fallocate regression Btrfs: fix loop device on top of btrfs
2010-06-11Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jbarnes/pci-2.6Linus Torvalds9-130/+17
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jbarnes/pci-2.6: PCI: clear bridge resource range if BIOS assigned bad one PCI: hotplug/cpqphp, fix NULL dereference Revert "PCI: create function symlinks in /sys/bus/pci/slots/N/" PCI: change resource collision messages from KERN_ERR to KERN_INFO
2010-06-11PCI: clear bridge resource range if BIOS assigned bad oneYinghai Lu4-0/+5
Yannick found that video does not work with 2.6.34. The cause of this bug was that the BIOS had assigned the wrong range to the PCI bridge above the video device. Before 2.6.34 the kernel would have shrunk the size of the bridge window, but since d65245c PCI: don't shrink bridge resources the kernel will avoid shrinking BIOS ranges. So zero out the old range if we fail to claim it at boot time; this will cause us to allocate a new range at startup, restoring the 2.6.34 behavior. Fixes regression https://bugzilla.kernel.org/show_bug.cgi?id=16009. Reported-by: Yannick <yannick.roehlly@free.fr> Acked-by: Bjorn Helgaas <bjorn.helgaas@hp.com> Signed-off-by: Yinghai Lu <yinghai@kernel.org> Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
2010-06-11PCI: hotplug/cpqphp, fix NULL dereferenceJiri Slaby1-0/+7
There are devices out there which are PCI Hot-plug controllers with compaq PCI IDs, but are not bridges, hence have pdev->subordinate NULL. But cpqphp expects the pointer to be non-NULL. Add a check to the probe function to avoid oopses like: BUG: unable to handle kernel NULL pointer dereference at 00000050 IP: [<f82e3c41>] cpqhpc_probe+0x951/0x1120 [cpqphp] *pdpt = 0000000033779001 *pde = 0000000000000000 ... The device here was: 00:0b.0 PCI Hot-plug controller [0804]: Compaq Computer Corporation PCI Hotplug Controller [0e11:a0f7] (rev 11) Subsystem: Compaq Computer Corporation Device [0e11:a2f8] Signed-off-by: Jiri Slaby <jslaby@suse.cz> Cc: Greg KH <greg@kroah.com> Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
2010-06-11Revert "PCI: create function symlinks in /sys/bus/pci/slots/N/"Jesse Barnes3-125/+0
This reverts commit 75568f8094eb0333e9c2109b23cbc8b82d318a3c. Since they're just a convenience anyway, remove these symlinks since they're causing duplicate filename errors in the wild. Acked-by: Alex Chiang <achiang@canonical.com> Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>