mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-09 05:39:54 -04:00
[capsensor] add debug support for cap sensor
Capri: sx9338 sar sensor load reference phase config from dts Change-Id: I9aaeb587e87e74a9bb1bedbc31551ffd2c50c8bf Signed-off-by: tnlizd <tnlizd@motorola.com> Reviewed-on: https://gerrit.mot.com/1790916 SLTApproved: Slta Waiver SME-Granted: SME Approvals Granted Tested-by: Jira Key Reviewed-by: Wen Xie <xiewen3@motorola.com> Reviewed-by: Xiangpo Zhao <zhaoxp3@motorola.com> Submit-Approved: Jira Key
This commit is contained in:
parent
93e72f7758
commit
9f2d0a4994
1 changed files with 13 additions and 0 deletions
|
|
@ -980,6 +980,19 @@ static int sx933x_parse_dt(struct sx933x_platform_data *pdata, struct device *de
|
|||
of_property_read_u32(dNode,"Semtech,button-flag",&pdata->button_used_flag);
|
||||
LOG_INFO("used button 0x%x \n", pdata->button_used_flag);
|
||||
|
||||
pdata->ref_phase_a = -1;
|
||||
pdata->ref_phase_b = -1;
|
||||
if ( of_property_read_u32(dNode,"Semtech,ref-phases-a",&pdata->ref_phase_a) )
|
||||
{
|
||||
LOG_ERR("[SX933x]: %s - get ref-phases error\n", __func__);
|
||||
}
|
||||
if ( of_property_read_u32(dNode,"Semtech,ref-phases-b",&pdata->ref_phase_b) )
|
||||
{
|
||||
LOG_ERR("[SX933x]: %s - get ref-phases-b error\n", __func__);
|
||||
}
|
||||
LOG_INFO("[SX933x]: %s ref_phase_a= %d ref_phase_b= %d\n",
|
||||
__func__, pdata->ref_phase_a, pdata->ref_phase_b);
|
||||
|
||||
#ifdef USE_DTS_REG
|
||||
// load in registers from device tree
|
||||
of_property_read_u32(dNode,"Semtech,reg-num",&pdata->i2c_reg_num);
|
||||
|
|
|
|||
Loading…
Reference in a new issue