Commit graph

2,209 commits

Author SHA1 Message Date
xuwei9
fe82961abc qc3p:set qc3p charging voltage threshold 3.4V
Set QC3P beging charging voltage
threshold to 3.4V for optimization.

Change-Id: Ib5ad2454ba7d0f2655785651b7535f5170b8d5f4
Signed-off-by: xuwei9 <xuwei9@lenovo.com>
Reviewed-on: https://gerrit.mot.com/2158288
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Xiangpo Zhao <zhaoxp3@motorola.com>
Submit-Approved: Jira Key
2021-12-30 01:19:34 -06:00
Yan Zhang
3d1cecc323 Change to mdelay for power up delay
FOD will turn on/off frequently, msleep will take longer delay than
 expected, use mdelay to optimize the power up time.

Change-Id: I9c4d23f0c3b98713eeee7bb1393106ebac507af4
Signed-off-by: Yan Zhang <zhangy26@motorola.com>
Reviewed-on: https://gerrit.mot.com/2157879
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Xiangpo Zhao <zhaoxp3@motorola.com>
Submit-Approved: Jira Key
2021-12-29 23:49:12 -06:00
yanyh2
64bca136c8 Adjust bq27426 fg module to support Android S
Adjust bq27426 fg module to support Android S and different
HW design.

Change-Id: I90e0c6e49a47ca148e519564cc1a448deeb29177
Signed-off-by: yanyh2 <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/2152626
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2021-12-29 22:36:10 -06:00
Qiong Xie
c2086f49d3 Revert (CR):sgm4154x:add hawao vbus adc sample ratio
Revert "(CR):
sgm4154x:add hawao vbus adc sample ratio"

This reverts commit 3fa23f1771ca5bd9b1509823f8a52b160d2bf0f6.

Change-Id: I422474dd15250c8b99a81ab766a2d19c15f6d107
Reviewed-on: https://gerrit.mot.com/2153198
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Wang Wang <wangwang1@lenovo.com>
Submit-Approved: Jira Key
2021-12-29 20:49:11 -06:00
huaqin87
0652de385b wt6670: add QC3P firmware num node to /proc/driver
Adding a node to the power supply will affect the IIC timing,
adding to the IIO system file path is not fixed,
so add the node to the proc

Change-Id: Ib4842d6eaf37daf53e9c6bdb2a8f5d2a90694c38
Signed-off-by: huaqin87 <huaqin87@motorola.com>
Reviewed-on: https://gerrit.mot.com/2157051
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
2021-12-29 04:43:36 -06:00
chenlj2
3775caaa65 DLKM/fps:optimise power ctl for focal
optimise log process
Enable ff_device_control_reset

Change-Id: Ibb899cd1bfa22acd42066ec9368b9312afe4d273
Signed-off-by: chenlj2 <chenlj2@motorola.com>
Reviewed-on: https://gerrit.mot.com/2156913
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Weilong Wu <wuwl10@motorola.com>
Reviewed-by: Yan Zhang <zhangy26@motorola.com>
Reviewed-by: Tao Sun <suntao2@motorola.com>
Submit-Approved: Jira Key
2021-12-29 04:18:30 -06:00
liuyc20
b6b28fc271 FG: apply rt9426a 0015 patch
1. remove pm_wakeup on fg_update_work_func, becase update_work will be cancle
   when the device into suspend.
2. Relax the unseal state determination criteria, and the unseal only determines the bit0
3. update Correct unknown error. about writing rt9426a_reg_swindows value,
   moto did not use this function

Change-Id: I38e2acd5b11fb78e722b6cb86e192ac389057705
Signed-off-by: liuyc20 <liuyc20@lenovo.com>
Reviewed-on: https://gerrit.mot.com/2156775
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Haijian Ma <mahj8@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2021-12-29 02:13:05 -06:00
bchhq23
de31178d74 rhodep:open charger mode;
kernel/tp:
	open charger mode;
	wait probe is ok that send cmd;

Change-Id: I186884262858227efdfcd5a6588b70e4414b1556
Signed-off-by: bchhq23 <bchhq23@motorola.com>
Reviewed-on: https://gerrit.mot.com/2153152
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jun Weng <wengjun1@motorola.com>
Reviewed-by: Hujun Liao <liaohj@motorola.com>
Submit-Approved: Jira Key
2021-12-28 23:07:04 -06:00
mahj8
c73d42c876 charging: enable irq wake up
when system suspend and then inserted charger, the system
can't wake up and update charger info.

