Implement command GetDateTime

This commit implements the GetDateTime command which is
defined in PLDM Bios Control and Configuration Specification.

Change-Id: Iced21bbad7be07d357b6885b1b1e03b07a3da165
Signed-off-by: Sampa Misra <sampmisr@in.ibm.com>
diff --git a/libpldmresponder/utils.hpp b/libpldmresponder/utils.hpp
new file mode 100644
index 0000000..d76b716
--- /dev/null
+++ b/libpldmresponder/utils.hpp
@@ -0,0 +1,48 @@
+#pragma once
+
+#include <stdint.h>
+#include <systemd/sd-bus.h>
+
+#include <sdbusplus/server.hpp>
+#include <string>
+
+namespace pldm
+{
+namespace responder
+{
+
+/**
+ *  @brief Get the DBUS Service name for the input dbus path
+ *  @param[in] bus - DBUS Bus Object
+ *  @param[in] path - DBUS object path
+ *  @param[in] interface - DBUS Interface
+ *  @return std::string - the dbus service name
+ */
+std::string getService(sdbusplus::bus::bus& bus, const std::string& path,
+                       const std::string& interface);
+
+/** @brief Convert any Decimal number to BCD
+ *
+ *  @tparam[in] decimal - Decimal number
+ *  @return Corresponding BCD number
+ */
+template <typename T>
+T decimalToBcd(T decimal)
+{
+    T bcd = 0;
+    T rem = 0;
+    auto cnt = 0;
+
+    while (decimal)
+    {
+        rem = decimal % 10;
+        bcd = bcd + (rem << cnt);
+        decimal = decimal / 10;
+        cnt += 4;
+    }
+
+    return bcd;
+}
+
+} // namespace responder
+} // namespace pldm