Commit graph

2,614 commits

Author SHA1 Message Date
Shicheng Gong
5dbca0ed55 sgm4154x_charger_lite: add thermal mitigation
Add thermal mitigation for battery charging current to support
thermal-engine policy.

Change-Id: I478ec42d85b5c8c1c2cb5aa4ad75242f88534710
Reviewed-on: https://gerrit.mot.com/2312431
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2022-07-05 06:45:07 -05:00
dengwei1
a2b37b646a rhode: input touch update syna config id
syna
config id

Change-Id: Ie472d2b45b199a1edba9a0b1685a6aaf9655a372
Signed-off-by: dengwei1 <dengwei1@motorola.com>
Reviewed-on: https://gerrit.mot.com/2320173
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Wang Wang <wangwang1@lenovo.com>
Submit-Approved: Jira Key
2022-07-03 20:58:02 -05:00
Yonghua Yan
1ff2f1a3f7 fixup! (CR): Reset charging if it's halt
When the battery charging is halt under chargable
condition, reset the battery charging to recover it.

Put the charger in HIZ mode if the battery is absent
or OTG is enabled to prevent battery charging by
boost power.

Mot-CRs-fixed: (CR)

Signed-off-by: Yonghua Yan <yanyh2@motorola.com>
Change-Id: I7631a7fdd2329c108d1dc2bd3d341775a194ccb8
Reviewed-on: https://gerrit.mot.com/2321180
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2022-07-02 01:37:14 -05:00
Yonghua Yan
d16d1f99f1 Reset charging if it's halt
When the battery charging is halt under chargable
condition, reset the battery charging to recover it.

Put the charger in HIZ mode if the battery is absent
or OTG is enabled to prevent battery charging by
boost power.

Change-Id: I435bcb751d22ef2ac515aa15bb63e423dfdc4cb6
Signed-off-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/2320930
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2022-07-02 00:58:40 -05:00
liuyc20
8d978d3a80 FG_MM8013: Update logic to compatible with param_ver=0xa200
param_ver=0xa200 is for temporary parameter.
Need to update to offical parameter.

Change-Id: I3624f7776c095051a9aa28fc23c9ba422e736db5
Signed-off-by: liuyc20 <liuyc20@lenovo.com>
Reviewed-on: https://gerrit.mot.com/2318274
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Haijian Ma <mahj8@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2022-06-30 20:25:28 -05:00
Yonghua Yan
ed90b000ce control charger irq for otg or battery presence
Disable charger IRQ if OTG is enabled or battery is absence
to prevent unexpected charger IRQ wakeup.

Change-Id: I71b699f25a5624f0f3699434f142abc8cd3d69d4
Signed-off-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/2319107
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2022-06-30 11:27:50 -05:00
Yonghua Yan
fc575f57fc Trigger battery current read on demand
Schedule the heartbeat work to update the battery properties
if read current_now.

Change-Id: I47cdd15911219ce8af268a23acefd4980c081b45
Signed-off-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/2316770
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2022-06-30 05:34:31 -05:00
Konstantin Makariev
ee7e452d82 drv8424_mmi: proper IRQ setup
As it turned out nFAULT signal drops for about 200us every time BOOST_EN
enabled. Arming IRQ after SLEEP signal allowing for avoiding false
fault interrupts

Change-Id: I947839591e7c6bff2231bb8e39ae8b6fdd5c2ab7
Signed-off-by: Konstantin Makariev <hcv867@motorola.com>
Reviewed-on: https://gerrit.mot.com/2317946
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Qing Chang <qing@motorola.com>
Submit-Approved: Jira Key
2022-06-29 14:45:38 -05:00
Konstantin Makariev
eb5123d536 drv8424_mmi: unify source code indentation
Replace leading white spaces with tabs

Change-Id: I6c26f0083cb5bae6a6c76a6fdb7e2a35b28ea936
Signed-off-by: Konstantin Makariev <hcv867@motorola.com>
Reviewed-on: https://gerrit.mot.com/2316810
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Qing Chang <qing@motorola.com>
Submit-Approved: Jira Key
2022-06-29 11:33:49 -05:00
Konstantin Makariev
48e2ea9a62 drv8424_mmi: dual motors fault handling
Felix has 2 motors. Thus nFAULT signal can be raised individually
for each motor. If both motors consistently failing any further
motor communications must be suppressed to avoid mechanical damage

