Added support for active touch area. This feature utilized by
Rollable HAL in Felix. Goodix calls this feature display modes.
Currently supports 5 modes that correspods to primary, rear and
full touch active regions in different slider positions
Change-Id: I0535c1a8c80947452bc20b92feded4d71b8a1905
Signed-off-by: Konstantin Makariev <hcv867@motorola.com>
Reviewed-on: https://gerrit.mot.com/2360061
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Qing Chang <qing@motorola.com>
Submit-Approved: Jira Key
Fix noise test case fail of factory test,still go on noise testing when
noise data check sum error.
Change-Id: I58fb65cb568758c250f7bcbf5ca7f7339ab2ac4a
Signed-off-by: Wenge Zhu <zhuwg1@motorola.com>
Reviewed-on: https://gerrit.mot.com/2360618
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Wei Deng <dengwei1@motorola.com>
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
Fine motor stepping sequences tuning based on closed unit
Change-Id: Iddba5b7a5c7e52c993c16a51fa9e7ed503f2c52f
Signed-off-by: Konstantin Makariev <hcv867@motorola.com>
Reviewed-on: https://gerrit.mot.com/2353560
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Qing Chang <qing@motorola.com>
Submit-Approved: Jira Key
Decrease the log of register panel notifier and print the log every
1s when not find matched display panel.
Change-Id: Iab2f4f7accc4bc9de5722e2d0f03255ad6b764e9
Signed-off-by: Wenge Zhu <zhuwg1@motorola.com>
Reviewed-on: https://gerrit.mot.com/2354041
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jichao Zou <zoujc@motorola.com>
Submit-Approved: Jira Key
1.There is no need to send IC config,this func is a workaround way for old
goodix touch IC to upgrade config again after upgrade touch firmware.
2.Also this func will load config to ram when driver loaded,affecting
touch firmware update.
Change-Id: Icce7a8d57090305231e7f69b2150715578299896
Signed-off-by: Wenge Zhu <zhuwg1@motorola.com>
Reviewed-on: https://gerrit.mot.com/2352764
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jun Weng <wengjun1@motorola.com>
Reviewed-by: Yeqing Wang <wangyq13@motorola.com>
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
There is a mix of devices with 2.3&2.8 pitch motors. Added sequences
for both pitches. Sequence for 2.3 pitch will be set by default.
Setting sequences for 2.8 pitch requires property use-2p8-pitch set
in device tree. In sensors equipped devices each sequence will be
extended with slow PPS stage to ensure it's a bit longer and allow
successful sensors data processing
Change-Id: I2d0242f4d806632468348e609d5d0c60aebad667
Signed-off-by: Konstantin Makariev <hcv867@motorola.com>
Reviewed-on: https://gerrit.mot.com/2351204
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Qing Chang <qing@motorola.com>
Submit-Approved: Jira Key
Sensor data reported whenever signal changes above pre-defined
threshold. This causes data arriving in bursts when signal changes
rapidly. Handle position detection in kthread to ensure no data will
be lost
Change-Id: Ie08d428a47a792e1b80689a99d2587f4b0dbd389
Signed-off-by: Konstantin Makariev <hcv867@motorola.com>
Reviewed-on: https://gerrit.mot.com/2331896
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Qing Chang <qing@motorola.com>
Submit-Approved: Jira Key
TP:
Support double tap to wake up the screen.
Change-Id: Ie99fda37fd7dcba66f3c4d91e9fd6b8179d61018
Signed-off-by: Wenge Zhu <zhuwg1@motorola.com>
Reviewed-on: https://gerrit.mot.com/2298079
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Wei Deng <dengwei1@motorola.com>
Reviewed-by: Jun Weng <wengjun1@motorola.com>
Reviewed-by: Jichao Zou <zoujc@motorola.com>
Submit-Approved: Jira Key
Remove the way that when tap sensor register to notify touch enter
gesture mode.Use node to notify CLI touch enable/disable gesture mode.
Change-Id: Ib732a61289bcfed78b7ffecd3c6c2b27ae590bd1
Signed-off-by: Wenge Zhu <zhuwg1@motorola.com>
Reviewed-on: https://gerrit.mot.com/2320662
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Wei Deng <dengwei1@motorola.com>
Reviewed-by: Jichao Zou <zoujc@motorola.com>
Submit-Approved: Jira Key
Notify usbnet if configure to sync with netconfig in userspace
in factory mode.
Clear the gadget in context in case it has been removed when
phone switch to host mode. In that case, there will be kernel
panic for invalid gadget device access.
Change-Id: I28fdb1455eff5fa0592f024e7f1096cbf662de23
Signed-off-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/2337318
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Haichao Li <liuhc3@motorola.com>
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
When WLC(wireless charge pad) is offline, cps4019 could not
accessed by i2c bus. And we should return the value of 0
to indicate the status of offline. For healthd judgement logic,
it will just distiguish the valud of 0(offline) and non-zero(online).
So it will regards -1 as non-zero(online). As a result, we should
not return non-zero value for psy properties.
Change-Id: I4724d1b4a2d2d607b07fa3b52475e707da55fecf
Reviewed-on: https://gerrit.mot.com/2337171
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
For some charge pad, we need to get the result of iout
from cps4019 to judge its working status. So ibat could
not work in this scene. So we should change the current
result form ibat to iout.
Change-Id: Ie31b1308ecd59507208ad4ec9038e6e950bfef76
Reviewed-on: https://gerrit.mot.com/2330599
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
If vbus is absent, CPS4019 could not be accessed duel to loss of power.
So before power supply read operations, we should check vbus status.
If it is not exist, we should not access CPS4019.
Change-Id: I32bcdec8dd7aa9829a727ffb0205adaa04e185ba
Reviewed-on: https://gerrit.mot.com/2334726
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
The charger input current provides for both main
and flip battery charger, so there should be balance
between the two charger input in order to meet
the BC1.2 charger current spec:
SDP: 500/900mA
CDP: 1500mA
DCP: 1500mA
Change-Id: Idf52ec497a46a01340a8a96888148cc324858ad3
Signed-off-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/2331227
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
In order to avoid battery over discharging when charger attached
in some cases with high system load or charging disabled in factory
mode.
Change-Id: If323b2a5c558c944ba85a33188235c58909b6ada
Signed-off-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/2330746
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
Fixed sensors active logic, data order and values range to match
sensor hub's expectations. Timeout timer is disabled due to the
panic it causes.
Change-Id: I2ceae34b7ecdac2f790593b6ff25ea8caa34fb12
Signed-off-by: Konstantin Makariev <hcv867@motorola.com>
Reviewed-on: https://gerrit.mot.com/2326249
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Sridhar Vashist <svashist@motorola.com>
Reviewed-by: Yinjun Chen <a7301c@motorola.com>
Submit-Approved: Jira Key
When CLI touch wake irq triggerd to wake up kernel,add a wake lock
for it in case kernel suspend before resume.
Change-Id: I47f045f6d53cbe9e491922e60799c2e831e14ce2
Signed-off-by: Wenge Zhu <zhuwg1@motorola.com>
Reviewed-on: https://gerrit.mot.com/2326776
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: litong <litong20@motorola.com>
Reviewed-by: Jichao Zou <zoujc@motorola.com>
Submit-Approved: Jira Key
As vbus remove and type-c cable still inserted at BSP test, the
CC voltage transfer to VBUS pin, the vbus pin voltage range is 0~1.25V
frequent switch. So the interrupt of vbus under 0.8V is triggered frequently.
So disable this interrupt when vbus remove.
Change-Id: Ibfc26ed1e7db2c1031ac27642aa38a2dcb120f92
Signed-off-by: Haijian Ma <mahj8@motorola.com>
Reviewed-on: https://gerrit.mot.com/2325805
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
The fg psy may be created later than sgm4154x charger probe
and the fg psy event will be missing according to current
psy filter condition in psy notify call.
In order to fix this, use the fg psy name directly for
psy check, and not check the fg psy pointer.
Change-Id: I6ca888864045c0f523bfbef9f30411567214d995
Signed-off-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/2326012
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
1.If touch wait kernel wake up timed out, we must reset IC or just need
to read out data from IC via I2C interface when I2C is ready to let IC
pull up the INT,if we can not wait I2C ready finally, single tap will
not be available at this time sleep state, display on/off once will
restore it.
2.Disable watchdog work to ping IC when IC is on SLEEPING and SLEEP_ON
state.
Change-Id: I10106ef993ddb8270293c3defd4002e6cda6e9b5
Signed-off-by: Wenge Zhu <zhuwg1@motorola.com>
Reviewed-on: https://gerrit.mot.com/2324444
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: litong <litong20@motorola.com>
Reviewed-by: Jichao Zou <zoujc@motorola.com>
Submit-Approved: Jira Key
In order to avoid battery over voltage and current
during charging or over current in discharging
add threshold to trigger the protection based on
battery voltage and current.
Change-Id: I2c9329a181ba9dd814d6e48a5e0f9c8e7f9d5147
Signed-off-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/2322540
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Tested-by: Jira Key
Submit-Approved: Jira Key