Added the following features:
1) BOS0614 registers dump sysfs
2) reading device tree and applying default config
in case of power cut
Change-Id: I53f1b7069ea4d74aa8b02ac525765951fe29bcce
Signed-off-by: Konstantin Makariev <hcv867@motorola.com>
Reviewed-on: https://gerrit.mot.com/1889879
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Ling Jin <lingjin@motorola.com>
Submit-Approved: Jira Key
TP:
1. Support init.mmi.touch.sh service to force flash TP FW.
2. Add power status sys node
Release Info format,take 21031801 as an example:
ext_release_byte0 [0x01]
ext_release_byte1 [0x18]
ext_release_byte2 [0x03]
ext_release_byte3 [0x21]
Change-Id: I8ffa0244dfc10257ce92cc8f2fbc9841e8ead4c9
Reviewed-on: https://gerrit.mot.com/1904886
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Reviewed-by: Konstantin Makariev <kmakariev@motorola.com>
Tested-by: Jira Key
Submit-Approved: Jira Key
Synaptics DSX driver is still used in older products in its non-class
version. Version utilizing MMI touchscreen class has more dependencies
and it seems easier to maintain if it's kept separate.
This change combines the following:
1) added MMI status check into probe
2) added module dependencies
3) fixed up panel notifications
Change-Id: I0fcb165c39ef09e0fbd4d5b82ef8130df51ec627
Signed-off-by: Konstantin Makariev <hcv867@motorola.com>
Reviewed-on: https://gerrit.mot.com/1887465
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Ling Jin <lingjin@motorola.com>
Submit-Approved: Jira Key
Setup meaningful config and build IDs info to allow for automated
firmware update. Driver will be using release info field of ST
sysinfo as config ID while build ID will become a combination of
FW CFG and CFG version.
Change-Id: I53cec2619ed6afaa83994e7cd40a8254791437a8
Signed-off-by: Konstantin Makariev <hcv867@motorola.com>
Reviewed-on: https://gerrit.mot.com/1902864
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: litong <litong20@motorola.com>
Reviewed-by: Ling Jin <lingjin@motorola.com>
Submit-Approved: Jira Key
TP:
If we support ABS_MT_PRESSURE event, when we keep touching the screen
during the boot process, it will cause the touch to be unresponsive
after booting, and all input events will be treated as HOVER events in
framwrok.
Change-Id: I75d33a691bba5729b066df3b80fb1681ce97b5c9
Reviewed-on: https://gerrit.mot.com/1908277
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
Includes the following fixes:
* max coordinates values handling
* invalid preprocessor statements
* proper interrupt setup on FW update
And following features have been added:
* option to flip coordinates
* suspend/resume pin and power control
Change-Id: Id65bababf1daad807aa1b7a56bd457512bcd1b97
Signed-off-by: Konstantin Makariev <hcv867@motorola.com>
Reviewed-on: https://gerrit.mot.com/1896934
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Igor Kovalenko <igork@motorola.com>
Submit-Approved: Jira Key
Get the battery profile id via looking up from a profile id
and battery serial number mapping table in device tree, so
each product can specify the supported battery profile id and
serial number mapping table by its own in device tree.
Change-Id: Ide3a5b73e5500c47e1afca2122d6ef082982875d
Signed-off-by: yanyh2 <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/1899502
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
1. Use common wakeup source APIs
2. Add combo_health and combo_temp as combo property of
mmi_battery power supply.
3. Correct the initial value of battery status when
calculate the battery combo status.
4. Change the driver name to be constant for compatibles.
5. Export the including path for header file in Kbuild
6. Update the README for more platform driver support.
Change-Id: I0f3403c1e622aa35ccbf753d6c30142b16655752
Signed-off-by: yanyh2 <yanyh2@motorola.com>
Reviewed-on: https://gerrit.mot.com/1896694
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
On enable GKI products, there will use Qcom latest dlkm compile file
(device/qcom/common/dlkm/AndroidKernelModule.mk) to build kernel driver module,
and it requires all files of the current target driver module to be in the same
hierarchy path. Otherwise, when compile this module, a file will can not find
other local header files that under the different hierarchy path.
Change-Id: I09cfc7bd4539fb3ba8d654b240493d8a11066bee
Signed-off-by: linyx10 <linyx10@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1884805
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Binsheng Que <quebs2@motorola.com>
Reviewed-by: Zhenxin Xi <xizx@motorola.com>
Submit-Approved: Jira Key
The paths and interfaces for qcom scm call on kernel 4.x and kernel 5.x are
different, considering that different platform use different kernels, so
workaround here for compatibility.
Change-Id: I1a52e58be740799587a8ec924a5fd76d8f69a018
Signed-off-by: linyx10 <linyx10@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1885962
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jefferson Rodrigo Capovilla <jeffecap@motorola.com>
Reviewed-by: Binsheng Que <quebs2@motorola.com>
Reviewed-by: Zhenxin Xi <xizx@motorola.com>
Submit-Approved: Jira Key
when User attaches a 45W charger, the UI : 45W Hyper charging
In kernel space, driver module report "Hyper" to user space
when the 45w charger adapter connected
and report "Super" to user space when the 27w charger connected
/sys/class/power_supply/battery/charger_rate
Change-Id: I54041e6289fcea3808c1270bc70f2022c8d840cf
Signed-off-by: xuwt2 <xuwt2@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1450586
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
Reviewed-on: https://gerrit.mot.com/1893600
Reviewed-by: Xiangpo Zhao <zhaoxp3@motorola.com>
Reviewed-by: Wei Xu <xuwei9@lenovo.com>
In defender Project, there are two fuel gauge(bq27426, qpnp-qg),
sometimes, the soc 99% lasted for long time after recharging.
the battery status was NOT_CHARGING, because the current has been
terminated.
in that case, force it report 100%
Change-Id: I9b851ac7a7e3776730be386420ea974c15cbe321
Signed-off-by: xuwt2 <xuwt2@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1443240
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Yonghua Yan <yanyh2@motorola.com>
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
Reviewed-on: https://gerrit.mot.com/1893598
Reviewed-by: Xiangpo Zhao <zhaoxp3@motorola.com>
Reviewed-by: Wei Xu <xuwei9@lenovo.com>
the pmic current would be limit when 45w pd charger connect,
and must clear the pmic limit setting after PD power removed.
Change-Id: I814e2825ca29c0975542bda0dcc72f6571ea437a
Signed-off-by: xuwt2 <xuwt2@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1439744
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
Reviewed-on: https://gerrit.mot.com/1893582
Reviewed-by: Wei Xu <xuwei9@lenovo.com>
Reviewed-by: Xiangpo Zhao <zhaoxp3@motorola.com>
Under the parallel charging framework, the battery status should be
determined by all charging IC status, and not only from pmic charging
Change-Id: Idc85e8b96c1ff854f42f321e8e7b7a4c5ec55f6c
Signed-off-by: xuwt2 <xuwt2@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1435998
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
Reviewed-on: https://gerrit.mot.com/1893580
Reviewed-by: Wei Xu <xuwei9@lenovo.com>
Reviewed-by: Xiangpo Zhao <zhaoxp3@motorola.com>
-1, define a last chrg step flag.
-2, Disable charger pump IC at PM_STATE_ENTRY.
-3, Add second search cycle in mmi_find_chrg_step
-4, clear the batt_curr_roof and pd_constant_power_cnt
when switch the state machine work
Change-Id: I1156b8168c387ae2edf88052e9251302ef899ae1
Signed-off-by: xuwt2 <xuwt2@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1429346
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
Reviewed-on: https://gerrit.mot.com/1893575
Reviewed-by: Xiangpo Zhao <zhaoxp3@motorola.com>
Reviewed-by: Wei Xu <xuwei9@lenovo.com>
-1, Set the initial PD current to 2A.
-2, filter out the wrong PD request power for selecting PD charger.
-3, clear the pps result history after error pd result handing
-4, detect the pd constant power state, and avoid to excessive
boost vbus
Change-Id: I158a68c2907af42c07cd408ce162b528b3e39f10
Signed-off-by: xuwt2 <xuwt2@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1428520
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jianqi Yang <yangj@motorola.com>
Submit-Approved: Jira Key
Reviewed-on: https://gerrit.mot.com/1893572
Reviewed-by: Wei Xu <xuwei9@lenovo.com>
Reviewed-by: Xiangpo Zhao <zhaoxp3@motorola.com>
Under certain condition, the PD adapter would be instability,
and the sm work who responsible for the entire charging policy
might exited abnormally.
improve the synchronous processing.
Change-Id: I87bb51a4b69178f9eb40d6519328975203027c7e
Signed-off-by: xuwt2 <xuwt2@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1427554
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Jichao Zou <zoujc@motorola.com>
Submit-Approved: Jira Key
Reviewed-on: https://gerrit.mot.com/1893556
Reviewed-by: Xiangpo Zhao <zhaoxp3@motorola.com>
Reviewed-by: Wei Xu <xuwei9@lenovo.com>
Redefine the charger device error type,
In some case, the output of PD adapter is not stable,
It would cause the UCP or OCP occurs on the bq2597x,
Add a recovery handling to response to this issue.
Change-Id: I9350df26252483b5c9010c9ef27d0364b59d57b2
Signed-off-by: xuwt2 <xuwt2@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1427195
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Jichao Zou <zoujc@motorola.com>
Submit-Approved: Jira Key
Reviewed-on: https://gerrit.mot.com/1893555
Reviewed-by: Xiangpo Zhao <zhaoxp3@motorola.com>
Reviewed-by: Wei Xu <xuwei9@lenovo.com>