arm-trusted-firmware/drivers/auth
Sandrine Bailleux 0b4e59211b TBBR: Reduce size of hash buffers when possible
The TBBR implementation extracts hashes from certificates and stores
them in static buffers. TF-A supports 3 variants of SHA right now:
SHA-256, SHA-384 and SHA-512. When support for SHA-512 was added in
commit 9a3088a5f5 ("tbbr: Add build flag
HASH_ALG to let the user to select the SHA"), the hash buffers got
unconditionally increased from 51 to 83 bytes each. We can reduce that
space if we're using SHA-256 or SHA-384.

This saves some BSS space in both BL1 and BL2:
- BL1 with SHA-256: saving 168 bytes.
- BL1 with SHA-384: saving 80 bytes.
- BL2 with SHA-256: saving 384 bytes.
- BL2 with SHA-384: saving 192 bytes.

Change-Id: I0d02e5dc5f0162e82339c768609c9766cfe7e2bd
Signed-off-by: Sandrine Bailleux <sandrine.bailleux@arm.com>
2020-02-18 09:47:12 +01:00
..
cryptocell cryptocell: add cryptocell 712 RSA 3K support 2019-12-11 14:18:18 +02:00
mbedtls Measured Boot: add function for hash calculation 2020-01-28 16:51:40 +00:00
tbbr TBBR: Reduce size of hash buffers when possible 2020-02-18 09:47:12 +01:00
auth_mod.c fconf: initial commit 2020-02-07 13:29:09 +00:00
crypto_mod.c Measured Boot: add function for hash calculation 2020-01-28 16:51:40 +00:00
img_parser_mod.c Coverity: remove unnecessary header file includes 2020-02-04 10:23:51 -06:00