Commit graph

707 commits

Author SHA1 Message Date
Konstantin Makariev
1464201514 sec_mmi: hack for input device name
Samsung LSI touch driver creates input device with name
samsung_mmi.primary. Framework has primary touchscreen input
name hard coded as synaptics_mmi.primary and thus won't accept
touch events from new input. This is temporary hack to allow
functional touch until CR (CR) gets resolved.

MMI_STOPSHIP

Change-Id: Ia69683d25f5216c642d86bd62e6bd29839f5b9c8
Signed-off-by: Konstantin Makariev <hcv867@motorola.com>
Reviewed-on: https://gerrit.mot.com/1394708
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Konstantin Makariev <kmakariev@motorola.com>
Submit-Approved: Jira Key
2019-07-31 23:52:30 +00:00
Konstantin Makariev
48c03881f2 sec_mmi: move mmi interfaces under i2c device path
MMI interfaces expected to reside under I2C device path to ensure
successful firmware update.

Change-Id: I7335df7184b593b72462e6a310776ef08e6e0a54
Signed-off-by: Konstantin Makariev <hcv867@motorola.com>
Reviewed-on: https://gerrit.mot.com/1395090
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Konstantin Makariev <kmakariev@motorola.com>
Submit-Approved: Jira Key
2019-07-31 23:51:51 +00:00
Konstantin Makariev
9cdcea28d2 synaptics_mmi: optimize probe execution
Probe was taking long time to fail when HW not detected due to
various delays in detection work and I2C transactions. This allowed
for resources allocation errors in another driver started
concurrently.

Change-Id: I1cb5e9c206197c8a4af3be2902a6f7f6c8249c8d
Signed-off-by: Konstantin Makariev <hcv867@motorola.com>
Reviewed-on: https://gerrit.mot.com/1395070
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Reviewed-by: Konstantin Makariev <kmakariev@motorola.com>
Tested-by: Jira Key
Submit-Approved: Jira Key
2019-07-31 23:29:22 +00:00
Ryan Lattrel
4f2e232594 power: max17xx: Reset fuel gauge on diff
Reset the main and flip fuel gauges if there is a difference
of more than 15 percent between the two.  This could indicate
that there is an error with the capacity value, as it
should not be physically possible for this to happen.

Change-Id: I3b74d97c1892bf1dfe537f29818dbe735f0bfa01
Signed-off-by: Ryan Lattrel <ryanl@motorola.com>
Reviewed-on: https://gerrit.mot.com/1390571
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Cesar Augusto Marcelino dos Santos <cmsantos@motorola.com>
Reviewed-by: Konstantin Makariev <kmakariev@motorola.com>
Submit-Approved: Jira Key
2019-07-31 17:27:24 +00:00
Konstantin Makariev
20b1b03bf5 sec_mmi: restore internal access to sec device
Samsung LSI has tool accessing touch IC information via bunch
of function provided by sec device. This function was temporarily
unavailable to simplify bringup.

Change-Id: I9eb29f0ed8a52126df0a5dcfecf0d26dd5d7f5cc
Signed-off-by: Konstantin Makariev <hcv867@motorola.com>
Reviewed-on: https://gerrit.mot.com/1393553
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Konstantin Makariev <kmakariev@motorola.com>
Submit-Approved: Jira Key
2019-07-30 19:29:24 +00:00
liaohj
bf99337c22 modules:tfa98xx:delete time printk
cherrypick from (CR)
- fix compile fail.
  error: 'start_time' may be used uninitialized in this function
  [-Werror=maybe-uninitialized]
- just printk start time. delete it.

Change-Id: I846597f1227e958b1360d0cfd61756a67e56c9a1
Signed-off-by: liaohj <liaohj@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1260694
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Minghui Wei <weimh1@motorola.com>
Reviewed-by: Wanlong Zhou <zhouwl@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
(cherry picked from commit b9b7b207c4b80f8e99ecbd0dcf0573525dc88a66)
Reviewed-on: https://gerrit.mot.com/1393913
Reviewed-by: Hujun Liao <liaohj@motorola.com>
2019-07-30 08:31:46 +00:00
Yonghua Yan
7385bf598a power: override USB ICL
Override USB ICL using the targer ICL value, so that
the ICL settled value will not be limited to a lower
value than target value.
For example, when connect device using a CC floated
typec cable, the settled icl will be set to 100mA,
which will block the charging.