Change-Id: I11eec76eea7b056bfa93ebe19e7bb81fe823abd2
Signed-off-by: Konstantin Makariev <hcv867@motorola.com>
Reviewed-on: https://gerrit.mot.com/2299699
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Qing Chang <qing@motorola.com>
Submit-Approved: Jira Key
2022-06-29 11:33:38 -05:00
Yonghua Yan
9f61fd6d0e Add OVP and OCP for battery
Add battery OVP and OCP for battery charging
to workaroud the CE certification.

Change-Id: I2004e4a280cf2e5e8ce0d19c501e4a338e45d500
Signed-off-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/2316155
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2022-06-29 03:20:04 -05:00
Haijian Ma
9c4e76e7b1 charging: change wireless charging icl step increase rate
As HW require, change wireless charging icl step
increase rate from 200ms to 500ms

Change-Id: I7ec1ffb229e6a8be997de4b5224de0bd554890bd
Signed-off-by: Haijian Ma <mahj8@motorola.com>
Reviewed-on: https://gerrit.mot.com/2312396
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2022-06-24 05:37:11 -05:00
Yonghua Yan
d8ef9cab5a Add the description sysfs node when usbnet init
As the factory tcmd init depends on the usbnet description sysfs
node when tcmd start up, so create it as early as possible to
avoid tcmd fails to get usbnet description.

Change-Id: Ie2946efe49ffa5815504bd45734c3538bee15a1f
Signed-off-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/2311260
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2022-06-23 10:20:36 -05:00
Haijian Ma
d1a2cf641d charging: optimize select pd capacity
optimize select pd capacity to cover
more PD charger

Change-Id: Ie67c3b530f6cfb250508ecec72b12de537492969
Signed-off-by: Haijian Ma <mahj8@motorola.com>
Reviewed-on: https://gerrit.mot.com/2310810
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Submit-Approved: Jira Key
2022-06-23 04:48:02 -05:00
Haijian Ma
0caa4ffe0d charging: optimize wireless charging icl vote
As HW require, wireless charging icl vote from 500ma
for authentication

Change-Id: I922495b3f89a72f3a2b2b4306b941351614631e8
Signed-off-by: Haijian Ma <mahj8@motorola.com>
Reviewed-on: https://gerrit.mot.com/2310686
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2022-06-23 02:29:37 -05:00
wangyq13
33cf825022 dlkm: led_aw2033: don't enable led and CHGDIS when boot
dlkm:
- don't enable led if brightness and blink is zero
- don't enable CHGDIS when boot, set reset reg can enable CHGDIS, so
  change reset function.

Change-Id: I2c86386a2f1e0714793871dc72ac2ad553d67aaf
Signed-off-by: wangyq13 <wangyq13@lenovo.com>
Reviewed-on: https://gerrit.mot.com/2309617
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: <lvxj4@motorola.com>
Reviewed-by: Yuecai Liu <liuyc20@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2022-06-22 22:51:52 -05:00
zhangly19
4d4e63a83c Add parrot in Build_external_kernelmodule.mk
add  parrot(6450) a new mechansim for
building external modules.

Change-Id: I1bdd6b55482fdd6ada9f63e160a27de33b664f83
Reviewed-on: https://gerrit.mot.com/2306144
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Tested-by: Jira Key
Submit-Approved: Liyun Zhang <zhangly19@lenovo.com>
2022-06-21 22:46:48 -05:00
Haijian Ma
28886f1477 charging: enable cp ADC when factory mode
As factory test, so need to enable cp ADC
when factory mode

Change-Id: I82e96fd9acbd4727f9750ef1ca85447e7316297e
Signed-off-by: Haijian Ma <mahj8@motorola.com>
Reviewed-on: https://gerrit.mot.com/2308976
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2022-06-21 21:07:44 -05:00
Yonghua Yan
b9556551e5 add and remove sysfs files when usbnet config
Add and remove the sysfs files when usbnet configures the
ip by host PC.

When this sysfs files are ready, it means ip config received
from host PC and the phone can configure the network interface.

Change-Id: I2dabc4693d5e698e0c4853d0fa9d06e454ba7875
Signed-off-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/2306945
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2022-06-21 09:24:18 -05:00
zhuangnk1
83c7cd9c22 Always power-on eSE to avoid ese not open issue
Always power on eSE to avoid eSE not open
issue

Change-Id: I46c9697fb329eb259759d2c461eec8cfd5782cf7
Signed-off-by: zhuangnk1 <zhuangnk1@lenovo.com>
Reviewed-on: https://gerrit.mot.com/2307741
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Tao Sun <suntao2@motorola.com>
Submit-Approved: Jira Key
2022-06-21 01:18:24 -05:00
liuyc20
cd2e724d56 mm8013c_fg: add more safeguard when update FW/param
1.only in factory-mode enable fw/param update
2.add 3 times retry when update fw fail.
3.when get battery_id is zero.read utag battery_sn to search the correct battery_id.

