diff options
author | Allen Webb <allenwebb@google.com> | 2018-11-09 09:42:53 -0800 |
---|---|---|
committer | chrome-bot <chrome-bot@chromium.org> | 2018-11-15 13:16:06 -0800 |
commit | 1c95cff7463ef29bd0c6d087ce8c3d7e17f94c6a (patch) | |
tree | 90de208cb94b874a8fc3a8a1f1082116e908cc48 /chip | |
parent | 268b07da45535033ae39240e958fc00386e37684 (diff) | |
download | chrome-ec-1c95cff7463ef29bd0c6d087ce8c3d7e17f94c6a.tar.gz |
cr50: Add extern "C" to headers used by future fuzzing target.
BRANCH=None
BUG=None
TEST=make -j buildall
Change-Id: Icf2cfb6a2657064c10721c0e527d24fbb3be6ab3
Signed-off-by: Allen Webb <allenwebb@google.com>
Reviewed-on: https://chromium-review.googlesource.com/1330102
Reviewed-by: Mike Frysinger <vapier@chromium.org>
Diffstat (limited to 'chip')
-rw-r--r-- | chip/g/dcrypto/dcrypto.h | 8 | ||||
-rw-r--r-- | chip/g/dcrypto/internal.h | 7 | ||||
-rw-r--r-- | chip/host/persistence.h | 8 |
3 files changed, 23 insertions, 0 deletions
diff --git a/chip/g/dcrypto/dcrypto.h b/chip/g/dcrypto/dcrypto.h index 93763b1f26..f51907f767 100644 --- a/chip/g/dcrypto/dcrypto.h +++ b/chip/g/dcrypto/dcrypto.h @@ -21,6 +21,10 @@ #include "cryptoc/hmac.h" +#ifdef __cplusplus +extern "C" { +#endif + enum cipher_mode { CIPHER_MODE_ECB = 0, CIPHER_MODE_CTR = 1, @@ -337,4 +341,8 @@ BUILD_ASSERT(DCRYPTO_CIPHER_SALT_SIZE == CIPHER_SALT_SIZE); int DCRYPTO_app_cipher(enum dcrypto_appid appid, const void *salt, void *out, const void *in, size_t len); +#ifdef __cplusplus +} +#endif + #endif /* ! __EC_CHIP_G_DCRYPTO_DCRYPTO_H */ diff --git a/chip/g/dcrypto/internal.h b/chip/g/dcrypto/internal.h index 3e546e90a2..fa280e94b5 100644 --- a/chip/g/dcrypto/internal.h +++ b/chip/g/dcrypto/internal.h @@ -18,6 +18,10 @@ #include "cryptoc/sha384.h" #include "cryptoc/sha512.h" +#ifdef __cplusplus +extern "C" { +#endif + /* * SHA. */ @@ -178,5 +182,8 @@ int dcrypto_ladder_derive(enum dcrypto_appid appid, const uint32_t salt[8], const uint32_t input[8], uint32_t output[8]); #endif +#ifdef __cplusplus +} +#endif #endif /* ! __EC_CHIP_G_DCRYPTO_INTERNAL_H */ diff --git a/chip/host/persistence.h b/chip/host/persistence.h index 1fab1c8235..56e2df2eb4 100644 --- a/chip/host/persistence.h +++ b/chip/host/persistence.h @@ -10,10 +10,18 @@ #include <stdio.h> +#ifdef __cplusplus +extern "C" { +#endif + FILE *get_persistent_storage(const char *tag, const char *mode); void release_persistent_storage(FILE *ps); void remove_persistent_storage(const char *tag); +#ifdef __cplusplus +} +#endif + #endif /* __CROS_EC_PERSISTENCE_H */ |