Change-Id: Icd2ea3e020437297642d790f4e1fa8ab25231504
Signed-off-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/1393334
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Ryan Lattrel <ryanl@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Reviewed-by: Haijian Ma <mahj8@motorola.com>
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2019-07-30 08:25:58 +00:00
liuyc20
26b854ce75 usbnet: Release skb if bulk_in do not enable completely
sometimes TCP/IP send data before usbnet port complete.
Free the skb in this case.

05-15 18:56:41.065 0 0 I Call trace:
05-15 18:56:41.065 0 0 I : usb_ep_queue+0x104/0x118
05-15 18:56:41.065 0 0 I : usb_ether_xmit+0xd0/0x200 [moto_f_usbnet]
05-15 18:56:41.065 0 0 I : dev_hard_start_xmit+0x148/0x298
05-15 18:56:41.065 0 0 I : sch_direct_xmit+0x160/0x1a8
05-15 18:56:41.065 0 0 I : __dev_queue_xmit+0x4c0/0x738
05-15 18:56:41.065 0 0 I : dev_queue_xmit+0x10/0x18
05-15 18:56:41.065 0 0 I : neigh_resolve_output+0x158/0x188
05-15 18:56:41.065 0 0 I : ip6_finish_output2+0x470/0x5f8
05-15 18:56:41.065 0 0 I : ip6_finish_output+0x190/0x210
05-15 18:56:41.065 0 0 I : ip6_output+0xc0/0x1a8
05-15 18:56:41.065 0 0 I : ndisc_send_skb+0x348/0x420
05-15 18:56:41.065 0 0 I : ndisc_send_ns+0x218/0x250
05-15 18:56:41.065 0 0 I : addrconf_dad_work+0x41c/0x708
05-15 18:56:41.065 0 0 I : process_one_work+0x1f4/0x458
05-15 18:56:41.065 0 0 I : worker_thread+0x2f0/0x458
05-15 18:56:41.065 0 0 I : kthread+0x110/0x120
05-15 18:56:41.065 0 0 I : ret_from_fork+0x10/0x18
05-15 18:56:41.065 0 0 W : --[ end trace 65a258926fd49736 ]--
05-15 18:56:41.065 0 0 I configfs-gadget gadget: usb_ether_xmit: could not queue tx request

Change-Id: I74edf5bfafd4a157760e118d71c68b794aea2591
Signed-off-by: liuyc20 <liuyc20@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1360881
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Zonghua Liu <a17671@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Reviewed-by: Xiaojun Ji <jixj@motorola.com>
Submit-Approved: Jira Key
(cherry picked from commit 4c7eb1827278db5f6dffe352b1f6e53022429ffd)
Reviewed-on: https://gerrit.mot.com/1393235
Reviewed-by: Haichao Li <liuhc3@motorola.com>
2019-07-30 02:43:22 +00:00
wengjun1
713f4fb686 DLKM: touch: Support CQA test for ft8756
Since the firmware size of ft8756 will exceed 64K, so the CQA test
jar and ini need to be changed, at the same time have to change
touch driver to match this change.Now we need to increase size
when calling download firmware function.

Change-Id: Icea129ab53663006ebedce0af1ff0ba5b8a03f1d
Signed-off-by: wengjun1 <wengjun1@motorola.com>
Reviewed-on: https://gerrit.mot.com/1391750
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Yang Yang <yangy19@motorola.com>
Reviewed-by: Jialei Hao <haojl2@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2019-07-29 03:17:16 +00:00
liuyc20
3a242c673c vl53l1: Update uevent after laser input entries created
Driver code create laser class->create virtual device->
add sys entries to this virtual device.