Change-Id: I17999baf0f1a66731c4d95279de0ca0c1a46a33a
Signed-off-by: liuyc20 <liuyc20@lenovo.com>
Reviewed-on: https://gerrit.mot.com/2302762
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Haijian Ma <mahj8@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2022-06-19 21:04:42 -05:00
Haijian Ma
a34d156d50 charging: disable cp adc when cp don't work
disable cp adc when quit cp policy
enable cp adc when enter cp policy
for reduce power

Change-Id: I279c2493e4483c161c31df903866c75f7c7da513
Signed-off-by: Haijian Ma <mahj8@motorola.com>
Reviewed-on: https://gerrit.mot.com/2304010
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
2022-06-19 20:00:21 -05:00
Wenge Zhu
9ab8033192 Support goodix 9916P touch IC
Add goodix,9916P to spi device match table to support
9916P touch IC.

Change-Id: I7dbd07075c7bb63ff54171c6c98f6567046ab2f8
Signed-off-by: Wenge Zhu <zhuwg1@motorola.com>
Reviewed-on: https://gerrit.mot.com/2305630
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2022-06-19 01:05:27 -05:00
Yonghua Yan
7eb1770837 Set to discharging status if charger absent
Set charging status to discharging if charger absent
in case FG report confused status.

Change-Id: I95194b19750eb5af422ebb05f5937ca18a15a61c
Signed-off-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/2301533
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2022-06-15 05:59:53 -05:00
Haijian Ma
6b5d72caf4 fg: modify fake battery default value for assembly test
modify fake battery default value for assembly test
in factory

Change-Id: Id479e2ec546026decae31d6fdfd5d56987bfbeb7
Signed-off-by: Haijian Ma <mahj8@motorola.com>
Reviewed-on: https://gerrit.mot.com/2301490
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Hujun Liao <liaohj@motorola.com>
Submit-Approved: Jira Key
2022-06-15 05:42:53 -05:00
liuyc20
cd707d1093 mm8013c_fg: force none update fw/paramerter
there is low probablilty update fail.
then the phone will can't be bootup.

Change-Id: I1f25bc5cd5e74f7301090859fb7f6287b1e61d04
Signed-off-by: liuyc20 <liuyc20@lenovo.com>
Reviewed-on: https://gerrit.mot.com/2301067
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Haijian Ma <mahj8@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2022-06-15 01:04:04 -05:00
Haijian Ma
59b9242ac5 charging: add some log
add some log for easy debug
for miami

Change-Id: Ie3c4910d589f7fa475ba66cccfa730148deda08d
Signed-off-by: Haijian Ma <mahj8@motorola.com>
Reviewed-on: https://gerrit.mot.com/2299091
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2022-06-14 21:15:49 -05:00
liuyc20
8c600f0b6d mm8013c_fg: create fw/param/battery_id node
create fw_ver/param_ver/batt_id
for debug convenient.

Change-Id: I46e089cb5c2b6724cd1368f2fc9cbfdd5d6400dd
Signed-off-by: liuyc20 <liuyc20@lenovo.com>
Reviewed-on: https://gerrit.mot.com/2300325
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2022-06-14 21:11:53 -05:00
liuyc20
34c837abba MM8013C_FG: match battery_id && parameter ver when do update
the first_batt_param_ver and second_batt_param_ver maybe different.
so we need match battery_id && param_ver when update parameter.

Change-Id: I474d711b9d83286ed6c5e1c1a19ae3d30e2b1319
Signed-off-by: liuyc20 <liuyc20@lenovo.com>
Reviewed-on: https://gerrit.mot.com/2291391
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Reviewed-by: Haijian Ma <mahj8@motorola.com>
Submit-Approved: Jira Key
2022-06-14 21:11:43 -05:00
Gong Shicheng
e70961e21b sgm4154x_charger_lite:get charge counter from flip fg
get charge counter value from flip fg and assign this value
to batt_chg_counter of battery info struct.

Change-Id: I4356f928217dc2806fc722d2e8d9e7ff1da755d6
Reviewed-on: https://gerrit.mot.com/2300250
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
2022-06-14 07:27:08 -05:00
Gong Shicheng
0b97a147ed mmi_charger: combine flip & main battery charge counter
combine flip & main battery charge counter
for maven.

