From 8dce1b9e6e869d96b47573a0acb205465247b5fc Mon Sep 17 00:00:00 2001 From: Konstantin Makariev Date: Wed, 8 Jun 2022 13:24:32 -0500 Subject: [PATCH] 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 Reviewed-on: https://gerrit.mot.com/2294160 SME-Granted: SME Approvals Granted SLTApproved: Slta Waiver Tested-by: Jira Key Reviewed-by: Qing Chang Submit-Approved: Jira Key --- drivers/misc/drv8424/drv8424.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/misc/drv8424/drv8424.c b/drivers/misc/drv8424/drv8424.c index f0262c2dd03a..7b2ec0943d10 100644 --- a/drivers/misc/drv8424/drv8424.c +++ b/drivers/misc/drv8424/drv8424.c @@ -2016,7 +2016,9 @@ static int moto_drv8424_probe(struct platform_device *pdev) } else { md->time_out = MOTOR_DEFAULT_EXPIRE; atomic_set(&md->position, POS_COMPACT); + moto_drv8424_cmd_push(md, CMD_POSITION, 0); atomic_set(&md->status, STATUS_STOPPED_COMPACT); + moto_drv8424_cmd_push(md, CMD_STATUS, 0); dev_info(dev, "Assume COMPACT position\n"); }