After laser class or virtual device create, kernel will
send add uevent to userspace.
Ueventd will received this add event and change sys entries
owner and permisions.

But ueventd thread have ran before sys entries created.
In this case, sys entries owner and permisions will not be set
correctly.

So After sys entries created, send a update uevent to userspace.
Make sure ueventd can fix sys entries permision.

Change-Id: I7b206cd99428252a8c2138083ea954211e655e6f
Signed-off-by: liuyc20 <liuyc20@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1392489
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Xiaojun Ji <jixj@motorola.com>
Reviewed-by: Jun Weng <wengjun1@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2019-07-29 03:10:09 +00:00
Yonghua Yan
940f3d27b1 add xtalk and offset sysfs for tof calibration
Add xtalk sysfs interface for tof xtalk calibration.
Update the offset sysfs for tof offset calibration.

Change-Id: I6cb6b9762fa3446829f4bb3f921615215f90a2f1
Signed-off-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/1387848
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Dawei Wang <wangdw10@motorola.com>
Reviewed-by: Yuecai Liu <liuyc20@motorola.com>
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
Reviewed-on: https://gerrit.mot.com/1390242
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
2019-07-29 03:04:57 +00:00
Yonghua Yan
886224b5ec power: add work for charger type correction
The charger type based on BC1.2 detection may be wrong
at the first time when charger is attached.

Add a delay work to check the usb icl and apsd result,
and check if the usb icl is less than 100mA or apsd
is FLOAT/OCP after 10s when the apsd result changes.

This patch can fix the slow charging or no charging issue
due to slow plugin or wrong apsd result.

Change-Id: I8d02edfe4617b23c0a9f8af7251c80f733df0f71
Signed-off-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/1390378
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Haijian Ma <mahj8@motorola.com>
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2019-07-24 09:27:03 +00:00
houdz1
371e29b742 DLKM: Compatible with different modules for focal 0flash
Since we are using different modules with the same IC(ft8756) on
sofia & sofiap, so we need to use different firmware to match different
panel, add dts property focaltech,panel-supplier for this request.

Change-Id: Ie7f74ce4437f7ee2d7f277403b448d099e1fa4dd
Signed-off-by: houdz1 <houdz1@motorola.com>
Reviewed-on: https://gerrit.mot.com/1390106
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jun Weng <wengjun1@motorola.com>
Reviewed-by: Jialei Hao <haojl2@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2019-07-24 01:50:17 +00:00
Konstantin Makariev
d1fcdd2a49 sec_mmi: support normal firmware update
This commit enables firmware update via MMI doreflash interface.
At this point code only covers the case when touch IC has
valid firmware at the time of power up.

Change-Id: I06c7ba1b7e1f6dd6f463bc6e961845555fb6da5b
Signed-off-by: Konstantin Makariev <hcv867@motorola.com>
Reviewed-on: https://gerrit.mot.com/1388759
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Konstantin Makariev <kmakariev@motorola.com>
Submit-Approved: Jira Key
2019-07-23 13:25:21 +00:00
Cesar Santos
a878ec13cd power: qpnp-smbcharger-mmi: Disable Force Votables
On Factory Mode, PMIC module votes on having high charging current,
interpreting USB cable as a Turbo Charger. Setting vote to OFF(0) will reset
such behavior, and will display Toast message correctly only when a Turbo
Charger is plugged.

Based on https://gerrit.mot.com/#/c/1325224/

Change-Id: I3661e6f093d284ce244435b71340d0f7ec56b6ec
Signed-off-by: Cesar Santos <cmsantos@motorola.com>
Reviewed-on: https://gerrit.mot.com/1387920
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Ryan Lattrel <ryanl@motorola.com>
Reviewed-by: Ling Jin <lingjin@motorola.com>
Submit-Approved: Jira Key
2019-07-22 13:34:51 +00:00
haojl2
e3bcdde9df focaltech_0flash: Fix USB detection function
TP:
Increase retry count in USB detection set function.
If retry times larger than max retry number, break set function.

