Camera: obtain and use the timestamp from camera driver to avoid
jerkiness in recorded clip.

Fix the jerkiness in recorded clip by getting the timestamp from camera
driver instead of using the timestamp generated at camera HAL, thus
avoiding thread scheduling dependency.

CRs-Fixed: 232272

Change-Id: Ifded5d7c08c1aad1b67c690d4b6d0eee34b9ab90
diff --git a/QualcommCameraHardware.cpp b/QualcommCameraHardware.cpp
index 410d930..a908685 100644
--- a/QualcommCameraHardware.cpp
+++ b/QualcommCameraHardware.cpp
@@ -1957,6 +1957,8 @@
             LOGV("offset = %d , alignsize = %d , offset later = %d", offset, mRecordHeap->mAlignedBufferSize, (offset / mRecordHeap->mAlignedBufferSize));
 
             offset /= mRecordHeap->mAlignedBufferSize;
+            /* Extract the timestamp of this frame */
+            nsecs_t timeStamp = nsecs_t(vframe->ts.tv_sec)*1000000000LL + vframe->ts.tv_nsec;
 
             // dump frames for test purpose
 #ifdef DUMP_VIDEO_FRAMES
@@ -1989,7 +1991,7 @@
 
             if(rcb != NULL && (msgEnabled & CAMERA_MSG_VIDEO_FRAME) ) {
                 LOGV("in video_thread : got video frame, giving frame to services/encoder");
-                rcb(systemTime(), CAMERA_MSG_VIDEO_FRAME, mRecordHeap->mBuffers[offset], rdata);
+                rcb(timeStamp, CAMERA_MSG_VIDEO_FRAME, mRecordHeap->mBuffers[offset], rdata);
             }
 #else
             // 720p output2  : simulate release frame here:
@@ -3974,7 +3976,7 @@
     if( (!strcmp(sensorType->name, "2mp")) ||
         (!strcmp(mSensorInfo.name, "vx6953")) ||
 	(!strcmp(mSensorInfo.name, "VX6953")) ) {
-        LOGE("Parameter Rolloff is not supported for this sensor");
+        LOGI("Parameter Rolloff is not supported for this sensor");
         return NO_ERROR;
     }
     const char *str = params.get(CameraParameters::KEY_LENSSHADE);
@@ -4526,7 +4528,7 @@
 void QualcommCameraHardware::receive_camframetimeout(void) {
     LOGV("receive_camframetimeout: E");
     Mutex::Autolock l(&mCamframeTimeoutLock);
-    LOGD(" Camframe timed out. Not receiving any frames from camera driver ");
+    LOGE(" Camframe timed out. Not receiving any frames from camera driver ");
     camframe_timeout_flag = TRUE;
     LOGV("receive_camframetimeout: X");
 }