mirror of
https://github.com/espressif/esp-idf.git
synced 2025-08-02 20:24:32 +02:00
Merge branch 'bugfix/fix_build_warring_v4.3' into 'release/v4.3'
esp_wifi: fix build warning(v4.3) See merge request espressif/esp-idf!17839
This commit is contained in:
@@ -332,8 +332,6 @@ IRAM_ATTR void esp_mac_bb_power_down(void)
|
|||||||
|
|
||||||
const esp_phy_init_data_t* esp_phy_get_init_data(void)
|
const esp_phy_init_data_t* esp_phy_get_init_data(void)
|
||||||
{
|
{
|
||||||
esp_err_t err = ESP_OK;
|
|
||||||
const esp_partition_t* partition = NULL;
|
|
||||||
#if CONFIG_ESP32_MULTIPLE_PHY_DATA_BIN_EMBEDDED
|
#if CONFIG_ESP32_MULTIPLE_PHY_DATA_BIN_EMBEDDED
|
||||||
size_t init_data_store_length = sizeof(phy_init_magic_pre) +
|
size_t init_data_store_length = sizeof(phy_init_magic_pre) +
|
||||||
sizeof(esp_phy_init_data_t) + sizeof(phy_init_magic_post);
|
sizeof(esp_phy_init_data_t) + sizeof(phy_init_magic_post);
|
||||||
@@ -345,7 +343,7 @@ const esp_phy_init_data_t* esp_phy_get_init_data(void)
|
|||||||
memcpy(init_data_store, multi_phy_init_data_bin_start, init_data_store_length);
|
memcpy(init_data_store, multi_phy_init_data_bin_start, init_data_store_length);
|
||||||
ESP_LOGI(TAG, "loading embedded multiple PHY init data");
|
ESP_LOGI(TAG, "loading embedded multiple PHY init data");
|
||||||
#else
|
#else
|
||||||
partition = esp_partition_find_first(
|
const esp_partition_t* partition = esp_partition_find_first(
|
||||||
ESP_PARTITION_TYPE_DATA, ESP_PARTITION_SUBTYPE_DATA_PHY, NULL);
|
ESP_PARTITION_TYPE_DATA, ESP_PARTITION_SUBTYPE_DATA_PHY, NULL);
|
||||||
if (partition == NULL) {
|
if (partition == NULL) {
|
||||||
ESP_LOGE(TAG, "PHY data partition not found");
|
ESP_LOGE(TAG, "PHY data partition not found");
|
||||||
@@ -359,7 +357,7 @@ const esp_phy_init_data_t* esp_phy_get_init_data(void)
|
|||||||
ESP_LOGE(TAG, "failed to allocate memory for PHY init data");
|
ESP_LOGE(TAG, "failed to allocate memory for PHY init data");
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
err = esp_partition_read(partition, 0, init_data_store, init_data_store_length);
|
esp_err_t err = esp_partition_read(partition, 0, init_data_store, init_data_store_length);
|
||||||
if (err != ESP_OK) {
|
if (err != ESP_OK) {
|
||||||
ESP_LOGE(TAG, "failed to read PHY data partition (0x%x)", err);
|
ESP_LOGE(TAG, "failed to read PHY data partition (0x%x)", err);
|
||||||
free(init_data_store);
|
free(init_data_store);
|
||||||
|
Reference in New Issue
Block a user