Change-Id: Ifa97ac3f8f66b422bd21dc249acfce081a13b35d
Signed-off-by: haojl2 <haojl2@motorola.com>
Reviewed-on: https://gerrit.mot.com/1389717
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2019-07-22 13:32:43 +00:00
Yonghua Yan
77ca0f2fca power: apply adapter allowance range in PMI632
Configure the usbin voltage allowance range to 5V_TO_9V
according to product requirement.

Change-Id: I3fba391443a411eb54b58965196e6491b3efd9b3
Signed-off-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/1389257
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2019-07-22 09:37:51 +00:00
Alex Narita
01d541eec7 Turn off ToF sensor force device on
Turn off STMVL53L1 ToF sensor force_device_on and
let the ToF power supllies (VDD) to disable during
power down, otherwise ToF VDD will always On.

Change-Id: I17363f88921868a05ef833ce63c94cff0c7b6ecb
Reviewed-on: https://gerrit.mot.com/1368523
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Sumit Jamadar <xkbr38@motorola.com>
Reviewed-by: Rav(CR) Vembu <raviv@motorola.com>
Submit-Approved: Jira Key
2019-07-18 18:54:12 +00:00
yangjq
4cd52d87bc aw8695: Add wakelock to make vibration stop on time
Without wakelock, system would suspend when vibration is on going,
which may cause the STOP command failed to be sent and in turn leave
the phone vibrating for a long time.

Signed-off-by: yangjq <yangjq@lenovo.com>

Change-Id: Iee5d2691954f960f203f4be8c82c9198304f5977
Reviewed-on: https://gerrit.mot.com/1387741
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2019-07-18 10:56:34 +00:00
Konstantin Makariev
9a8a94046a sec_mmi: plug in mmi interfaces
First step to align reference driver's code with MMI requirements

Change-Id: I832c7d2927ccd0d04c6ea44548198fe2e54131d3
Signed-off-by: Konstantin Makariev <hcv867@motorola.com>
Reviewed-on: https://gerrit.mot.com/1387460
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Konstantin Makariev <kmakariev@motorola.com>
Submit-Approved: Jira Key
2019-07-17 21:58:30 +00:00
Konstantin Makariev
bada97e392 synaptics_mmi: export touchscreen class get/set functions
Export touchscreen class get/set functions to allow Synaptics driver
to co-exist with Samsung.

Change-Id: Iadac17f1b8e80a00974c6b58571a55ebe29e2ef2
Signed-off-by: Konstantin Makariev <hcv867@motorola.com>
Reviewed-on: https://gerrit.mot.com/1385480
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Konstantin Makariev <kmakariev@motorola.com>
Submit-Approved: Jira Key
2019-07-17 21:48:05 +00:00
haojl2
f87ee46a09 himax_v2_mmi: release points when tp enter suspend.
TP:
release points when tp enter suspend. This is required for moto

Change-Id: Ife74c0e3def202d0ff8a1b1d00067c5f8368b7bf
Signed-off-by: haojl2 <haojl2@motorola.com>
Reviewed-on: https://gerrit.mot.com/1387003
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2019-07-17 10:17:36 +00:00
huangjq9
0dd39eea44 hall-sensor: add Stylus Detector driver
Stylus Detector is a hall sensor.
Input_Name: pen_detect
Event_type: EV_SW
Event: SW_PEN_INSERTED

When stylus is off, it will report 0(stylus off);
When stylus is on, it will report 1(stylus on);

Change-Id: I7836c19f1142e9112b42d7d12ad788d19163d497
Signed-off-by: huangjq9 <huangjq9@motorola.com>
Reviewed-on: https://gerrit.mot.com/1385729
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Hujun Liao <liaohj@motorola.com>
Reviewed-by: Weilong Wu <wuwl10@motorola.com>
Submit-Approved: Jira Key
2019-07-16 06:06:49 +00:00
Yonghua Yan
19811209d1 power: check the factory image from bootarg in dts
Check the factory image in bootarg in dts so that it can make decision
the first time when the driver is loaded making charging limitation
policy take effect immediately.

