watchdog: timeRemaining doesn't need to check enabled

The Timer is fully owned by the Watchdog and is only enabled when the
watchdog is enabled. Therefore, we only need to check the state of the
timer instead of the interface and timer before populating the
timeRemaining value. This simplifies later patches and does not make any
functional change.

Change-Id: Ib11edd75eb1953360bf4eae7fc4b29b5251cf0c5
Signed-off-by: William A. Kennington III <wak@google.com>
diff --git a/watchdog.cpp b/watchdog.cpp
index c948d27..4a87a0d 100644
--- a/watchdog.cpp
+++ b/watchdog.cpp
@@ -49,24 +49,21 @@
 {
     uint64_t timeRemain = 0;
 
-    if (this->enabled())
+    // timer may have already expired and disabled
+    if (timer.getEnabled() != SD_EVENT_OFF)
     {
-        // timer may have already expired and disabled
-        if (timer.getEnabled() != SD_EVENT_OFF)
-        {
-            // the one-shot timer does not expire yet
-            auto expiry = duration_cast<milliseconds>(
-                                   timer.getRemaining());
+        // the one-shot timer does not expire yet
+        auto expiry = duration_cast<milliseconds>(
+                timer.getRemaining());
 
-            // convert to msec per interface expectation.
-            auto timeNow = duration_cast<milliseconds>(
-                                    Timer::getCurrentTime());
+        // convert to msec per interface expectation.
+        auto timeNow = duration_cast<milliseconds>(
+                Timer::getCurrentTime());
 
-            // Its possible that timer may have expired by now.
-            // So need to cross verify.
-            timeRemain = (expiry > timeNow) ?
-                            (expiry - timeNow).count() : 0;
-        }
+        // Its possible that timer may have expired by now.
+        // So need to cross verify.
+        timeRemain = (expiry > timeNow) ?
+            (expiry - timeNow).count() : 0;
     }
     return timeRemain;
 }