Update to PSA FWU 1.0 protocol (DEN0118)
Update FWU provider and clients to follow the 1.0 version specification.
Signed-off-by: Imre Kis <imre.kis@arm.com>
Change-Id: I0710b0df388609a7c3f2ce4a5e98a9fe5c2e2b99
diff --git a/components/service/fwu/agent/update_agent.c b/components/service/fwu/agent/update_agent.c
index 77037b1..733a012 100644
--- a/components/service/fwu/agent/update_agent.c
+++ b/components/service/fwu/agent/update_agent.c
@@ -54,6 +54,18 @@
static int cancel_staging(void *context);
+static int discover(void *context, struct fwu_discovery_result *result)
+{
+ result->service_status = 0;
+ result->version_major = FWU_PROTOCOL_VERSION_MAJOR;
+ result->version_minor = FWU_PROTOCOL_VERSION_MINOR;
+ result->max_payload_size = 0;
+ result->flags = 0;
+ result->vendor_specific_flags = 0;
+
+ return FWU_STATUS_SUCCESS;
+}
+
static int begin_staging(void *context, uint32_t vendor_flags, uint32_t partial_update_count,
const struct uuid_octets *update_guid)
{
@@ -295,7 +307,7 @@
static const struct update_agent_interface interface = {
- .discover = NULL,
+ .discover = discover,
.begin_staging = begin_staging,
.end_staging = end_staging,
.cancel_staging = cancel_staging,