Change-Id: Idb69dfc330b93d5929ce1b10b5c95491d6997aff
Signed-off-by: mahj8 <mahj8@motorola.com>
Reviewed-on: https://gerrit.mot.com/2155893
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2021-12-28 02:46:30 -06:00
mahj8
ffbae57032 charging: optimize sgm41542 charging type detected
As in some case charging type detected error, so optimize
sgm41542 charging type detected.

Change-Id: Iad9608794ff0cf9116295037f6bacdfc1bdd619a
Signed-off-by: mahj8 <mahj8@motorola.com>
Reviewed-on: https://gerrit.mot.com/2154824
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2021-12-28 02:40:22 -06:00
huaqin86
a4e8e09997 Revert "(CR):add firmware interface"
This reverts commit c36e4a8eb858da064615bbfa7941312fe2d82c5b.
The node /sys/class/power_supply/QC3P/firmware_num that reads the 6670
firmware cannot be placed under the power supply,because the battery
service obtains information every 5s, which leads to the need to read 
the version number every 5s,which will affect the bus timing on the IIC,
Which will affect the identification of the charger type

Change-Id: I0bbcc6419caf2e340a1ae6e951fe2bd32643b0a2
Signed-off-by: huaqin86 <huaqin86@motorola.com>
Reviewed-on: https://gerrit.mot.com/2154893
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Ying Xu <xuying9@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2021-12-27 03:50:47 -06:00
wutao
9b9c0d3edf bq2589x:add qc3p charger type
add qc3p charger type at bq2589x charger ic.
it will not charger icon if not have charger type

Change-Id: I950fd7e9fc9855f27174e58fce81a9e5c654f3c8
Signed-off-by: wutao <huaqin89@motorola.com>
Reviewed-on: https://gerrit.mot.com/2154583
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Reviewed-by: Wei Xu <xuwei9@lenovo.com>
Reviewed-by: Yuecai Liu <liuyc20@motorola.com>
Submit-Approved: Jira Key
2021-12-26 21:40:17 -06:00
wutao
a16d6cfe74 sgm:add qc3p charger type
add qc3p charger type at sgm4154x charger ic.
it will not charger icon if not have charger type

Change-Id: I2c62c685a347dee2e35e3e8b545ac4d3e0a16941
Signed-off-by: wutao <huaqin89@motorola.com>
Reviewed-on: https://gerrit.mot.com/2154578
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Reviewed-by: Wei Xu <xuwei9@lenovo.com>
Submit-Approved: Jira Key
2021-12-26 21:40:10 -06:00
wingte49
f0e3866cd7 backlight/sm5350: Add a sm5350 IC which is second backlight IC
Modify:
 Porting backlight sm5350,add pamameter of second backlight IC.

Change-Id: Ib9b2ad61ecf942d7b0258890af03f4ccf45c0328
Reviewed-on: https://gerrit.mot.com/2152637
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Yeqing Wang <wangyq13@motorola.com>
Reviewed-by: gaoyx9 <gaoyx9@motorola.com>
Submit-Approved: gaoyx9 <gaoyx9@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
2021-12-26 20:35:04 -06:00
mahj8
5a998abf5d charging: avoid to report usb type before apsd done
don't report usb type before rerun apsd done, to avoid input current
limit auto changed to 500ma by charger IC.

Change-Id: If148bded78a3ae8a628353ca70c7fa15f2b1363c
Signed-off-by: mahj8 <mahj8@motorola.com>
Reviewed-on: https://gerrit.mot.com/2154207
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2021-12-24 02:36:36 -06:00
mahj8
264b8e8d71 charging: add icl*vbus to report power max
As pd type can't equal to real_charger_type in discrete charging,
so need to add icl*vbus to report power max for showing turbopower
connected UI.

Change-Id: I16f4b559383f86eb38ec1b5e6cac09556d9dfada
Signed-off-by: mahj8 <mahj8@motorola.com>
Reviewed-on: https://gerrit.mot.com/2154206
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2021-12-24 02:36:27 -06:00
huaqin85
1c7538d444 charger: compatible NU2105 Charge Pump in bq2597x
NU2105: compatible ADC & regulator for NU2105 pump
print bq2597x , NU2105 , SC8551A PartNo, and Deivce Name
Change the base Addr for show registers

