(CR)[Kane]:[kernel]motor shorten probe time(1/1)
authorzhangyijie <zhangyijie@huaqin.com>
Thu, 20 Dec 2018 07:12:22 +0000 (15:12 +0800)
committerxiest1 <xiest1@lenovo.com>
Tue, 5 Nov 2019 09:30:07 +0000 (17:30 +0800)
motor update driver code for shorten driver probe time

Change-Id: Id89d18da218e362ed1afbf1ac327208c7c85b25d

drivers/misc/aw8695_haptic/aw8695.c

index c48b376d2acfdf65c463ea1ecc480a2443a76e57..dd1766838b668ce770bba4ccc6857fbd12630c14 100755 (executable)
@@ -1453,7 +1453,9 @@ static int aw8695_haptic_f0_calibration(struct aw8695 *aw8695)
 
     /* restore default work mode */
     aw8695_haptic_play_mode(aw8695, AW8695_HAPTIC_STANDBY_MODE);
-    aw8695_haptic_play_mode(aw8695, AW8695_HAPTIC_RAM_MODE);
+    aw8695->play_mode = AW8695_HAPTIC_RAM_MODE;
+    aw8695_i2c_write_bits(aw8695, AW8695_REG_SYSCTRL,
+            AW8695_BIT_SYSCTRL_PLAY_MODE_MASK, AW8695_BIT_SYSCTRL_PLAY_MODE_RAM);
     aw8695_haptic_stop(aw8695);
 
     return ret;