aaudio: disable new external timestamp

Disable recent change that caused a regression and broke
OUTPUT timestamps.

Bug: 169773867
Test: OboeTester, TEST OUTPUT
Test: "latnc" for MMAP streams should be a few msec not "?"
Change-Id: I7c4697a34d63a1fd514298f04fc91421c2bb32b1
diff --git a/services/oboeservice/AAudioServiceStreamMMAP.cpp b/services/oboeservice/AAudioServiceStreamMMAP.cpp
index a4c064e..57dc1ab 100644
--- a/services/oboeservice/AAudioServiceStreamMMAP.cpp
+++ b/services/oboeservice/AAudioServiceStreamMMAP.cpp
@@ -19,6 +19,7 @@
 #include <utils/Log.h>
 
 #include <atomic>
+#include <inttypes.h>
 #include <iomanip>
 #include <iostream>
 #include <stdint.h>
@@ -163,7 +164,7 @@
 }
 
 // Get timestamp from presentation position.
-// If fails, get time stamp that was written by getFreeRunningPosition()
+// If it fails, get timestamp that was written by getFreeRunningPosition()
 aaudio_result_t AAudioServiceStreamMMAP::getHardwareTimestamp(int64_t *positionFrames,
                                                                 int64_t *timeNanos) {
 
@@ -175,11 +176,18 @@
     sp<AAudioServiceEndpointMMAP> serviceEndpointMMAP =
             static_cast<AAudioServiceEndpointMMAP *>(endpoint.get());
 
+    // Disable this code temporarily because the HAL is not returning
+    // a useful result.
+#if 0
     uint64_t position;
     if (serviceEndpointMMAP->getExternalPosition(&position, timeNanos) == AAUDIO_OK) {
+        ALOGD("%s() getExternalPosition() says pos = %" PRIi64 ", time = %" PRIi64,
+                __func__, position, *timeNanos);
         *positionFrames = (int64_t) position;
         return AAUDIO_OK;
-    } else if (mAtomicStreamTimestamp.isValid()) {
+    } else
+#endif
+    if (mAtomicStreamTimestamp.isValid()) {
         Timestamp timestamp = mAtomicStreamTimestamp.read();
         *positionFrames = timestamp.getPosition();
         *timeNanos = timestamp.getNanoseconds() + serviceEndpointMMAP->getHardwareTimeOffsetNanos();