Change-Id: I4540dc9fac6caa35b848988359c4462d86f4dd76
Signed-off-by: huaqin85 <huaqin85@motorola.com>
Reviewed-on: https://gerrit.mot.com/2142696
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Submit-Approved: Jira Key
2021-12-24 01:16:18 -06:00
yanyh2
fed40d1211 Reset charger configure and constraint for glink down
Reset charger configure and constraint for glink down, so that
AP will resend the charger configure and constraint to ADSP
battery management, otherwise uninitilized value of charger
configure and constraint will be used in ADSP side after ADSP
restart, and then power max value will use default value 0;

Change-Id: Ic29a61763c85be62102ecb0333ae7f03f79ac670
Signed-off-by: yanyh2 <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/2153260
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Wentao Xu <xuwt2@motorola.com>
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2021-12-23 21:13:13 -06:00
liuyc20
abd4219f55 FG: rt9426a add cancel_work when system into suspend
when system into suspend. at this time running battery_work to
read the I2C that will make reading the i2c error.
so add cancle_delay_work when suspend, queue_delay_work when resume.

Change-Id: I7a39f8689b8b560ecfc04b40171bb59f20b6b57a
Signed-off-by: liuyc20 <liuyc20@lenovo.com>
Reviewed-on: https://gerrit.mot.com/2152989
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
2021-12-23 05:42:39 -06:00
huaqin86
efc3721336 wt6670: add retry function to wt6670 read fw
Power supply is updated every 5 seconds, and firmware reading will be called every 5 seconds
The original firmware reading will pull the interrupt pin up and down
This operation will cause incorrect timing of wt6670, resulting in incorrect value read by wt6670

Change-Id: Ia4cfd37b8705ce2527fe6f6509a4b14b1eb8dd51
Signed-off-by: huaqin86 <huaqin86@motorola.com>
Reviewed-on: https://gerrit.mot.com/2153027
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2021-12-23 05:35:54 -06:00
Yan Zhang
565cf7a3ab Update Goodix TP FOD event implementation
1. Update FOD gesture trigger in screen off mode.
2. Add FOD event support in screen on mode

Change-Id: I7ecbfdb4aff8eaf34e88247d91d08279edd018a6
Signed-off-by: Yan Zhang <zhangy26@motorola.com>
Reviewed-on: https://gerrit.mot.com/2152070
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Wei Deng <dengwei1@motorola.com>
Reviewed-by: Xiangpo Zhao <zhaoxp3@motorola.com>
Submit-Approved: Jira Key
2021-12-23 03:06:05 -06:00
xuwei9
3f42788a45 qc3p:optimize power supply init
Optimize power supply int time
Keep get supply name once.

Change-Id: Iba46c0885dccecf6c66346879227d1e8756aa70a
Signed-off-by: xuwei9 <xuwei9@lenovo.com>
Reviewed-on: https://gerrit.mot.com/2152814
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Xiangpo Zhao <zhaoxp3@motorola.com>
Submit-Approved: Jira Key
2021-12-23 02:08:15 -06:00
xizx
15f84bb003 mmi_annotate: write info mem when persist mem unsupported
From 8450 platform, Qcom doesn't support warmreset, so pstore memory
cannot work again. All persist memory data should be writtle into
memory.

Change-Id: I9f20a35b50a10c69b7df96037a27b965e130b5f9
Reviewed-on: https://gerrit.mot.com/2152098
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
2021-12-23 00:54:01 -06:00
tinno18
beb23b07a3 [hawaii+oled]:vibrator long short vibration intensity 1/2
vibration intensity
play_ms > 80ms means long, otherwise short
long : 2.6V
short: 3V


change reason:vibrator resonates with camera

Change-Id: Icdb29bf77b3987ef7f25e0f6660b8461fe74e84c
Reviewed-on: https://gerrit.mot.com/2152699
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: <tinno18@motorola.com>
Reviewed-by: Zhenghai Pan <panzh2@lenovo.com>
Reviewed-by: Wang Wang <wangwang1@lenovo.com>
Submit-Approved: Jira Key
2021-12-23 00:40:08 -06:00
xuwt2
81a711a700 smart_pen_charger: Add PEN_STAT_CHARGE_DISABLED
Add new pen status : PEN_STAT_CHARGE_DISABLED
it means the pen charging was disabled.

