From 955993c4b5ade57d5345839ab7f71a45fcbaaa6f Mon Sep 17 00:00:00 2001 From: Gilles Peskine Date: Wed, 29 Jun 2022 14:37:17 +0200 Subject: [PATCH] For status values, the macro expansions must not change either Signed-off-by: Gilles Peskine --- include/psa/crypto_values.h | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/include/psa/crypto_values.h b/include/psa/crypto_values.h index 99be43395d..e60257d7fa 100644 --- a/include/psa/crypto_values.h +++ b/include/psa/crypto_values.h @@ -47,7 +47,14 @@ /* PSA error codes */ /* Error codes are standardized across PSA domains (framework, crypto, storage, - * etc.). Do not change the values in this section. If you must add a new + * etc.). Do not change the values in this section or even the expansions + * of each macro: it must be possible to `#include` both this header + * and some other PSA component's headers in the same C source, + * which will lead to duplicate definitions of the `PSA_SUCCESS` and + * `PSA_ERROR_xxx` macros, which is ok if and only if the macros expand + * to the same sequence of tokens. + * + * If you must add a new * value, check with the Arm PSA framework group to pick one that other * domains aren't already using. */