From: XiaXiaotian Date: Mon, 22 Oct 2018 12:46:14 +0000 (+0800) Subject: esp32: do not try to load PHY data if fail to open NVS X-Git-Tag: v3.3-beta1~135^2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=901e2af79334c7656ad2a6a68fa12e973e8e2bb2;p=esp-idf esp32: do not try to load PHY data if fail to open NVS --- diff --git a/components/esp32/phy_init.c b/components/esp32/phy_init.c index c15840d582..dcc3b417e1 100644 --- a/components/esp32/phy_init.c +++ b/components/esp32/phy_init.c @@ -446,6 +446,7 @@ esp_err_t esp_phy_load_cal_data_from_nvs(esp_phy_calibration_data_t* out_cal_dat if (err == ESP_ERR_NVS_NOT_INITIALIZED) { ESP_LOGE(TAG, "%s: NVS has not been initialized. " "Call nvs_flash_init before starting WiFi/BT.", __func__); + return err; } else if (err != ESP_OK) { ESP_LOGD(TAG, "%s: failed to open NVS namespace (0x%x)", __func__, err); return err;