Change-Id: I784d770f34b1bbe1e8e34bf785810e180924de6d
Signed-off-by: xuwt2 <xuwt2@lenovo.com>
Reviewed-on: https://gerrit.mot.com/2151778
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
2021-12-22 23:43:37 -06:00
liyiying
ef103ab40d mod the sc89890h register config
as the sc89890 datasheet,
the REG04 Icc - Fast Charge Current offset is 0ma, LSB is 60ma
the REG05 Itc - Tirckle Current offect is 60ma, LSB is 60ma
the REG05 Iterm - Termination Current offect is 30ma, LSB is 60ma

Change-Id: I6cd85cd48878492682c1c9802e5ce972e2db0664
Signed-off-by: liyiying <liyiying@wingtech.com>
Reviewed-on: https://gerrit.mot.com/2151683
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2021-12-22 20:40:37 -06:00
wangwang1
e02ce4fcd2 Rhode:use regulator interface to control vbus
during kernel boot up sequence, regulator framework has a delayed
workitem to cleanup all pre-enabled but not in use regulators,
as we want to keep the vbus on when otg device is plugged in before
kernel boots up, we need to use regulator interface to turn on the
related regulators, which in turn set the regulator as in use,
so the delayed workitem ignores the already engaged regulators.

Change-Id: I6baf4977768eb6837cd3b416a23c30fad5af789b
Reviewed-on: https://gerrit.mot.com/2151867
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Reviewed-by: Xiangpo Zhao <zhaoxp3@motorola.com>
Tested-by: Jira Key
Reviewed-by: Wei Xu <xuwei9@lenovo.com>
Submit-Approved: Jira Key
2021-12-22 20:01:44 -06:00
dengwei1
868e8bde39 dubai: input touch add gki support
add
gki

Change-Id: I84ee20f77b4665c20e0f09b3180be5ecffb8b90f
Signed-off-by: dengwei1 <dengwei1@motorola.com>
Reviewed-on: https://gerrit.mot.com/2152515
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Wang Wang <wangwang1@lenovo.com>
Submit-Approved: Jira Key
2021-12-22 20:01:02 -06:00
huaqin86
a08643e104 bq:add enable termination function
Add main charger enable termination function
at sc89890H charger ic.

Change-Id: I8b53d39c1db702e30f1e94281e38621216dd6152
Signed-off-by: huaqin86 <huaqin86@motorola.com>
Reviewed-on: https://gerrit.mot.com/2150957
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2021-12-22 07:04:41 -06:00
liuyc20
cc3c111f0f FG: RT9426a add safeguard for SOH
In some abnormal cases the soh=0 from the chip, that make the
bms_charge_counter&&bms_charge_full abnormal,then calculate the wrong
UI_SOC for battery.
if get soh=0; use old soh to aviod getting the wrong soc.

Change-Id: Ic7433d23c3162a96a40f9bc5e7043dcdfb42fb14
Signed-off-by: liuyc20 <liuyc20@lenovo.com>
Reviewed-on: https://gerrit.mot.com/2151691
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2021-12-22 04:10:53 -06:00
liuyc20
881e346bc6 FG: RT9426A add safeguard for ocv_index
ocv_index is used for ocv_table parameter.
In some case read a invalid ocv_indes(65535/-13),then driver read the wrong
ocv parameter, that make checksum fail and exit the driver.
the ocv_index only 0~4 is valid, if read a invalid ocv_index,
using the default ocv_index to fix above issue.

Change-Id: I633aaa7f9abc4a98abb72cbec45025c8c52d5662
Signed-off-by: liuyc20 <liuyc20@lenovo.com>
Reviewed-on: https://gerrit.mot.com/2151514
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2021-12-22 04:10:42 -06:00
litong20
2d3b0cbc54 goodix: Solve cpu_latency_qos_add_request called warning
TP:
WARNING cpu_latency_qos_add_request called for already added request

Change-Id: If99edff041cfeb57c45d9f6e2119ad24bf35f3ab
Reviewed-on: https://gerrit.mot.com/2147984
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jichao Zou <zoujc@motorola.com>
Submit-Approved: Jira Key
2021-12-22 00:45:32 -06:00
wangyq13
df08fa99ef input: goodix_v1510: add charging and gtp-tools node
- Add charging detection function
- Add gtp-tools node for cqa test
- Remove software esd check for touch, touch firmware itself to recover