Change-Id: I3eb32d3cd252ad9abffab70aa249b41925f325e2
Signed-off-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/1385578
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Haijian Ma <mahj8@motorola.com>
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2019-07-15 12:04:42 +00:00
Yonghua Yan
f3a28daaf2 power: Return effective FCC for constant current
Return effective FCC for constant current in battery property
in PMI632 chip platform as SMB5 QC driver does not support
this property.

Change-Id: I71e2c1559fad0ff3dd5dcd1eb75b6ccb0f5711a6
Signed-off-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/1385623
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2019-07-15 11:57:08 +00:00
haojl2
c91a6f8e9d focaltech_0flash: Enable USB detection function
TP:
Enable USB detection function.
Increase the anti-interference ability after plugging in the USB cable.

Change-Id: I64ecb13f58e87f9f687d4ad3a6725884c7304bc7
Signed-off-by: haojl2 <haojl2@motorola.com>
Reviewed-on: https://gerrit.mot.com/1385264
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2019-07-12 13:36:05 +00:00
haojl2
3736593581 himax_v2_mmi: Enable USB detection function
TP:
Enable USB detection function.
Increase the anti-interference ability after plugging in the USB cable.

Change-Id: I8b7d6138513b02ade09b096935abfc8bbdf56df1
Signed-off-by: haojl2 <haojl2@motorola.com>
Reviewed-on: https://gerrit.mot.com/1385252
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2019-07-12 13:36:00 +00:00
haojl2
d1b6361a13 himax_v2_mmi: Update FW in thread when resume
TP:
Enable FW download function when resume.
Download FW in thread, do not increase screen up time.

Change-Id: Id00af6279b1752ede13b847d2d43e81fd75a0894
Signed-off-by: haojl2 <haojl2@motorola.com>
Reviewed-on: https://gerrit.mot.com/1385251
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2019-07-12 13:35:38 +00:00
Ryan Lattrel
ccfe95d60d power: create charger_mmi debugfs dir
Kernel 4.9 is not able to lookup existing debugfs
directories. Create a charger_mmi dir instead of
adding to the charger dir instead.

Change-Id: Ice155bc2eb60dc27b98c2af0876b9f9ced4f6f34
Signed-off-by: Ryan Lattrel <ryanl@motorola.com>
Reviewed-on: https://gerrit.mot.com/1384240
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Cesar Augusto Marcelino dos Santos <cmsantos@motorola.com>
Reviewed-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2019-07-11 06:16:05 +00:00
gongsc1
3da8d50e42 power:qpnp-smbcharger-mmi:Remove charger config for factory
Factory sw usually use AC adapter to do Runin test.
They think power not off when finished test is a bug.

Change-Id: I28ce0d32c4e2c75c7328ac5f1158ebac039919bb
Reviewed-on: https://gerrit.mot.com/1382878
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Ryan Lattrel <ryanl@motorola.com>
Reviewed-by: Cesar Augusto Marcelino dos Santos <cmsantos@motorola.com>
Reviewed-by: Ling Jin <lingjin@motorola.com>
Submit-Approved: Jira Key
2019-07-11 01:33:13 +00:00
Yonghua Yan
ad6d3453d7 power: support charger register dump
Add charger register dump inferace to the debugfs
for charger register dump.

Change-Id: I516b745168a9d668531429b893a768e2530af182
Signed-off-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/1383100
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Ryan Lattrel <ryanl@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2019-07-10 12:19:30 +00:00
liaoxl
dbaf6b20d1 enable elna in fmradio TCMD test
RF team add one elna for signal losing issue in sofia/Sofia_plus,
we need to enable it before TCMD test, otherwise will get wrong RSSI.

Change-Id: I0ac4d1f13fe4da7cbde14c331c4cd57eafad5b97
Reviewed-on: https://gerrit.mot.com/1382284
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Qiu Feng <fengqiu1@lenovo.com>
Reviewed-by: Yuecai Liu <liuyc20@motorola.com>
Reviewed-by: Tao Sun <suntao2@motorola.com>
Submit-Approved: Jira Key
2019-07-10 04:15:53 +00:00
wangdw10
bc5a38e302 doha: skip disable TOF_VANA when power down
GPIO_70 used for Prox and TOF, don't disable it to avoid Prox can
not work when camera open and exit

