Add TimeManager daemon to openbmc

Time Manager daemon supporting NTP and MANUAL modes and below policy

  *) BMC owns the time
  *) HOST owns the time
  *) SPLIT clock and HOST's time is maintained as an offset to BMC
  *) BOTH the BMC and HOST own the clock

Change-Id: I81701b67731aa4b37d6926d5b93d397fea96e086
Signed-off-by: Vishwanatha Subbanna <vishwa@linux.vnet.ibm.com>
diff --git a/time-register.c b/time-register.c
new file mode 100644
index 0000000..cdc1dd2
--- /dev/null
+++ b/time-register.c
@@ -0,0 +1,25 @@
+#include <systemd/sd-bus.h>
+#include "time-register.hpp"
+#include <sys/timerfd.h>
+#include <errno.h>
+#include <stdio.h>
+
+/* Function pointer of APIs exposed via Dbus */
+//const sd_bus_vtable timeServicesVtable[] =
+const sd_bus_vtable timeServicesVtable [] =
+{
+    SD_BUS_VTABLE_START(0),
+    SD_BUS_PROPERTY("curr_time_mode", "s", getCurrTimeModeProperty, 0,
+    SD_BUS_VTABLE_PROPERTY_CONST),
+    SD_BUS_PROPERTY("curr_time_owner", "s", getCurrTimeOwnerProperty, 0,
+    SD_BUS_VTABLE_PROPERTY_CONST),
+    SD_BUS_PROPERTY("requested_time_mode", "s", getReqTimeModeProperty, 0,
+    SD_BUS_VTABLE_PROPERTY_CONST),
+    SD_BUS_PROPERTY("requested_time_owner", "s", getReqTimeOwnerProperty, 0,
+    SD_BUS_VTABLE_PROPERTY_CONST),
+    SD_BUS_METHOD("GetTime", "s", "sx", &GetTime,
+    SD_BUS_VTABLE_UNPRIVILEGED),
+    SD_BUS_METHOD("SetTime", "ss", "i", &SetTime,
+    SD_BUS_VTABLE_UNPRIVILEGED),
+    SD_BUS_VTABLE_END,
+};