diff options
author | Vincent Palatin <vpalatin@chromium.org> | 2017-02-16 14:15:30 +0100 |
---|---|---|
committer | chrome-bot <chrome-bot@chromium.org> | 2017-02-23 16:02:03 -0800 |
commit | 0d858f1544cfd50f4a63f348d722bb16d638c0b1 (patch) | |
tree | c4fe70955629048828b9fdb4369a667d4f26c515 /builtin | |
parent | bff020fc6b25fe5dc0245c811d9f53b7c518aa08 (diff) | |
download | chrome-ec-0d858f1544cfd50f4a63f348d722bb16d638c0b1.tar.gz |
curve25519: strip-down, build and test
Keep only the most compact version of the curve25519 code
and remove the remaining unused code for easier compilation.
Do the minimal changes to make it compile in the EC code base,
there should be no real functional changes.
Re-use the wording from BoringSSL include/openssl/curve25519.h for the
header.
Signed-off-by: Vincent Palatin <vpalatin@chromium.org>
BRANCH=none
BUG=chrome-os-partner:62991
TEST=run x25519 on host (ie 'make run-x25519')
and the STM32L4 target:
make BOARD=eve_fp PROJECT=x25519 TEST_BUILD=y
./util/flash_ec --board=eve_fp --image=build/eve_fp/x25519.bin
execute 'runtest' in the console.
Change-Id: I13dbe453eff39b461effb1b3ffa549afc1749fef
Reviewed-on: https://chromium-review.googlesource.com/444187
Commit-Ready: Vincent Palatin <vpalatin@chromium.org>
Tested-by: Vincent Palatin <vpalatin@chromium.org>
Reviewed-by: Adam Langley <agl@chromium.org>
Reviewed-by: Randall Spangler <rspangler@chromium.org>
Diffstat (limited to 'builtin')
-rw-r--r-- | builtin/stdint.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/builtin/stdint.h b/builtin/stdint.h index b82268b409..fe4a92e2ea 100644 --- a/builtin/stdint.h +++ b/builtin/stdint.h @@ -44,4 +44,11 @@ typedef uint8_t uint_least8_t; #define INT32_MAX (2147483647U) #endif +#ifndef UINT64_C +#define UINT64_C(c) c ## ULL +#endif +#ifndef INT64_C +#define INT64_C(c) c ## LL +#endif + #endif /* __CROS_EC_STDINT_H__ */ |