Change-Id: Id28677ab24f664dc7af6777459ed7f2ccdece703
Signed-off-by: wangdw10 <wangdw10@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1383266
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Dawei Wang <wangdw10@motorola.com>
Reviewed-by: Chuanxin Guo <guocx4@motorola.com>
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2019-07-10 02:36:47 +00:00
Qiuliang Cheng
2cc59893c2 Doha.Egis: Adjust input key events accordingly to FPS pose
motorola/kernel/modules/drivers/input/misc/ets_fps_mmi:
Kbuild: If current product is Doha, FPS pose is 0 degree of angle
ets_navi_input.c: Set different key events for different FPS pose

Defaultly, the product mounts FPS with pose of 270 degree of angle.
But, for Doha, FPS has a right pose, i.e. with 0 degree of angle.

Change-Id: I051cfc96696f2a0527b5b8e8ea27ca56685ddbcc
Reviewed-on: https://gerrit.mot.com/1381158
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jialei Hao <haojl2@motorola.com>
Reviewed-by: Tao Sun <suntao2@motorola.com>
Submit-Approved: Jira Key
2019-07-09 02:23:59 +00:00
Qiuliang Cheng
75984a81eb Doha.Egis: Add kobject_uevent() in sysfs_egis_init
motorola/kernel/modules/drivers/input/misc/ets_fps_mmi/
ets_navi_input.c: Add kobject_uevent( , KOBJ_CHANGE) at the end of
sysfs_egis_init

To set Egis sysfs file nodes via /vendor/ueventd.rc, uevent should be
sent by calling kobject_uevent().

Change-Id: I1973bca7d4088e0271c3e37b7572ce45831819d7
Reviewed-on: https://gerrit.mot.com/1380409
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jialei Hao <haojl2@motorola.com>
Reviewed-by: Tao Sun <suntao2@motorola.com>
Submit-Approved: Jira Key
2019-07-09 02:23:57 +00:00
huangjq9
b2216cbb0a sar-sensor: Fix compilation issues in SDM660
On the bo branch of the SM660 platform,
since the sx933x.h file are defined in both DLMK and native.
the drivers in DLMK will find the header file from the native firstly
if using the method #include <xxx>.
Be fixed by changing #include <xxx> to #include "xxx".

Change-Id: I0ee4491b5f0273a8c8e3d67ff69fbdadb0187097
Signed-off-by: huangjq9 <huangjq9@motorola.com>
Reviewed-on: https://gerrit.mot.com/1382882
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jiyue Cui <cuijy2@lenovo.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2019-07-08 07:04:16 +00:00
huangjq9
57b272c252 sofia: sx933x: Compatible with external LDO.
The default driver uses the PMIC's LDO output.
The sofia project uses an external LDO power supply.
Make the driver compatible with external LDO power.

Change-Id: I0a7d42dbbbd3ae80e65bcd742309f99c532d39f1
Signed-off-by: huangjq9 <huangjq9@motorola.com>
Reviewed-on: https://gerrit.mot.com/1379366
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Wen Xie <xiewen3@motorola.com>
Reviewed-by: Lijun Chen <chenlj2@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2019-07-08 01:38:13 +00:00
weiweij
60b6181207 driver/boot_info: change boot seq format to decimal
Original boot sequence format is hexadecimal. but for
bootlooder log and logfs format, it is decimal. So in order
to show them as the same format. changing boot sequence
number format in kernel to decimal.

