Return chip values with an 0x prefix so that the bash
init script can compare hex values with > and <.
Change-Id: If3c1ef37acf550433d114718a66b248d7b1e5e32
Signed-off-by: Ryan Lattrel <ryanl@motorola.com>
Reviewed-on: https://gerrit.mot.com/1442938
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Cesar Augusto Marcelino dos Santos <cmsantos@motorola.com>
Reviewed-by: Ling Jin <lingjin@motorola.com>
Submit-Approved: Jira Key
L(CR) (CR) we need to make sure to set intval
to 0 at the end of chrager presence detection because
it can report incorrectly while in sink mode(aka otg cable)
Change-Id: Ib7b93ec77929d4c738498fe3fee2e78d556661ce
Signed-off-by: Curtis Porter <porterc@motorola.com>
Reviewed-on: https://gerrit.mot.com/1438655
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Cesar Augusto Marcelino dos Santos <cmsantos@motorola.com>
Reviewed-by: Ling Jin <lingjin@motorola.com>
Submit-Approved: Jira Key
(cherry picked from commit 0a86b47264b81c699ac20613b3dbbd7a643708a2)
Reviewed-on: https://gerrit.mot.com/1444680
Sometimes memory is scarce, especially those continuous memory,
so use vzalloc to have more chance to allocate memory successfully.
Change-Id: I374d9009092701ba1c3d609ad05271af0739fd35
Signed-off-by: yangjq <yangjq@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1436053
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
(cherry picked from commit c3499d1140811a8c1e8edfc3ef715170f8f98a1d)
Reviewed-on: https://gerrit.mot.com/1442611
Reviewed-by: Chuanchun Zhu <zhucc2@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
- Because now we are using stylus on sofiap and this will keep
touch always on high sensitive mode which will easy to lead to
the problem such as ghost touch , residue points etc. So we add
a pen notifier to touch and then the firmware of the touch can adjust
the mode according to the status of the pen.
Change-Id: Idb333c38a2af08d8d9a7038b9a8c87f80bdefed7
Signed-off-by: wengjun1 <wengjun1@motorola.com>
Reviewed-on: https://gerrit.mot.com/1441556
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jianqiu Huang <huangjq9@motorola.com>
Reviewed-by: Yeqing Wang <wangyq13@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
For the EV_SW type event, only the event value of 0/1 will be reported,
and other values are reported as value 1 reported.
If the status is unstable, the status of the report will be inconsistent
with the actual status.
Remove unnecessary events that reported value 2.
Change-Id: I304dc9632f026a8417d2ac87cf19be6e31f05ca4
Signed-off-by: huangjq9 <huangjq9@motorola.com>
Reviewed-on: https://gerrit.mot.com/1442158
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
-Fix registers for the mode and the interrupt handler
-Add extra fields to assist in firmware flashing
-Update power_supply fields to the correct values
-Clean up debug messages
-Add initial BPP/EPP mode voltages and currents
-Add wakeup source to keep awake when charging
-Add sysfs hook to enable/disable tx_mode
-Remove unused code leftover from p922x driver
Change-Id: Ieaf95cf8a93440761e236c75443e730c9c89da0f
Reviewed-on: https://gerrit.mot.com/1436652
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Ling Jin <lingjin@motorola.com>
Reviewed-by: Cesar Augusto Marcelino dos Santos <cmsantos@motorola.com>
Submit-Approved: Jira Key
For bringup purpose adding stubs for the functions from other DLKM
not available at the moment.
Change-Id: I91c42f0c4472db606b871b10a1c64217fd3fd635
Signed-off-by: Konstantin Makariev <hcv867@motorola.com>
Reviewed-on: https://gerrit.mot.com/1441361
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Konstantin Makariev <kmakariev@motorola.com>
Submit-Approved: Jira Key
For device without kungpow, KPDPWR bark irq is recommended to
halt the kernel. But since this is a hard reset, a dvdd flag
(reuse the kungpow bit flag) is needed to indicate this is
an intended HW reset by s1 timer, even if s2 is not fired. In this
way, bootloader is able to detect correct power up reason (0x100000).
Dependency: BL need to detect this bit flag for power up reason
amendment.
Change-Id: If4f2cffc87bd75fd03fcb5cbf87cd90664eb71bf
Signed-off-by: Donghua Yan <a18317@motorola.com>
Reviewed-on: https://gerrit.mot.com/1439390
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Qing Chang <qing@motorola.com>
Submit-Approved: Jira Key
- Because now we are using stylus on sofiap and this will keep
touch always on high sensitive mode which will easy to lead to
the problem such as ghost touch , residue points etc. So we add
a pen notifier to touch and then the firmware of the touch can adjust
the mode according to the status of the pen.
Change-Id: I328fbe973d960e0decc60b86e4d16140e66e2cb9
Signed-off-by: wengjun1 <wengjun1@motorola.com>
Reviewed-on: https://gerrit.mot.com/1438179
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jianqiu Huang <huangjq9@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
sync sx933x patch to abov sar sensor code:
(CR) sensor:sometimes avc error after reboot
Issue:
Sometimes avc error after reboot:
avc: denied { write } for comm="capsense_reset" name="reset" dev="sysfs"
ino=54780 scontext=u:r:capsense_reset:s0 tcontext =u:object_r:sysfs:s0
tclass=file permissive=0 pkg=""
Rootcause:
class_register logic: -create sysfs dir 'capsense'
-send uevent 'add' to hal
-create sysfs file 'reset'
Most of times sysfs file haven't create while ueventd monitor 'ADD' to
fresh sys/class/capsense label as 'sysfs_capsense',
file under capsense will inherit /sys label ,which is 'sysfs'.
Fix:
Send uevent 'CHANGE' again to HAL,
so that relabeling '/sys/class/capsense/*'.
Change-Id: Iea5270830160e1edef2429ae11829eccbb388838
Signed-off-by: chenlj2 <chenlj2@motorola.com>
Reviewed-on: https://gerrit.mot.com/1436924
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jiacheng Ou <oujc1@motorola.com>
Reviewed-by: Jianqiu Huang <huangjq9@motorola.com>
Reviewed-by: Tao Sun <suntao2@motorola.com>
Reviewed-by: Wen Xie <xiewen3@motorola.com>
Submit-Approved: Jira Key
This macro is used to enable factory test in driver.
But moto use jar for test, so it's useless.
Change-Id: Id612aae662d54a36b922169d397a0834426055d4
Signed-off-by: wangyq13 <wangyq13@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1436897
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
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
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
permissions. But ueventd thread have ran before sys entries
created. In this case, sys entries owner and permissions will
not be set correctly. So After sys entries created, send an
update uevent to user space.
Change-Id: I268c61af7ca39abc4d8a71e573c91d3f0a96762c
Signed-off-by: wangdw10 <wangdw10@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1436717
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Yuecai Liu <liuyc20@motorola.com>
Reviewed-by: Jingjing Xiao <xiaojj1@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
In some scenario, vibrator may can not stop immediately
because stop command was returned. use 5ms delay
to replace it and make sure short vibrator can work well.
Change-Id: I82720f0d031c7306e1b5f806aa5a380ccccb8eec
Signed-off-by: Weilong Wu <wuwl10@motorola.com>
Reviewed-on: https://gerrit.mot.com/1436810
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Hujun Liao <liaohj@motorola.com>
Submit-Approved: Jira Key
sync sx933x patch to sx9310 and sx9325:
(CR) sensor:sometimes avc error after reboot
Issue:
Sometimes avc error after reboot:
avc: denied { write } for comm="capsense_reset" name="reset"
dev="sysfs" ino=54780 scontext=u:r:capsense_reset:s0 tcontext
=u:object_r:sysfs:s0 tclass=file permissive=0 pkg=""
Rootcause:
class_register logic:
-create sysfs dir 'capsense'
-send uevent 'add' to hal
-create sysfs file 'reset'
Most of times sysfs file haven't create while ueventd monitor 'ADD'
to fresh sys/class/capsense label as 'sysfs_capsense',file under
capsense will inherit /sys label ,which is 'sysfs'.
Fix:
Send uevent 'CHANGE' again to HAL,so that relabeling
'/sys/class/capsense/*'.
Change-Id: Ibe356ce4670bc33874f351b4371aec5e9d0c80fb
Signed-off-by: Wen Xie <xiewen3@motorola.com>
Reviewed-on: https://gerrit.mot.com/1436726
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Submit-Approved: Lu Lu <lulu2@lenovo.com>
Reviewed-by: Jiacheng Ou <oujc1@motorola.com>
Reviewed-by: Xiangpo Zhao <zhaoxp3@motorola.com>
TP:
If tp gesture is not enabled, disable touch irq when suspend, and enable
it in resume
Change-Id: I1a0973206e0bcd81c3dd020538c357b7913ad142
Signed-off-by: haojl2 <haojl2@motorola.com>
Reviewed-on: https://gerrit.mot.com/1436140
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Reviewed-by: Jun Weng <wengjun1@motorola.com>
Submit-Approved: Jira Key
TP:
Change sensor flag into on-change sensor.
one shot sensor can not work normal for TDDI panel
Change-Id: Ia1a99650e0885187fea6bbcfdc36d4e484c4e17a
Signed-off-by: haojl2 <haojl2@motorola.com>
Reviewed-on: https://gerrit.mot.com/1435388
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jianlin Nie <niejl1@motorola.com>
Reviewed-by: Hujun Liao <liaohj@motorola.com>
Submit-Approved: Jira Key
TP:
Change sensor flag into on-change sensor.
one shot sensor can not work normal for TDDI panel
Change-Id: I0a33ad017b2a11e86f3f437009904678509a9f22
Signed-off-by: haojl2 <haojl2@motorola.com>
Reviewed-on: https://gerrit.mot.com/1435389
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jianlin Nie <niejl1@motorola.com>
Reviewed-by: Hujun Liao <liaohj@motorola.com>
Submit-Approved: Jira Key
Add an additional chip id 0x97 to match evt
part change.
Change-Id: I2660c0f2694a8f4d5c1e3933ba44e02fe9542d86
Signed-off-by: Ryan Lattrel <ryanl@motorola.com>
Reviewed-on: https://gerrit.mot.com/1432851
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Ling Jin <lingjin@motorola.com>
Submit-Approved: Jira Key
when in STEP FLOAT, charging will don't stop when current less than
charging iterm, so we add stop charging in STEP FLOAT.
Change-Id: I2c710dfd2b8026c57ca88a17b7d85cae7a241bbf
Signed-off-by: Haijian Ma <mahj8@motorola.com>
Reviewed-on: https://gerrit.mot.com/1430072
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Lu Chai <chailu1@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
For testing purposes and due to continuous hardware modifications,
some temperature values may provide incorrect values due to
thermistor positioning or calibration. Hence, performing runtime
temperature limitation sets for internal testing can avoid
unexpected behaviors, l(CR) charging speed limitations.
Change-Id: I5016cd2ddeb7c8c3afbeb1277a208dbc80853709
Signed-off-by: Cesar Santos <cmsantos@motorola.com>
Reviewed-on: https://gerrit.mot.com/1432920
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Ling Jin <lingjin@motorola.com>
Submit-Approved: Jira Key
CONFIG_SPECTRA_CAMERA has to be defined so that the
correct cci subdev is returned by cam_cci_get_subdev.
Change-Id: I98e4c8653fe50d88db58026509122261ce78fa9c
Reviewed-on: https://gerrit.mot.com/1428309
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Rav(CR) Vembu <raviv@motorola.com>
Submit-Approved: Jira Key
cherry-pick from (CR)
Goodix FOD driver is used for Goodix G5-GW9608
Fingerprint Over Display (FOD) sensor.
Change-Id: I31a45ec4239d63bcc520013e63ba7da1c900fb85
Signed-off-by: Yan Zhang <zhangy26@motorola.com>
Reviewed-on: https://gerrit.mot.com/1402926
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Konstantin Makariev <kmakariev@motorola.com>
Submit-Approved: Jira Key
Touch power supplies AVDD and IOVDD might not be always on and then
kernel driver needs to vote for them. Adding optional handling for
avdd and iovdd. Both power supplies can be configured in device tree
Change-Id: I9e22a4e1fe18c9d1e36defe7c98ce6c3852b722b
Signed-off-by: Konstantin Makariev <hcv867@motorola.com>
Reviewed-on: https://gerrit.mot.com/1428943
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Konstantin Makariev <kmakariev@motorola.com>
Submit-Approved: Jira Key
- (CR): focaltech_0flash_mmi: set deep sleep when predict failed
- (CR): focaltech_0flash_mmi: set reset pin to 0 if vio is close
- Release all fingers when resume
Change-Id: Ia6b8169d560951c3407a8c2b28b2d21d071bf710
Signed-off-by: wengjun1 <wengjun1@motorola.com>
Reviewed-on: https://gerrit.mot.com/1427799
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Yeqing Wang <wangyq13@motorola.com>
Reviewed-by: Hujun Liao <liaohj@motorola.com>
Submit-Approved: Jira Key
TP:
When gesture is on, LCD need use different suspend command.
Return specific value to LCD to tell current gesture state.
Change-Id: I79e57f448d38d1077f86748d2cacf88e3a74b4e0
Signed-off-by: haojl2 <haojl2@motorola.com>
(cherry picked from commit aa605c8d93b9c8258ad3e2133894330aa7f99713)
Change-Id: I79e57f448d38d1077f86748d2cacf88e3a74b4e0
Reviewed-on: https://gerrit.mot.com/1426753
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jialei Hao <haojl2@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Reviewed-by: Jun Weng <wengjun1@motorola.com>
Submit-Approved: Jira Key
Adding regulator driver for the device Dialog SLG51000.
The SLG51000 device contains seven compact and customizable low
dropout regulators and is designed for high performance camera modules
and other small multi-rail applications.
Change-Id: I871afe5c6b2f9e32e73696519983db33b04feeb6
Signed-off-by: Eric Jeong <eric.jeong.opensource@diasemi.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Ravi Vembu <raviv@motorola.com>
Mot-CRs-Fixed: (CR)
Change-Id: I871afe5c6b2f9e32e73696519983db33b04feeb6
Reviewed-on: https://gerrit.mot.com/1412454
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Rav(CR) Vembu <raviv@motorola.com>
Submit-Approved: Jira Key
When the power state is changing, which causes the USB plug to be mistaken,
and the sar sensor is calibrated.
Change-Id: Ia844dd891bc1301c7fa2f73617db92ccbdb6a435
Signed-off-by: huangjq9 <huangjq9@motorola.com>
Reviewed-on: https://gerrit.mot.com/1426418
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jun Weng <wengjun1@motorola.com>
Reviewed-by: Jiacheng Ou <oujc1@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
Enforcing SW reset on resume. Type of reset can be configured via device
tree option sec,reset-on-resume, which now accepts an argument. Type 1
correspods to HW and 2 to SW reset.
Change-Id: I751cfbe1d19a9e583def7e7889ee914a999bd542
Signed-off-by: Konstantin Makariev <hcv867@motorola.com>
Reviewed-on: https://gerrit.mot.com/1425966
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Konstantin Makariev <kmakariev@motorola.com>
Submit-Approved: Jira Key
TP:
Moto TP FW upload script is not bringuped for this driver.
So set firmware name in dtsi for racer lite.
Change-Id: Ia65ddf142e01c08448e23e88ae8116e623c18ac1
Signed-off-by: haojl2 <haojl2@motorola.com>
Reviewed-on: https://gerrit.mot.com/1426485
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Tao Sun <suntao2@motorola.com>
Submit-Approved: Jira Key
TP:
Moto TP FW upload script is not bringuped for this driver.
So update FW automatically when bootup.
Change-Id: Iabc14f37f0207bd535f25e02574ef9eefae8b358
Signed-off-by: haojl2 <haojl2@motorola.com>
Reviewed-on: https://gerrit.mot.com/1426462
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Tao Sun <suntao2@motorola.com>
Submit-Approved: Jira Key
Two function registers address form PM660 are different
with other PMICs:
PM660:
1341: USB_CMD_ICL_OVERRIDE
160B: POWER_PATH_STATUS_REGS
Other PMICs:
1342: USB_CMD_ICL_OVERRIDE
110B: POWER_PATH_STATUS_REGS
Change-Id: If1c2bcacf498281bf1b4156b65021e9b83c44041
Signed-off-by: xuwt2 <xuwt2@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1426165
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key