Change-Id: Id140068a200a419a4aaa23255a90f75c4346073d
Reviewed-on: https://gerrit.mot.com/2293045
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
2022-06-14 07:26:52 -05:00
Gong Shicheng
5c44e5e0dd qti_glink_charger:add charge counter prop
add charge counter prop for
main battery.

Change-Id: Ia8c19db723805196a88268cf7606d9a330a1d98e
Reviewed-on: https://gerrit.mot.com/2293043
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
2022-06-14 07:26:41 -05:00
Gong Shicheng
d33397d510 bq27426_fg_mmi:add charge counter prop
add charge counter prop for
flip_battery.

Change-Id: Idf37049f8cf4bfaef7b9b5685debacb93e9ea0c8
Reviewed-on: https://gerrit.mot.com/2293041
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
2022-06-14 07:26:27 -05:00
Haijian Ma
542ccbc59a charging: don't enable term when slave cp disabled
Don't enable main charger termination when slave cp
disabled, because main cp also work well, it will load
to main charger termination.

Change-Id: Idce843eaede60120963efdee92746b3d15c98742
Signed-off-by: Haijian Ma <mahj8@motorola.com>
Reviewed-on: https://gerrit.mot.com/2298500
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
2022-06-14 04:54:00 -05:00
weiweij
f7c69fecb1 charging: export charge ops interface for authen test
For some authen tests, charging parameters may need to be changed
as requirement. And for original designation, these ops interfaces only
work in factory mode. So we need to export them in normal mode.

Change-Id: I4ed54474fb6f8e0a164231d8919bc0f385954bd5
Reviewed-on: https://gerrit.mot.com/2299683
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2022-06-14 02:41:21 -05:00
weiweij
6e6e150be2 WLC: Add force flag for fw upgrade interface
For some reasons, WLC authen test may upgrade FW without
fw version changed. So we add force flag for fw upgrade interface,
to let it could be applied in authen test.

Change-Id: I964984b4dd81e750e17ac23bfe0a5e9cf70a109f
Reviewed-on: https://gerrit.mot.com/2296260
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2022-06-14 01:19:32 -05:00
zhangjun10
53f295b746 : tundra : keep nfc irq always wakeupable
keep irq always wake up
can get I2C message from irq

Change-Id: Ie338aec3f3caf90cd910b87ebbfc5089d7ceb7d1
Signed-off-by: zhangjun10 <zhangj10@motorola.com>
Reviewed-on: https://gerrit.mot.com/2298808
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Wang Wang <wangwang1@lenovo.com>
Submit-Approved: Jira Key
2022-06-13 02:34:36 -05:00
wangyq13
f04c87e4f3 dlkm: aw2033: set blink mode brightness
- set blink mode brightness, change as set by upper layer
- add logs to debug brightness change issue

Change-Id: Ia602012a27b7d9aacad1ab66148f9d7618141f77
Signed-off-by: wangyq13 <wangyq13@lenovo.com>
Reviewed-on: https://gerrit.mot.com/2294938
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Yuecai Liu <liuyc20@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2022-06-12 21:39:19 -05:00
Yonghua Yan
be6a9eccb7 correct the paired_ichg value before setting
It gets incorrect paired_ichg value before setting to make a wrong
decision on charging current setting.

This issue may cause battery charging out of controlling of battery
charging policy.

Change-Id: If5ed84d5cebc231ecda70dcb919b76c681f52d84
Signed-off-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/2298136
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2022-06-12 07:14:31 -05:00
longc102
e0bf7314a3 connect 33W charger, the power is only 2.5W
if plug in usb slowly, wt6670 will output float or sdp type
recheck charge type if detect float or sdp

Change-Id: I316d05a5178e4e6f5a3140ba6adf3e4a0c19e987
Signed-off-by: longc102 <longc102@motorola.com>
Reviewed-on: https://gerrit.mot.com/2295174
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Qiong Xie <xieq2@motorola.com>
Reviewed-by: Wang Wang <wangwang1@lenovo.com>
Submit-Approved: Jira Key
2022-06-10 02:01:52 -05:00
Yonghua Yan
15dd6d3da4 Stop charging by paired battery
It's not reasonable to allow paired main battery to
charge the backup battery, as the main battery is
constant power supply for the system power, and it
does not benefit the principle to keep the main battery
voltage no less than backup battery.

Force battery soc to 0 only if paired battery volatge
is lower than empty voltage and soc becomes to 0.

Change-Id: Ifdaed984565f3c696d08fa43696e5b563930adf4
Signed-off-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/2294021
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2022-06-09 19:40:51 -05:00
Wenge Zhu
014874eac4 Support touch sensitivity in game mode for eqs
Support touch sensitivity in game mode for eqs,default touch report rate
is 240HZ and high report rate is 360HZ.

