update when system wakes up
authorPeter Li <peter-li@ti.com>
Wed, 8 Mar 2017 16:14:07 +0000 (00:14 +0800)
committerPeter Li <peter-li@ti.com>
Wed, 8 Mar 2017 16:14:07 +0000 (00:14 +0800)
tas2557-regmap.c

index f07043cf223268b4dfadd95d2a876fe872bb1970..9af4ca4e6420c0d2d88b4be807ffb60cb0855a17 100755 (executable)
@@ -491,9 +491,11 @@ static int tas2557_resume(struct device *dev)
 
        pProgram = &(pTAS2557->mpFirmware->mpPrograms[pTAS2557->mnCurrentProgram]);
        if (pTAS2557->mbPowerUp && (pProgram->mnAppMode == TAS2557_APP_TUNINGMODE)) {
-               dev_dbg(pTAS2557->dev, "%s, start Die Temp check timer\n", __func__);
-               hrtimer_start(&pTAS2557->mtimer,
-                       ns_to_ktime((u64)LOW_TEMPERATURE_CHECK_PERIOD * NSEC_PER_MSEC), HRTIMER_MODE_REL);
+               if (!hrtimer_active(&pTAS2557->mtimer)) {
+                       dev_dbg(pTAS2557->dev, "%s, start Die Temp check timer\n", __func__);
+                       hrtimer_start(&pTAS2557->mtimer,
+                               ns_to_ktime((u64)LOW_TEMPERATURE_CHECK_PERIOD * NSEC_PER_MSEC), HRTIMER_MODE_REL);
+               }
        }
 
 end: