mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2026-10-28 18:07:34 +08:00
Add comment explaining the derivation of the number of keys
Signed-off-by: Ben Taylor <ben.taylor@linaro.org> (cherry picked from commit e0766f1b4a2133ea043e10cef86cc1c76f69b49b)
This commit is contained in:
parent
ad282114a1
commit
23370efdea
@ -49,6 +49,14 @@ static size_t ssl_test_tiny_key_slice_length(size_t slice_idx)
|
||||
default: return 1;
|
||||
}
|
||||
}
|
||||
|
||||
/* In the below definition SSL_TEST_KEY_SLICE_1_LENGTH has 4 slots and
|
||||
* SSL_TEST_KEY_SLICE_2_LENGTH has 10 all other slices have 1.
|
||||
* psa_key_slot_volatile_slice_count() returns the total number of slices.
|
||||
* However we have already countes slices 1 and 2, so we mustr subtract 2 from
|
||||
* this number to avoid double counting.
|
||||
*/
|
||||
|
||||
#define SSL_TEST_MAX_VOLATILE_KEYS \
|
||||
(SSL_TEST_KEY_SLICE_1_LENGTH + \
|
||||
SSL_TEST_KEY_SLICE_2_LENGTH + \
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user