Change-Id: Id3b398f302370baddf56b5973813d5a09591460e
Signed-off-by: wangyq13 <wangyq13@lenovo.com>
Reviewed-on: https://gerrit.mot.com/2150842
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jun Weng <wengjun1@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2021-12-21 23:51:35 -06:00
chailu1
06ca2a6c80 PD: config cc status for sc2150 after shutdown
pd/sc2150
config CC status to RD after shudown for sc2150

Change-Id: Iba282f3f7b982a63715553df5eded9168a76f459
Signed-off-by: chailu1 <chailu1@lenovo.com>
Reviewed-on: https://gerrit.mot.com/2150656
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>
Reviewed-by: Yuecai Liu <liuyc20@motorola.com>
Submit-Approved: Jira Key
2021-12-21 23:34:51 -06:00
litong20
c042d862af Do not re-enable the stylus when the stylus mode is switched
TP:
  When exiting the stylus mode, the IC will send an abnormal reset
interrupt. At this time, the stylus will be enabled again,
but because the stylus clock is closed, the touch will not work.

Change-Id: Id1b393de2b2bee5b06e9d4f5b74dfd301be4547d
Reviewed-on: https://gerrit.mot.com/2150837
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jichao Zou <zoujc@motorola.com>
Submit-Approved: Jira Key
2021-12-21 19:46:47 -06:00
zhuwg1
bcb890a074 mmi_charger:use orderly shutdown in factory mode
On user-debug build, use an orderly shutdown for factory kill instead
of a kernel power off. The orderly shutdown will attempt to call the
reboot binary from userspace first, and then fallback to kernel power
off if it fails.

Change-Id: Ia3d80b828670a5098afccbca2d934f9d32255a93
Signed-off-by: zhuwg1 <zhuwg1@motorola.com>
Reviewed-on: https://gerrit.mot.com/2145390
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-by: Xiangpo Zhao <zhaoxp3@motorola.com>
Submit-Approved: Jira Key
2021-12-21 06:19:14 -06:00
xieqiong2
0899181581 sgm4154x:add hawao vbus adc sample ratio
Hawao use 180 pull up and 39 pull down
hw design for vbus adc.
So we need to use specific sample ratio
to do the caculation.
This is just a debug modification to
accommodate evt/evt1 hw.

Change-Id: If062be5ac2f0586d39eb7115ab16f211c5c29d29
Signed-off-by: xieqiong2 <xieqiong2@lenovo.com>
Reviewed-on: https://gerrit.mot.com/2147468
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Wang Wang <wangwang1@lenovo.com>
Submit-Approved: Jira Key
2021-12-21 03:29:21 -06:00
xuwei9
dce57a8af0 qc3p:limit ibus 300mA for main charger no ibus adc
Due to discrete main charger have no ibus adc
so limit main charger fixed input 300mA.

Change-Id: Ic762f33d91552c387aa27d6cbe8e4639b39df388
Signed-off-by: xuwei9 <xuwei9@lenovo.com>
Reviewed-on: https://gerrit.mot.com/2150432
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Xiangpo Zhao <zhaoxp3@motorola.com>
Submit-Approved: Jira Key
2021-12-21 03:07:40 -06:00
mahj8
3f275d7116 charging: Ignore the PD vote icl unless BC1.2 done
Third charging ic IINLIM bits will be changed auto
when BC1.2 done. So we need to Ignore the PD
vote icl untill BC1.2 done.

Change-Id: I394f80b71c427e5b2a98b6012aeb7a852329ce4f
Signed-off-by: mahj8 <mahj8@motorola.com>
Reviewed-on: https://gerrit.mot.com/2150599
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
2021-12-21 02:37:15 -06:00
liyiying
b04c4e14c3 add charger ic - sc89890h config
motorola/kernel/modules
config sc89890 charger ic param for rhodec

Change-Id: I04813d73feae4844dfb37aaaf63fd6c70c07765f
Signed-off-by: liyiying <liyiying@wingtech.com>
Reviewed-on: https://gerrit.mot.com/2148046
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Reviewed-by: Yuecai Liu <liuyc20@motorola.com>
Submit-Approved: Jira Key
2021-12-21 01:52:56 -06:00
liyiying
646dd1871c modules:add sm5602 patch to fix the soc jump problem
1.what circumstances does this problem occur.
RD found sometimes the soc will jump as normal use
2. the rootcause of this issue.
the soc return value is not conform to the calculation method
3. how to fix this issue.
change the soc report way

