BMC boot time and count

The algorithm here to determine boot time and incrementing boot
count is simple reasoning logic. The /proc/stat btime gives the
time at which the system booted, in seconds since the Unix epoch.

By default Boot time and count is set to 0. When the first instance
of call is made to set the boot time, both the boot time and count
is updated. Subsequent calls to update is done if the global boot
time is less than the current boot time from the BMC.

Resolves openbmc/openbmc-test-automation#294

Change-Id: Iab5778af1d928ed583572b99ce2257d8df6c5238
Signed-off-by: George Keishing <gkeishin@in.ibm.com>
1 file changed