Re: [PATCH v2] HID: wacom: Call 'wacom_query_tablet_data' only after 'hid_hw_start'

2015-11-05 Thread Jiri Kosina
On Tue, 3 Nov 2015, Jason Gerecke wrote: > When connecting the Cintiq Companion 2 as an external tablet (i.e., using > it in "hybrid" mode) it has been seen to cause the kernel of the machine > it is connected to to Oops. The cause has been traced to us attempting to > switch the tablet's mode

[PATCH] usbhid: discarded events don't abort idleness

2015-11-05 Thread Oliver Neukum
If an event is discarded the device stays idle. Just reverse the order of check and marking busy. Signed-off-by: Oliver Neukum --- drivers/hid/usbhid/hid-core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/hid/usbhid/hid-core.c

Re: [PATCH] HID: hid-gfrm: avoid warning for input_configured API change

2015-11-05 Thread Dmitry Torokhov
On Wed, Nov 04, 2015 at 10:32:24AM +0100, Jiri Kosina wrote: > On Tue, 3 Nov 2015, Dmitry Torokhov wrote: > > > > > The input_configured callback was recently changed to return > > > > an 'int', but the newly added driver uses the old API: > > > > > > > > drivers/hid/hid-gfrm.c:151:22: warning:

[PATCH 03/26] Input: synaptics-rmi4 - explicitly request polling when needed

2015-11-05 Thread Andrew Duggan
From: Benjamin Tissoires Host Notify does not work with neither IRQ nor polling. Allow a RMI4 driver to request or not polling depending on the attn_gpio. When neither the internal IRQ or polling systems are used, the transport driver can call

[PATCH 01/26] Input: synaptics-rmi4 - embed the function modules in rmi_core

2015-11-05 Thread Andrew Duggan
From: Benjamin Tissoires the function modules can not be auto-loaded by udev. So at boot, the functions are not there and the device is not properly populated. Force the functions to be embedded in rmi_core so that when the touchpad is there, the functions are

[PATCH 20/26] Input: synaptics-rmi4: Create common functions for 2D sensors

2015-11-05 Thread Andrew Duggan
RMI4 defines two functions for 2D sensors. This patch moves some of the code which is shared between the two functions into a new file to avoid duplicating the code on rmi_f11.c and rmi_f12.c. Signed-off-by: Andrew Duggan --- .../bindings/input/rmi4/rmi_2d_sensor.txt

[PATCH 22/26] Input: synaptics-rmi4 - Add F30 support

2015-11-05 Thread Andrew Duggan
From: Benjamin Tissoires RMI4 Function 0x30 provides support for GPIOs, LEDs and mechanical buttons. In particular, the mechanical button support is used in an increasing number of touchpads. [BT] cured the code to rely only on the unified input node created by

[PATCH 18/26] Input: synaptics-rmi4: Add SPI transport driver

2015-11-05 Thread Andrew Duggan
Add a transport driver for devices using RMI4 over SPI. Signed-off-by: Andrew Duggan --- .../devicetree/bindings/input/rmi4/rmi_spi.txt | 57 +++ drivers/input/rmi4/Kconfig | 9 + drivers/input/rmi4/Makefile| 1 +

[PATCH 21/26] Input: synaptics-rmi4: Add support for F12

2015-11-05 Thread Andrew Duggan
Function 12 implements 2D touch position sensor for newer Synaptics touch devices. It replaces F11 and no device will contain both functions. Signed-off-by: Andrew Duggan --- drivers/input/rmi4/Kconfig | 10 + drivers/input/rmi4/Makefile | 1 +

[PATCH 04/26] Input: synaptics-rmi4 - prevent oopses when irq arrives while the device is not bound

2015-11-05 Thread Andrew Duggan
From: Benjamin Tissoires If the device has been registered but is not populated, we should not process any incoming interrupt. Make sure the pointers we are following are valid. Signed-off-by: Benjamin Tissoires Tested-by: Andrew

[PATCH 01/26] Input: synaptics-rmi4 - embed the function modules in rmi_core

2015-11-05 Thread Andrew Duggan
From: Benjamin Tissoires the function modules can not be auto-loaded by udev. So at boot, the functions are not there and the device is not properly populated. Force the functions to be embedded in rmi_core so that when the touchpad is there, the functions are

[PATCH 02/26] Input: synaptics-rmi4 - add a common input device in rmi_driver

2015-11-05 Thread Andrew Duggan
From: Benjamin Tissoires When .unified_input is set to true in the platform data, the functions should rely on the common input node created by rmi_driver to forward events instead of having their own input node. This node is named "Synaptics PRODUCT_ID" to be

[PATCH 25/26] Input: synaptics-rmi4: remove sensor_name in platform data

2015-11-05 Thread Andrew Duggan
The platform data contained a sensor_name string which was used in debug logs to identify the device. But, the logs already contain enough information to uniquely identify the device. This patch removes the sensor_name and substitutes the transport device's name or the rmi device's when needed.