Change-Id: I27032c5252d5ebe5ea005deac9e2e8403245e37f
Signed-off-by: liyiying <liyiying@wingtech.com>
Reviewed-on: https://gerrit.mot.com/2149683
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Yuecai Liu <liuyc20@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2021-12-21 01:50:49 -06:00
liuyc20
ca98480525 FG: Modify SM5602 FG first update battery data time to 50ms
start driver then update battery data was delayed 8s.
that is too late, it will cause UI can't get correct battery capacity.
so from 8s change to 50ms.

Change-Id: I3cfb510e222c1c937e02bc5bd8cd1d7a88c958f7
Signed-off-by: liuyc20 <liuyc20@lenovo.com>
Reviewed-on: https://gerrit.mot.com/2149410
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2021-12-20 20:18:00 -06:00
huaqin86
cbdab92e7e add force_chg_auto_enable interface
add sys/class/power_supply/cp-standalone/force_chg_auto_enable
self tcmd test step:
enable Cap SWITCH:tcmd_send 00850702
disable Cap SWITCH:tcmd_send 00850703

Change-Id: I4ae5c9e9088bd16da7c33b6bbd62a22a1d76b617
Reviewed-on: https://gerrit.mot.com/2149651
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2021-12-20 20:15:51 -06:00
huaqin86
8f7de27de6 add firmware interface
charging qc3+ wt6670
add sys/class/power_supply/QC3P/firmware_num

Change-Id: I57f1d32846a6211ca8f7e33c4e6f7e1853d5fab0
Reviewed-on: https://gerrit.mot.com/2149692
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2021-12-20 20:15:23 -06:00
litong20
0c96a30306 Disable irq before entering gesture mode and IC resetting.
TP:
Disable interrupt before entering gesture mode and IC resetting.


Change-Id: I056458b7b405c1ba46f27eda9754c9d64eeeaef0
Reviewed-on: https://gerrit.mot.com/2149576
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jichao Zou <zoujc@motorola.com>
Submit-Approved: Jira Key
2021-12-20 19:45:37 -06:00
wangyq13
28a097c665 input: goodix_v1510: enable single tap function
goodix_v1510:
Enable single tap function.

Change-Id: I783f8ca04efd73354f0b10c2e4e13add6721cc96
Signed-off-by: wangyq13 <wangyq13@lenovo.com>
Reviewed-on: https://gerrit.mot.com/2146428
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Wei Deng <dengwei1@motorola.com>
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2021-12-20 03:17:46 -06:00
litong20
4710e99d3f Support resend stylus cmd after abnormal resetting.
TP:
Support resend stylus command after abnormal resetting.

Change-Id: I9cd2885988f92ca8d50b96f2b5c7569439e277b2
Reviewed-on: https://gerrit.mot.com/2147994
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jichao Zou <zoujc@motorola.com>
Submit-Approved: Jira Key
2021-12-20 02:36:43 -06:00
litong20
95429c472f Record and restore the value of the mode
TP:
Record the value of the received mode from system and the value
successfully set to the touch IC.

Change-Id: Ie10f25be6d0d9fe9d21cf385a626496cc9aedfa5
Reviewed-on: https://gerrit.mot.com/2144916
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jichao Zou <zoujc@motorola.com>
Submit-Approved: Jira Key
2021-12-20 02:36:31 -06:00
wutao
119a19f18e QC3P:use qc3p config distinguish other not qc3p project
Add QC3P config
use qc3p config distinguish other not qc3p project

Change-Id: I32571a4d3d407867eab6da1ec1f9b5b30b8b4b87
Reviewed-on: https://gerrit.mot.com/2149237
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2021-12-20 01:15:53 -06:00
wutao
453ca3dcbd QC3P:detection and iio sys support
Add QC3P detection and iio
sys support.

Change-Id: I7459889d1c7fc35b0913ba908b3ef9cf00c5729e
Signed-off-by: wutao <huaqin89@motorola.com>
Reviewed-on: https://gerrit.mot.com/2148672
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Huosheng Liao <liaohs@motorola.com>
Submit-Approved: Jira Key
2021-12-20 01:15:41 -06:00