From 630f9e7a266eb09799e5665673fdac482c49677d Mon Sep 17 00:00:00 2001 From: Jeff Johnson Date: Mon, 25 Jul 2016 12:00:12 -0700 Subject: [PATCH] qcacld-3.0: Convert wlan_hdd_ext_scan.c to unified logging Currently the HDD code uses a variety of logging APIs. In qcacld-3.0 HDD should converge on a unified set of logging APIs. Update wlan_hdd_ext_scan.c to use the unified set of APIs. Change-Id: I2777678a6d85d0d7c87b37144219cf18dc5c7d3d CRs-Fixed: 937650 --- core/hdd/src/wlan_hdd_ext_scan.c | 590 +++++++++++++++---------------- 1 file changed, 287 insertions(+), 303 deletions(-) diff --git a/core/hdd/src/wlan_hdd_ext_scan.c b/core/hdd/src/wlan_hdd_ext_scan.c index c594b40966..36a5211654 100644 --- a/core/hdd/src/wlan_hdd_ext_scan.c +++ b/core/hdd/src/wlan_hdd_ext_scan.c @@ -28,6 +28,9 @@ #ifdef FEATURE_WLAN_EXTSCAN +/* denote that this file does not allow legacy hddLog */ +#define HDD_DISALLOW_LEGACY_HDDLOG 1 + #include "wlan_hdd_ext_scan.h" #include "cds_utils.h" #include "cds_sched.h" @@ -161,7 +164,7 @@ wlan_hdd_cfg80211_extscan_get_capabilities_rsp(void *ctx, if (wlan_hdd_validate_context(hdd_ctx)) return; if (!data) { - hddLog(LOGE, FL("data is null")); + hdd_err("data is null"); return; } @@ -171,8 +174,7 @@ wlan_hdd_cfg80211_extscan_get_capabilities_rsp(void *ctx, /* validate response received from target*/ if (context->request_id != data->requestId) { spin_unlock(&context->context_lock); - hddLog(LOGE, - FL("Target response id did not match: request_id %d response_id %d"), + hdd_err("Target response id did not match: request_id %d response_id %d", context->request_id, data->requestId); return; } else { @@ -238,13 +240,13 @@ static int hdd_extscan_nl_fill_bss(struct sk_buff *skb, tSirWifiScanResult *ap, nla_put_u16(skb, PARAM_BEACON_PERIOD, ap->beaconPeriod) || nla_put_u16(skb, PARAM_CAPABILITY, ap->capability) || nla_put_u16(skb, PARAM_IE_LENGTH, ap->ieLength)) { - hddLog(LOGE, FL("put fail")); + hdd_err("put fail"); return -EINVAL; } if (ap->ieLength) if (nla_put(skb, PARAM_IE_DATA, ap->ieLength, ap->ieData)) { - hddLog(LOGE, FL("put fail")); + hdd_err("put fail"); return -EINVAL; } @@ -294,7 +296,7 @@ wlan_hdd_cfg80211_extscan_cached_results_ind(void *ctx, if (wlan_hdd_validate_context(pHddCtx)) return; if (!data) { - hddLog(LOGE, FL("data is null")); + hdd_err("data is null"); return; } @@ -304,8 +306,7 @@ wlan_hdd_cfg80211_extscan_cached_results_ind(void *ctx, spin_unlock(&context->context_lock); if (ignore_cached_results) { - hddLog(LOGE, - FL("Ignore the cached results received after timeout")); + hdd_err("Ignore the cached results received after timeout"); return; } @@ -357,19 +358,19 @@ wlan_hdd_cfg80211_extscan_cached_results_ind(void *ctx, } } - hddLog(LOG1, FL("nl_buf_len = %u"), nl_buf_len); + hdd_notice("nl_buf_len = %u", nl_buf_len); skb = cfg80211_vendor_cmd_alloc_reply_skb(pHddCtx->wiphy, nl_buf_len); if (!skb) { - hddLog(LOGE, FL("cfg80211_vendor_cmd_alloc_reply_skb failed")); + hdd_err("cfg80211_vendor_cmd_alloc_reply_skb failed"); goto fail; } - hddLog(LOG1, "Req Id %u Num_scan_ids %u More Data %u", + hdd_notice("Req Id %u Num_scan_ids %u More Data %u", data->request_id, data->num_scan_ids, data->more_data); result = &data->result[0]; for (i = 0; i < data->num_scan_ids; i++) { - hddLog(LOG1, "[i=%d] scan_id %u flags %u num_results %u", + hdd_notice("[i=%d] scan_id %u flags %u num_results %u", i, result->scan_id, result->flags, result->num_results); ap = &result->ap[0]; @@ -382,7 +383,7 @@ wlan_hdd_cfg80211_extscan_cached_results_ind(void *ctx, * BSSID was cached. */ ap->ts += pHddCtx->ext_scan_start_since_boot; - hddLog(LOG1, "Timestamp %llu " + hdd_notice("Timestamp %llu " "Ssid: %s " "Bssid (" MAC_ADDRESS_STR ") " "Channel %u " @@ -415,7 +416,7 @@ wlan_hdd_cfg80211_extscan_cached_results_ind(void *ctx, nla_put_u8(skb, QCA_WLAN_VENDOR_ATTR_EXTSCAN_RESULTS_SCAN_RESULT_MORE_DATA, data->more_data)) { - hddLog(LOGE, FL("put fail")); + hdd_err("put fail"); goto fail; } @@ -426,7 +427,7 @@ wlan_hdd_cfg80211_extscan_cached_results_ind(void *ctx, if (nla_put_u32(skb, QCA_WLAN_VENDOR_ATTR_EXTSCAN_CACHED_RESULTS_SCAN_ID, result->scan_id)) { - hddLog(LOGE, FL("put fail")); + hdd_err("put fail"); goto fail; } nla_results = nla_nest_start(skb, @@ -451,7 +452,7 @@ wlan_hdd_cfg80211_extscan_cached_results_ind(void *ctx, nla_put_u32(skb, QCA_WLAN_VENDOR_ATTR_EXTSCAN_NUM_RESULTS_AVAILABLE, result->num_results)) { - hddLog(LOGE, FL("put fail")); + hdd_err("put fail"); goto fail; } @@ -520,7 +521,7 @@ wlan_hdd_cfg80211_extscan_hotlist_match_ind(void *ctx, if (wlan_hdd_validate_context(pHddCtx)) return; if (!data) { - hddLog(LOGE, FL("data is null")); + hdd_err("data is null"); return; } @@ -536,7 +537,7 @@ wlan_hdd_cfg80211_extscan_hotlist_match_ind(void *ctx, index, flags); if (!skb) { - hddLog(LOGE, FL("cfg80211_vendor_event_alloc failed")); + hdd_err("cfg80211_vendor_event_alloc failed"); return; } hdd_info("Req Id: %u Num_APs: %u MoreData: %u ap_found: %u", @@ -546,7 +547,7 @@ wlan_hdd_cfg80211_extscan_hotlist_match_ind(void *ctx, for (i = 0; i < data->numOfAps; i++) { data->ap[i].ts = qdf_get_monotonic_boottime(); - hddLog(LOG1, "[i=%d] Timestamp %llu " + hdd_notice("[i=%d] Timestamp %llu " "Ssid: %s " "Bssid (" MAC_ADDRESS_STR ") " "Channel %u " @@ -568,7 +569,7 @@ wlan_hdd_cfg80211_extscan_hotlist_match_ind(void *ctx, nla_put_u32(skb, QCA_WLAN_VENDOR_ATTR_EXTSCAN_NUM_RESULTS_AVAILABLE, data->numOfAps)) { - hddLog(LOGE, FL("put fail")); + hdd_err("put fail"); goto fail; } @@ -659,7 +660,7 @@ wlan_hdd_cfg80211_extscan_signif_wifi_change_results_ind( if (wlan_hdd_validate_context(pHddCtx)) return; if (!pData) { - hddLog(LOGE, FL("pData is null")); + hdd_err("pData is null"); return; } @@ -671,15 +672,15 @@ wlan_hdd_cfg80211_extscan_signif_wifi_change_results_ind( flags); if (!skb) { - hddLog(LOGE, FL("cfg80211_vendor_event_alloc failed")); + hdd_err("cfg80211_vendor_event_alloc failed"); return; } - hddLog(LOG1, "Req Id %u Num results %u More Data %u", + hdd_notice("Req Id %u Num results %u More Data %u", pData->requestId, pData->numResults, pData->moreData); ap_info = &pData->ap[0]; for (i = 0; i < pData->numResults; i++) { - hddLog(LOG1, "[i=%d] " + hdd_notice("[i=%d] " "Bssid (" MAC_ADDRESS_STR ") " "Channel %u " "numOfRssi %d", @@ -688,7 +689,7 @@ wlan_hdd_cfg80211_extscan_signif_wifi_change_results_ind( ap_info->channel, ap_info->numOfRssi); rssi = &(ap_info)->rssi[0]; for (j = 0; j < ap_info->numOfRssi; j++) - hddLog(LOG1, "Rssi %d", *rssi++); + hdd_notice("Rssi %d", *rssi++); ap_info += ap_info->numOfRssi * sizeof(*rssi); } @@ -699,7 +700,7 @@ wlan_hdd_cfg80211_extscan_signif_wifi_change_results_ind( nla_put_u32(skb, QCA_WLAN_VENDOR_ATTR_EXTSCAN_NUM_RESULTS_AVAILABLE, pData->numResults)) { - hddLog(LOGE, FL("put fail")); + hdd_err("put fail"); goto fail; } @@ -781,13 +782,12 @@ wlan_hdd_cfg80211_extscan_full_scan_result_event(void *ctx, if (wlan_hdd_validate_context(pHddCtx)) return; if (!pData) { - hddLog(LOGE, FL("pData is null")); + hdd_err("pData is null"); return; } if ((sizeof(*pData) + pData->ap.ieLength) >= EXTSCAN_EVENT_BUF_SIZE) { - hddLog(LOGE, - FL("Frame exceeded NL size limitation, drop it!!")); + hdd_err("Frame exceeded NL size limitation, drop it!!"); return; } skb = cfg80211_vendor_event_alloc( @@ -798,7 +798,7 @@ wlan_hdd_cfg80211_extscan_full_scan_result_event(void *ctx, flags); if (!skb) { - hddLog(LOGE, FL("cfg80211_vendor_event_alloc failed")); + hdd_err("cfg80211_vendor_event_alloc failed"); return; } @@ -809,9 +809,9 @@ wlan_hdd_cfg80211_extscan_full_scan_result_event(void *ctx, get_monotonic_boottime(&ts); pData->ap.ts = ((u64)ts.tv_sec * 1000000) + (ts.tv_nsec / 1000); - hddLog(LOG1, "Req Id %u More Data %u", pData->requestId, + hdd_notice("Req Id %u More Data %u", pData->requestId, pData->moreData); - hddLog(LOG1, "AP Info: Timestamp %llu Ssid: %s " + hdd_notice("AP Info: Timestamp %llu Ssid: %s " "Bssid (" MAC_ADDRESS_STR ") " "Channel %u " "Rssi %d " @@ -867,7 +867,7 @@ wlan_hdd_cfg80211_extscan_full_scan_result_event(void *ctx, nla_put_u8(skb, QCA_WLAN_VENDOR_ATTR_EXTSCAN_RESULTS_SCAN_RESULT_MORE_DATA, pData->moreData)) { - hddLog(LOGE, FL("nla put fail")); + hdd_err("nla put fail"); goto nla_put_failure; } @@ -911,7 +911,7 @@ wlan_hdd_cfg80211_extscan_scan_res_available_event( if (wlan_hdd_validate_context(pHddCtx)) return; if (!pData) { - hddLog(LOGE, FL("pData is null")); + hdd_err("pData is null"); return; } @@ -923,11 +923,11 @@ wlan_hdd_cfg80211_extscan_scan_res_available_event( flags); if (!skb) { - hddLog(LOGE, FL("cfg80211_vendor_event_alloc failed")); + hdd_err("cfg80211_vendor_event_alloc failed"); return; } - hddLog(LOG1, "Req Id %u Num results %u", + hdd_notice("Req Id %u Num results %u", pData->requestId, pData->numResultsAvailable); if (nla_put_u32(skb, QCA_WLAN_VENDOR_ATTR_EXTSCAN_RESULTS_REQUEST_ID, @@ -935,7 +935,7 @@ wlan_hdd_cfg80211_extscan_scan_res_available_event( nla_put_u32(skb, QCA_WLAN_VENDOR_ATTR_EXTSCAN_NUM_RESULTS_AVAILABLE, pData->numResultsAvailable)) { - hddLog(LOGE, FL("nla put fail")); + hdd_err("nla put fail"); goto nla_put_failure; } @@ -972,7 +972,7 @@ wlan_hdd_cfg80211_extscan_scan_progress_event(void *ctx, if (wlan_hdd_validate_context(pHddCtx)) return; if (!pData) { - hddLog(LOGE, FL("pData is null")); + hdd_err("pData is null"); return; } @@ -984,10 +984,10 @@ wlan_hdd_cfg80211_extscan_scan_progress_event(void *ctx, flags); if (!skb) { - hddLog(LOGE, FL("cfg80211_vendor_event_alloc failed")); + hdd_err("cfg80211_vendor_event_alloc failed"); return; } - hddLog(LOG1, "Req Id %u Scan event type %u Scan event status %u", + hdd_notice("Req Id %u Scan event type %u Scan event status %u", pData->requestId, pData->scanEventType, pData->status); if (nla_put_u32(skb, QCA_WLAN_VENDOR_ATTR_EXTSCAN_RESULTS_REQUEST_ID, @@ -998,7 +998,7 @@ wlan_hdd_cfg80211_extscan_scan_progress_event(void *ctx, nla_put_u32(skb, QCA_WLAN_VENDOR_ATTR_EXTSCAN_RESULTS_SCAN_EVENT_STATUS, pData->status)) { - hddLog(LOGE, FL("nla put fail")); + hdd_err("nla put fail"); goto nla_put_failure; } @@ -1037,7 +1037,7 @@ wlan_hdd_cfg80211_extscan_epno_match_found(void *ctx, if (wlan_hdd_validate_context(pHddCtx)) return; if (!data) { - hddLog(LOGE, FL("data is null")); + hdd_err("data is null"); return; } @@ -1051,7 +1051,7 @@ wlan_hdd_cfg80211_extscan_epno_match_found(void *ctx, len += data->ap[i].ieLength; if (len >= EXTSCAN_EVENT_BUF_SIZE) { - hddLog(LOGE, FL("Frame exceeded NL size limitation, drop it!")); + hdd_err("Frame exceeded NL size limitation, drop it!"); return; } @@ -1062,15 +1062,15 @@ wlan_hdd_cfg80211_extscan_epno_match_found(void *ctx, flags); if (!skb) { - hddLog(LOGE, FL("cfg80211_vendor_event_alloc failed")); + hdd_err("cfg80211_vendor_event_alloc failed"); return; } - hddLog(LOG1, "Req Id %u More Data %u num_results %d", + hdd_notice("Req Id %u More Data %u num_results %d", data->request_id, data->more_data, data->num_results); for (i = 0; i < data->num_results; i++) { data->ap[i].channel = cds_chan_to_freq(data->ap[i].channel); - hddLog(LOG1, "AP Info: Timestamp %llu) Ssid: %s " + hdd_notice("AP Info: Timestamp %llu) Ssid: %s " "Bssid (" MAC_ADDRESS_STR ") " "Channel %u " "Rssi %d " @@ -1099,7 +1099,7 @@ wlan_hdd_cfg80211_extscan_epno_match_found(void *ctx, nla_put_u8(skb, QCA_WLAN_VENDOR_ATTR_EXTSCAN_RESULTS_SCAN_RESULT_MORE_DATA, data->more_data)) { - hddLog(LOGE, FL("nla put fail")); + hdd_err("nla put fail"); goto fail; } @@ -1152,13 +1152,13 @@ wlan_hdd_cfg80211_passpoint_match_found(void *ctx, if (wlan_hdd_validate_context(pHddCtx)) return; if (!data) { - hddLog(LOGE, FL("data is null")); + hdd_err("data is null"); return; } len = sizeof(*data) + data->ap.ieLength + data->anqp_len; if (len >= EXTSCAN_EVENT_BUF_SIZE) { - hddLog(LOGE, FL("Result exceeded NL size limitation, drop it")); + hdd_err("Result exceeded NL size limitation, drop it"); return; } @@ -1169,14 +1169,14 @@ wlan_hdd_cfg80211_passpoint_match_found(void *ctx, flags); if (!skb) { - hddLog(LOGE, FL("cfg80211_vendor_event_alloc failed")); + hdd_err("cfg80211_vendor_event_alloc failed"); return; } - hddLog(LOG1, "Req Id %u Id %u ANQP length %u num_matches %u", + hdd_notice("Req Id %u Id %u ANQP length %u num_matches %u", data->request_id, data->id, data->anqp_len, num_matches); for (i = 0; i < num_matches; i++) { - hddLog(LOG1, "AP Info: Timestamp %llu Ssid: %s " + hdd_notice("AP Info: Timestamp %llu Ssid: %s " "Bssid (" MAC_ADDRESS_STR ") " "Channel %u " "Rssi %d " @@ -1205,7 +1205,7 @@ wlan_hdd_cfg80211_passpoint_match_found(void *ctx, nla_put_u8(skb, QCA_WLAN_VENDOR_ATTR_EXTSCAN_RESULTS_SCAN_RESULT_MORE_DATA, more_data)) { - hddLog(LOGE, FL("nla put fail")); + hdd_err("nla put fail"); goto fail; } @@ -1285,16 +1285,16 @@ wlan_hdd_cfg80211_extscan_hotlist_ssid_match_ind(void *ctx, if (wlan_hdd_validate_context(hdd_ctx)) return; if (!event) { - hddLog(LOGE, FL("event is null")); + hdd_err("event is null"); return; } if (event->ap_found) { index = QCA_NL80211_VENDOR_SUBCMD_EXTSCAN_HOTLIST_SSID_FOUND_INDEX; - hddLog(LOG1, "SSID hotlist found"); + hdd_notice("SSID hotlist found"); } else { index = QCA_NL80211_VENDOR_SUBCMD_EXTSCAN_HOTLIST_SSID_LOST_INDEX; - hddLog(LOG1, "SSID hotlist lost"); + hdd_notice("SSID hotlist lost"); } skb = cfg80211_vendor_event_alloc(hdd_ctx->wiphy, @@ -1303,14 +1303,14 @@ wlan_hdd_cfg80211_extscan_hotlist_ssid_match_ind(void *ctx, index, flags); if (!skb) { - hddLog(LOGE, FL("cfg80211_vendor_event_alloc failed")); + hdd_err("cfg80211_vendor_event_alloc failed"); return; } - hddLog(LOG1, "Req Id %u, Num results %u, More Data %u", + hdd_notice("Req Id %u, Num results %u, More Data %u", event->requestId, event->numOfAps, event->moreData); for (i = 0; i < event->numOfAps; i++) { - hddLog(LOG1, "[i=%d] Timestamp %llu " + hdd_notice("[i=%d] Timestamp %llu " "Ssid: %s " "Bssid (" MAC_ADDRESS_STR ") " "Channel %u " @@ -1333,7 +1333,7 @@ wlan_hdd_cfg80211_extscan_hotlist_ssid_match_ind(void *ctx, nla_put_u32(skb, QCA_WLAN_VENDOR_ATTR_EXTSCAN_NUM_RESULTS_AVAILABLE, event->numOfAps)) { - hddLog(LOGE, FL("put fail")); + hdd_err("put fail"); goto fail; } @@ -1342,7 +1342,7 @@ wlan_hdd_cfg80211_extscan_hotlist_ssid_match_ind(void *ctx, aps = nla_nest_start(skb, QCA_WLAN_VENDOR_ATTR_EXTSCAN_RESULTS_LIST); if (!aps) { - hddLog(LOGE, FL("nest fail")); + hdd_err("nest fail"); goto fail; } @@ -1351,7 +1351,7 @@ wlan_hdd_cfg80211_extscan_hotlist_ssid_match_ind(void *ctx, ap = nla_nest_start(skb, i); if (!ap) { - hddLog(LOGE, FL("nest fail")); + hdd_err("nest fail"); goto fail; } @@ -1378,7 +1378,7 @@ wlan_hdd_cfg80211_extscan_hotlist_ssid_match_ind(void *ctx, nla_put_u32(skb, QCA_WLAN_VENDOR_ATTR_EXTSCAN_RESULTS_SCAN_RESULT_RTT_SD, event->ap[i].rtt_sd)) { - hddLog(LOGE, FL("put fail")); + hdd_err("put fail"); goto fail; } nla_nest_end(skb, ap); @@ -1388,7 +1388,7 @@ wlan_hdd_cfg80211_extscan_hotlist_ssid_match_ind(void *ctx, if (nla_put_u8(skb, QCA_WLAN_VENDOR_ATTR_EXTSCAN_RESULTS_SCAN_RESULT_MORE_DATA, event->moreData)) { - hddLog(LOGE, FL("put fail")); + hdd_err("put fail"); goto fail; } } @@ -1424,13 +1424,12 @@ wlan_hdd_cfg80211_extscan_generic_rsp ENTER(); if (wlan_hdd_validate_context(hdd_ctx) || !response) { - hddLog(LOGE, - FL("HDD context is not valid or response(%p) is null"), + hdd_err("HDD context is not valid or response(%p) is null", response); return; } - hddLog(LOG1, FL("request %u status %u"), + hdd_notice("request %u status %u", response->request_id, response->status); context = &ext_scan_context; @@ -1462,14 +1461,13 @@ void wlan_hdd_cfg80211_extscan_callback(void *ctx, const uint16_t evType, if (wlan_hdd_validate_context(pHddCtx)) return; - hddLog(LOG1, FL("Rcvd Event %d"), evType); + hdd_notice("Rcvd Event %d", evType); switch (evType) { case eSIR_EXTSCAN_CACHED_RESULTS_RSP: /* There is no need to send this response to upper layer Just log the message */ - hddLog(LOG1, - FL("Rcvd eSIR_EXTSCAN_CACHED_RESULTS_RSP")); + hdd_notice("Rcvd eSIR_EXTSCAN_CACHED_RESULTS_RSP"); break; case eSIR_EXTSCAN_GET_CAPABILITIES_IND: @@ -1532,7 +1530,7 @@ void wlan_hdd_cfg80211_extscan_callback(void *ctx, const uint16_t evType, break; default: - hddLog(LOGE, FL("Unknown event type %u"), evType); + hdd_err("Unknown event type %u", evType); break; } EXIT(); @@ -1609,34 +1607,34 @@ static int wlan_hdd_send_ext_scan_capability(hdd_context_t *hdd_ctx) skb = cfg80211_vendor_cmd_alloc_reply_skb(hdd_ctx->wiphy, nl_buf_len); if (!skb) { - hddLog(LOGE, FL("cfg80211_vendor_cmd_alloc_reply_skb failed")); + hdd_err("cfg80211_vendor_cmd_alloc_reply_skb failed"); return -ENOMEM; } - hddLog(LOG1, "Req Id %u", data->requestId); - hddLog(LOG1, "Status %u", data->status); - hddLog(LOG1, "Scan cache size %u", + hdd_notice("Req Id %u", data->requestId); + hdd_notice("Status %u", data->status); + hdd_notice("Scan cache size %u", data->max_scan_cache_size); - hddLog(LOG1, "Scan buckets %u", data->max_scan_buckets); - hddLog(LOG1, "Max AP per scan %u", + hdd_notice("Scan buckets %u", data->max_scan_buckets); + hdd_notice("Max AP per scan %u", data->max_ap_cache_per_scan); - hddLog(LOG1, "max_rssi_sample_size %u", + hdd_notice("max_rssi_sample_size %u", data->max_rssi_sample_size); - hddLog(LOG1, "max_scan_reporting_threshold %u", + hdd_notice("max_scan_reporting_threshold %u", data->max_scan_reporting_threshold); - hddLog(LOG1, "max_hotlist_bssids %u", + hdd_notice("max_hotlist_bssids %u", data->max_hotlist_bssids); - hddLog(LOG1, "max_significant_wifi_change_aps %u", + hdd_notice("max_significant_wifi_change_aps %u", data->max_significant_wifi_change_aps); - hddLog(LOG1, "max_bssid_history_entries %u", + hdd_notice("max_bssid_history_entries %u", data->max_bssid_history_entries); - hddLog(LOG1, "max_hotlist_ssids %u", data->max_hotlist_ssids); - hddLog(LOG1, "max_number_epno_networks %u", + hdd_notice("max_hotlist_ssids %u", data->max_hotlist_ssids); + hdd_notice("max_number_epno_networks %u", data->max_number_epno_networks); - hddLog(LOG1, "max_number_epno_networks_by_ssid %u", + hdd_notice("max_number_epno_networks_by_ssid %u", data->max_number_epno_networks_by_ssid); - hddLog(LOG1, "max_number_of_white_listed_ssid %u", + hdd_notice("max_number_of_white_listed_ssid %u", data->max_number_of_white_listed_ssid); if (nla_put_u32(skb, PARAM_REQUEST_ID, data->requestId) || @@ -1661,7 +1659,7 @@ static int wlan_hdd_send_ext_scan_capability(hdd_context_t *hdd_ctx) data->max_number_epno_networks_by_ssid) || nla_put_u32(skb, MAX_NUM_WHITELISTED_SSID, data->max_number_of_white_listed_ssid)) { - hddLog(LOGE, FL("nla put fail")); + hdd_err("nla put fail"); goto nla_put_failure; } @@ -1728,19 +1726,19 @@ static int __wlan_hdd_cfg80211_extscan_get_capabilities(struct wiphy *wiphy, if (nla_parse(tb, QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_MAX, data, data_len, wlan_hdd_extscan_config_policy)) { - hddLog(LOGE, FL("Invalid ATTR")); + hdd_err("Invalid ATTR"); return -EINVAL; } pReqMsg = qdf_mem_malloc(sizeof(*pReqMsg)); if (!pReqMsg) { - hddLog(LOGE, FL("qdf_mem_malloc failed")); + hdd_err("qdf_mem_malloc failed"); return -ENOMEM; } /* Parse and fetch request Id */ if (!tb[QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_REQUEST_ID]) { - hddLog(LOGE, FL("attr request id failed")); + hdd_err("attr request id failed"); goto fail; } @@ -1748,7 +1746,7 @@ static int __wlan_hdd_cfg80211_extscan_get_capabilities(struct wiphy *wiphy, nla_get_u32(tb [QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_REQUEST_ID]); pReqMsg->sessionId = pAdapter->sessionId; - hddLog(LOG1, FL("Req Id %d Session Id %d"), + hdd_notice("Req Id %d Session Id %d", pReqMsg->requestId, pReqMsg->sessionId); context = &ext_scan_context; @@ -1759,7 +1757,7 @@ static int __wlan_hdd_cfg80211_extscan_get_capabilities(struct wiphy *wiphy, status = sme_ext_scan_get_capabilities(pHddCtx->hHal, pReqMsg); if (!QDF_IS_STATUS_SUCCESS(status)) { - hddLog(LOGE, FL("sme_ext_scan_get_capabilities failed(err=%d)"), + hdd_err("sme_ext_scan_get_capabilities failed(err=%d)", status); goto fail; } @@ -1767,13 +1765,13 @@ static int __wlan_hdd_cfg80211_extscan_get_capabilities(struct wiphy *wiphy, rc = wait_for_completion_timeout(&context->response_event, msecs_to_jiffies(WLAN_WAIT_TIME_EXTSCAN)); if (!rc) { - hddLog(LOGE, FL("Target response timed out")); + hdd_err("Target response timed out"); return -ETIMEDOUT; } ret = wlan_hdd_send_ext_scan_capability(pHddCtx); if (ret) - hddLog(LOGE, FL("Failed to send ext scan capability to user space")); + hdd_err("Failed to send ext scan capability to user space"); EXIT(); return ret; fail: @@ -1862,34 +1860,34 @@ static int __wlan_hdd_cfg80211_extscan_get_cached_results(struct wiphy *wiphy, if (nla_parse(tb, PARAM_MAX, data, data_len, wlan_hdd_extscan_config_policy)) { - hddLog(LOGE, FL("Invalid ATTR")); + hdd_err("Invalid ATTR"); return -EINVAL; } pReqMsg = qdf_mem_malloc(sizeof(*pReqMsg)); if (!pReqMsg) { - hddLog(LOGE, FL("qdf_mem_malloc failed")); + hdd_err("qdf_mem_malloc failed"); return -ENOMEM; } /* Parse and fetch request Id */ if (!tb[PARAM_REQUEST_ID]) { - hddLog(LOGE, FL("attr request id failed")); + hdd_err("attr request id failed"); goto fail; } pReqMsg->requestId = nla_get_u32(tb[PARAM_REQUEST_ID]); pReqMsg->sessionId = pAdapter->sessionId; - hddLog(LOG1, FL("Req Id %d Session Id %d"), + hdd_notice("Req Id %d Session Id %d", pReqMsg->requestId, pReqMsg->sessionId); /* Parse and fetch flush parameter */ if (!tb[PARAM_FLUSH]) { - hddLog(LOGE, FL("attr flush failed")); + hdd_err("attr flush failed"); goto fail; } pReqMsg->flush = nla_get_u8(tb[PARAM_FLUSH]); - hddLog(LOG1, FL("Flush %d"), pReqMsg->flush); + hdd_notice("Flush %d", pReqMsg->flush); context = &ext_scan_context; spin_lock(&context->context_lock); @@ -1900,15 +1898,14 @@ static int __wlan_hdd_cfg80211_extscan_get_cached_results(struct wiphy *wiphy, status = sme_get_cached_results(pHddCtx->hHal, pReqMsg); if (!QDF_IS_STATUS_SUCCESS(status)) { - hddLog(LOGE, - FL("sme_get_cached_results failed(err=%d)"), status); + hdd_err("sme_get_cached_results failed(err=%d)", status); goto fail; } rc = wait_for_completion_timeout(&context->response_event, msecs_to_jiffies(WLAN_WAIT_TIME_EXTSCAN)); if (!rc) { - hddLog(LOGE, FL("Target response timed out")); + hdd_err("Target response timed out"); retval = -ETIMEDOUT; spin_lock(&context->context_lock); context->ignore_cached_results = true; @@ -2010,48 +2007,48 @@ __wlan_hdd_cfg80211_extscan_set_bssid_hotlist(struct wiphy *wiphy, if (nla_parse(tb, QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_MAX, data, data_len, wlan_hdd_extscan_config_policy)) { - hddLog(LOGE, FL("Invalid ATTR")); + hdd_err("Invalid ATTR"); return -EINVAL; } pReqMsg = qdf_mem_malloc(sizeof(*pReqMsg)); if (!pReqMsg) { - hddLog(LOGE, FL("qdf_mem_malloc failed")); + hdd_err("qdf_mem_malloc failed"); return -ENOMEM; } /* Parse and fetch request Id */ if (!tb[QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_REQUEST_ID]) { - hddLog(LOGE, FL("attr request id failed")); + hdd_err("attr request id failed"); goto fail; } pReqMsg->requestId = nla_get_u32(tb [QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_REQUEST_ID]); - hddLog(LOG1, FL("Req Id %d"), pReqMsg->requestId); + hdd_notice("Req Id %d", pReqMsg->requestId); /* Parse and fetch number of APs */ if (!tb[QCA_WLAN_VENDOR_ATTR_EXTSCAN_BSSID_HOTLIST_PARAMS_NUM_AP]) { - hddLog(LOGE, FL("attr number of AP failed")); + hdd_err("attr number of AP failed"); goto fail; } pReqMsg->numAp = nla_get_u32(tb [QCA_WLAN_VENDOR_ATTR_EXTSCAN_BSSID_HOTLIST_PARAMS_NUM_AP]); pReqMsg->sessionId = pAdapter->sessionId; - hddLog(LOG1, FL("Number of AP %d Session Id %d"), + hdd_notice("Number of AP %d Session Id %d", pReqMsg->numAp, pReqMsg->sessionId); /* Parse and fetch lost ap sample size */ if (!tb[QCA_WLAN_VENDOR_ATTR_EXTSCAN_BSSID_HOTLIST_PARAMS_LOST_AP_SAMPLE_SIZE]) { - hddLog(LOGE, FL("attr lost ap sample size failed")); + hdd_err("attr lost ap sample size failed"); goto fail; } pReqMsg->lost_ap_sample_size = nla_get_u32( tb[QCA_WLAN_VENDOR_ATTR_EXTSCAN_BSSID_HOTLIST_PARAMS_LOST_AP_SAMPLE_SIZE]); - hddLog(LOG1, FL("Lost ap sample size %d"), + hdd_notice("Lost ap sample size %d", pReqMsg->lost_ap_sample_size); i = 0; @@ -2062,43 +2059,43 @@ __wlan_hdd_cfg80211_extscan_set_bssid_hotlist(struct wiphy *wiphy, (tb2, QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_MAX, nla_data(apTh), nla_len(apTh), wlan_hdd_extscan_config_policy)) { - hddLog(LOGE, FL("nla_parse failed")); + hdd_err("nla_parse failed"); goto fail; } /* Parse and fetch MAC address */ if (!tb2[QCA_WLAN_VENDOR_ATTR_EXTSCAN_AP_THRESHOLD_PARAM_BSSID]) { - hddLog(LOGE, FL("attr mac address failed")); + hdd_err("attr mac address failed"); goto fail; } nla_memcpy(pReqMsg->ap[i].bssid.bytes, tb2 [QCA_WLAN_VENDOR_ATTR_EXTSCAN_AP_THRESHOLD_PARAM_BSSID], QDF_MAC_ADDR_SIZE); - hddLog(LOG1, MAC_ADDRESS_STR, + hdd_notice(MAC_ADDRESS_STR, MAC_ADDR_ARRAY(pReqMsg->ap[i].bssid.bytes)); /* Parse and fetch low RSSI */ if (!tb2 [QCA_WLAN_VENDOR_ATTR_EXTSCAN_AP_THRESHOLD_PARAM_RSSI_LOW]) { - hddLog(LOGE, FL("attr low RSSI failed")); + hdd_err("attr low RSSI failed"); goto fail; } pReqMsg->ap[i].low = nla_get_s32(tb2 [QCA_WLAN_VENDOR_ATTR_EXTSCAN_AP_THRESHOLD_PARAM_RSSI_LOW]); - hddLog(LOG1, FL("RSSI low %d"), pReqMsg->ap[i].low); + hdd_notice("RSSI low %d", pReqMsg->ap[i].low); /* Parse and fetch high RSSI */ if (!tb2 [QCA_WLAN_VENDOR_ATTR_EXTSCAN_AP_THRESHOLD_PARAM_RSSI_HIGH]) { - hddLog(LOGE, FL("attr high RSSI failed")); + hdd_err("attr high RSSI failed"); goto fail; } pReqMsg->ap[i].high = nla_get_s32(tb2 [QCA_WLAN_VENDOR_ATTR_EXTSCAN_AP_THRESHOLD_PARAM_RSSI_HIGH]); - hddLog(LOG1, FL("RSSI High %d"), pReqMsg->ap[i].high); + hdd_notice("RSSI High %d", pReqMsg->ap[i].high); i++; } @@ -2111,7 +2108,7 @@ __wlan_hdd_cfg80211_extscan_set_bssid_hotlist(struct wiphy *wiphy, status = sme_set_bss_hotlist(pHddCtx->hHal, pReqMsg); if (!QDF_IS_STATUS_SUCCESS(status)) { - hddLog(LOGE, FL("sme_set_bss_hotlist failed(err=%d)"), status); + hdd_err("sme_set_bss_hotlist failed(err=%d)", status); goto fail; } @@ -2121,7 +2118,7 @@ __wlan_hdd_cfg80211_extscan_set_bssid_hotlist(struct wiphy *wiphy, msecs_to_jiffies(WLAN_WAIT_TIME_EXTSCAN)); if (!rc) { - hddLog(LOGE, FL("sme_set_bss_hotlist timed out")); + hdd_err("sme_set_bss_hotlist timed out"); retval = -ETIMEDOUT; } else { spin_lock(&context->context_lock); @@ -2207,70 +2204,70 @@ __wlan_hdd_cfg80211_extscan_set_significant_change(struct wiphy *wiphy, if (nla_parse(tb, QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_MAX, data, data_len, wlan_hdd_extscan_config_policy)) { - hddLog(LOGE, FL("Invalid ATTR")); + hdd_err("Invalid ATTR"); return -EINVAL; } pReqMsg = qdf_mem_malloc(sizeof(*pReqMsg)); if (!pReqMsg) { - hddLog(LOGE, FL("qdf_mem_malloc failed")); + hdd_err("qdf_mem_malloc failed"); return -ENOMEM; } /* Parse and fetch request Id */ if (!tb[QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_REQUEST_ID]) { - hddLog(LOGE, FL("attr request id failed")); + hdd_err("attr request id failed"); goto fail; } pReqMsg->requestId = nla_get_u32(tb [QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_REQUEST_ID]); - hddLog(LOG1, FL("Req Id %d"), pReqMsg->requestId); + hdd_notice("Req Id %d", pReqMsg->requestId); /* Parse and fetch RSSI sample size */ if (!tb [QCA_WLAN_VENDOR_ATTR_EXTSCAN_SIGNIFICANT_CHANGE_PARAMS_RSSI_SAMPLE_SIZE]) { - hddLog(LOGE, FL("attr RSSI sample size failed")); + hdd_err("attr RSSI sample size failed"); goto fail; } pReqMsg->rssiSampleSize = nla_get_u32(tb [QCA_WLAN_VENDOR_ATTR_EXTSCAN_SIGNIFICANT_CHANGE_PARAMS_RSSI_SAMPLE_SIZE]); - hddLog(LOG1, FL("RSSI sample size %u"), pReqMsg->rssiSampleSize); + hdd_notice("RSSI sample size %u", pReqMsg->rssiSampleSize); /* Parse and fetch lost AP sample size */ if (!tb [QCA_WLAN_VENDOR_ATTR_EXTSCAN_SIGNIFICANT_CHANGE_PARAMS_LOST_AP_SAMPLE_SIZE]) { - hddLog(LOGE, FL("attr lost AP sample size failed")); + hdd_err("attr lost AP sample size failed"); goto fail; } pReqMsg->lostApSampleSize = nla_get_u32(tb [QCA_WLAN_VENDOR_ATTR_EXTSCAN_SIGNIFICANT_CHANGE_PARAMS_LOST_AP_SAMPLE_SIZE]); - hddLog(LOG1, FL("Lost AP sample size %u"), pReqMsg->lostApSampleSize); + hdd_notice("Lost AP sample size %u", pReqMsg->lostApSampleSize); /* Parse and fetch AP min breacing */ if (!tb [QCA_WLAN_VENDOR_ATTR_EXTSCAN_SIGNIFICANT_CHANGE_PARAMS_MIN_BREACHING]) { - hddLog(LOGE, FL("attr AP min breaching")); + hdd_err("attr AP min breaching"); goto fail; } pReqMsg->minBreaching = nla_get_u32(tb [QCA_WLAN_VENDOR_ATTR_EXTSCAN_SIGNIFICANT_CHANGE_PARAMS_MIN_BREACHING]); - hddLog(LOG1, FL("AP min breaching %u"), pReqMsg->minBreaching); + hdd_notice("AP min breaching %u", pReqMsg->minBreaching); /* Parse and fetch number of APs */ if (!tb[QCA_WLAN_VENDOR_ATTR_EXTSCAN_SIGNIFICANT_CHANGE_PARAMS_NUM_AP]) { - hddLog(LOGE, FL("attr number of AP failed")); + hdd_err("attr number of AP failed"); goto fail; } pReqMsg->numAp = nla_get_u32(tb [QCA_WLAN_VENDOR_ATTR_EXTSCAN_SIGNIFICANT_CHANGE_PARAMS_NUM_AP]); pReqMsg->sessionId = pAdapter->sessionId; - hddLog(LOG1, FL("Number of AP %d Session Id %d"), + hdd_notice("Number of AP %d Session Id %d", pReqMsg->numAp, pReqMsg->sessionId); i = 0; @@ -2281,43 +2278,43 @@ __wlan_hdd_cfg80211_extscan_set_significant_change(struct wiphy *wiphy, (tb2, QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_MAX, nla_data(apTh), nla_len(apTh), wlan_hdd_extscan_config_policy)) { - hddLog(LOGE, FL("nla_parse failed")); + hdd_err("nla_parse failed"); goto fail; } /* Parse and fetch MAC address */ if (!tb2[QCA_WLAN_VENDOR_ATTR_EXTSCAN_AP_THRESHOLD_PARAM_BSSID]) { - hddLog(LOGE, FL("attr mac address failed")); + hdd_err("attr mac address failed"); goto fail; } nla_memcpy(pReqMsg->ap[i].bssid.bytes, tb2 [QCA_WLAN_VENDOR_ATTR_EXTSCAN_AP_THRESHOLD_PARAM_BSSID], QDF_MAC_ADDR_SIZE); - hddLog(LOG1, MAC_ADDRESS_STR, + hdd_notice(MAC_ADDRESS_STR, MAC_ADDR_ARRAY(pReqMsg->ap[i].bssid.bytes)); /* Parse and fetch low RSSI */ if (!tb2 [QCA_WLAN_VENDOR_ATTR_EXTSCAN_AP_THRESHOLD_PARAM_RSSI_LOW]) { - hddLog(LOGE, FL("attr low RSSI failed")); + hdd_err("attr low RSSI failed"); goto fail; } pReqMsg->ap[i].low = nla_get_s32(tb2 [QCA_WLAN_VENDOR_ATTR_EXTSCAN_AP_THRESHOLD_PARAM_RSSI_LOW]); - hddLog(LOG1, FL("RSSI low %d"), pReqMsg->ap[i].low); + hdd_notice("RSSI low %d", pReqMsg->ap[i].low); /* Parse and fetch high RSSI */ if (!tb2 [QCA_WLAN_VENDOR_ATTR_EXTSCAN_AP_THRESHOLD_PARAM_RSSI_HIGH]) { - hddLog(LOGE, FL("attr high RSSI failed")); + hdd_err("attr high RSSI failed"); goto fail; } pReqMsg->ap[i].high = nla_get_s32(tb2 [QCA_WLAN_VENDOR_ATTR_EXTSCAN_AP_THRESHOLD_PARAM_RSSI_HIGH]); - hddLog(LOG1, FL("RSSI High %d"), pReqMsg->ap[i].high); + hdd_notice("RSSI High %d", pReqMsg->ap[i].high); i++; } @@ -2330,8 +2327,7 @@ __wlan_hdd_cfg80211_extscan_set_significant_change(struct wiphy *wiphy, status = sme_set_significant_change(pHddCtx->hHal, pReqMsg); if (!QDF_IS_STATUS_SUCCESS(status)) { - hddLog(LOGE, - FL("sme_set_significant_change failed(err=%d)"), status); + hdd_err("sme_set_significant_change failed(err=%d)", status); qdf_mem_free(pReqMsg); return -EINVAL; } @@ -2341,7 +2337,7 @@ __wlan_hdd_cfg80211_extscan_set_significant_change(struct wiphy *wiphy, msecs_to_jiffies(WLAN_WAIT_TIME_EXTSCAN)); if (!rc) { - hddLog(LOGE, FL("sme_set_significant_change timed out")); + hdd_err("sme_set_significant_change timed out"); retval = -ETIMEDOUT; } else { spin_lock(&context->context_lock); @@ -2489,46 +2485,45 @@ __wlan_hdd_cfg80211_extscan_get_valid_channels(struct wiphy *wiphy, if (nla_parse(tb, QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_MAX, data, data_len, wlan_hdd_extscan_config_policy)) { - hddLog(LOGE, FL("Invalid ATTR")); + hdd_err("Invalid ATTR"); return -EINVAL; } /* Parse and fetch request Id */ if (!tb[QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_REQUEST_ID]) { - hddLog(LOGE, FL("attr request id failed")); + hdd_err("attr request id failed"); return -EINVAL; } requestId = nla_get_u32(tb [QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_REQUEST_ID]); - hddLog(LOG1, FL("Req Id %d"), requestId); + hdd_notice("Req Id %d", requestId); /* Parse and fetch wifi band */ if (!tb [QCA_WLAN_VENDOR_ATTR_EXTSCAN_GET_VALID_CHANNELS_CONFIG_PARAM_WIFI_BAND]) { - hddLog(LOGE, FL("attr wifi band failed")); + hdd_err("attr wifi band failed"); return -EINVAL; } wifiBand = nla_get_u32(tb [QCA_WLAN_VENDOR_ATTR_EXTSCAN_GET_VALID_CHANNELS_CONFIG_PARAM_WIFI_BAND]); - hddLog(LOG1, FL("Wifi band %d"), wifiBand); + hdd_notice("Wifi band %d", wifiBand); if (!tb [QCA_WLAN_VENDOR_ATTR_EXTSCAN_GET_VALID_CHANNELS_CONFIG_PARAM_MAX_CHANNELS]) { - hddLog(LOGE, FL("attr max channels failed")); + hdd_err("attr max channels failed"); return -EINVAL; } maxChannels = nla_get_u32(tb [QCA_WLAN_VENDOR_ATTR_EXTSCAN_GET_VALID_CHANNELS_CONFIG_PARAM_MAX_CHANNELS]); - hddLog(LOG1, FL("Max channels %d"), maxChannels); + hdd_notice("Max channels %d", maxChannels); status = sme_get_valid_channels_by_band((tHalHandle) (pHddCtx->hHal), wifiBand, chan_list, &num_channels); if (QDF_STATUS_SUCCESS != status) { - hddLog(LOGE, - FL("sme_get_valid_channels_by_band failed (err=%d)"), + hdd_err("sme_get_valid_channels_by_band failed (err=%d)", status); return -EINVAL; } @@ -2541,9 +2536,9 @@ __wlan_hdd_cfg80211_extscan_get_valid_channels(struct wiphy *wiphy, !strncmp(hdd_get_fwpath(), "ap", 2)) hdd_remove_indoor_channels(wiphy, chan_list, &num_channels); - hddLog(LOG1, FL("Number of channels %d"), num_channels); + hdd_notice("Number of channels %d", num_channels); for (i = 0; i < num_channels; i++) - hddLog(LOG1, "Channel: %u ", chan_list[i]); + hdd_notice("Channel: %u ", chan_list[i]); reply_skb = cfg80211_vendor_cmd_alloc_reply_skb(wiphy, sizeof(u32) + sizeof(u32) * @@ -2557,7 +2552,7 @@ __wlan_hdd_cfg80211_extscan_get_valid_channels(struct wiphy *wiphy, nla_put(reply_skb, QCA_WLAN_VENDOR_ATTR_EXTSCAN_RESULTS_CHANNELS, sizeof(u32) * num_channels, chan_list)) { - hddLog(LOGE, FL("nla put fail")); + hdd_err("nla put fail"); kfree_skb(reply_skb); return -EINVAL; } @@ -2566,7 +2561,7 @@ __wlan_hdd_cfg80211_extscan_get_valid_channels(struct wiphy *wiphy, return ret; } - hddLog(LOGE, FL("valid channels: buffer alloc fail")); + hdd_err("valid channels: buffer alloc fail"); return -EINVAL; } @@ -2720,80 +2715,80 @@ static int hdd_extscan_start_fill_bucket_channel_spec( if (nla_parse(bucket, QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_MAX, nla_data(buckets), nla_len(buckets), NULL)) { - hddLog(LOGE, FL("nla_parse failed")); + hdd_err("nla_parse failed"); return -EINVAL; } /* Parse and fetch bucket spec */ if (!bucket[QCA_WLAN_VENDOR_ATTR_EXTSCAN_BUCKET_SPEC_INDEX]) { - hddLog(LOGE, FL("attr bucket index failed")); + hdd_err("attr bucket index failed"); return -EINVAL; } req_msg->buckets[bkt_index].bucket = nla_get_u8( bucket[QCA_WLAN_VENDOR_ATTR_EXTSCAN_BUCKET_SPEC_INDEX]); - hddLog(LOG1, FL("Bucket spec Index %d"), + hdd_notice("Bucket spec Index %d", req_msg->buckets[bkt_index].bucket); /* Parse and fetch wifi band */ if (!bucket[QCA_WLAN_VENDOR_ATTR_EXTSCAN_BUCKET_SPEC_BAND]) { - hddLog(LOGE, FL("attr wifi band failed")); + hdd_err("attr wifi band failed"); return -EINVAL; } req_msg->buckets[bkt_index].band = nla_get_u8( bucket[QCA_WLAN_VENDOR_ATTR_EXTSCAN_BUCKET_SPEC_BAND]); - hddLog(LOG1, FL("Wifi band %d"), + hdd_notice("Wifi band %d", req_msg->buckets[bkt_index].band); /* Parse and fetch period */ if (!bucket[QCA_WLAN_VENDOR_ATTR_EXTSCAN_BUCKET_SPEC_PERIOD]) { - hddLog(LOGE, FL("attr period failed")); + hdd_err("attr period failed"); return -EINVAL; } req_msg->buckets[bkt_index].period = nla_get_u32( bucket[QCA_WLAN_VENDOR_ATTR_EXTSCAN_BUCKET_SPEC_PERIOD]); - hddLog(LOG1, FL("period %d"), + hdd_notice("period %d", req_msg->buckets[bkt_index].period); /* Parse and fetch report events */ if (!bucket[ QCA_WLAN_VENDOR_ATTR_EXTSCAN_BUCKET_SPEC_REPORT_EVENTS]) { - hddLog(LOGE, FL("attr report events failed")); + hdd_err("attr report events failed"); return -EINVAL; } req_msg->buckets[bkt_index].reportEvents = nla_get_u8( bucket[ QCA_WLAN_VENDOR_ATTR_EXTSCAN_BUCKET_SPEC_REPORT_EVENTS]); - hddLog(LOG1, FL("report events %d"), + hdd_notice("report events %d", req_msg->buckets[bkt_index].reportEvents); /* Parse and fetch max period */ if (!bucket[QCA_WLAN_VENDOR_ATTR_EXTSCAN_BUCKET_SPEC_MAX_PERIOD]) { - hddLog(LOGE, FL("attr max period failed")); + hdd_err("attr max period failed"); return -EINVAL; } req_msg->buckets[bkt_index].max_period = nla_get_u32( bucket[QCA_WLAN_VENDOR_ATTR_EXTSCAN_BUCKET_SPEC_MAX_PERIOD]); - hddLog(LOG1, FL("max period %u"), + hdd_notice("max period %u", req_msg->buckets[bkt_index].max_period); /* Parse and fetch exponent */ if (!bucket[QCA_WLAN_VENDOR_ATTR_EXTSCAN_BUCKET_SPEC_EXPONENT]) { - hddLog(LOGE, FL("attr exponent failed")); + hdd_err("attr exponent failed"); return -EINVAL; } req_msg->buckets[bkt_index].exponent = nla_get_u32( bucket[QCA_WLAN_VENDOR_ATTR_EXTSCAN_BUCKET_SPEC_EXPONENT]); - hddLog(LOG1, FL("exponent %u"), + hdd_notice("exponent %u", req_msg->buckets[bkt_index].exponent); /* Parse and fetch step count */ if (!bucket[QCA_WLAN_VENDOR_ATTR_EXTSCAN_BUCKET_SPEC_STEP_COUNT]) { - hddLog(LOGE, FL("attr step count failed")); + hdd_err("attr step count failed"); return -EINVAL; } req_msg->buckets[bkt_index].step_count = nla_get_u32( bucket[QCA_WLAN_VENDOR_ATTR_EXTSCAN_BUCKET_SPEC_STEP_COUNT]); - hddLog(LOG1, FL("Step count %u"), + hdd_notice("Step count %u", req_msg->buckets[bkt_index].step_count); /* start with known good values for bucket dwell times */ @@ -2816,17 +2811,16 @@ static int hdd_extscan_start_fill_bucket_channel_spec( return 0; num_channels = 0; - hddLog(LOG1, "WiFi band is specified, driver to fill channel list"); + hdd_notice("WiFi band is specified, driver to fill channel list"); status = sme_get_valid_channels_by_band(hdd_ctx->hHal, req_msg->buckets[bkt_index].band, chan_list, &num_channels); if (!QDF_IS_STATUS_SUCCESS(status)) { - hddLog(LOGE, - FL("sme_GetValidChannelsByBand failed (err=%d)"), + hdd_err("sme_GetValidChannelsByBand failed (err=%d)", status); return -EINVAL; } - hddLog(LOG1, FL("before trimming, num_channels: %d"), + hdd_notice("before trimming, num_channels: %d", num_channels); req_msg->buckets[bkt_index].numChannels = @@ -2885,8 +2879,7 @@ static int hdd_extscan_start_fill_bucket_channel_spec( } - hddLog(LOG1, - "Channel: %u Passive: %u Dwell time: %u ms Class: %u", + hdd_notice("Channel: %u Passive: %u Dwell time: %u ms Class: %u", req_msg->buckets[bkt_index].channels[j].channel, req_msg->buckets[bkt_index].channels[j].passive, req_msg->buckets[bkt_index].channels[j].dwellTimeMs, @@ -2900,7 +2893,7 @@ static int hdd_extscan_start_fill_bucket_channel_spec( min_dwell_time_passive_bucket, max_dwell_time_passive_bucket); - hddLog(LOG1, FL("bkt_index:%d actv_min:%d actv_max:%d pass_min:%d pass_max:%d"), + hdd_notice("bkt_index:%d actv_min:%d actv_max:%d pass_min:%d pass_max:%d", bkt_index, req_msg->buckets[bkt_index].min_dwell_time_active, req_msg->buckets[bkt_index].max_dwell_time_active, @@ -2915,7 +2908,7 @@ static int hdd_extscan_start_fill_bucket_channel_spec( /* Parse and fetch number of channels */ if (!bucket[ QCA_WLAN_VENDOR_ATTR_EXTSCAN_BUCKET_SPEC_NUM_CHANNEL_SPECS]) { - hddLog(LOGE, FL("attr num channels failed")); + hdd_err("attr num channels failed"); return -EINVAL; } req_msg->buckets[bkt_index].numChannels = @@ -2934,7 +2927,7 @@ static int hdd_extscan_start_fill_bucket_channel_spec( return 0; if (!bucket[QCA_WLAN_VENDOR_ATTR_EXTSCAN_CHANNEL_SPEC]) { - hddLog(LOGE, FL("attr channel spec failed")); + hdd_err("attr channel spec failed"); return -EINVAL; } @@ -2950,26 +2943,26 @@ static int hdd_extscan_start_fill_bucket_channel_spec( QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_MAX, nla_data(channels), nla_len(channels), wlan_hdd_extscan_config_policy)) { - hddLog(LOGE, FL("nla_parse failed")); + hdd_err("nla_parse failed"); return -EINVAL; } /* Parse and fetch channel */ if (!channel[ QCA_WLAN_VENDOR_ATTR_EXTSCAN_CHANNEL_SPEC_CHANNEL]) { - hddLog(LOGE, FL("attr channel failed")); + hdd_err("attr channel failed"); return -EINVAL; } req_msg->buckets[bkt_index].channels[j].channel = nla_get_u32(channel[ QCA_WLAN_VENDOR_ATTR_EXTSCAN_CHANNEL_SPEC_CHANNEL]); - hddLog(LOG1, FL("channel %u"), + hdd_notice("channel %u", req_msg->buckets[bkt_index].channels[j].channel); /* Parse and fetch dwell time */ if (!channel[ QCA_WLAN_VENDOR_ATTR_EXTSCAN_CHANNEL_SPEC_DWELL_TIME]) { - hddLog(LOGE, FL("attr dwelltime failed")); + hdd_err("attr dwelltime failed"); return -EINVAL; } req_msg->buckets[bkt_index].channels[j].dwellTimeMs = @@ -2981,7 +2974,7 @@ static int hdd_extscan_start_fill_bucket_channel_spec( hdd_ctx->config->extscan_active_min_chn_time || req_msg->buckets[bkt_index].channels[j].dwellTimeMs > hdd_ctx->config->extscan_active_max_chn_time) { - hddLog(LOG1, FL("WiFi band is unspecified, dwellTime:%d"), + hdd_notice("WiFi band is unspecified, dwellTime:%d", req_msg->buckets[bkt_index].channels[j].dwellTimeMs); if (CDS_IS_PASSIVE_OR_DISABLE_CH( @@ -2995,7 +2988,7 @@ static int hdd_extscan_start_fill_bucket_channel_spec( } } - hddLog(LOG1, FL("New Dwell time %u ms"), + hdd_notice("New Dwell time %u ms", req_msg->buckets[bkt_index].channels[j].dwellTimeMs); if (CDS_IS_PASSIVE_OR_DISABLE_CH( @@ -3027,14 +3020,13 @@ static int hdd_extscan_start_fill_bucket_channel_spec( /* Parse and fetch channel spec passive */ if (!channel[ QCA_WLAN_VENDOR_ATTR_EXTSCAN_CHANNEL_SPEC_PASSIVE]) { - hddLog(LOGE, - FL("attr channel spec passive failed")); + hdd_err("attr channel spec passive failed"); return -EINVAL; } req_msg->buckets[bkt_index].channels[j].passive = nla_get_u8(channel[ QCA_WLAN_VENDOR_ATTR_EXTSCAN_CHANNEL_SPEC_PASSIVE]); - hddLog(LOG1, FL("Chnl spec passive %u"), + hdd_notice("Chnl spec passive %u", req_msg->buckets[bkt_index].channels[j].passive); /* Override scan type if required */ if (CDS_IS_PASSIVE_OR_DISABLE_CH( @@ -3055,7 +3047,7 @@ static int hdd_extscan_start_fill_bucket_channel_spec( min_dwell_time_passive_bucket, max_dwell_time_passive_bucket); - hddLog(LOG1, FL("bktIndex:%d actv_min:%d actv_max:%d pass_min:%d pass_max:%d"), + hdd_notice("bktIndex:%d actv_min:%d actv_max:%d pass_min:%d pass_max:%d", bkt_index, req_msg->buckets[bkt_index].min_dwell_time_active, req_msg->buckets[bkt_index].max_dwell_time_active, @@ -3066,7 +3058,7 @@ static int hdd_extscan_start_fill_bucket_channel_spec( req_msg->numBuckets++; } - hddLog(LOG1, FL("Global: actv_min:%d actv_max:%d pass_min:%d pass_max:%d"), + hdd_notice("Global: actv_min:%d actv_max:%d pass_min:%d pass_max:%d", req_msg->min_dwell_time_active, req_msg->max_dwell_time_active, req_msg->min_dwell_time_passive, @@ -3154,66 +3146,66 @@ __wlan_hdd_cfg80211_extscan_start(struct wiphy *wiphy, if (nla_parse(tb, PARAM_MAX, data, data_len, wlan_hdd_extscan_config_policy)) { - hddLog(LOGE, FL("Invalid ATTR")); + hdd_err("Invalid ATTR"); return -EINVAL; } pReqMsg = qdf_mem_malloc(sizeof(*pReqMsg)); if (!pReqMsg) { - hddLog(LOGE, FL("memory allocation failed")); + hdd_err("memory allocation failed"); return -ENOMEM; } /* Parse and fetch request Id */ if (!tb[PARAM_REQUEST_ID]) { - hddLog(LOGE, FL("attr request id failed")); + hdd_err("attr request id failed"); goto fail; } pReqMsg->requestId = nla_get_u32(tb[PARAM_REQUEST_ID]); pReqMsg->sessionId = pAdapter->sessionId; - hddLog(LOG1, FL("Req Id %d Session Id %d"), + hdd_notice("Req Id %d Session Id %d", pReqMsg->requestId, pReqMsg->sessionId); /* Parse and fetch base period */ if (!tb[PARAM_BASE_PERIOD]) { - hddLog(LOGE, FL("attr base period failed")); + hdd_err("attr base period failed"); goto fail; } pReqMsg->basePeriod = nla_get_u32(tb[PARAM_BASE_PERIOD]); - hddLog(LOG1, FL("Base Period %d"), + hdd_notice("Base Period %d", pReqMsg->basePeriod); /* Parse and fetch max AP per scan */ if (!tb[PARAM_MAX_AP_PER_SCAN]) { - hddLog(LOGE, FL("attr max_ap_per_scan failed")); + hdd_err("attr max_ap_per_scan failed"); goto fail; } pReqMsg->maxAPperScan = nla_get_u32(tb[PARAM_MAX_AP_PER_SCAN]); - hddLog(LOG1, FL("Max AP per Scan %d"), pReqMsg->maxAPperScan); + hdd_notice("Max AP per Scan %d", pReqMsg->maxAPperScan); /* Parse and fetch report threshold percent */ if (!tb[PARAM_RPT_THRHLD_PERCENT]) { - hddLog(LOGE, FL("attr report_threshold percent failed")); + hdd_err("attr report_threshold percent failed"); goto fail; } pReqMsg->report_threshold_percent = nla_get_u8(tb[PARAM_RPT_THRHLD_PERCENT]); - hddLog(LOG1, FL("Report Threshold percent %d"), + hdd_notice("Report Threshold percent %d", pReqMsg->report_threshold_percent); /* Parse and fetch report threshold num scans */ if (!tb[PARAM_RPT_THRHLD_NUM_SCANS]) { - hddLog(LOGE, FL("attr report_threshold num scans failed")); + hdd_err("attr report_threshold num scans failed"); goto fail; } pReqMsg->report_threshold_num_scans = nla_get_u8(tb[PARAM_RPT_THRHLD_NUM_SCANS]); - hddLog(LOG1, FL("Report Threshold num scans %d"), + hdd_notice("Report Threshold num scans %d", pReqMsg->report_threshold_num_scans); /* Parse and fetch number of buckets */ if (!tb[PARAM_NUM_BUCKETS]) { - hddLog(LOGE, FL("attr number of buckets failed")); + hdd_err("attr number of buckets failed"); goto fail; } num_buckets = nla_get_u8(tb[PARAM_NUM_BUCKETS]); @@ -3234,11 +3226,11 @@ __wlan_hdd_cfg80211_extscan_start(struct wiphy *wiphy, pReqMsg->extscan_adaptive_dwell_mode = pHddCtx->config->extscan_adaptive_dwell_mode; - hddLog(LOG1, FL("Configuration flags: %u"), + hdd_notice("Configuration flags: %u", pReqMsg->configuration_flags); if (!tb[QCA_WLAN_VENDOR_ATTR_EXTSCAN_BUCKET_SPEC]) { - hddLog(LOGE, FL("attr bucket spec failed")); + hdd_err("attr bucket spec failed"); goto fail; } @@ -3253,13 +3245,12 @@ __wlan_hdd_cfg80211_extscan_start(struct wiphy *wiphy, status = sme_ext_scan_start(pHddCtx->hHal, pReqMsg); if (!QDF_IS_STATUS_SUCCESS(status)) { - hddLog(LOGE, - FL("sme_ext_scan_start failed(err=%d)"), status); + hdd_err("sme_ext_scan_start failed(err=%d)", status); goto fail; } pHddCtx->ext_scan_start_since_boot = qdf_get_monotonic_boottime(); - hddLog(LOG1, FL("Timestamp since boot: %llu"), + hdd_notice("Timestamp since boot: %llu", pHddCtx->ext_scan_start_since_boot); /* request was sent -- wait for the response */ @@ -3267,7 +3258,7 @@ __wlan_hdd_cfg80211_extscan_start(struct wiphy *wiphy, msecs_to_jiffies(WLAN_WAIT_TIME_EXTSCAN)); if (!rc) { - hddLog(LOGE, FL("sme_ext_scan_start timed out")); + hdd_err("sme_ext_scan_start timed out"); retval = -ETIMEDOUT; } else { spin_lock(&context->context_lock); @@ -3367,25 +3358,25 @@ __wlan_hdd_cfg80211_extscan_stop(struct wiphy *wiphy, if (nla_parse(tb, PARAM_MAX, data, data_len, wlan_hdd_extscan_config_policy)) { - hddLog(LOGE, FL("Invalid ATTR")); + hdd_err("Invalid ATTR"); return -EINVAL; } pReqMsg = qdf_mem_malloc(sizeof(*pReqMsg)); if (!pReqMsg) { - hddLog(LOGE, FL("qdf_mem_malloc failed")); + hdd_err("qdf_mem_malloc failed"); return -ENOMEM; } /* Parse and fetch request Id */ if (!tb[PARAM_REQUEST_ID]) { - hddLog(LOGE, FL("attr request id failed")); + hdd_err("attr request id failed"); goto fail; } pReqMsg->requestId = nla_get_u32(tb[PARAM_REQUEST_ID]); pReqMsg->sessionId = pAdapter->sessionId; - hddLog(LOG1, FL("Req Id %d Session Id %d"), + hdd_notice("Req Id %d Session Id %d", pReqMsg->requestId, pReqMsg->sessionId); context = &ext_scan_context; @@ -3396,8 +3387,7 @@ __wlan_hdd_cfg80211_extscan_stop(struct wiphy *wiphy, status = sme_ext_scan_stop(pHddCtx->hHal, pReqMsg); if (!QDF_IS_STATUS_SUCCESS(status)) { - hddLog(LOGE, - FL("sme_ext_scan_stop failed(err=%d)"), status); + hdd_err("sme_ext_scan_stop failed(err=%d)", status); goto fail; } @@ -3406,7 +3396,7 @@ __wlan_hdd_cfg80211_extscan_stop(struct wiphy *wiphy, msecs_to_jiffies(WLAN_WAIT_TIME_EXTSCAN)); if (!rc) { - hddLog(LOGE, FL("sme_ext_scan_stop timed out")); + hdd_err("sme_ext_scan_stop timed out"); retval = -ETIMEDOUT; } else { spin_lock(&context->context_lock); @@ -3494,19 +3484,19 @@ __wlan_hdd_cfg80211_extscan_reset_bssid_hotlist(struct wiphy *wiphy, if (nla_parse(tb, QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_MAX, data, data_len, wlan_hdd_extscan_config_policy)) { - hddLog(LOGE, FL("Invalid ATTR")); + hdd_err("Invalid ATTR"); return -EINVAL; } pReqMsg = qdf_mem_malloc(sizeof(*pReqMsg)); if (!pReqMsg) { - hddLog(LOGE, FL("qdf_mem_malloc failed")); + hdd_err("qdf_mem_malloc failed"); return -ENOMEM; } /* Parse and fetch request Id */ if (!tb[QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_REQUEST_ID]) { - hddLog(LOGE, FL("attr request id failed")); + hdd_err("attr request id failed"); goto fail; } @@ -3514,7 +3504,7 @@ __wlan_hdd_cfg80211_extscan_reset_bssid_hotlist(struct wiphy *wiphy, nla_get_u32(tb [QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_REQUEST_ID]); pReqMsg->sessionId = pAdapter->sessionId; - hddLog(LOG1, FL("Req Id %d Session Id %d"), + hdd_notice("Req Id %d Session Id %d", pReqMsg->requestId, pReqMsg->sessionId); context = &ext_scan_context; @@ -3525,8 +3515,7 @@ __wlan_hdd_cfg80211_extscan_reset_bssid_hotlist(struct wiphy *wiphy, status = sme_reset_bss_hotlist(pHddCtx->hHal, pReqMsg); if (!QDF_IS_STATUS_SUCCESS(status)) { - hddLog(LOGE, - FL("sme_reset_bss_hotlist failed(err=%d)"), status); + hdd_err("sme_reset_bss_hotlist failed(err=%d)", status); goto fail; } @@ -3535,7 +3524,7 @@ __wlan_hdd_cfg80211_extscan_reset_bssid_hotlist(struct wiphy *wiphy, (&context->response_event, msecs_to_jiffies(WLAN_WAIT_TIME_EXTSCAN)); if (!rc) { - hddLog(LOGE, FL("sme_reset_bss_hotlist timed out")); + hdd_err("sme_reset_bss_hotlist timed out"); retval = -ETIMEDOUT; } else { spin_lock(&context->context_lock); @@ -3619,19 +3608,19 @@ __wlan_hdd_cfg80211_extscan_reset_significant_change(struct wiphy if (nla_parse(tb, QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_MAX, data, data_len, wlan_hdd_extscan_config_policy)) { - hddLog(LOGE, FL("Invalid ATTR")); + hdd_err("Invalid ATTR"); return -EINVAL; } pReqMsg = qdf_mem_malloc(sizeof(*pReqMsg)); if (!pReqMsg) { - hddLog(LOGE, FL("qdf_mem_malloc failed")); + hdd_err("qdf_mem_malloc failed"); return -ENOMEM; } /* Parse and fetch request Id */ if (!tb[QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_REQUEST_ID]) { - hddLog(LOGE, FL("attr request id failed")); + hdd_err("attr request id failed"); goto fail; } @@ -3639,7 +3628,7 @@ __wlan_hdd_cfg80211_extscan_reset_significant_change(struct wiphy nla_get_u32(tb [QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_REQUEST_ID]); pReqMsg->sessionId = pAdapter->sessionId; - hddLog(LOG1, FL("Req Id %d Session Id %d"), + hdd_notice("Req Id %d Session Id %d", pReqMsg->requestId, pReqMsg->sessionId); context = &ext_scan_context; @@ -3650,7 +3639,7 @@ __wlan_hdd_cfg80211_extscan_reset_significant_change(struct wiphy status = sme_reset_significant_change(pHddCtx->hHal, pReqMsg); if (!QDF_IS_STATUS_SUCCESS(status)) { - hddLog(LOGE, FL("sme_reset_significant_change failed(err=%d)"), + hdd_err("sme_reset_significant_change failed(err=%d)", status); qdf_mem_free(pReqMsg); return -EINVAL; @@ -3661,7 +3650,7 @@ __wlan_hdd_cfg80211_extscan_reset_significant_change(struct wiphy msecs_to_jiffies(WLAN_WAIT_TIME_EXTSCAN)); if (!rc) { - hddLog(LOGE, FL("sme_ResetSignificantChange timed out")); + hdd_err("sme_ResetSignificantChange timed out"); retval = -ETIMEDOUT; } else { spin_lock(&context->context_lock); @@ -3733,13 +3722,13 @@ static int hdd_extscan_epno_fill_network_list( if (nla_parse(network, QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_MAX, nla_data(networks), nla_len(networks), NULL)) { - hddLog(LOGE, FL("nla_parse failed")); + hdd_err("nla_parse failed"); return -EINVAL; } /* Parse and fetch ssid */ if (!network[QCA_WLAN_VENDOR_ATTR_PNO_SET_LIST_PARAM_EPNO_NETWORK_SSID]) { - hddLog(LOGE, FL("attr network ssid failed")); + hdd_err("attr network ssid failed"); return -EINVAL; } ssid_len = nla_len( @@ -3749,41 +3738,41 @@ static int hdd_extscan_epno_fill_network_list( ssid_len--; req_msg->networks[index].ssid.length = ssid_len; - hddLog(LOG1, FL("network ssid length %d"), ssid_len); + hdd_notice("network ssid length %d", ssid_len); ssid = nla_data(network[QCA_WLAN_VENDOR_ATTR_PNO_SET_LIST_PARAM_EPNO_NETWORK_SSID]); qdf_mem_copy(req_msg->networks[index].ssid.ssId, ssid, ssid_len); - hddLog(LOG1, FL("Ssid (%.*s)"), + hdd_notice("Ssid (%.*s)", req_msg->networks[index].ssid.length, req_msg->networks[index].ssid.ssId); /* Parse and fetch rssi threshold */ if (!network[QCA_WLAN_VENDOR_ATTR_PNO_SET_LIST_PARAM_EPNO_NETWORK_RSSI_THRESHOLD]) { - hddLog(LOGE, FL("attr rssi threshold failed")); + hdd_err("attr rssi threshold failed"); return -EINVAL; } req_msg->networks[index].rssi_threshold = nla_get_s8( network[QCA_WLAN_VENDOR_ATTR_PNO_SET_LIST_PARAM_EPNO_NETWORK_RSSI_THRESHOLD]); - hddLog(LOG1, FL("rssi threshold %d"), + hdd_notice("rssi threshold %d", req_msg->networks[index].rssi_threshold); /* Parse and fetch epno flags */ if (!network[QCA_WLAN_VENDOR_ATTR_PNO_SET_LIST_PARAM_EPNO_NETWORK_FLAGS]) { - hddLog(LOGE, FL("attr epno flags failed")); + hdd_err("attr epno flags failed"); return -EINVAL; } req_msg->networks[index].flags = nla_get_u8( network[QCA_WLAN_VENDOR_ATTR_PNO_SET_LIST_PARAM_EPNO_NETWORK_FLAGS]); - hddLog(LOG1, FL("flags %u"), req_msg->networks[index].flags); + hdd_notice("flags %u", req_msg->networks[index].flags); /* Parse and fetch auth bit */ if (!network[QCA_WLAN_VENDOR_ATTR_PNO_SET_LIST_PARAM_EPNO_NETWORK_AUTH_BIT]) { - hddLog(LOGE, FL("attr auth bit failed")); + hdd_err("attr auth bit failed"); return -EINVAL; } req_msg->networks[index].auth_bit_field = nla_get_u8( network[QCA_WLAN_VENDOR_ATTR_PNO_SET_LIST_PARAM_EPNO_NETWORK_AUTH_BIT]); - hddLog(LOG1, FL("auth bit %u"), + hdd_notice("auth bit %u", req_msg->networks[index].auth_bit_field); index++; @@ -3832,24 +3821,24 @@ static int __wlan_hdd_cfg80211_set_epno_list(struct wiphy *wiphy, if (nla_parse(tb, QCA_WLAN_VENDOR_ATTR_PNO_MAX, data, data_len, wlan_hdd_extscan_config_policy)) { - hddLog(LOGE, FL("Invalid ATTR")); + hdd_err("Invalid ATTR"); return -EINVAL; } /* Parse and fetch number of networks */ if (!tb[QCA_WLAN_VENDOR_ATTR_PNO_SET_LIST_PARAM_NUM_NETWORKS]) { - hddLog(LOGE, FL("attr num networks failed")); + hdd_err("attr num networks failed"); return -EINVAL; } num_networks = nla_get_u32( tb[QCA_WLAN_VENDOR_ATTR_PNO_SET_LIST_PARAM_NUM_NETWORKS]); - hddLog(LOG1, FL("num networks %u"), num_networks); + hdd_notice("num networks %u", num_networks); len = sizeof(*req_msg) + (num_networks * sizeof(struct wifi_epno_network)); req_msg = qdf_mem_malloc(len); if (!req_msg) { - hddLog(LOGE, FL("qdf_mem_malloc failed")); + hdd_err("qdf_mem_malloc failed"); return -ENOMEM; } qdf_mem_zero(req_msg, len); @@ -3857,22 +3846,22 @@ static int __wlan_hdd_cfg80211_set_epno_list(struct wiphy *wiphy, /* Parse and fetch request Id */ if (!tb[QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_REQUEST_ID]) { - hddLog(LOGE, FL("attr request id failed")); + hdd_err("attr request id failed"); goto fail; } req_msg->request_id = nla_get_u32( tb[QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_REQUEST_ID]); - hddLog(LOG1, FL("Req Id %u"), req_msg->request_id); + hdd_notice("Req Id %u", req_msg->request_id); req_msg->session_id = adapter->sessionId; - hddLog(LOG1, FL("Session Id %d"), req_msg->session_id); + hdd_notice("Session Id %d", req_msg->session_id); if (hdd_extscan_epno_fill_network_list(hdd_ctx, req_msg, tb)) goto fail; status = sme_set_epno_list(hdd_ctx->hHal, req_msg); if (!QDF_IS_STATUS_SUCCESS(status)) { - hddLog(LOGE, FL("sme_set_epno_list failed(err=%d)"), status); + hdd_err("sme_set_epno_list failed(err=%d)", status); goto fail; } @@ -3940,55 +3929,55 @@ static int hdd_extscan_passpoint_fill_network_list( if (nla_parse(network, QCA_WLAN_VENDOR_ATTR_PNO_MAX, nla_data(networks), nla_len(networks), NULL)) { - hddLog(LOGE, FL("nla_parse failed")); + hdd_err("nla_parse failed"); return -EINVAL; } /* Parse and fetch identifier */ if (!network[QCA_WLAN_VENDOR_ATTR_PNO_PASSPOINT_NETWORK_PARAM_ID]) { - hddLog(LOGE, FL("attr passpoint id failed")); + hdd_err("attr passpoint id failed"); return -EINVAL; } req_msg->networks[index].id = nla_get_u32( network[QCA_WLAN_VENDOR_ATTR_PNO_PASSPOINT_NETWORK_PARAM_ID]); - hddLog(LOG1, FL("Id %u"), req_msg->networks[index].id); + hdd_notice("Id %u", req_msg->networks[index].id); /* Parse and fetch realm */ if (!network[QCA_WLAN_VENDOR_ATTR_PNO_PASSPOINT_NETWORK_PARAM_REALM]) { - hddLog(LOGE, FL("attr realm failed")); + hdd_err("attr realm failed"); return -EINVAL; } len = nla_len( network[QCA_WLAN_VENDOR_ATTR_PNO_PASSPOINT_NETWORK_PARAM_REALM]); if (len < 0 || len > SIR_PASSPOINT_REALM_LEN) { - hddLog(LOGE, FL("Invalid realm size %d"), len); + hdd_err("Invalid realm size %d", len); return -EINVAL; } qdf_mem_copy(req_msg->networks[index].realm, nla_data(network[QCA_WLAN_VENDOR_ATTR_PNO_PASSPOINT_NETWORK_PARAM_REALM]), len); - hddLog(LOG1, FL("realm len %d"), len); - hddLog(LOG1, FL("realm: %s"), req_msg->networks[index].realm); + hdd_notice("realm len %d", len); + hdd_notice("realm: %s", req_msg->networks[index].realm); /* Parse and fetch roaming consortium ids */ if (!network[QCA_WLAN_VENDOR_ATTR_PNO_PASSPOINT_NETWORK_PARAM_ROAM_CNSRTM_ID]) { - hddLog(LOGE, FL("attr roaming consortium ids failed")); + hdd_err("attr roaming consortium ids failed"); return -EINVAL; } nla_memcpy(&req_msg->networks[index].roaming_consortium_ids, network[QCA_WLAN_VENDOR_ATTR_PNO_PASSPOINT_NETWORK_PARAM_ROAM_CNSRTM_ID], sizeof(req_msg->networks[0].roaming_consortium_ids)); - hddLog(LOG1, FL("roaming consortium ids")); + hdd_notice("roaming consortium ids"); /* Parse and fetch plmn */ if (!network[QCA_WLAN_VENDOR_ATTR_PNO_PASSPOINT_NETWORK_PARAM_ROAM_PLMN]) { - hddLog(LOGE, FL("attr plmn failed")); + hdd_err("attr plmn failed"); return -EINVAL; } nla_memcpy(&req_msg->networks[index].plmn, network[QCA_WLAN_VENDOR_ATTR_PNO_PASSPOINT_NETWORK_PARAM_ROAM_PLMN], SIR_PASSPOINT_PLMN_LEN); - hddLog(LOG1, FL("plmn %02x:%02x:%02x)"), + hdd_notice("plmn %02x:%02x:%02x)", req_msg->networks[index].plmn[0], req_msg->networks[index].plmn[1], req_msg->networks[index].plmn[2]); @@ -4037,37 +4026,37 @@ static int __wlan_hdd_cfg80211_set_passpoint_list(struct wiphy *wiphy, if (nla_parse(tb, QCA_WLAN_VENDOR_ATTR_PNO_MAX, data, data_len, wlan_hdd_extscan_config_policy)) { - hddLog(LOGE, FL("Invalid ATTR")); + hdd_err("Invalid ATTR"); return -EINVAL; } /* Parse and fetch number of networks */ if (!tb[QCA_WLAN_VENDOR_ATTR_PNO_PASSPOINT_LIST_PARAM_NUM]) { - hddLog(LOGE, FL("attr num networks failed")); + hdd_err("attr num networks failed"); return -EINVAL; } num_networks = nla_get_u32( tb[QCA_WLAN_VENDOR_ATTR_PNO_PASSPOINT_LIST_PARAM_NUM]); - hddLog(LOG1, FL("num networks %u"), num_networks); + hdd_notice("num networks %u", num_networks); req_msg = qdf_mem_malloc(sizeof(*req_msg) + (num_networks * sizeof(req_msg->networks[0]))); if (!req_msg) { - hddLog(LOGE, FL("qdf_mem_malloc failed")); + hdd_err("qdf_mem_malloc failed"); return -ENOMEM; } req_msg->num_networks = num_networks; /* Parse and fetch request Id */ if (!tb[QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_REQUEST_ID]) { - hddLog(LOGE, FL("attr request id failed")); + hdd_err("attr request id failed"); goto fail; } req_msg->request_id = nla_get_u32( tb[QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_REQUEST_ID]); req_msg->session_id = adapter->sessionId; - hddLog(LOG1, FL("Req Id %u Session Id %d"), req_msg->request_id, + hdd_notice("Req Id %u Session Id %d", req_msg->request_id, req_msg->session_id); if (hdd_extscan_passpoint_fill_network_list(hdd_ctx, req_msg, tb)) @@ -4075,8 +4064,7 @@ static int __wlan_hdd_cfg80211_set_passpoint_list(struct wiphy *wiphy, status = sme_set_passpoint_list(hdd_ctx->hHal, req_msg); if (!QDF_IS_STATUS_SUCCESS(status)) { - hddLog(LOGE, - FL("sme_set_passpoint_list failed(err=%d)"), status); + hdd_err("sme_set_passpoint_list failed(err=%d)", status); goto fail; } @@ -4153,32 +4141,31 @@ static int __wlan_hdd_cfg80211_reset_passpoint_list(struct wiphy *wiphy, if (nla_parse(tb, QCA_WLAN_VENDOR_ATTR_PNO_MAX, data, data_len, wlan_hdd_extscan_config_policy)) { - hddLog(LOGE, FL("Invalid ATTR")); + hdd_err("Invalid ATTR"); return -EINVAL; } req_msg = qdf_mem_malloc(sizeof(*req_msg)); if (!req_msg) { - hddLog(LOGE, FL("qdf_mem_malloc failed")); + hdd_err("qdf_mem_malloc failed"); return -ENOMEM; } /* Parse and fetch request Id */ if (!tb[QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_REQUEST_ID]) { - hddLog(LOGE, FL("attr request id failed")); + hdd_err("attr request id failed"); goto fail; } req_msg->request_id = nla_get_u32( tb[QCA_WLAN_VENDOR_ATTR_EXTSCAN_SUBCMD_CONFIG_PARAM_REQUEST_ID]); req_msg->session_id = adapter->sessionId; - hddLog(LOG1, FL("Req Id %u Session Id %d"), + hdd_notice("Req Id %u Session Id %d", req_msg->request_id, req_msg->session_id); status = sme_reset_passpoint_list(hdd_ctx->hHal, req_msg); if (!QDF_IS_STATUS_SUCCESS(status)) { - hddLog(LOGE, - FL("sme_reset_passpoint_list failed(err=%d)"), status); + hdd_err("sme_reset_passpoint_list failed(err=%d)", status); goto fail; } @@ -4284,70 +4271,69 @@ __wlan_hdd_cfg80211_extscan_set_ssid_hotlist(struct wiphy *wiphy, if (nla_parse(tb, PARAM_MAX, data, data_len, wlan_hdd_extscan_config_policy)) { - hddLog(LOGE, FL("Invalid ATTR")); + hdd_err("Invalid ATTR"); return -EINVAL; } request = qdf_mem_malloc(sizeof(*request)); if (!request) { - hddLog(LOGE, FL("qdf_mem_malloc failed")); + hdd_err("qdf_mem_malloc failed"); return -ENOMEM; } /* Parse and fetch request Id */ if (!tb[PARAM_REQUEST_ID]) { - hddLog(LOGE, FL("attr request id failed")); + hdd_err("attr request id failed"); goto fail; } request->request_id = nla_get_u32(tb[PARAM_REQUEST_ID]); - hddLog(LOG1, FL("Request Id %d"), request->request_id); + hdd_notice("Request Id %d", request->request_id); /* Parse and fetch lost SSID sample size */ if (!tb[PARAMS_LOST_SSID_SAMPLE_SIZE]) { - hddLog(LOGE, FL("attr number of Ssid failed")); + hdd_err("attr number of Ssid failed"); goto fail; } request->lost_ssid_sample_size = nla_get_u32(tb[PARAMS_LOST_SSID_SAMPLE_SIZE]); - hddLog(LOG1, FL("Lost SSID Sample Size %d"), + hdd_notice("Lost SSID Sample Size %d", request->lost_ssid_sample_size); /* Parse and fetch number of hotlist SSID */ if (!tb[PARAMS_NUM_SSID]) { - hddLog(LOGE, FL("attr number of Ssid failed")); + hdd_err("attr number of Ssid failed"); goto fail; } request->ssid_count = nla_get_u32(tb[PARAMS_NUM_SSID]); - hddLog(LOG1, FL("Number of SSID %d"), request->ssid_count); + hdd_notice("Number of SSID %d", request->ssid_count); request->session_id = adapter->sessionId; - hddLog(LOG1, FL("Session Id %d"), request->session_id); + hdd_notice("Session Id %d", request->session_id); i = 0; nla_for_each_nested(ssids, tb[THRESHOLD_PARAM], rem) { if (i >= WLAN_EXTSCAN_MAX_HOTLIST_SSIDS) { - hddLog(LOGE, - FL("Too Many SSIDs, %d exceeds %d"), + hdd_err("Too Many SSIDs, %d exceeds %d", i, WLAN_EXTSCAN_MAX_HOTLIST_SSIDS); break; } if (nla_parse(tb2, PARAM_MAX, nla_data(ssids), nla_len(ssids), wlan_hdd_extscan_config_policy)) { - hddLog(LOGE, FL("nla_parse failed")); + hdd_err("nla_parse failed"); goto fail; } /* Parse and fetch SSID */ if (!tb2[PARAM_SSID]) { - hddLog(LOGE, FL("attr ssid failed")); + hdd_err("attr ssid failed"); goto fail; } nla_memcpy(ssid_string, tb2[PARAM_SSID], sizeof(ssid_string)); - hddLog(LOG1, FL("SSID %s"), + hdd_notice("SSID %s", ssid_string); ssid_len = strlen(ssid_string); memcpy(request->ssids[i].ssid.ssId, ssid_string, ssid_len); @@ -4355,27 +4341,27 @@ __wlan_hdd_cfg80211_extscan_set_ssid_hotlist(struct wiphy *wiphy, /* Parse and fetch low RSSI */ if (!tb2[PARAM_BAND]) { - hddLog(LOGE, FL("attr band failed")); + hdd_err("attr band failed"); goto fail; } request->ssids[i].band = nla_get_u8(tb2[PARAM_BAND]); - hddLog(LOG1, FL("band %d"), request->ssids[i].band); + hdd_notice("band %d", request->ssids[i].band); /* Parse and fetch low RSSI */ if (!tb2[PARAM_RSSI_LOW]) { - hddLog(LOGE, FL("attr low RSSI failed")); + hdd_err("attr low RSSI failed"); goto fail; } request->ssids[i].rssi_low = nla_get_s32(tb2[PARAM_RSSI_LOW]); - hddLog(LOG1, FL("RSSI low %d"), request->ssids[i].rssi_low); + hdd_notice("RSSI low %d", request->ssids[i].rssi_low); /* Parse and fetch high RSSI */ if (!tb2[PARAM_RSSI_HIGH]) { - hddLog(LOGE, FL("attr high RSSI failed")); + hdd_err("attr high RSSI failed"); goto fail; } request->ssids[i].rssi_high = nla_get_u32(tb2[PARAM_RSSI_HIGH]); - hddLog(LOG1, FL("RSSI high %d"), request->ssids[i].rssi_high); + hdd_notice("RSSI high %d", request->ssids[i].rssi_high); i++; } @@ -4387,8 +4373,7 @@ __wlan_hdd_cfg80211_extscan_set_ssid_hotlist(struct wiphy *wiphy, status = sme_set_ssid_hotlist(hdd_ctx->hHal, request); if (!QDF_IS_STATUS_SUCCESS(status)) { - hddLog(LOGE, - FL("sme_set_ssid_hotlist failed(err=%d)"), status); + hdd_err("sme_set_ssid_hotlist failed(err=%d)", status); goto fail; } @@ -4399,7 +4384,7 @@ __wlan_hdd_cfg80211_extscan_set_ssid_hotlist(struct wiphy *wiphy, msecs_to_jiffies (WLAN_WAIT_TIME_EXTSCAN)); if (!rc) { - hddLog(LOGE, FL("sme_set_ssid_hotlist timed out")); + hdd_err("sme_set_ssid_hotlist timed out"); retval = -ETIMEDOUT; } else { spin_lock(&context->context_lock); @@ -4504,27 +4489,27 @@ __wlan_hdd_cfg80211_extscan_reset_ssid_hotlist(struct wiphy *wiphy, if (nla_parse(tb, PARAM_MAX, data, data_len, wlan_hdd_extscan_config_policy)) { - hddLog(LOGE, FL("Invalid ATTR")); + hdd_err("Invalid ATTR"); return -EINVAL; } request = qdf_mem_malloc(sizeof(*request)); if (!request) { - hddLog(LOGE, FL("qdf_mem_malloc failed")); + hdd_err("qdf_mem_malloc failed"); return -ENOMEM; } /* Parse and fetch request Id */ if (!tb[PARAM_REQUEST_ID]) { - hddLog(LOGE, FL("attr request id failed")); + hdd_err("attr request id failed"); goto fail; } request->request_id = nla_get_u32(tb[PARAM_REQUEST_ID]); - hddLog(LOG1, FL("Request Id %d"), request->request_id); + hdd_notice("Request Id %d", request->request_id); request->session_id = adapter->sessionId; - hddLog(LOG1, FL("Session Id %d"), request->session_id); + hdd_notice("Session Id %d", request->session_id); request->lost_ssid_sample_size = 0; request->ssid_count = 0; @@ -4537,8 +4522,7 @@ __wlan_hdd_cfg80211_extscan_reset_ssid_hotlist(struct wiphy *wiphy, status = sme_set_ssid_hotlist(hdd_ctx->hHal, request); if (!QDF_IS_STATUS_SUCCESS(status)) { - hddLog(LOGE, - FL("sme_reset_ssid_hotlist failed(err=%d)"), status); + hdd_err("sme_reset_ssid_hotlist failed(err=%d)", status); goto fail; } @@ -4549,7 +4533,7 @@ __wlan_hdd_cfg80211_extscan_reset_ssid_hotlist(struct wiphy *wiphy, msecs_to_jiffies (WLAN_WAIT_TIME_EXTSCAN)); if (!rc) { - hddLog(LOGE, FL("sme_reset_ssid_hotlist timed out")); + hdd_err("sme_reset_ssid_hotlist timed out"); retval = -ETIMEDOUT; } else { spin_lock(&context->context_lock);