aboutsummaryrefslogtreecommitdiff
path: root/interface/include
diff options
context:
space:
mode:
authorDavid Hu <david.hu@arm.com>2021-04-01 16:34:30 +0800
committerDavid Hu <david.hu@arm.com>2021-04-29 08:56:18 +0200
commit7c2a744b3712f481b9dc7ab89bcc0ef5cb30f5fa (patch)
tree300e04d87a0abc5ae4090bc9074076a6da8f4d39 /interface/include
parentcd22d1bd7f96ece9f88df87445f7be138de380b3 (diff)
downloadtrusted-firmware-m-7c2a744b3712f481b9dc7ab89bcc0ef5cb30f5fa.tar.gz
Interface: Fix veneer function naming
Some veneer functions are named with "tfm_tfm_" prefix. It is confusing and unfriendly to NS integration. This patch unifies the prefix of all the veneer function as "tfm_" - Fix the duplicated "tfm_" prefixes by checking secure function prefix in tfm_veneer template. - Replace all the "tfm_tfm_" prefixes with "tfm_". Change-Id: Id658486f49f4a6f1f22fd3897be27865889474ae Signed-off-by: David Hu <david.hu@arm.com>
Diffstat (limited to 'interface/include')
-rw-r--r--interface/include/tfm_veneers.h.template7
1 files changed, 7 insertions, 0 deletions
diff --git a/interface/include/tfm_veneers.h.template b/interface/include/tfm_veneers.h.template
index 502dee28ae..ee17d3f953 100644
--- a/interface/include/tfm_veneers.h.template
+++ b/interface/include/tfm_veneers.h.template
@@ -22,7 +22,14 @@ extern "C" {
{% endif %}
/******** {{partition.manifest.name}} ********/
{% for function in partition.manifest.secure_functions%}
+ {% if function.signal.lower().startswith('tfm_') %}
+ {# If signal already contains tfm_ prefix, avoid adding a duplicated one
+ in veneer function name.
+ #}
+psa_status_t {{function.signal.lower()}}_veneer(psa_invec *in_vec, size_t in_len, psa_outvec *out_vec, size_t out_len);
+ {% else %}
psa_status_t tfm_{{function.signal.lower()}}_veneer(psa_invec *in_vec, size_t in_len, psa_outvec *out_vec, size_t out_len);
+ {% endif %}
{% endfor %}
{% if partition.attr.conditional %}
#endif /* {{partition.attr.conditional}} */