aboutsummaryrefslogtreecommitdiffstats
path: root/firmware (unfollow)
AgeCommit message (Collapse)AuthorFilesLines
2016-12-12Input: drv260x - use generic device propertiesJingkui Wang2-92/+19
Update driver drv260x to use generic device properties so that it can be used on non-DT systems. We also remove platform data as generic device properties work on static board code as well. Signed-off-by: Jingkui Wang <jkwang@google.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-12-12Input: drv260x - use temporary for &client->devDmitry Torokhov1-22/+15
Let's introduce a temporary for "client->dev" is probe() as we use it quite a few times and "dev" is shorter. Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-12-12Input: drv260x - fix input device's parent assignmentJingkui Wang1-1/+0
We were assigning I2C bus controller instead of client as parent device. Besides being logically wrong, it messed up with devm handling of input device. As a result we were leaving input device and event node behind after rmmod-ing the driver, which lead to a kernel oops if one were to access the event node later. Let's remove the assignment and rely on devm_input_allocate_device() to set it up properly for us. Signed-off-by: Jingkui Wang <jkwang@google.com> Fixes: 7132fe4f5687 ("Input: drv260x - add TI drv260x haptics driver") Cc: stable@vger.kernel.org Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-12-12Input: synaptics-rmi4 - add support for F34 V7 bootloaderNick Dyer6-34/+1688
Port firmware update code from Samsung Galaxy S7 driver into mainline framework. This patch has been tested on Synaptics S7813. Signed-off-by: Nick Dyer <nick@shmanahar.org> Tested-by: Chris Healy <cphealy@gmail.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-12-12Input: drv260x - fix initializing overdrive voltageDmitry Torokhov1-1/+1
We were accidentally initializing haptics->rated_voltage twice, and did not initialize overdrive voltage. Acked-by: Dan Murphy <dmurphy@ti.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-12-12Input: ALPS - fix protcol -> protocolMarcos Paulo de Souza1-1/+1
Signed-off-by: Marcos Paulo de Souza <marcos.souza.org@gmail.com> Reviewed-by: Pali Rohár <pali.rohar@gmail.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-12-12Input: i8042 - comment #else/#endif of CONFIG_PNPMarcos Paulo de Souza1-2/+2
As this define check if huge, this makes easier to read the code. Signed-off-by: Marcos Paulo de Souza <marcos.souza.org@gmail.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-12-07Input: lpc32xx-keys - fix invalid error handling of a requested irqVladimir Zapolskiy1-1/+1
Semantics of NR_IRQS is different on machines with SPARSE_IRQ option disabled or enabled, in the latter case IRQs are allocated starting at least from the value specified by NR_IRQS and going upwards, so the check of (irq >= NR_IRQ) to decide about an error code returned by platform_get_irq() is completely invalid, don't attempt to overrule irq subsystem in the driver. The change fixes lpc32xx_keys driver initialization on boot: lpc32xx_keys 40050000.key: failed to get platform irq lpc32xx_keys: probe of 40050000.key failed with error -22 Signed-off-by: Vladimir Zapolskiy <vz@mleia.com> Acked-by: Sylvain Lemieux <slemieux.tyco@gmail.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-12-07Input: synaptics-rmi4 - fix debug for sensor clipNick Dyer1-5/+3
The debug would only ever output zero for the clip information. Signed-off-by: Nick Dyer <nick@shmanahar.org> Reviewed-by: Andrew Duggan <aduggan@synaptics.com> Tested-by: Chris Healy <cphealy@gmail.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-12-02Input: synaptics-rmi4 - store the attn data in the driverBenjamin Tissoires6-44/+45
Now that we have a proper API to set the attention data, there is no point in keeping it in the transport driver. Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Reviewed-by: Andrew Duggan <aduggan@synaptics.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-12-02Input: synaptics-rmi4 - allow to add attention dataBenjamin Tissoires2-2/+58
The HID implementation of RMI4 provides the data during the interrupt (in the input report). We need to provide a way for this transport driver to provide the attention data while calling an IRQ. We use a fifo in rmi_core to not lose any incoming event. Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Reviewed-by: Andrew Duggan <aduggan@synaptics.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-12-02Input: synaptics-rmi4 - f03 - grab data passed by transport deviceDennis Wassenberg1-9/+26
First check if there are data available passed by the transport device. If data available use these data. If there are no data available try to read the rmi block if dsata are passed this way. This is the way the other rmi function handlers will do this. This patch is needed on HID devices because the firmware reads F03 data registers and adds them to the HID attention report. Reading those registers from the driver after the firmware read them will result in invalid data. Reviewed-by: Andrew Duggan <aduggan@synaptics.com> Signed-off-by: Dennis Wassenberg <dennis.wassenberg@secunet.com> Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-12-02Input: synaptics-rmi4 - add support for F03Lyude Paul5-0/+246
This adds basic functionality for PS/2 passthrough on Synaptics Touchpads using RMI4 through smbus. Reviewed-by: Andrew Duggan <aduggan@synaptics.com> Signed-off-by: Lyude Paul <thatslyude@gmail.com> Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-30Input: imx6ul_tsc - convert int to u32Guy Shapiro1-21/+21
The code uses of_property_read_u32 and expects positive values. However, the values are stored in signed int variables. Additionally, the registers values are also stored in signed variables without a good reason (readl/writel expect u32). The only time this caused a real bug was in the new average-samples property, in which the property is numerically compared and implicitly expected to be positive. I believe it's better to change all the properties and registers to u32, for consistency and warnings reduction. Signed-off-by: Guy Shapiro <guy.shapiro@mobi-wize.com> Reported-by: Bjørn Forsman <bjorn.forsman@gmail.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-30Input: imx6ul_tsc - add mask when set REG_ADC_CFGHaibo Chen1-1/+10
Add mask of each function bits of REG_ADC_CFG, and clear these function bits first, otherwise use '|=' operation may get the wrong setting which depends on the original value of REG_ADC_CFG. Signed-off-by: Haibo Chen <haibo.chen@nxp.com> Reviewed-by: Guy Shapiro <guy.shapiro@mobi-wize.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-30Input: synaptics-rmi4 - have only one struct platform dataBenjamin Tissoires4-11/+10
If struct rmi_device_platform_data contains pointers to other struct, it gets difficult to allocate a fixed size struct and copy it over between drivers. Change the pointers into a struct and change the code in rmi4 accordingly. Reviewed-by: Andrew Duggan <aduggan@synaptics.com> Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-30Input: synaptics-rmi4 - remove EXPORT_SYMBOL_GPL for internal functionsBenjamin Tissoires2-16/+2
those functions should not be used outside of rmi_core.ko. There is no point in exporting them to the world. It looks like rmi_read_pdt_entry() should be static too. Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-30Input: synaptics-rmi4 - remove mutex calls while updating the firmwareBenjamin Tissoires2-37/+22
This partially reverts commit 29fd0ec2bdbe ("Input: synaptics-rmi4 - add support for F34 device reflash") irq_mutex should be used only to protect data->current_irq_mask, not preventing incoming input to be processed while the upgrade of the firmware is happening. We can simply disable the irqs when we don't want them to interfere with the upgrade process. Tested on S7300 and S7800 (with F34 v7 patch added) Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Nick Dyer <nick@shmanahar.org> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-30Input: drv2667 - fix misuse of regmap_update_bitsFlorian Vaussard1-2/+2
Using regmap_update_bits(..., mask, 1) with 'mask' following (1 << k) and k greater than 0 is wrong. Indeed, _regmap_update_bits will perform (mask & 1), which results in 0 if LSB of mask is 0. Thus the call regmap_update_bits(..., mask, 1) is in reality equivalent to regmap_update_bits(..., mask, 0). In such a case, the correct use is regmap_update_bits(..., mask, mask). This driver is performing such a mistake with the DRV2667_STANDBY mask, which equals (1 << 6). Fix the driver to make it consistent with the API, and fix the alignment problem at the same time. Please note that this change is untested, as I do not have this piece of hardware. Testers are welcome! Signed-off-by: Florian Vaussard <florian.vaussard@heig-vd.ch> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-30Input: drv2665 - fix misuse of regmap_update_bitsFlorian Vaussard1-3/+3
Using regmap_update_bits(..., mask, 1) with 'mask' following (1 << k) and k greater than 0 is wrong. Indeed, _regmap_update_bits will perform (mask & 1), which results in 0 if LSB of mask is 0. Thus the call regmap_update_bits(..., mask, 1) is in reality equivalent to regmap_update_bits(..., mask, 0). In such a case, the correct use is regmap_update_bits(..., mask, mask). This driver is performing such a mistake with the DRV2665_STANDBY mask, which equals BIT(6). Fix the driver to make it consistent with the API, and fix the alignment problem at the same time. Please note that this change is untested, as I do not have this piece of hardware. Testers are welcome! Signed-off-by: Florian Vaussard <florian.vaussard@heig-vd.ch> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-30Input: synaptics-rmi4 - add rmi_enable/disable_irqBenjamin Tissoires3-19/+67
Set the .enabled boolean and trigger an event processing when enabling for edge-triggered systems. Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-30Input: synaptics-rmi4 - remove unused fields in struct rmi_driver_dataBenjamin Tissoires1-4/+0
These fields are not used anywhere, there is no point in carrying them. Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-30Input: synaptics-rmi4 - fix documentation of rmi_2d_sensor_platform_dataBenjamin Tissoires1-1/+1
Typos... Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-28Input: ALPS - clean up code for SS5 hardwarePaul Donohue2-15/+28
The return value of alps_get_pkt_id_ss4_v2() should really be "enum SS4_PACKET_ID", not "unsigned char". Correct this. Also, most of the Alps SS5 (SS4 v2) packet byte parsing code is implemented using macros, but there are a few places where bytes are directly manipulated in alps.c. For consistency, migrate the rest of these to macros. Reviewed-by: Pali Rohár <pali.rohar@gmail.com> Signed-off-by: Paul Donohue <linux-kernel@PaulSD.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-28Input: ALPS - clean up TrackStick handling for SS5 hardwarePaul Donohue1-17/+25
For consistency and clarity, the input_report_*() functions should be called by alps_process_packet_ss4_v2() instead of by alps_decode_ss4_v2(). Reviewed-by: Pali Rohár <pali.rohar@gmail.com> Signed-off-by: Paul Donohue <linux-kernel@PaulSD.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-28Input: ALPS - fix TrackStick support for SS5 hardwarePaul Donohue1-7/+12
The current Alps SS5 (SS4 v2) code generates bogus TouchPad events when TrackStick packets are processed. This causes the xorg synaptics driver to print "unable to find touch point 0" and "BUG: triggered 'if (priv->num_active_touches > priv->num_slots)'" messages. It also causes unexpected TouchPad button release and re-click event sequences if the TrackStick is moved while holding a TouchPad button. This commit corrects the problem by adjusting alps_process_packet_ss4_v2() so that it only sends TrackStick reports when processing TrackStick packets. Reviewed-by: Pali Rohár <pali.rohar@gmail.com> Signed-off-by: Paul Donohue <linux-kernel@PaulSD.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-27Input: imx6ul_tsc - add support for sample averagingGuy Shapiro2-0/+26
The i.MX6UL internal touchscreen controller contains an option to average upon samples. This feature reduces noise from the produced touch locations. This patch adds sample averaging support to the imx6ul_tsc device driver. Signed-off-by: Guy Shapiro <guy.shapiro@mobi-wize.com> Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-27Input: xpad - fix Xbox One rumble stopping after 2.5 secsCameron Gutman1-3/+3
Unlike previous Xbox pads, the Xbox One pad doesn't have "sticky" rumble packets. The duration is encoded into the command and expiration is handled by the pad firmware. ff-memless needs pseudo-sticky behavior for rumble effects to behave properly for long duration effects. We already specify the maximum rumble on duration in the command packets, but it's still only good for about 2.5 seconds of rumble. This is easily reproducible running fftest's sine vibration test. It turns out there's a repeat count encoded in the rumble command. We can abuse that to get the pseudo-sticky behavior needed for rumble to behave as expected for effects with long duration. By my math, this change should allow a single ff_effect to rumble for 10 minutes straight, which should be more than enough for most needs. Signed-off-by: Cameron Gutman <aicommander@gmail.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-27Input: xpad - add product ID for Xbox One S padCameron Gutman1-0/+1
This is the new gamepad that ships with the Xbox One S which includes Bluetooth functionality. Signed-off-by: Cameron Gutman <aicommander@gmail.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-25Input: soc_button_array - bail out earlier if gpiod_count is zeroBenjamin Tissoires1-0/+5
The PNP0C40 device of the Surface 3 doesn't have any GPIO attached to it. Instead of trying to access the GPIO, request the count beforehand and bail out if it is null or if an error is returned. Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-25Input: soc_button_array - use gpio_is_valid()Benjamin Tissoires1-1/+2
gpio_keys will later use gpio_is_valid(). To match the actual behavior, we should use it here too. Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-22Input: i8042 - fix typo from i8042_aux_close to i8042_port_closeMarcos Paulo de Souza1-1/+1
Signed-off-by: Marcos Paulo de Souza <marcos.souza.org@gmail.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-22Input: synaptics-rmi4 - propagate correct number of rx and tx electrodes to F54Guenter Roeck4-4/+21
F54 diagnostics report functions provide data based on the number of enabled rx and tx electrodes, which is not identical to the number of electrodes reported with F54:Query0 and F54:Query1. Those values report the number of supported electrodes, not the number of enabled electrodes. The number of enabled electrodes can be determined by analyzing F55:Ctrl1 (sensor receiver assignment) and F55:Ctrl2 (sensor transmitter assignment). Propagate the number of enabled electrodes from F55 to F54 to avoid corrupted output if not all electrodes are enabled. Fixes: 3a762dbd5347 ("[media] Input: synaptics-rmi4 - add support for F54 ...") Signed-off-by: Guenter Roeck <linux@roeck-us.net> Tested-by: Nick Dyer <nick@shmanahar.org> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-22Input: synaptics-rmi4 - add support for F55 sensor tuningGuenter Roeck5-0/+138
Sensor tuning support is needed to determine the number of enabled tx and rx electrodes for use in F54 functions. The number of enabled electrodes is not identical to the total number of electrodes as reported with F55:Query0 and F55:Query1. It has to be calculated by analyzing F55:Ctrl1 (sensor receiver assignment) and F55:Ctrl2 (sensor transmitter assignment). Support for additional sensor tuning functions may be added later. Fixes: 3a762dbd5347 ("[media] Input: synaptics-rmi4 - add support for F54 ...") Signed-off-by: Guenter Roeck <linux@roeck-us.net> Tested-by: Nick Dyer <nick@shmanahar.org> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-22Input: synaptics-rmi4 - add support for F34 device reflashNick Dyer9-31/+670
Add support for updating firmware, triggered by a sysfs attribute. This patch has been tested on Synaptics S7300. Signed-off-by: Nick Dyer <nick@shmanahar.org> Tested-by: Chris Healy <cphealy@gmail.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-17Input: gpio_keys - set input direction explicitlySudeep Holla2-0/+15
Commit 700a38b27eef ("Input: gpio_keys - switch to using generic device properties") switched to use generic device properties for GPIO keys and commit 5feeca3c1e39 ("Input: gpio_keys - add support for GPIO descriptors") switched from legacy GPIO numbers to GPIO descriptors. Previously devm_gpio_request_one was explicitly passed GPIOF_DIR_IN flag to set the GPIO direction as input. However devm_get_gpiod_from_child doesn't have such provisions and hence fwnode_get_named_gpiod can't set it as input. This breaks few platforms with the following error: " gpiochip_lock_as_irq: tried to flag a GPIO set as output for IRQ unable to lock HW IRQ <n> for IRQ genirq: Failed to request resources for POWER (irq <x>) on irqchip gpio_keys: Unable to claim irq <x>; error -22 gpio-keys: probe failed with error -22 " This patch fixes the issue by setting input direction explicitly for gpio lines described by generic properties. Fixes: 700a38b27eef ("Input: gpio_keys - switch to using generic device properties") Signed-off-by: Sudeep Holla <sudeep.holla@arm.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-16Input: synaptics-rmi4 - unlock on errorDan Carpenter1-2/+3
We should unlock before returning on this error path. Fixes: 3a762dbd5347 ('[media] Input: synaptics-rmi4 - add support for F54 diagnostics') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-16Input: raydium_i2c_ts - fix spelling mistake in dev_err messageColin Ian King1-1/+1
Trivial fix to spelling mistake "failied" to "failed" in dev_err message. Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-16Input: silead - add regulator supportHans de Goede2-0/+31
On some tablets the touchscreen controller is powered by separate regulators, add support for this. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-16Input: bma150 - avoid binding to bma180 if IIO bma180 driver presentHans de Goede1-1/+8
commit ef3714fdbc8d ("Input: bma150 - extend chip detection for bma180"), adds bma180 chip-ids to the input bma150 driver, assuming that they are 100% compatible, but the bma180 is not compatible with the bma150 at all, it has 14 bits resolution instead of 10, and it has quite different control registers too. Treating the bma180 as a bma150 wrt its data registers will just result in throwing away the lowest 4 bits, which is not too bad. But the ctrl registers are a different story. Things happen to just work but supporting that certainly does not make treating the bma180 the same as the bma150 right. Since some setups depend on the evdev interface the bma150 driver offers on top of the bma180, we cannot simply remove the bma180 ids. So this commit only removes the bma180 id when the bma180 iio driver, which does treat the bma180 properly, is enabled. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-08Input: synaptics-rmi4 - add SMBus supportBenjamin Tissoires4-0/+472
Code obtained from https://raw.githubusercontent.com/mightybigcar/synaptics-rmi4/jf/drivers/input/rmi4/rmi_smbus.c and updated to match upstream. And fixed to make it work. Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Andrew Duggan <aduggan@synaptics.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-08Input: synaptics-rmi4 - set the ABS_MT_TOOL_TYPE bit to report tool typeAndrew Duggan1-4/+6
The rmi4 2D sensor functions report the tool type via input_mt_report_slot_state(), but the abs parameter bit has not been set so the tool type is not reported to userspace. This patch set the ABS_MT_TOOL_TYPE bit. Signed-off-by: Andrew Duggan <aduggan@synaptics.com> Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-08Input: synaptics-rmi4 - add support for controlling dribble packets in F12Andrew Duggan1-1/+69
Implements reading and setting the dribble bit in F12's control registers. Signed-off-by: Andrew Duggan <aduggan@synaptics.com> Acked-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-08Input: synaptics-rmi4 - add parameters for dribble packets and palm detect gestureAndrew Duggan4-15/+46
The rmi_f11 driver currently disables dribble packets and the palm detect gesture for all devices. This patch creates a parameter in the 2d sensor platform data for controlling this functionality on a per device basis. For more information on dribble packets: Commit 05ba999fcabb ("HID: rmi: disable dribble packets on Synaptics touchpads") For more information on the palm detect gesture: Commit f097deef59a6 ("HID: rmi: disable palm detect gesture when present") Signed-off-by: Andrew Duggan <aduggan@synaptics.com> Reviewed-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-08Input: synaptics-rmi4 - handle incomplete input dataAndrew Duggan3-20/+61
Commit 5b65c2a02966 ("HID: rmi: check sanity of the incoming report") added support for handling incomplete HID reports do to the input data being corrupted in transit. This patch reimplements this functionality in the function drivers so they can handle getting less valid data then they expect. Signed-off-by: Andrew Duggan <aduggan@synaptics.com> Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-08Input: synaptics-rmi4 - move IRQ handling to rmi_driverBjorn Andersson4-143/+83
The attn IRQ is related to the chip, rather than the transport, so move all handling of interrupts to the core driver. This also makes sure that there are no races between interrupts and availability of the resources used by the core driver. Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-08Input: da9062 - update bindings docs to account for da9061Steve Twiss1-15/+30
Add binding information for DA9061 onkey. This patch updates the compatible string "dlg,da9061-onkey" to support DA9061, removes the reference to KEY_SLEEP (which the driver no longer supports) and fixes a typo in the example for DA9063. Supporting KEY_SLEEP was not the general convention and the typical solution should have been for KEY_POWER to support both cases of suspend and S/W power off. This change was sent to the DA9063 ONKEY device driver in a separate patch, but the documentation was not updated at that time. - f889bea Report KEY_POWER instead of KEY_SLEEP during power key-press This patch also adds two new examples, one for DA9062 and one for DA9061. The DA9061 examples uses a fall-back compatible string for the DA9062 onkey driver. Signed-off-by: Steve Twiss <stwiss.opensource@diasemi.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-08Input: melfas_mip4 - add product ID reportingSangwon Jee1-1/+2
Add reporting product ID through input_id. Signed-off-by: Sangwon Jee <jeesw@melfas.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-08Input: synaptics-rmi4 - add a couple of debug linesNick Dyer2-0/+4
Signed-off-by: Nick Dyer <nick@shmanahar.org> Tested-by: Chris Healy <cphealy@gmail.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
2016-11-08Input: synaptics-rmi4 - factor out functions from probeNick Dyer1-53/+86
Signed-off-by: Nick Dyer <nick@shmanahar.org> Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> Tested-by: Chris Healy <cphealy@gmail.com> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>