Add fwu update agent deployment for linux-pc/posix
The fwu update agent can be deployed in different
execution environments to suite platform requirements.
This commit adds a deployment where the fwu update
agent runs within a command-line app for Posix
environments where the firmware image file is accessible
via standard file io. Can be built to run in a native PC
environment to enable a disk image file to be inspected.
Signed-off-by: Julian Hall <julian.hall@arm.com>
Change-Id: I3a652c7ab201c5b7059f8dd1bb6b590e6d8c4c37
diff --git a/deployments/fwu/env/posix/print_uuid.cpp b/deployments/fwu/env/posix/print_uuid.cpp
new file mode 100644
index 0000000..6cfbdcd
--- /dev/null
+++ b/deployments/fwu/env/posix/print_uuid.cpp
@@ -0,0 +1,17 @@
+/*
+ * Copyright (c) 2023, Arm Limited and Contributors. All rights reserved.
+ *
+ * SPDX-License-Identifier: BSD-3-Clause
+ */
+
+#include <common/uuid/uuid.h>
+#include "print_uuid.h"
+
+std::string print_uuid(const uint8_t *uuid_octets)
+{
+ struct uuid_canonical canonical_uuid;
+
+ uuid_canonical_from_guid_octets(&canonical_uuid, (const struct uuid_octets *)uuid_octets);
+
+ return std::string(canonical_uuid.characters);
+}