Add timestamp prefix to LOG[0|1|2]() macros
authorRobert Tivy <rtivy@ti.com>
Fri, 28 Feb 2014 00:19:11 +0000 (16:19 -0800)
committerChris Ring <cring@ti.com>
Thu, 13 Mar 2014 15:21:55 +0000 (08:21 -0700)
commit123b9263fca191b976cc3b41f326e5e08a5062b4
tree907d750f9fa30acbb33d18afcc793f53d9dc6db0
parentc18fece0c9f0dc76361dc1ee11b7ee2417479847
Add timestamp prefix to LOG[0|1|2]() macros

For the timestamp prefix, subtract the start time (which is established
when the logFile is opened) so that the massive "since the epoch" value
is not displayed.  For this, subtract only the timeval.tv_sec (seconds)
value so we don't have to worry about the "borrow" that results when
start_tv.tv_usec > tv.tv_usec (essentially, treat start_tv.tv_usec as 0,
which skews this "relative" time ahead by start_tv.tv_usec microseconds).
linux/include/_lad.h
linux/src/daemon/lad.c