Change-Id: I422359adae3f3c31cd87c2a4d511e00d23fb6db3
Signed-off-by: weiweij <weiweij@motorola.com>
Reviewed-on: https://gerrit.mot.com/1381523
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Chuanchun Zhu <zhucc2@motorola.com>
Reviewed-by: Zhenxin Xi <xizx@motorola.com>
Submit-Approved: Jira Key
(cherry picked from commit eb8e58c71924a1df197d1facb4b2edd93cd1000b)
Reviewed-on: https://gerrit.mot.com/1381613
2019-07-05 07:35:29 +00:00
Yonghua Yan
8eff437c3f Add typec mode check for charger presence
When usb is in suspend state, the power supply usb
and pc_port will be offline. The demo mode cannot exit
from this situation.
Use typec mode as additional condition check for
charger presence, so that the step charge can keep
in demo mode and handle recharge event.

Change-Id: I7c22bb814affd92ab0ef29be149facd6c49f60d5
Signed-off-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/1381455
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2019-07-05 06:50:30 +00:00
liuyc20
88553a17d8 vl53l1: fix build error
loff_t --> %llu
size_t --> %lu

Change-Id: I038cad8baac70c280a591f358fd7a4a1bbd55761
Signed-off-by: liuyc20 <liuyc20@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1379385
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Reviewed-by: Xiaojun Ji <jixj@motorola.com>
Reviewed-by: Dawei Wang <wangdw10@motorola.com>
Submit-Approved: Jira Key
2019-07-04 09:16:46 +00:00
liuyc20
22eff391cf vl53l1: change netlink protocol ID to 8
STMVL531_CFG_NETLINK_USER is defined as 23,which is conflicted with
NETLINK_SOCKET for socket administrative events,(kernel4.14)
but kernel4.9 Netlink_SOCKET is 22.
change it to 8 to avoid the conflict.

8 is NETLINK_ISCSI,
NETLINK_ISCSI only be used by CONFIG_SCSI_ISCSI_ATTRS=y

Change-Id: I91a03cf46dbd6ca6a92dbc37d5bb27e53dd8ea86
Signed-off-by: liuyc20 <liuyc20@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1377648
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Xiaojun Ji <jixj@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Reviewed-by: Dawei Wang <wangdw10@motorola.com>
Submit-Approved: Jira Key
2019-07-04 09:16:21 +00:00
liuyc20
e388a3537b vl53l1: fix i2c dma transfer crash
If the i2c master starts the dma transfer,
the buffer must be physical continous. or i2c_transfer will crash.

__dma_inv_area+0x28/0x58
geni_se_rx_dma_prep+0xb0/0x208
geni_i2c_xfer+0x2e8/0xf88
__i2c_transfer+0x598/0x790
i2c_transfer+0xa0/0xe8
cci_read.isra.1+0xa4/0x140 [stmvl53l1]
VL53L1_ReadMulti+0x3c/0x54 [stmvl53l1]
VL53L1_get_nvm_copy_data+0x40/0x88 [stmvl53l1]
VL53L1_read_p2p_data+0xbc/0x210 [stmvl53l1]
VL53L1_data_init+0x248/0x254 [stmvl53l1]
VL53L1_DataInit+0x28/0xcc [stmvl53l1]
stmvl53l1_setup+0x4a8/0x9f0 [stmvl53l1]
stmvl53l1_probe+0x1e4/0x8c8 [stmvl53l1]
i2c_device_probe+0x258/0x2e0
driver_probe_device+0x4c0/0x658
__driver_attach+0x104/0x1b0
bus_for_each_dev+0x8c/0xd8
driver_attach+0x2c/0x38
bus_add_driver+0x138/0x240
driver_register+0xac/0xf8
i2c_register_driver+0x4c/0xd0
stmvl53l1_init_i2c+0x44/0x188 [stmvl53l1]
stmvl53l1_init+0x3c/0x1000 [stmvl53l1]

Change-Id: I8c328f1e5187dbd1de80aa700aa560ef29a9ed4d
Signed-off-by: liuyc20 <liuyc20@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1377597
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Reviewed-by: Dawei Wang <wangdw10@motorola.com>
Submit-Approved: Jira Key
2019-07-04 09:16:14 +00:00
liuyc20
c3001644d7 vl53l1: fix get signal gpio value way
pwren-gpio only use signal gpio to control. so it is better to use
(of_get_named_gpio) API to get. API(of_property_read_u32_array) was used for
getting mutil value.