[PATCH 23/26] Input: synaptics-rmi4: move structures and definitions to rmi.h

2015-11-05 Thread Andrew Duggan
Move all of the structures and function definitions needed by hid-rmi into rmi.h so that they can be accessed by hid-rmi. Signed-off-by: Andrew Duggan --- drivers/input/rmi4/rmi_bus.h| 119 --- drivers/input/rmi4/rmi_driver.h | 47 ---

[PATCH 26/26] Input: synaptics-rmi4: Change the rmi device's name to be less generic

2015-11-05 Thread Andrew Duggan
Currently, the rmi device has the name sensorXX. Sensor is very generic and in cases when there is little context it is hard to tell what the device is (ie in /sys/devices or /proc/interrupts). This patch changes the name to rmiXX which at least indicates that it is an rmi device. Signed-off-by:

[PATCH 24/26] Input: synaptics-rmi4: use device managed memory for the data packet buffer

2015-11-05 Thread Andrew Duggan
The data packet should use device managed memory since the buffer is retained until the device goes away. Signed-off-by: Andrew Duggan --- drivers/input/rmi4/rmi_f11.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/input/rmi4/rmi_f11.c

[PATCH 06/26] Input: synaptics-rmi4 - add a reset callback

2015-11-05 Thread Andrew Duggan
From: Benjamin Tissoires When a device is physically reset, the transport layer may need to reset its state too and also do extra work to make the device accessible on the bus. Signed-off-by: Benjamin Tissoires Tested-by: Andrew

[PATCH 10/26] Input: synaptics-rmi4 - f11: allow the top software button property to be set

2015-11-05 Thread Andrew Duggan
From: Benjamin Tissoires Currently, in PS/2 we only have the PNPIds list to detect the property. Unfortunately, it looks like the information is not embeded in the RMI4 protocol either, so allow the Top software buttons property to be set in the platform data.

[PATCH 09/26] Input: synaptics-rmi4 - f11: clean up rmi_f11_finger_handler

2015-11-05 Thread Andrew Duggan
From: Benjamin Tissoires abs_bit and rel_bits should not be computed at each iteration of the for loop. finger_press_count is unused. Break out rmi_f11_parse_finger_state in its own function. Signed-off-by: Benjamin Tissoires

[PATCH 08/26] Input: synaptics-rmi4 - f11: use the unified input node if available

2015-11-05 Thread Andrew Duggan
From: Benjamin Tissoires Signed-off-by: Benjamin Tissoires Tested-by: Andrew Duggan --- drivers/input/rmi4/rmi_f11.c | 60 ++-- 1 file changed, 35 insertions(+), 25

[PATCH 05/26] Input: synaptics-rmi4 - call rmi_driver_process_config_requests in enable_sensor

2015-11-05 Thread Andrew Duggan
From: Benjamin Tissoires The SMBus devices have their IRQs disabled after a reset. We need to configure them by calling rmi_driver_process_config_request() when enabling the sensor. Signed-off-by: Benjamin Tissoires Tested-by:

[PATCH 04/26] Input: synaptics-rmi4 - prevent oopses when irq arrives while the device is not bound

2015-11-05 Thread Andrew Duggan
From: Benjamin Tissoires If the device has been registered but is not populated, we should not process any incoming interrupt. Make sure the pointers we are following are valid. Signed-off-by: Benjamin Tissoires Tested-by: Andrew

[PATCH 07/26] Input: synaptics-rmi4 - f11: fix bitmap irq check

2015-11-05 Thread Andrew Duggan
From: Benjamin Tissoires num_irq_regs is the count of registers of 1 bytes that we use to check the irqs. bitmap_and() expects the number of bits. Signed-off-by: Benjamin Tissoires Tested-by: Andrew Duggan

[PATCH 19/26] Input: synaptics-rmi4: Add support for packet register descriptors

2015-11-05 Thread Andrew Duggan
Newer RMI functions make use of packet registers. Packet registers contain several bytes of data at a RMI address instead of just a single byte. Packet registers may also contain subpackets which may or may not be present for a given firmware configuration. Functions which use packet registers

Re: [PATCH 2/2] Input: uinput: Sanity check on ff_effects_max and EV_FF

2015-11-05 Thread Elias Vanderstuyft
Hi Dmitry, Excuse me for the long delay. On Thu, Oct 15, 2015 at 2:52 AM, Dmitry Torokhov wrote: > On Thu, Sep 17, 2015 at 07:29:48PM +0200, Elias Vanderstuyft wrote: >> Currently the user can specify a non-zero value for ff_effects_max, >> without setting the EV_FF

[PATCH 00/26] Consolidate patches and add support for new devices

2015-11-05 Thread Andrew Duggan
NOTE: This patch set applies to synaptics-rmi4 branch in Dmitry Torokhov's input tree. This patch set consolidates some outstanding patches and then builds on that to add support for new devices. The first 11 patches were provided by Benjamin Tissoires with slight modifications. The remainder of

