esp_rmaker_secure_boot: Fix compilation

This commit is contained in:
Chirag Atal
2023-07-28 17:41:48 +05:30
parent 844e931187
commit d2e6629e73
2 changed files with 25 additions and 0 deletions

View File

@@ -3,8 +3,16 @@
*
* SPDX-License-Identifier: Apache-2.0
*/
#include <inttypes.h>
#include <sys/time.h>
#include <esp_log.h>
#include <esp_idf_version.h>
#include <esp_rmaker_utils.h>
#include "esp_rmaker_secure_boot_digest.h"
static const char *TAG = "rmaker_secure_boot";
#ifdef CONFIG_SECURE_BOOT_V2_ENABLED
static inline uint8_t to_hex_digit(unsigned val)
@@ -89,6 +97,7 @@ esp_err_t esp_rmaker_secure_boot_digest_free(char **digest)
char** esp_rmaker_get_secure_boot_digest()
{
ESP_LOGI(TAG, "Secure boot is not enabled. Could not get digest.");
return NULL;
}

View File

@@ -8,6 +8,22 @@
#include <esp_secure_boot.h>
#include <esp_efuse.h>
#if CONFIG_IDF_TARGET_ESP32
#include "esp32/rom/secure_boot.h"
#elif CONFIG_IDF_TARGET_ESP32S2
#include "esp32s2/rom/secure_boot.h"
#elif CONFIG_IDF_TARGET_ESP32C3
#include "esp32c3/rom/secure_boot.h"
#elif CONFIG_IDF_TARGET_ESP32S3
#include "esp32s3/rom/secure_boot.h"
#elif CONFIG_IDF_TARGET_ESP32C2
#include "esp32c2/rom/secure_boot.h"
#elif CONFIG_IDF_TARGET_ESP32C6
#include "esp32c6/rom/secure_boot.h"
#elif CONFIG_IDF_TARGET_ESP32H2
#include "esp32h2/rom/secure_boot.h"
#endif
/**
* @brief Get secure boot digest
*