Change-Id: I7a8ea686e9f8dced4e39a6c3cb8991cfc39e4418
Signed-off-by: liuyc20 <liuyc20@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1377674
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Xiaojun Ji <jixj@motorola.com>
Reviewed-by: Wei Wei <weiweij@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Reviewed-by: Dawei Wang <wangdw10@motorola.com>
Submit-Approved: Jira Key
2019-07-04 09:16:10 +00:00
Ryan Lattrel
a766f64559 power: wait 30 seconds to determine weak
Wait 30 seconds from a charge mode change event
before checking if the charge mode is weak in order
to prevent false positives.

Change-Id: Ibe816a310bf73e75f43d61dcb3969fa62e87ca3d
Signed-off-by: Ryan Lattrel <ryanl@motorola.com>
Reviewed-on: https://gerrit.mot.com/1380576
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Kenneth Kessler <kennykessler@motorola.com>
Submit-Approved: Jira Key
2019-07-03 14:12:04 +00:00
liaoxl
03d5170904 Initial bringup for FM elan module & use fm_ctrl.ko
As request from RF team, for fmradio signal lose issue in new HW design,
need to add elna module for ensure fmradio performance.

Change-Id: I9c21f63788fbef4c28785e9d985631f1ef248105
Reviewed-on: https://gerrit.mot.com/1376704
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Qiu Feng <fengqiu1@lenovo.com>
Reviewed-by: Tao Sun <suntao2@motorola.com>
Submit-Approved: Jira Key
2019-07-03 06:37:59 +00:00
wangdw10
3f79599b45 vl53l0: improve offset/xtalk calibration time
reduce vl53l0 calibration time to less than 1s

Change-Id: Ia7ce65797e5b88d46ed883bb2e360be0d66a86b2
Signed-off-by: wangdw10 <wangdw10@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1380167
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Dawei Wang <wangdw10@motorola.com>
Reviewed-by: <liuwang1@lenovo.com>
Reviewed-by: Chuanxin Guo <guocx4@motorola.com>
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2019-07-03 01:34:26 +00:00
Konstantin Makariev
572485df96 synaptics_mmi: remove unnecessary logs
Reduce amount of debug logs printed out from detection work

Change-Id: Ib195680ea65a0cb7c035a99ff32393624de01bb0
Signed-off-by: Konstantin Makariev <hcv867@motorola.com>
Reviewed-on: https://gerrit.mot.com/1377866
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Konstantin Makariev <kmakariev@motorola.com>
Submit-Approved: Jira Key
2019-07-02 15:11:55 +00:00
haojl2
84df22401f fpc1020: Add reset function if defined in dts.
If dts defined reset pin, kernel driver reset FPC IC.
If dts not defined this pin, reset function will do nothing.

Change-Id: I59c413c519bd030efa5d3f1ba4a223681db06cdc
Signed-off-by: haojl2 <haojl2@motorola.com>
Reviewed-on: https://gerrit.mot.com/1379449
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Weilong Wu <wuwl10@motorola.com>
Reviewed-by: Lei Chen <chenl18@motorola.com>
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2019-07-02 12:10:54 +00:00
haojl2
e98ba6016d himax_v2_mmi: Enable TP reset in resume.
TP:
Enable TP reset in resume. This can ensure TP panel working normal.
If panel is 0flash panel, we can decrease delay time

Change-Id: I880a4e82e845c79c37ed5be74d59a9e4d9f5105d
Signed-off-by: haojl2 <haojl2@motorola.com>
Reviewed-on: https://gerrit.mot.com/1380206
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2019-07-02 12:09:48 +00:00
haojl2
b3e5067a9b himax_v2_mmi: support set touch info in dts.
TP:
Support set touch_info in dts.

Change-Id: I14e0fecff77bd5c17b022823d8ae351f0986ec88
Signed-off-by: haojl2 <haojl2@motorola.com>
Reviewed-on: https://gerrit.mot.com/1380183
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2019-07-02 12:09:17 +00:00