[PATCH 13/26] Input: synaptics-rmi4: Add device tree support for RMI4 I2C devices

2015-11-05 Thread Andrew Duggan
Add devicetree binding for I2C devices and add bindings for optional parameters in the function drivers. Parameters for function drivers are defined in child nodes for each of the functions. Signed-off-by: Andrew Duggan --- .../devicetree/bindings/input/rmi4/rmi_f01.txt

[PATCH 12/26] Input: synaptics-rmi4: Use generic interrupt handling

2015-11-05 Thread Andrew Duggan
Currently the RMI4 driver expects the device to have a GPIO and manages the that GPIO internally. However, this duplicates functionality which could be handled by more generic interrupt handling code. Also, some RMI devices will not have a GPIO or it won't be accessible to the rmi4 driver. This

[PATCH 15/26] Input: synaptics-rmi4: Remove unused debugfs code

2015-11-05 Thread Andrew Duggan
Previous versions of the driver reported statistics in debugfs. But that code has been removed and debugfs is no longer used. This patch removes all remaining debugfs code. Signed-off-by: Andrew Duggan --- drivers/input/rmi4/rmi_bus.c| 109

[PATCH 16/26] Input: synaptics-rmi4: Use ifdef to check if CONFIG_PM_SLEEP is set

2015-11-05 Thread Andrew Duggan
The pm variables are not included in the struct rmi_driver_data at compile time. Using the IS_ENABLED macro in rmi_driver.c will result in a compiler error if CONFIG_PM_SLEEP is not enabled. Signed-off-by: Andrew Duggan --- drivers/input/rmi4/rmi_driver.c | 16

[PATCH 17/26] Input: synaptics-rmi4: Remove unused firmware_name variable

2015-11-05 Thread Andrew Duggan
Firmware update is not currently supported in the current state of this driver. We can add it back if we need it when implementing firmware update. Signed-off-by: Andrew Duggan --- include/linux/rmi.h | 4 1 file changed, 4 deletions(-) diff --git

[PATCH 11/26] Input: synaptics-rmi4 - f11: add support for kernel tracking

2015-11-05 Thread Andrew Duggan
From: Benjamin Tissoires Kernel tracking is used in 2 use cases: - filter out jumps when the sensor is not relieable enough - provide a MT protocol B when the sensor is providing MT protocol A data Signed-off-by: Benjamin Tissoires

[PATCH 14/26] Input: synaptics-rmi4: Clean up Makefile

2015-11-05 Thread Andrew Duggan
The Makefile contained commands for a different build environment. These should be removed and are not needed in the upstream kernel. Signed-off-by: Andrew Duggan --- drivers/input/rmi4/Makefile | 16 1 file changed, 16 deletions(-) diff --git

[PATCH 03/26] Input: synaptics-rmi4 - explicitly request polling when needed

2015-11-05 Thread Andrew Duggan
From: Benjamin Tissoires Host Notify does not work with neither IRQ nor polling. Allow a RMI4 driver to request or not polling depending on the attn_gpio. When neither the internal IRQ or polling systems are used, the transport driver can call

[PATCH] goldfish: add goldfish match node for dt driver probe

2015-11-05 Thread yalin wang
Signed-off-by: yalin wang --- drivers/input/keyboard/goldfish_events.c | 9 + drivers/platform/goldfish/goldfish_pipe.c | 11 ++- drivers/power/goldfish_battery.c | 11 ++- drivers/staging/goldfish/goldfish_audio.c | 11 ++-

Re: [PATCH] goldfish: add goldfish match node for dt driver probe

2015-11-05 Thread kbuild test robot
Hi yalin, [auto build test ERROR on staging/staging-testing] [also build test ERROR on v4.3 next-20151105] url: https://github.com/0day-ci/linux/commits/yalin-wang/goldfish-add-goldfish-match-node-for-dt-driver-probe/20151106-132647 config: x86_64-allyesconfig (attached as .config) reproduce

Re: [PATCH 2/2] Input: uinput: Sanity check on ff_effects_max and EV_FF

2015-11-05 Thread Dmitry Torokhov
On Thu, Nov 05, 2015 at 11:34:55PM +0100, Elias Vanderstuyft wrote: > Hi Dmitry, > > Excuse me for the long delay. > > On Thu, Oct 15, 2015 at 2:52 AM, Dmitry Torokhov > wrote: > > On Thu, Sep 17, 2015 at 07:29:48PM +0200, Elias Vanderstuyft wrote: > >> Currently the

[PATCH V2] goldfish: add goldfish match node for dt driver probe

2015-11-05 Thread yalin wang
qemu use device tree to bootup linux kernel, we need add device node match table to plaftorm driver, so that can probe the goldfish driver correctly. test by this qemu: git clone https://android.googlesource.com/platform/external/qemu Signed-off-by: yalin wang ---