- May 01, 2018
-
-
Vittorio Gambaletta (VittGam) authored
This patch adds the correct platform data information for the Caroline Chromebook, so that the mouse button does not get stuck in pressed state after the first click. The Samus button keymap and platform data definition are the correct ones for Caroline, so they have been reused here. Signed-off-by:
Vittorio Gambaletta <linuxbugs@vittgam.net> Signed-off-by:
Salvatore Bellizzi <lkml@seppia.net> Tested-by:
Guenter Roeck <groeck@chromium.org> Cc: stable@vger.kernel.org [dtor: adjusted vendor spelling to match shipping firmware] Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
- Aug 21, 2017
-
-
Sebastian Reichel authored
Provide support for controlling reset pin. If this is not driven correctly the device will be held in reset and will not respond. Acked-by:
Rob Herring <robh@kernel.org> Signed-off-by:
Sebastian Reichel <sebastian.reichel@collabora.co.uk> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Sebastian Reichel authored
Switch mxt_data and interrupt to resource managed allocation methods, which cleans up the driver slightly and prepares for adding reset GPIO support. Signed-off-by:
Sebastian Reichel <sebastian.reichel@collabora.co.uk> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
- May 23, 2017
-
-
Maxime Roussin-Bélanger authored
When using the 'object' sysfs attribute, T100 is not displayed in the output. Signed-off-by:
Maxime Roussin-Bélanger <maxime.roussinbelanger@gmail.com> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
- Jan 22, 2017
-
-
Guenter Roeck authored
If a function declares a variable to access a structure element, use it consistently. Signed-off-by:
Guenter Roeck <linux@roeck-us.net> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
- Sep 19, 2016
-
-
Nick Dyer authored
Add copyright lines for Zodiac who paid for the V4L touch work. Signed-off-by:
Nick Dyer <nick@shmanahar.org> Signed-off-by:
Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by:
Mauro Carvalho Chehab <mchehab@s-opensource.com>
-
- Aug 23, 2016
-
-
Nick Dyer authored
There are different datatypes available from a maXTouch chip. Add support to retrieve reference data as well. Signed-off-by:
Nick Dyer <nick@shmanahar.org> Signed-off-by:
Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by:
Mauro Carvalho Chehab <mchehab@s-opensource.com> Acked-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Nick Dyer authored
The mXT1386 family of chips have a different architecture which splits the diagnostic data into 3 columns. Signed-off-by:
Nick Dyer <nick@shmanahar.org> Signed-off-by:
Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by:
Mauro Carvalho Chehab <mchehab@s-opensource.com> Acked-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Nick Dyer authored
Invert the diagnostic data to match the orientation of the input device. Signed-off-by:
Nick Dyer <nick@shmanahar.org> Signed-off-by:
Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by:
Mauro Carvalho Chehab <mchehab@s-opensource.com> Acked-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Nick Dyer authored
The touchscreen may have a margin where not all the matrix is used. Read the parameters from T9 and T100 and take account of the difference. Note: this does not read the XORIGIN/YORIGIN fields so it assumes that the touchscreen starts at (0,0) Signed-off-by:
Nick Dyer <nick@shmanahar.org> Signed-off-by:
Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by:
Mauro Carvalho Chehab <mchehab@s-opensource.com> Acked-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Nick Dyer authored
Register a video device to output T37 diagnostic data. Signed-off-by:
Nick Dyer <nick@shmanahar.org> Signed-off-by:
Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by:
Mauro Carvalho Chehab <mchehab@s-opensource.com> Acked-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Nick Dyer authored
Atmel maXTouch devices have a T37 object which can be used to read raw touch deltas from the device. This consists of an array of 16-bit integers, one for each node on the touchscreen matrix. Signed-off-by:
Nick Dyer <nick@shmanahar.org> Signed-off-by:
Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by:
Mauro Carvalho Chehab <mchehab@s-opensource.com> Acked-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
- Apr 25, 2016
-
-
Nick Dyer authored
If using IRQF_TRIGGER_FALLING, then there is a race here: if the reset completes before we enable the IRQ, then CHG is already low and touch will be broken. This has been seen on Chromebook Pixel 2. A workaround is to reconfig T18 COMMSCONFIG to enable the RETRIGEN bit using mxt-app: mxt-app -W -T18 44 mxt-app --backup Tested-by:
Tom Rini <trini@konsulko.com> Signed-off-by:
Nick Dyer <nick.dyer@itdev.co.uk> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
- Jan 12, 2016
-
-
Nick Dyer authored
Both T100 and T9 handle range and orientation in a similar fashion. Reduce duplication between the two implementations. Signed-off-by:
Nick Dyer <nick.dyer@itdev.co.uk> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
- Dec 11, 2015
-
-
Javier Martinez Canillas authored
The Atmel maxtouch DT binding documents that the compatible string for the device is "atmel,maxtouch" and the I2C core always reports a module alias of the form i2c:alias where alias is the compatible string model: $ grep MODALIAS /sys/devices/platform/12e00000.i2c/i2c-8/8-004b/uevent MODALIAS=i2c:maxtouch But there isn't maxtouch entry in the I2C device ID table so when the i2c:maxtouch MODALIAS uevent is reported, kmod is not able to match the alias with a module to load: $ modinfo atmel_mxt_ts | grep alias alias: of:N*T*Catmel,maxtouch alias: i2c:mXT224 alias: i2c:atmel_mxt_tp alias: i2c:atmel_mxt_ts alias: i2c:qt602240_ts So add the maxtouch entry to the I2C device ID table to allow the module to be autoloaded when the device is registered via OF. Signed-off-by:
Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
- Dec 02, 2015
-
-
Dmitry Torokhov authored
Apparently people are installing generic Linux distributions not only on Pixels but also on other Chromebooks. Unfortunately on all of them Atmel parts assigned names ATML0000 and ATML0001, and do not carry any other configuration data. So let's create generic instance of platform data that should cover most of them (we assume that they will not be using T100 objects, since with those Google mapped BTN_LEFT onto a different GPIO, so slightly different keymap would be needed, but I think we used parts with T100 on ARM devices where we thankfully have DTS and can describe the devices better). Tested-by:
Rich K <rgkirch@gmail.com> Reviewed-by:
Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
- Aug 05, 2015
-
-
Nick Dyer authored
Signed-off-by:
Nick Dyer <nick.dyer@itdev.co.uk> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Nick Dyer authored
This indicates the device coordinates should be directly mapped to screen. This is valid since scaling/flipping/rotation should be done by configuring the MXT device. It also flags to Android using INPUT_PROP_DIRECT that the device should be treated as a touch screen by default, and removes the necessity for a default IDC file. Signed-off-by:
Nick Dyer <nick.dyer@itdev.co.uk> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Nick Dyer authored
The CHG/interrupt line is momentarily set (approximately 100 ms) as an input after power-up or reset for diagnostic purposes. This may cause spurious interrupts, so disable interrupt handler during this period. Signed-off-by:
Nick Dyer <nick.dyer@itdev.co.uk> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Nick Dyer authored
Use function rather than loop, define np to reduce wrapping. Signed-off-by:
Nick Dyer <nick.dyer@itdev.co.uk> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Pan Xinhui authored
input_dev may be NULL if mxt_initialize_input_device fails. But pm ops is still available and suspend/resume assume input_dev is not NULL. To fix this issue, we add a check if (!input_dev). Signed-off-by:
Pan Xinhui <xinhuix.pan@intel.com> Signed-off-by:
Nick Dyer <nick.dyer@itdev.co.uk> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Nick Dyer authored
Many of these values are out of date and they aren't used in the driver - all they do is increase the size of the kernel source. Signed-off-by:
Nick Dyer <nick.dyer@itdev.co.uk> Acked-by:
Benson Leung <bleung@chromium.org> Acked-by:
Yufeng Shen <miletus@chromium.org> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Nick Dyer authored
The hardcoded 0x83 CTRL setting overrides other settings in that byte, enabling extra reporting that may not be useful on a particular platform. Implement improved suspend mechanism via deep sleep. By writing zero to both the active and idle cycle times the maXTouch device can be put into a deep sleep mode, using minimal power. It is necessary to issue a calibrate command after the chip has spent any time in deep sleep, however a soft reset is unnecessary. Use the old method on Chromebook Pixel via platform data option. This patch also deals with the situation where the power configuration is zero on probe, which would mean that the device never wakes up to execute commands. After a config download, the T7 power configuration may have changed so it is necessary to re-read it. Signed-off-by:
Nick Dyer <nick.dyer@itdev.co.uk> Acked-by:
Benson Leung <bleung@chromium.org> Acked-by:
Yufeng Shen <miletus@chromium.org> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
- Jul 17, 2015
-
-
Krzysztof Kozlowski authored
i2c_driver does not need to set an owner because i2c_register_driver() will set it. Signed-off-by:
Krzysztof Kozlowski <k.kozlowski@samsung.com> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
- May 20, 2015
-
-
Dmitry Torokhov authored
This makes the intent a tad more clear. Reviewed-by:
Javier Martinez Canillas <javier.martinez@collabora.co.uk> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
- Apr 15, 2015
-
-
Dmitry Torokhov authored
This change allows atmel_mxt_ts to bind to ACPI-enumerated devices in Google Pixel 2 (2015). While newer version of ACPI standard allow use of device-tree-like properties in device descriptions, the version of ACPI implemented in Google BIOS does not support them, and we have to resort to DMI data to specify exact characteristics of the devices (touchpad vs. touchscreen, GPIO to button mapping, etc). Pixel 1 continues to use i2c devices and platform data created by chromeos-laptop driver, since ACPI does not enumerate them. Reviewed-by:
Javier Martinez Canillas <javier.martinez@collabora.co.uk> Tested-by:
Javier Martinez Canillas <javier.martinez@collabora.co.uk> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
- Apr 06, 2015
-
-
Sjoerd Simons authored
If the "linux,gpio-keymap" DT property is defined, the T19 keys are configured and the device is setup as a touchpad rather than a touchscreen. The logic is part of the input device initialization routine but it can be factored out to its own function to simplify the former. Signed-off-by:
Sjoerd Simons <sjoerd.simons@collabora.co.uk> Signed-off-by:
Javier Martinez Canillas <javier.martinez@collabora.co.uk> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Nick Dyer authored
Add support for the new T100 object which replaces the previous T9 multitouch touchscreen object in recent maXTouch devices. T100 provides improved reporting with selectable auxiliary information, and a type field for hover/stylus/glove reporting. The hovering finger support was based on Chung-Yih's work in the ChromiumOS downstream kernel: https://chromium-review.googlesource.com/#/c/219280/ Signed-off-by:
Nick Dyer <nick.dyer@itdev.co.uk> Acked-by:
Yufeng Shen <miletus@chromium.org> [javier: Factor out T9 and T100 init functions and rework hover support] Signed-off-by:
Javier Martinez Canillas <javier.martinez@collabora.co.uk> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
- Dec 31, 2014
-
-
Linus Torvalds authored
This reverts commit 9d469d03. It breaks the Chromebook Pixel touchpad (and touchscreen). Reported-by:
Dirk Hohndel <dirk@hohndel.org> Bisected-by:
Linus Torvalds <torvalds@linux-foundation.org> Cc: Nick Dyer <nick.dyer@itdev.co.uk> Cc: Benson Leung <bleung@chromium.org> Cc: Yufeng Shen <miletus@chromium.org> Cc: Dmitry Torokhov <dmitry.torokhov@gmail.com> Cc: stable@vger.kernel.org # v3.16+ Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
- Nov 02, 2014
-
-
Jingoo Han authored
Use __maybe_unused instead of ifdef guards around suspend/resume functions, in order to increase build coverage and fix build warnings. Signed-off-by:
Jingoo Han <jg1.han@samsung.com> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
- Sep 10, 2014
-
-
Stephen Warren authored
[Nick Dyer: reworked to move free of input device into separate function and only call in paths that require it.] Signed-off-by:
Nick Dyer <nick.dyer@itdev.co.uk> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
- Sep 09, 2014
-
-
Nick Dyer authored
In the case where the CHG/interrupt line mode is not configured correctly, this warning is output to dmesg output for each interrupt. Downgrade the message to debug. Signed-off-by:
Nick Dyer <nick.dyer@itdev.co.uk> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
- Aug 13, 2014
-
-
Dmitry Torokhov authored
This should fix the following issues reported by Coverity: *** CID 1230625: Logically dead code (DEADCODE) /drivers/input/touchscreen/atmel_mxt_ts.c: 1692 in mxt_initialize() *** CID 12306276: Missing break in switch (MISSING_BREAK) /drivers/input/touchscreen/atmel_mxt_ts.c: 1436 in mxt_get_object_table() *** CID 1230629: Out-of-bounds write (OVERRUN) /drivers/input/touchscreen/atmel_mxt_ts.c: 1267 in mxt_update_cfg() *** CID 1230632: Unused pointer value (UNUSED_VALUE) /drivers/input/touchscreen/atmel_mxt_ts.c: 1211 in mxt_update_cfg() Acked-by:
Nick Dyer <nick.dyer@itdev.co.uk> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Dmitry Torokhov authored
Let's split config update code a bit so it is hopefully a bit easier to read. Also, the firmware update callback should be the entity releasing firmware blob, not lower layers. Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by:
Nick Dyer <nick.dyer@itdev.co.uk>
-
Dmitry Torokhov authored
I think having control flow with 2 goto/labels/flags is quite hard to read, this version is a bit more readable IMO. Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com> Signed-off-by:
Nick Dyer <nick.dyer@itdev.co.uk>
-
- Aug 08, 2014
-
-
Nick Dyer authored
Signed-off-by:
Nick Dyer <nick.dyer@itdev.co.uk> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
- Jul 28, 2014
-
-
Nick Dyer authored
By writing zero to both the active and idle cycle times the maXTouch device is put into a deep sleep mode when it consumes minimal power. It is unnecessary to change the configuration of any other objects (for example to disable T9 touchscreen). It is counterproductive to reset the chip on resume, it will result in a long delay. However it is necessary to issue a calibrate command after the chip has spent any time in deep sleep. This patch also deals with the situation where the power configuration is zero on probe, which would mean that the device never wakes up to execute commands. Signed-off-by:
Nick Dyer <nick.dyer@itdev.co.uk> Acked-by:
Benson Leung <bleung@chromium.org> Acked-by:
Yufeng Shen <miletus@chromium.org> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
- Jul 23, 2014
-
-
Nick Dyer authored
maXTouch chips allow the reading of multiple messages in a single I2C transaction, which reduces bus overhead and improves performance/latency. The number of messages available to be read is given by the value in the T44 object which is located directly before the T5 object. Signed-off-by:
Nick Dyer <nick.dyer@itdev.co.uk> Acked-by:
Benson Leung <bleung@chromium.org> Acked-by:
Yufeng Shen <miletus@chromium.org> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Nick Dyer authored
This is in preparation for support of the T44 message count object. Also, cache T5 address to avoid lookup on every interrupt cycle. Signed-off-by:
Nick Dyer <nick.dyer@itdev.co.uk> Acked-by:
Benson Leung <bleung@chromium.org> Acked-by:
Yufeng Shen <miletus@chromium.org> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-
Nick Dyer authored
By storing the previous T6 status byte multiple debug output of the same status can be suppressed (for example CFGERR). Signed-off-by:
Nick Dyer <nick.dyer@itdev.co.uk> Acked-by:
Benson Leung <bleung@chromium.org> Acked-by:
Yufeng Shen <miletus@chromium.org> Signed-off-by:
Dmitry Torokhov <dmitry.torokhov@gmail.com>
-