Touchscreen is unfunctional after reset of the device during fw update.
Touch IC keep in flash mode and skip update due to incomplete query result.
Make touch fw update when driver detects flash mode during probing.
Initial parameters are also neccessary since querying to IC is unavailable.
Bug: 22399314
Change-Id: Idf28c2de539a866731decb96a36d883b926e37c9
Signed-off-by: e2sh83.lee <e2sh83.lee@lge.com>
- use a sysfs for touch fw update on boot
- fix fw update failure with lower firmware ID
- check build information for firmware
- disable hover feature as default
- ensure firmware version with upper case
- support delayed init to avoid i2c error
Change-Id: I33aa44e24aae991e8c42a458047a7befbca53834
Signed-off-by: Yejin Lee <yejini.lee@lge.com>
Signed-off-by: Jongrak Kwon <jongrak.kwon@lge.com>
- Modified file header.
- Added get_frame timeout detection and IOCTL to start/stop timeout detection.
- Added IOCTL to notify SCAN_MODE - Modified to clear the frame data acquisition flag during the execution of the reset IOCTL.
- Modified to discard the acquired data if a reset has been performed during SPI read.
- Added IOCTL definitions. - Modified wornings for kernel checkpatch.
Change-Id: I4de7a2fe4e3761375917ab8dd2ef655234e3c4b5
Signed-off-by: Hirofumi Nakagawa <hirofumi.nakagawa.fk@j-display.com>
Git-commit: 5431b50d94963ec7bc728950c6d07132e9df3974
Git-repo: https://github.com/JapanDisplayInc/bu21150-driver
[jinglin@codeaurora.org: resolve minor merge conflicts, add commit subject,
move original Signed-off-by line down]
Signed-off-by: Jing Lin <jinglin@codeaurora.org>
Focaltech touch controller FT6436 support new feature Screen-off-Gesture.
It is able to turn on the screen by drawing gestures on the touch screen
when the screen is during off status. Enable the FT CTP driver to support
the screen off gesture recognization.
Change-Id: I77d111d3ef800b636a337221d7e605f746a113dd
Signed-off-by: Mao Li <maol@codeaurora.org>
Focaltech's CTP FT6436 is able to behave like a proximity sensor.
Enable the driver support this new feature.
Change-Id: I7a6ec3a387536c512637b0bd8dab95e7cceca212
Signed-off-by: Mao Li <maol@codeaurora.org>
Fix firmware and configuration update routines to follow
device specification. Parse the firmware and configuration
file names from DT and provide interfaces to read them
from user space.
Change-Id: I9fa2a13a17702cd26d36987a6584adf398e962a8
Signed-off-by: Mohan Pallaka <mpallaka@codeaurora.org>
This driver is for Rohm's touch Analog Front End (AFE) bu21150. It
receives raw frame from touch AFE via SPI so that host processor
can process raw frame to generate touch coordinates.
Change-Id: I6548dbd064e90653c0642e1a40a8834182997c71
Signed-off-by: iuchi <shinya.iuchi.jg@j-display.com>
Git-commit: 7f0911a70b204a2ba90f66b1792b5229b23342eb
Git-repo: https://github.com/JapanDisplayInc/bu21150-driver
[jinglin@codeaurora.org: fix compilation errors on 3.10 kernel, fix bug
in array definition, add commit text]
Signed-off-by: Jing Lin <jinglin@codeaurora.org>
The sensors HAL can't distinguish accelerometer from each other by
input device name. This may cause accelerometer data not correct on
target with multiple accelerometers. So rename the accelerometer
sensor name to distinguish each other.
Change-Id: I57ed6416d04fd5bd1208ba8f9bfed039cca3b441
Signed-off-by: Oliver Wang <mengmeng@codeaurora.org>
Add sensor fifo mode, then it can work in the fifo mode when the
system in deep suspend. And sensor can wake up system when the
sensor fifo is full.
Change-Id: I684a1a67b34fe00a7889af5bee7b0f733c787ddc
Signed-off-by: c_daqing <chendaqing@codeaurora.org>
Signed-off-by: Bingzhe Cai <bingzhec@codeaurora.org>
Cyclic Redundancy Check is performed on object configuration
during boot. Some of the atmel controllers store incorrect
CRC and causes the driver to fail. Add optional feature to
disable CRC in such cases.
Change-Id: I512318976462de4944184a05d9ca9745a545b270
Signed-off-by: Mohan Pallaka <mpallaka@codeaurora.org>
Add lis3dh accelerometer sensor interrupt handler, so we can select
interrupt mode or polling mode.
Change-Id: I36172bb2b04e0a787a1d07c735b0783c83ebe5ca
Signed-off-by: c_daqing <chendaqing@codeaurora.org>
The touchscreen controllers are field-swappable on both customer
devices and internal reference devices. It is possible to have
multiple Synaptics touch controllers where each controller would
support softkey in a different way. While some touch controllers
support 2-dimensional touch sensor, some others support capacitative
button(0D) sensing. In the former case, the touch sensor reports
native X-Y touch coordinates of the touch sensor in the soft key region.
This is implemented by RMI4 function F11 or F12 and software needs to
translate these coordinates to keycodes. In the latter case, the touch
sensor directly reports the key codes and hence there is no need for
software to do any translation. This is implemented by RMI4 function
F1A or F19.
The current architecture of Synaptics touchscreen driver does not have
support to disambiguate between more than two Synaptics touch controllers
that support 2-dimensional touch sensor for soft keys. To support
this functionality in driver, a device-tree property is defined that
describes the key codes for the soft-key area. The driver calculates
the total soft key area based on the display resolution and touch sensor
dimensions. Based on the total soft-key area and number of keys to be
supported, it calculates the area for each of the soft-keys. It exports
this information to userspace by populating a sysfs file. User-space
programs can then translate the touch coordinates received to key codes.
Change-Id: I99876527660d0be7cef86e88d7583e331159e7eb
Signed-off-by: Himanshu Aggarwal <haggarwa@codeaurora.org>
Signed-off-by: Shantanu Jain <shjain@codeaurora.org>
The touchscreen controllers are field-swappable on both customer
devices and internal reference devices. Current touch driver
architecture for Synaptics does not support dynamic detection
of two or more Synaptics touchscreens having same slave address. The
patch provides a solution for the scenario in which it is required
to swap two Synaptics touchscreens without changing DT. Support of
this is added in driver as follows:
1. During driver probe, touch controller is identified by reading
the Package Id from controller. Package ID in F01_RMI_Query register
comprises of a 16-bit Package ID and a 16-bit Package ID Revision
of which both are unique for a touch controller part. If Package ID
is present,then a RMI read operation in UI Mode at seventeenth
register from F01 Query base returns it. First two bytes of this
Package ID base are used to select the correct Synaptics touch
controller from device tree.
2. Add a new property synaptics,detect-device in DT files which
will allow software to enable this logic to detect correct
touchscreen slave.
3. All such devices are placed as child nodes of Synaptics
Touchpanel node. These child nodes are parsed only if the property
synaptics,detect-device is defined in DT file.
Change-Id: I2383b8bed85b130a8558db403b565cec693d17fa
Signed-off-by: Himanshu Aggarwal <haggarwa@codeaurora.org>
Signed-off-by: Shantanu Jain <shjain@codeaurora.org>
Add support for following features to touch controller driver
- xvdd regulator
- i2cmode gpio
- pin control framework
- early suspend
- frame buffer notifications
Change-Id: Ib8338351dfd4927c33bf0ed383dd0d550a3d6e46
Signed-off-by: Mohan Pallaka <mpallaka@codeaurora.org>
The firmware image format is changed in CTP FT6436. Also vendor
id and version id are read from fw image from a different offset
as compared to previous controllers. The driver is updated to
support the new image format.
Change-Id: I465fdfa73e56e8fc4bbfdde980c558e4715d6d08
Signed-off-by: Mao Li <maol@codeaurora.org>
Add standard features to Synaptics V2 driver. The supported
features are -
- Frame buffer(fb) blank/unblank notifications
- Pin control framework for gpios
- Sysfs interface for config id
- Dtsi interface for panel and display resolution
Change-Id: I7b057b09a2f2f1e30fe0ae5f1449282fe06551dd
Signed-off-by: Mohan Pallaka <mpallaka@codeaurora.org>
Add support to modify the Maximum_X_Position and
Maximum_Y_position in F11 and F12 control registers.
Re-programm the maximum coordinates of touch controller
if the firmware resolution mismatches the required
touch panel resolution.
Change-Id: I6256ff861f7830f5604f8be3552266edb5aa07ba
Signed-off-by: Shantanu Jain <shjain@codeaurora.org>
The touchscreen controllers are field-swappable on both customer
devices and internal reference devices. Current touch driver
architecture for Synaptics does not support dynamic detection
of two Synaptics touchscreens with the same slave address. The
patch provides a solution for the scenario in which it is required
to swap two Synaptics touchscreens without changing DT. Support of
this is added in driver as follows:
1. During driver probe, touch controller is identified by reading
the Package Id from controller. Package ID in F01_RMI_Query register
comprises of a 16-bit Package ID and a 16-bit Package ID Revision
of which both are unique for a touch controller part. If Package ID
is present,then a RMI read operation in UI Mode at seventeenth
register from F01 Query base returns it. First two bytes of this
Package ID base are used to select the correct Synaptics touch
controller from device tree.
2. Add a new property synaptics,detect-device in DT files which
will allow software to enable this logic to detect correct
touchscreen slave.
3. All such devices are placed as child nodes of Synaptics
Touchpanel node. These child nodes are parsed only if the property
synaptics,detect-device is defined in DT file.
Change-Id: Iac0eaef1b8cd301da763ef980a33ba27ccfb858d
Signed-off-by: Himanshu Aggarwal <haggarwa@codeaurora.org>
This is the initial commit.
Change-Id: I24152b29e43cb2e54200ff1bf7d2151da7d2b2b3
Signed-off-by: Samuel Huo <samuel.huo@st.com>
Git-commit: ab583de73a4eede72c3ecf409c1f90f07c8e857c
Git-repo: https://github.com/stmems/sensors-linux-drv
Signed-off-by: Bingzhe Cai <bingzhec@codeaurora.org>
Enable device tree support along with necessary
platform data entries.
Change-Id: I6ff46b807fc8396674d834e9e8902916aa10dd95
Signed-off-by: Mohan Pallaka <mpallaka@codeaurora.org>
Add support for gpios to be configured by driver.
Change-Id: Id66aba9ce1a71dd18eb6d6ef06dadae89b148889
Signed-off-by: Amy Maloche <amaloche@codeaurora.org>
Enable device tree support along with necessary
platform data entries.
Change-Id: If50b937d67f38b76e2224f161c7b9b0a2392572b
Signed-off-by: Amy Maloche <amaloche@codeaurora.org>
This change removes source files from the kernel tree that
were not being used during make. The list of used files
was generated using an annotated make log and was then
compared with new files added since the public release of
kernel version 3.10.00. New files which were added but
not used have been removed from the tree.
A diff was also run to determine the list of files that had
been modified since the release of kernel version 3.10.00.
These files were then scrubbed based on the current kernel
configuration, removing invalid and unused conditionals.
Some files which support planned functionality or are
useful in debugging have been excluded from this reap.
Change-Id: Ia44a224d3cea7bc78dd45e8a8279860d35d4b008
Signed-off-by: Ian Maund <imaund@codeaurora.org>
Focaltech touchscreen ICs may use different chip IDs for same module.
Add support to ignore ID check for such cases.
Change-Id: I0fe8da6a5e687317b4878b59ac5d1a4a4b620e1d
Signed-off-by: Bingzhe Cai <bingzhec@codeaurora.org>
Read display resolution from platform data in order
to properly use all virtual key implementations.
Change-Id: Ic0a13d6a8166379f08c5bfb49d5ea47ac22b3229
Signed-off-by: Amy Maloche <amaloche@codeaurora.org>
Upgrade firmware on the controller only when a new
version of firmware is available.
Change-Id: I4cf75b3c5efb90f151da09ed73b1ba62b9b5bb1c
Signed-off-by: Mohan Pallaka <mpallaka@codeaurora.org>
To support all models supported by focaltech push necessary
parameters to platform data.
Change-Id: I00b0e8ba7cfc8d8fbd48aa910bd3d0010283ed00
Signed-off-by: Mohan Pallaka <mpallaka@codeaurora.org>
Allow user to set reset delay in device tree. Default at
100ms.
Change-Id: Ie785e7b1d6c1c734faee72962f1dee4db7034a65
Signed-off-by: Amy Maloche <amaloche@codeaurora.org>
Support flip X & flip Y through sysfs entry and move
lockdown enablement to device tree from #define.
Change-Id: If5cf5fc6c07f9226800823f64d14a01d3651d9aa
Signed-off-by: Amy Maloche <amaloche@codeaurora.org>
In order to save power, enable GPIOs to go into suspened mode
during sleep by freeing them, and re-requesting on wake.
Change-Id: I5b1839f5a15fff0bad13b636be35079a8687fa6a
Signed-off-by: Amy Maloche <amaloche@codeaurora.org>
In order to save maximum power, turn regulators completely off
in suspend instead of just putting into low power mode.
Change-Id: Ib325c7acf4c03a63124ed8d4f15b446ac8ad5ecb
Signed-off-by: Amy Maloche <amaloche@codeaurora.org>
This reverts commit c790dc84494b016ffe65f3bc18793ed6bc6d5ff2.
It causes 1.5mA rock bottom regression in 8226. A new fix is needed.
Change-Id: I9454693070b29f4ee87f8194b7460704ced657fb
Signed-off-by: Harry Yang <harryy@codeaurora.org>
In order to save maximum power, turn regulators completely off
instead of just putting into low power mode.
Change-Id: I43042283dc1e06a8c26fd7b14556180389869059
Signed-off-by: Amy Maloche <amaloche@codeaurora.org>
Accelerometer Kionix kxtj9 always outputs 8-bit data because assign
a boolean value to bit mask variable. This patch will fix this and
also change the resolution control variable name from "res_12bit"
to "res_ctl" to avoid misleading.
Change-Id: I4784bfb18679a1a64941eafc80762241cdd825fe
Signed-off-by: Figo Wang <figow@codeaurora.org>
Add device tree support in mpu3050 driver to parse and handle
sensor device configuration from DT. 'enable_gpio' is added as
the switch control for sensor vlogic power.
Change-Id: I45b5c0bf791d96646cd9ecfe4ac1038da97262e2
Signed-off-by: Richard Liu <richardl@codeaurora.org>
Use same name as name of input device on G-sensor driver kxtj9 and lis3dh
that HAL layer library can use same name to find them, that we can share
sensor library over projects which use different sensor device.
Signed-off-by: Figo Wang <figow@codeaurora.org>
Change-Id: I51ef9f2dfea23895a062009c7fdeb21d3fcef91a
Regulator will always be required, so use it by default.
Remove unnecessary device tree entry.
Change-Id: If9480e4d6d8b2290eca6f594048948a77ef42d08
Signed-off-by: Amy Maloche <amaloche@codeaurora.org>
Add DeviceTree support for focaltech controller driver.
The data is represented in device tree format and parsed
by the driver using of framework apis.
Change-Id: Ibcdd8c3579f401ac0632d670e1b7c674aa67ba8d
Signed-off-by: Mohan Pallaka <mpallaka@codeaurora.org>
Add virtual key position offset to match virtual key positions with
front panel.
Change-Id: Ibbf89e816d9654f202b75470df0c673aa42439c8
Acked-by: Chun Zhang <chunz@qti.qualcomm.com>
Signed-off-by: Amy Maloche <amaloche@codeaurora.org>
Firmware name should be passed in based on target, not hardcoded.
Remove hardcoding and add appropriate error checking for this.
Change-Id: Ia95bf2abf8a86adc649d64d757f22d84c8e0053f
Signed-off-by: Amy Maloche <amaloche@codeaurora.org>
To work with device tree framework, support must be added
in driver. Read in properties such as gpios, x/y size and
soft button mapping. Also, enable multitouch with protocol
b.
Change-Id: I17f41105c57f22db1623d03627ca89f47ef57a8b
Signed-off-by: Amy Maloche <amaloche@codeaurora.org>
Add support for regulators to be controlled from driver
side. This includes configuration and enablement.
Change-Id: I899dec377c4b766749d3f70b80a51f3c21757911
Signed-off-by: Amy Maloche <amaloche@codeaurora.org>
Add synaptics driver support and firmware update support
for synaptics touch panel, this patch also adds support
for virtual keys. Corrects issues in "first commit" and
"v1.1" of open source code.
Change-Id: I78dcc2f540ca78e192b4570e414a8802e8982945
Signed-off-by: Amy Maloche <amaloche@codeaurora.org>