btstack_crypto: add btstack_crypto_idle for unit testing

This commit is contained in:
Matthias Ringwald 2018-11-30 15:36:37 +01:00
parent 2f2a777b82
commit 80665fb721
2 changed files with 7 additions and 0 deletions

View File

@ -1213,3 +1213,7 @@ void btstack_crypto_ecc_p256_set_key(const uint8_t * public_key, const uint8_t *
btstack_crypto_ecc_p256_key_generation_state = ECC_P256_KEY_GENERATION_DONE;
#endif
}
// Unit testing
int btstack_crypto_idle(void){
return btstack_linked_list_empty(&btstack_crypto_operations);
}

View File

@ -273,6 +273,9 @@ void btstack_crypto_ccm_decrypt_block(btstack_crypto_ccm_t * request, uint16_t l
// PTS testing only - not possible when using Buetooth Controller for ECC operations
void btstack_crypto_ecc_p256_set_key(const uint8_t * public_key, const uint8_t * private_key);
// Unit testing
int btstack_crypto_idle(void);
#if defined __cplusplus
}
#endif