From ef978277038b37517878db7eb3fc0d335def3caf Mon Sep 17 00:00:00 2001 From: Kiran Gunda Date: Mon, 12 Jul 2021 14:58:08 +0530 Subject: [PATCH] input: qcom-hv-haptics: Enable boot-up F0 calibration for PM5100 In the boot up LRA frequency calibration sequence, CAL_TLRA_CL_STS is read out and stored in SDAM module registers by the bootloader. Later, the HLOS haptics driver can read it from there and use it for calculating LRA frequency. Enable the same for PM5100 PMIC. Change-Id: Ia5e307e5d536a42b29ab05e9888640121188312c Signed-off-by: Kiran Gunda --- drivers/input/misc/qcom-hv-haptics.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/input/misc/qcom-hv-haptics.c b/drivers/input/misc/qcom-hv-haptics.c index f1ca4a207eef..9f7653f41cc5 100644 --- a/drivers/input/misc/qcom-hv-haptics.c +++ b/drivers/input/misc/qcom-hv-haptics.c @@ -1042,7 +1042,7 @@ static int haptics_get_closeloop_lra_period( rc_clk_cal = ((val[0] & CAL_RC_CLK_MASK) >> CAL_RC_CLK_SHIFT); /* read auto resonance calibration result */ - if (in_boot && (chip->hw_type == HAP520)) { + if (in_boot && ((chip->hw_type == HAP520) || (chip->hw_type == HAP520_MV))) { if (chip->hap_cfg_nvmem == NULL) { dev_dbg(chip->dev, "nvmem device for hap_cfg is not defined\n"); return -EINVAL;