blob: 04f289a868e06f70da71d08330613b0a27e58d60 [file] [log] [blame]
Tom Josephf8da32a2016-12-06 16:56:04 +05301#pragma once
2
Tom Josephf8da32a2016-12-06 16:56:04 +05303#include "comm_module.hpp"
4
Vernon Mauery9e801a22018-10-12 13:20:49 -07005#include <sdbusplus/bus/match.hpp>
George Liubc8958f2022-07-04 09:29:49 +08006
7#include <cstddef>
Vernon Mauery9e801a22018-10-12 13:20:49 -07008#include <vector>
9
Tom Josephf8da32a2016-12-06 16:56:04 +053010namespace command
11{
12
13constexpr size_t BMC_GUID_LEN = 16;
14
Tom Joseph83029cb2017-09-01 16:37:31 +053015using Guid = std::array<uint8_t, BMC_GUID_LEN>;
16
Tom Joseph3563f8f2017-05-08 15:42:54 +053017/**
Tom Josephf8da32a2016-12-06 16:56:04 +053018 * @brief Get System GUID
19 *
20 * @return If UUID is successfully read from the Chassis DBUS object, then the
21 * GUID is returned, else a canned GUID is returned
22 */
Tom Joseph83029cb2017-09-01 16:37:31 +053023Guid getSystemGUID();
24
25/**
26 * @brief Register the callback to update the cache when the GUID changes
27 */
28void registerGUIDChangeCallback();
Tom Josephf8da32a2016-12-06 16:56:04 +053029
30} // namespace command
Tom Joseph83029cb2017-09-01 16:37:31 +053031
32namespace cache
33{
34
35extern command::Guid guid;
36
Vernon Mauery9e801a22018-10-12 13:20:49 -070037} // namespace cache