Using new-style return values for spci_version.
Bug: 132395846
Change-Id: I7d1a926b8dab526b3d8c3c6d06a8c136e5639e5e
diff --git a/src/api.c b/src/api.c
index ff56751..a605ac4 100644
--- a/src/api.c
+++ b/src/api.c
@@ -1653,7 +1653,7 @@
}
/** Returns the version of the implemented SPCI specification. */
-int32_t api_spci_version(void)
+struct spci_value api_spci_version(void)
{
/*
* Ensure that both major and minor revision representation occupies at
@@ -1664,8 +1664,11 @@
static_assert(0x10000 > SPCI_VERSION_MINOR,
"Minor revision representation take more than 16 bits.");
- return (SPCI_VERSION_MAJOR << SPCI_VERSION_MAJOR_OFFSET) |
- SPCI_VERSION_MINOR;
+ struct spci_value ret = {
+ .func = SPCI_SUCCESS_32,
+ .arg1 = (SPCI_VERSION_MAJOR << SPCI_VERSION_MAJOR_OFFSET) |
+ SPCI_VERSION_MINOR};
+ return ret;
}
int64_t api_debug_log(char c, struct vcpu *current)