Recover from bad input event timestamps from the kernel.

This can happen due to a race when the input device is
opened or if the kernel happens to be missing the required
Android patches to set the timestamp correctly.

Bug: 7291243
Change-Id: If4319440eaff2889147c86296abd39efc5664346
diff --git a/services/input/InputReader.cpp b/services/input/InputReader.cpp
index cebfeb4..bc8df18 100644
--- a/services/input/InputReader.cpp
+++ b/services/input/InputReader.cpp
@@ -956,8 +956,9 @@
     size_t numMappers = mMappers.size();
     for (const RawEvent* rawEvent = rawEvents; count--; rawEvent++) {
 #if DEBUG_RAW_EVENTS
-        ALOGD("Input event: device=%d type=0x%04x code=0x%04x value=0x%08x",
-                rawEvent->deviceId, rawEvent->type, rawEvent->code, rawEvent->value);
+        ALOGD("Input event: device=%d type=0x%04x code=0x%04x value=0x%08x when=%lld",
+                rawEvent->deviceId, rawEvent->type, rawEvent->code, rawEvent->value,
+                rawEvent->when);
 #endif
 
         if (mDropUntilNextSync) {