Change-Id: I5d6f580e05e15bb2cd62ef2500fc1d6559a968d0
Signed-off-by: Wenge Zhu <zhuwg1@motorola.com>
Reviewed-on: https://gerrit.mot.com/2294916
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: litong <litong20@motorola.com>
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2022-06-09 04:04:17 -05:00
Haijian Ma
7c645fdccc Revert "Revert "(CR): charging: Don't switch dpdm from AP to pmic when host mode""
https://gerrit.mot.com/#/c/2290827/  have fixed build error, 
so restore this change.

This reverts commit ca848f95330b1df33ef437247e478f976b2884c2.

Change-Id: I96d70452970902b240c56c3ada748f9ad822d06e
Reviewed-on: https://gerrit.mot.com/2294495
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2022-06-09 02:23:12 -05:00
Haijian Ma
c4404c1548 charging: limit max icl for wireless charging
As sgm41542 ic input current positive error,
so limit 100ma in max icl for wls attestation

Change-Id: I48a7aa7aa8be2709d39eaad891ba1e0f94d0bb61
Signed-off-by: Haijian Ma <mahj8@motorola.com>
Reviewed-on: https://gerrit.mot.com/2293039
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Wei Wei <weiweij@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2022-06-08 20:26:34 -05:00
Haijian Ma
d31601786d charging: add wireless icl increase step by step
As HW require, add wireless icl increase step
by step (100ma/200ms) for miami

Change-Id: I8d5a3deb81f106282dcae6c9d41491457c4f222e
Signed-off-by: Haijian Ma <mahj8@motorola.com>
Reviewed-on: https://gerrit.mot.com/2292877
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Wei Wei <weiweij@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2022-06-08 20:26:28 -05:00
Konstantin Makariev
8dce1b9e6e drv8424_mmi: update position/status w/o sensors
Driver option to work w/o data from position sensors has a caveat.
Current position at power up is not detected, but set manually.
This prevents Rollable Display HAL from properly updating active
touch region. This change enforces position/status sysfs entries
update when option no sensors present in device tree

Change-Id: If7c1fc59695652816003a192323bc4393f1e184f
Signed-off-by: Konstantin Makariev <hcv867@motorola.com>
Reviewed-on: https://gerrit.mot.com/2294160
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Qing Chang <qing@motorola.com>
Submit-Approved: Jira Key
2022-06-08 15:08:07 -05:00
Yonghua Yan
3006d8909c remove the sysfs notify from interrupt context
Remove the sysfs notify for sysfs node from usb interrupt
context, as sysfs_notify may be scheduled or sleep.

Change-Id: I45baf51b96506e4df6290b74c3a033240f8a1a83
Signed-off-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/2293617
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2022-06-08 04:58:24 -05:00
Yonghua Yan
aa3226523c usbnet: add sysfs files for net interface config
Add sysfs files under /sys/devices/virtual/net/usb0/
1. ip address
2. subnet mask
3. iff flag

Userspace program can set the net interface for the usbnet in factory mode,
and read back the ip address, subnet mask, and net interface up/down flag
to configure the net interface via socket ioctl to sending ifrequest.

Change-Id: I5c9d1181823a07467eaa9acd1b722b52f7601bed
Signed-off-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/2289066
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Haichao Li <liuhc3@motorola.com>
Reviewed-by: Tao Sun <suntao2@motorola.com>
Submit-Approved: Jira Key
2022-06-07 05:33:56 -05:00
longch99
56274b9880 the charging status shows "not charging",but the charging current is normal
classify ic state error
if ic status is eoc, charge status should be charging

Change-Id: I123a6256275b087762c599cad1a499f75f7aa7a4
Signed-off-by: longch99 <longch99@motorola.com>
Reviewed-on: https://gerrit.mot.com/2287101
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Qiong Xie <xieq2@motorola.com>
Reviewed-by: Wang Wang <wangwang1@lenovo.com>
Submit-Approved: Jira Key
2022-06-06 02:25:42 -05:00
liuyc20
d5703ed674 introduct MM8013C FG update fw/parameter program
1.update FW || parameter
2.update FW && parameter

Change-Id: Ia6337331feef8a0ab031536e9d472379b9d9f9dc
Signed-off-by: liuyc20 <liuyc20@lenovo.com>
Reviewed-on: https://gerrit.mot.com/2278312
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Haijian Ma <mahj8@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2022-06-05 23:56:08 -05:00