|
|
@@ -1,71 +0,0 @@
|
|
|
-/*
|
|
|
- * SPDX-FileCopyrightText: 2015-2022 Espressif Systems (Shanghai) CO LTD
|
|
|
- *
|
|
|
- * SPDX-License-Identifier: Apache-2.0
|
|
|
- */
|
|
|
-
|
|
|
-#include <sys/lock.h>
|
|
|
-#include <stdlib.h>
|
|
|
-#include "esp_crypto_lock.h"
|
|
|
-
|
|
|
-/* Lock overview:
|
|
|
-SHA: peripheral independent, but DMA is shared with AES
|
|
|
-AES: peripheral independent, but DMA is shared with SHA
|
|
|
-MPI/RSA: independent
|
|
|
-HMAC: needs SHA
|
|
|
-DS: needs HMAC (which needs SHA), AES and MPI
|
|
|
-*/
|
|
|
-
|
|
|
-#if 0 // TODO: IDF-4229
|
|
|
-/* Lock for DS peripheral */
|
|
|
-static _lock_t s_crypto_ds_lock;
|
|
|
-
|
|
|
-/* Lock for HMAC peripheral */
|
|
|
-static _lock_t s_crypto_hmac_lock;
|
|
|
-
|
|
|
-/* Lock for the MPI/RSA peripheral, also used by the DS peripheral */
|
|
|
-static _lock_t s_crypto_mpi_lock;
|
|
|
-
|
|
|
-/* Single lock for SHA and AES, sharing a reserved GDMA channel */
|
|
|
-static _lock_t s_crypto_sha_aes_lock;
|
|
|
-#endif
|
|
|
-
|
|
|
-void esp_crypto_hmac_lock_acquire(void)
|
|
|
-{
|
|
|
- abort(); // TODO: IDF-4229
|
|
|
-}
|
|
|
-
|
|
|
-void esp_crypto_hmac_lock_release(void)
|
|
|
-{
|
|
|
- abort(); // TODO: IDF-4229
|
|
|
-}
|
|
|
-
|
|
|
-void esp_crypto_ds_lock_acquire(void)
|
|
|
-{
|
|
|
- abort(); // TODO: IDF-4229
|
|
|
-}
|
|
|
-
|
|
|
-void esp_crypto_ds_lock_release(void)
|
|
|
-{
|
|
|
- abort(); // TODO: IDF-4229
|
|
|
-}
|
|
|
-
|
|
|
-void esp_crypto_sha_aes_lock_acquire(void)
|
|
|
-{
|
|
|
- abort(); // TODO: IDF-4229
|
|
|
-}
|
|
|
-
|
|
|
-void esp_crypto_sha_aes_lock_release(void)
|
|
|
-{
|
|
|
- abort(); // TODO: IDF-4229
|
|
|
-}
|
|
|
-
|
|
|
-void esp_crypto_mpi_lock_acquire(void)
|
|
|
-{
|
|
|
- abort(); // TODO: IDF-4229
|
|
|
-}
|
|
|
-
|
|
|
-void esp_crypto_mpi_lock_release(void)
|
|
|
-{
|
|
|
- abort(); // TODO: IDF-4229
|
|
|
-}
|