Merge "qcacld-3.0: Convert wlan_hdd_hostapd.c to unified logging [4/7]" into wlan-cld3.driver.lnx.1.1-dev

This commit is contained in:
Service qcabuildsw
2016-07-20 13:19:58 -07:00
committed by Gerrit - the friendly Code Review server

View File

@@ -3023,8 +3023,7 @@ static __iw_softap_getparam(struct net_device *dev,
sme_cfg_get_int(hHal, WNI_CFG_ASSOC_STA_LIMIT, sme_cfg_get_int(hHal, WNI_CFG_ASSOC_STA_LIMIT,
(uint32_t *) value); (uint32_t *) value);
if (QDF_STATUS_SUCCESS != status) { if (QDF_STATUS_SUCCESS != status) {
hddLog(LOGE, hdd_err("failed to get WNI_CFG_ASSOC_STA_LIMIT from cfg %d",
FL("failed to get WNI_CFG_ASSOC_STA_LIMIT from cfg %d"),
status); status);
ret = -EIO; ret = -EIO;
} }
@@ -3061,7 +3060,7 @@ static __iw_softap_getparam(struct net_device *dev,
case QCSAP_GTX_HT_MCS: case QCSAP_GTX_HT_MCS:
{ {
hddLog(LOG1, "GET WMI_VDEV_PARAM_GTX_HT_MCS"); hdd_notice("GET WMI_VDEV_PARAM_GTX_HT_MCS");
*value = wma_cli_get_command(pHostapdAdapter->sessionId, *value = wma_cli_get_command(pHostapdAdapter->sessionId,
WMI_VDEV_PARAM_GTX_HT_MCS, WMI_VDEV_PARAM_GTX_HT_MCS,
GTX_CMD); GTX_CMD);
@@ -3070,7 +3069,7 @@ static __iw_softap_getparam(struct net_device *dev,
case QCSAP_GTX_VHT_MCS: case QCSAP_GTX_VHT_MCS:
{ {
hddLog(LOG1, "GET WMI_VDEV_PARAM_GTX_VHT_MCS"); hdd_notice("GET WMI_VDEV_PARAM_GTX_VHT_MCS");
*value = wma_cli_get_command(pHostapdAdapter->sessionId, *value = wma_cli_get_command(pHostapdAdapter->sessionId,
WMI_VDEV_PARAM_GTX_VHT_MCS, WMI_VDEV_PARAM_GTX_VHT_MCS,
GTX_CMD); GTX_CMD);
@@ -3079,7 +3078,7 @@ static __iw_softap_getparam(struct net_device *dev,
case QCSAP_GTX_USRCFG: case QCSAP_GTX_USRCFG:
{ {
hddLog(LOG1, "GET WMI_VDEV_PARAM_GTX_USR_CFG"); hdd_notice("GET WMI_VDEV_PARAM_GTX_USR_CFG");
*value = wma_cli_get_command(pHostapdAdapter->sessionId, *value = wma_cli_get_command(pHostapdAdapter->sessionId,
WMI_VDEV_PARAM_GTX_USR_CFG, WMI_VDEV_PARAM_GTX_USR_CFG,
GTX_CMD); GTX_CMD);
@@ -3088,7 +3087,7 @@ static __iw_softap_getparam(struct net_device *dev,
case QCSAP_GTX_THRE: case QCSAP_GTX_THRE:
{ {
hddLog(LOG1, "GET WMI_VDEV_PARAM_GTX_THRE"); hdd_notice("GET WMI_VDEV_PARAM_GTX_THRE");
*value = wma_cli_get_command(pHostapdAdapter->sessionId, *value = wma_cli_get_command(pHostapdAdapter->sessionId,
WMI_VDEV_PARAM_GTX_THRE, WMI_VDEV_PARAM_GTX_THRE,
GTX_CMD); GTX_CMD);
@@ -3097,7 +3096,7 @@ static __iw_softap_getparam(struct net_device *dev,
case QCSAP_GTX_MARGIN: case QCSAP_GTX_MARGIN:
{ {
hddLog(LOG1, "GET WMI_VDEV_PARAM_GTX_MARGIN"); hdd_notice("GET WMI_VDEV_PARAM_GTX_MARGIN");
*value = wma_cli_get_command(pHostapdAdapter->sessionId, *value = wma_cli_get_command(pHostapdAdapter->sessionId,
WMI_VDEV_PARAM_GTX_MARGIN, WMI_VDEV_PARAM_GTX_MARGIN,
GTX_CMD); GTX_CMD);
@@ -3106,7 +3105,7 @@ static __iw_softap_getparam(struct net_device *dev,
case QCSAP_GTX_STEP: case QCSAP_GTX_STEP:
{ {
hddLog(LOG1, "GET WMI_VDEV_PARAM_GTX_STEP"); hdd_notice("GET WMI_VDEV_PARAM_GTX_STEP");
*value = wma_cli_get_command(pHostapdAdapter->sessionId, *value = wma_cli_get_command(pHostapdAdapter->sessionId,
WMI_VDEV_PARAM_GTX_STEP, WMI_VDEV_PARAM_GTX_STEP,
GTX_CMD); GTX_CMD);
@@ -3115,7 +3114,7 @@ static __iw_softap_getparam(struct net_device *dev,
case QCSAP_GTX_MINTPC: case QCSAP_GTX_MINTPC:
{ {
hddLog(LOG1, "GET WMI_VDEV_PARAM_GTX_MINTPC"); hdd_notice("GET WMI_VDEV_PARAM_GTX_MINTPC");
*value = wma_cli_get_command(pHostapdAdapter->sessionId, *value = wma_cli_get_command(pHostapdAdapter->sessionId,
WMI_VDEV_PARAM_GTX_MINTPC, WMI_VDEV_PARAM_GTX_MINTPC,
GTX_CMD); GTX_CMD);
@@ -3124,7 +3123,7 @@ static __iw_softap_getparam(struct net_device *dev,
case QCSAP_GTX_BWMASK: case QCSAP_GTX_BWMASK:
{ {
hddLog(LOG1, "GET WMI_VDEV_PARAM_GTX_BW_MASK"); hdd_notice("GET WMI_VDEV_PARAM_GTX_BW_MASK");
*value = wma_cli_get_command(pHostapdAdapter->sessionId, *value = wma_cli_get_command(pHostapdAdapter->sessionId,
WMI_VDEV_PARAM_GTX_BW_MASK, WMI_VDEV_PARAM_GTX_BW_MASK,
GTX_CMD); GTX_CMD);
@@ -3146,12 +3145,10 @@ static __iw_softap_getparam(struct net_device *dev,
case QCSAP_GET_ACL: case QCSAP_GET_ACL:
{ {
hddLog(LOG1, FL("QCSAP_GET_ACL")); hdd_notice("QCSAP_GET_ACL");
if (hdd_print_acl(pHostapdAdapter) != if (hdd_print_acl(pHostapdAdapter) !=
QDF_STATUS_SUCCESS) { QDF_STATUS_SUCCESS) {
hddLog(LOGE, hdd_err("QCSAP_GET_ACL returned Error: not completed");
FL
("QCSAP_GET_ACL returned Error: not completed"));
} }
*value = 0; *value = 0;
break; break;
@@ -3159,7 +3156,7 @@ static __iw_softap_getparam(struct net_device *dev,
case QCASAP_TX_CHAINMASK_CMD: case QCASAP_TX_CHAINMASK_CMD:
{ {
hddLog(LOG1, "QCASAP_TX_CHAINMASK_CMD"); hdd_notice("QCASAP_TX_CHAINMASK_CMD");
*value = wma_cli_get_command(pHostapdAdapter->sessionId, *value = wma_cli_get_command(pHostapdAdapter->sessionId,
WMI_PDEV_PARAM_TX_CHAIN_MASK, WMI_PDEV_PARAM_TX_CHAIN_MASK,
PDEV_CMD); PDEV_CMD);
@@ -3168,7 +3165,7 @@ static __iw_softap_getparam(struct net_device *dev,
case QCASAP_RX_CHAINMASK_CMD: case QCASAP_RX_CHAINMASK_CMD:
{ {
hddLog(LOG1, "QCASAP_RX_CHAINMASK_CMD"); hdd_notice("QCASAP_RX_CHAINMASK_CMD");
*value = wma_cli_get_command(pHostapdAdapter->sessionId, *value = wma_cli_get_command(pHostapdAdapter->sessionId,
WMI_PDEV_PARAM_RX_CHAIN_MASK, WMI_PDEV_PARAM_RX_CHAIN_MASK,
PDEV_CMD); PDEV_CMD);
@@ -3177,7 +3174,7 @@ static __iw_softap_getparam(struct net_device *dev,
case QCASAP_NSS_CMD: case QCASAP_NSS_CMD:
{ {
hddLog(LOG1, "QCASAP_NSS_CMD"); hdd_notice("QCASAP_NSS_CMD");
*value = wma_cli_get_command(pHostapdAdapter->sessionId, *value = wma_cli_get_command(pHostapdAdapter->sessionId,
WMI_VDEV_PARAM_NSS, WMI_VDEV_PARAM_NSS,
VDEV_CMD); VDEV_CMD);
@@ -3188,18 +3185,18 @@ static __iw_softap_getparam(struct net_device *dev,
break; break;
case QCASAP_GET_TEMP_CMD: case QCASAP_GET_TEMP_CMD:
{ {
hddLog(LOG1, "QCASAP_GET_TEMP_CMD"); hdd_notice("QCASAP_GET_TEMP_CMD");
ret = wlan_hdd_get_temperature(pHostapdAdapter, value); ret = wlan_hdd_get_temperature(pHostapdAdapter, value);
break; break;
} }
case QCSAP_GET_FW_PROFILE_DATA: case QCSAP_GET_FW_PROFILE_DATA:
hddLog(LOG1, "QCSAP_GET_FW_PROFILE_DATA"); hdd_notice("QCSAP_GET_FW_PROFILE_DATA");
ret = wma_cli_set_command(pHostapdAdapter->sessionId, ret = wma_cli_set_command(pHostapdAdapter->sessionId,
WMI_WLAN_PROFILE_GET_PROFILE_DATA_CMDID, WMI_WLAN_PROFILE_GET_PROFILE_DATA_CMDID,
0, DBG_CMD); 0, DBG_CMD);
break; break;
default: default:
hddLog(LOGE, FL("Invalid getparam command %d"), sub_cmd); hdd_err("Invalid getparam command %d", sub_cmd);
ret = -EINVAL; ret = -EINVAL;
break; break;
@@ -3268,8 +3265,7 @@ int __iw_softap_modify_acl(struct net_device *dev,
#ifndef WLAN_FEATURE_MBSSID #ifndef WLAN_FEATURE_MBSSID
cds_ctx = hdd_ctx->pcds_context; cds_ctx = hdd_ctx->pcds_context;
if (NULL == cds_ctx) { if (NULL == cds_ctx) {
QDF_TRACE(QDF_MODULE_ID_HDD, QDF_TRACE_LEVEL_ERROR, hdd_err("Vos Context is NULL");
"%s: Vos Context is NULL", __func__);
return -EINVAL; return -EINVAL;
} }
#endif #endif
@@ -3281,7 +3277,7 @@ int __iw_softap_modify_acl(struct net_device *dev,
i++; i++;
cmd = (int)(*(value + i)); cmd = (int)(*(value + i));
hddLog(LOG1, FL("Modify ACL mac:" MAC_ADDRESS_STR " type: %d cmd: %d"), hdd_notice("Modify ACL mac:" MAC_ADDRESS_STR " type: %d cmd: %d",
MAC_ADDR_ARRAY(pPeerStaMac), listType, cmd); MAC_ADDR_ARRAY(pPeerStaMac), listType, cmd);
#ifdef WLAN_FEATURE_MBSSID #ifdef WLAN_FEATURE_MBSSID
@@ -3295,7 +3291,7 @@ int __iw_softap_modify_acl(struct net_device *dev,
(eSapACLType) listType, (eSapACLCmdType) cmd); (eSapACLType) listType, (eSapACLCmdType) cmd);
#endif #endif
if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { if (!QDF_IS_STATUS_SUCCESS(qdf_status)) {
hddLog(LOGE, FL("Modify ACL failed")); hdd_err("Modify ACL failed");
ret = -EIO; ret = -EIO;
} }
EXIT(); EXIT();
@@ -3386,7 +3382,7 @@ static __iw_softap_set_max_tx_power(struct net_device *dev,
set_value = value[0]; set_value = value[0];
if (QDF_STATUS_SUCCESS != if (QDF_STATUS_SUCCESS !=
sme_set_max_tx_power(hHal, bssid, selfMac, set_value)) { sme_set_max_tx_power(hHal, bssid, selfMac, set_value)) {
hddLog(LOGE, FL("Setting maximum tx power failed")); hdd_err("Setting maximum tx power failed");
return -EIO; return -EIO;
} }
EXIT(); EXIT();
@@ -3436,7 +3432,7 @@ static __iw_softap_set_tx_power(struct net_device *dev,
if (QDF_STATUS_SUCCESS != if (QDF_STATUS_SUCCESS !=
sme_set_tx_power(hHal, pHostapdAdapter->sessionId, bssid, sme_set_tx_power(hHal, pHostapdAdapter->sessionId, bssid,
pHostapdAdapter->device_mode, set_value)) { pHostapdAdapter->device_mode, set_value)) {
hddLog(LOGE, FL("Setting tx power failed")); hdd_err("Setting tx power failed");
return -EIO; return -EIO;
} }
EXIT(); EXIT();
@@ -3498,14 +3494,14 @@ static __iw_softap_getassoc_stamacaddr(struct net_device *dev,
/* make sure userspace allocated a reasonable buffer size */ /* make sure userspace allocated a reasonable buffer size */
if (wrqu->data.length < sizeof(maclist_index)) { if (wrqu->data.length < sizeof(maclist_index)) {
hddLog(LOG1, FL("invalid userspace buffer")); hdd_notice("invalid userspace buffer");
return -EINVAL; return -EINVAL;
} }
/* allocate local buffer to build the response */ /* allocate local buffer to build the response */
buf = kmalloc(wrqu->data.length, GFP_KERNEL); buf = kmalloc(wrqu->data.length, GFP_KERNEL);
if (!buf) { if (!buf) {
hddLog(LOG1, FL("failed to allocate response buffer")); hdd_notice("failed to allocate response buffer");
return -ENOMEM; return -ENOMEM;
} }
@@ -3529,7 +3525,7 @@ static __iw_softap_getassoc_stamacaddr(struct net_device *dev,
*((u32 *) buf) = maclist_index; *((u32 *) buf) = maclist_index;
wrqu->data.length = maclist_index; wrqu->data.length = maclist_index;
if (copy_to_user(wrqu->data.pointer, buf, maclist_index)) { if (copy_to_user(wrqu->data.pointer, buf, maclist_index)) {
hddLog(LOG1, FL("failed to copy response to user buffer")); hdd_notice("failed to copy response to user buffer");
ret = -EFAULT; ret = -EFAULT;
} }
kfree(buf); kfree(buf);
@@ -3577,8 +3573,7 @@ static __iw_softap_disassoc_sta(struct net_device *dev,
ENTER_DEV(dev); ENTER_DEV(dev);
if (!capable(CAP_NET_ADMIN)) { if (!capable(CAP_NET_ADMIN)) {
QDF_TRACE(QDF_MODULE_ID_HDD, QDF_TRACE_LEVEL_ERROR, hdd_err("permission check failed");
FL("permission check failed"));
return -EPERM; return -EPERM;
} }
@@ -3592,7 +3587,7 @@ static __iw_softap_disassoc_sta(struct net_device *dev,
*/ */
peerMacAddr = (uint8_t *) (extra); peerMacAddr = (uint8_t *) (extra);
hddLog(LOG1, FL("data " MAC_ADDRESS_STR), hdd_notice("data " MAC_ADDRESS_STR,
MAC_ADDR_ARRAY(peerMacAddr)); MAC_ADDR_ARRAY(peerMacAddr));
hdd_softap_sta_disassoc(pHostapdAdapter, peerMacAddr); hdd_softap_sta_disassoc(pHostapdAdapter, peerMacAddr);
EXIT(); EXIT();
@@ -3677,7 +3672,7 @@ static int wlan_hdd_set_force_acs_ch_range(struct net_device *dev,
ENTER_DEV(dev); ENTER_DEV(dev);
if (!capable(CAP_NET_ADMIN)) { if (!capable(CAP_NET_ADMIN)) {
hddLog(LOGE, FL("permission check failed")); hdd_err("permission check failed");
return -EPERM; return -EPERM;
} }
@@ -3728,7 +3723,7 @@ static int __iw_softap_get_channel_list(struct net_device *dev,
return ret; return ret;
if (QDF_STATUS_SUCCESS != sme_get_freq_band(hHal, &curBand)) { if (QDF_STATUS_SUCCESS != sme_get_freq_band(hHal, &curBand)) {
hddLog(LOGE, FL("not able get the current frequency band")); hdd_err("not able get the current frequency band");
return -EIO; return -EIO;
} }
wrqu->data.length = sizeof(tChannelListInfo); wrqu->data.length = sizeof(tChannelListInfo);
@@ -3741,7 +3736,7 @@ static int __iw_softap_get_channel_list(struct net_device *dev,
bandEndChannel = CHAN_ENUM_184; bandEndChannel = CHAN_ENUM_184;
} }
hddLog(LOG1, FL("curBand = %d, StartChannel = %hu, EndChannel = %hu "), hdd_notice("curBand = %d, StartChannel = %hu, EndChannel = %hu ",
curBand, bandStartChannel, bandEndChannel); curBand, bandStartChannel, bandEndChannel);
for (i = bandStartChannel; i <= bandEndChannel; i++) { for (i = bandStartChannel; i <= bandEndChannel; i++) {
@@ -3753,7 +3748,7 @@ static int __iw_softap_get_channel_list(struct net_device *dev,
} }
} }
hddLog(LOG1, FL(" number of channels %d"), num_channels); hdd_notice(" number of channels %d", num_channels);
if (num_channels > IW_MAX_FREQUENCIES) { if (num_channels > IW_MAX_FREQUENCIES) {
num_channels = IW_MAX_FREQUENCIES; num_channels = IW_MAX_FREQUENCIES;
@@ -3803,8 +3798,7 @@ int __iw_get_genie(struct net_device *dev,
#ifndef WLAN_FEATURE_MBSSID #ifndef WLAN_FEATURE_MBSSID
cds_ctx = hdd_ctx->pcds_context; cds_ctx = hdd_ctx->pcds_context;
if (NULL == cds_ctx) { if (NULL == cds_ctx) {
QDF_TRACE(QDF_MODULE_ID_HDD, QDF_TRACE_LEVEL_ERROR, hdd_err("vos context is not valid ");
"%s: vos context is not valid ", __func__);
return -EINVAL; return -EINVAL;
} }
#endif #endif
@@ -3825,15 +3819,15 @@ int __iw_get_genie(struct net_device *dev,
length = QDF_MIN(length, DOT11F_IE_RSN_MAX_LEN); length = QDF_MIN(length, DOT11F_IE_RSN_MAX_LEN);
if (wrqu->data.length < length || if (wrqu->data.length < length ||
copy_to_user(wrqu->data.pointer, (void *)genIeBytes, length)) { copy_to_user(wrqu->data.pointer, (void *)genIeBytes, length)) {
hddLog(LOG1, FL("failed to copy data to user buffer")); hdd_notice("failed to copy data to user buffer");
return -EFAULT; return -EFAULT;
} }
wrqu->data.length = length; wrqu->data.length = length;
hddLog(LOG1, FL(" RSN IE of %d bytes returned"), hdd_notice(" RSN IE of %d bytes returned",
wrqu->data.length); wrqu->data.length);
} else { } else {
wrqu->data.length = 0; wrqu->data.length = 0;
hddLog(LOG1, FL(" RSN IE failed to populate")); hdd_notice(" RSN IE failed to populate");
} }
EXIT(); EXIT();
@@ -3872,7 +3866,7 @@ int __iw_get_wpspbc_probe_req_ies(struct net_device *dev,
if (0 != ret) if (0 != ret)
return ret; return ret;
hddLog(LOG1, FL("get_WPSPBCProbeReqIEs ioctl")); hdd_notice("get_WPSPBCProbeReqIEs ioctl");
memset((void *)&WPSPBCProbeReqIEs, 0, sizeof(WPSPBCProbeReqIEs)); memset((void *)&WPSPBCProbeReqIEs, 0, sizeof(WPSPBCProbeReqIEs));
WPSPBCProbeReqIEs.probeReqIELen = WPSPBCProbeReqIEs.probeReqIELen =
@@ -3885,7 +3879,7 @@ int __iw_get_wpspbc_probe_req_ies(struct net_device *dev,
if (copy_to_user(wrqu->data.pointer, if (copy_to_user(wrqu->data.pointer,
(void *)&WPSPBCProbeReqIEs, (void *)&WPSPBCProbeReqIEs,
sizeof(WPSPBCProbeReqIEs))) { sizeof(WPSPBCProbeReqIEs))) {
hddLog(LOG1, FL("failed to copy data to user buffer")); hdd_notice("failed to copy data to user buffer");
return -EFAULT; return -EFAULT;
} }
wrqu->data.length = 12 + WPSPBCProbeReqIEs.probeReqIELen; wrqu->data.length = 12 + WPSPBCProbeReqIEs.probeReqIELen;
@@ -3941,13 +3935,13 @@ int __iw_set_auth_hostap(struct net_device *dev, struct iw_request_info *info,
case IW_AUTH_TKIP_COUNTERMEASURES: case IW_AUTH_TKIP_COUNTERMEASURES:
{ {
if (wrqu->param.value) { if (wrqu->param.value) {
hddLog(LOG2, hdd_info("Counter Measure started %d",
"Counter Measure started %d", wrqu->param.value); wrqu->param.value);
pWextState->mTKIPCounterMeasures = pWextState->mTKIPCounterMeasures =
TKIP_COUNTER_MEASURE_STARTED; TKIP_COUNTER_MEASURE_STARTED;
} else { } else {
hddLog(LOG2, hdd_info("Counter Measure stopped=%d",
"Counter Measure stopped=%d", wrqu->param.value); wrqu->param.value);
pWextState->mTKIPCounterMeasures = pWextState->mTKIPCounterMeasures =
TKIP_COUNTER_MEASURE_STOPED; TKIP_COUNTER_MEASURE_STOPED;
} }
@@ -3960,7 +3954,7 @@ int __iw_set_auth_hostap(struct net_device *dev, struct iw_request_info *info,
default: default:
hddLog(LOGW, FL("called with unsupported auth type %d"), hdd_warn("called with unsupported auth type %d",
wrqu->param.flags & IW_AUTH_INDEX); wrqu->param.flags & IW_AUTH_INDEX);
break; break;
} }
@@ -4032,8 +4026,7 @@ static int __iw_set_ap_encodeext(struct net_device *dev,
#ifndef WLAN_FEATURE_MBSSID #ifndef WLAN_FEATURE_MBSSID
cds_ctx = hdd_ctx->pcds_context; cds_ctx = hdd_ctx->pcds_context;
if (NULL == cds_ctx) { if (NULL == cds_ctx) {
QDF_TRACE(QDF_MODULE_ID_HDD, QDF_TRACE_LEVEL_ERROR, hdd_err("pVosContext is NULL");
"%s: pVosContext is NULL", __func__);
return -EINVAL; return -EINVAL;
} }
#endif #endif
@@ -4085,7 +4078,7 @@ static int __iw_set_ap_encodeext(struct net_device *dev,
(ext->key_len == (ext->key_len ==
5) ? eCSR_ENCRYPT_TYPE_WEP40 : eCSR_ENCRYPT_TYPE_WEP104; 5) ? eCSR_ENCRYPT_TYPE_WEP40 : eCSR_ENCRYPT_TYPE_WEP104;
pHddApCtx->uPrivacy = 1; pHddApCtx->uPrivacy = 1;
hddLog(LOG1, FL("uPrivacy=%d"), pHddApCtx->uPrivacy); hdd_notice("uPrivacy=%d", pHddApCtx->uPrivacy);
break; break;
case IW_ENCODE_ALG_TKIP: case IW_ENCODE_ALG_TKIP:
@@ -4132,10 +4125,10 @@ static int __iw_set_ap_encodeext(struct net_device *dev,
break; break;
} }
hddLog(LOG1, FL(":EncryptionType:%d key_len:%d, KeyId:%d"), hdd_notice(":EncryptionType:%d key_len:%d, KeyId:%d",
setKey.encType, setKey.keyLength, setKey.keyId); setKey.encType, setKey.keyLength, setKey.keyId);
for (i = 0; i < ext->key_len; i++) for (i = 0; i < ext->key_len; i++)
hddLog(LOG1, "%02x", setKey.Key[i]); hdd_notice("%02x", setKey.Key[i]);
#ifdef WLAN_FEATURE_MBSSID #ifdef WLAN_FEATURE_MBSSID
vstatus = vstatus =
@@ -4146,7 +4139,7 @@ static int __iw_set_ap_encodeext(struct net_device *dev,
#endif #endif
if (vstatus != QDF_STATUS_SUCCESS) { if (vstatus != QDF_STATUS_SUCCESS) {
hddLog(LOGE, FL("wlansap_set_key_sta failed, status= %d"), hdd_err("wlansap_set_key_sta failed, status= %d",
vstatus); vstatus);
ret = -EINVAL; ret = -EINVAL;
} }
@@ -4481,8 +4474,7 @@ __iw_softap_setwpsie(struct net_device *dev,
ENTER_DEV(dev); ENTER_DEV(dev);
if (!capable(CAP_NET_ADMIN)) { if (!capable(CAP_NET_ADMIN)) {
QDF_TRACE(QDF_MODULE_ID_HDD, QDF_TRACE_LEVEL_ERROR, hdd_err("permission check failed");
FL("permission check failed"));
return -EPERM; return -EPERM;
} }
@@ -4494,8 +4486,7 @@ __iw_softap_setwpsie(struct net_device *dev,
#ifndef WLAN_FEATURE_MBSSID #ifndef WLAN_FEATURE_MBSSID
cds_ctx = hdd_ctx->pcds_context; cds_ctx = hdd_ctx->pcds_context;
if (NULL == cds_ctx) { if (NULL == cds_ctx) {
QDF_TRACE(QDF_MODULE_ID_HDD, QDF_TRACE_LEVEL_ERROR, hdd_err("HDD context is not valid ");
"%s: HDD context is not valid ", __func__);
return -EINVAL; return -EINVAL;
} }
#endif #endif
@@ -4514,7 +4505,7 @@ __iw_softap_setwpsie(struct net_device *dev,
s_priv_data.length); s_priv_data.length);
if (NULL == wps_genie) { if (NULL == wps_genie) {
hddLog(LOG1, FL("failed to alloc mem and copy data")); hdd_notice("failed to alloc mem and copy data");
return -EFAULT; return -EFAULT;
} }
@@ -4522,13 +4513,13 @@ __iw_softap_setwpsie(struct net_device *dev,
pSap_WPSIe = qdf_mem_malloc(sizeof(tSap_WPSIE)); pSap_WPSIe = qdf_mem_malloc(sizeof(tSap_WPSIE));
if (NULL == pSap_WPSIe) { if (NULL == pSap_WPSIe) {
hddLog(LOGE, "QDF unable to allocate memory"); hdd_err("QDF unable to allocate memory");
kfree(fwps_genie); kfree(fwps_genie);
return -ENOMEM; return -ENOMEM;
} }
qdf_mem_zero(pSap_WPSIe, sizeof(tSap_WPSIE)); qdf_mem_zero(pSap_WPSIe, sizeof(tSap_WPSIE));
hddLog(LOG1, FL("WPS IE type[0x%X] IE[0x%X], LEN[%d]"), hdd_notice("WPS IE type[0x%X] IE[0x%X], LEN[%d]",
wps_genie[0], wps_genie[1], wps_genie[2]); wps_genie[0], wps_genie[1], wps_genie[2]);
WPSIeType = wps_genie[0]; WPSIeType = wps_genie[0];
if (wps_genie[0] == eQC_WPS_BEACON_IE) { if (wps_genie[0] == eQC_WPS_BEACON_IE) {
@@ -4541,7 +4532,7 @@ __iw_softap_setwpsie(struct net_device *dev,
goto exit; goto exit;
} else if (memcmp(&wps_genie[2], } else if (memcmp(&wps_genie[2],
"\x00\x50\xf2\x04", 4) == 0) { "\x00\x50\xf2\x04", 4) == 0) {
hddLog(LOG1, FL("Set WPS BEACON IE(len %d)"), hdd_notice("Set WPS BEACON IE(len %d)",
wps_genie[1] + 2); wps_genie[1] + 2);
pos = &wps_genie[6]; pos = &wps_genie[6];
while (((size_t) pos - while (((size_t) pos -
@@ -4554,7 +4545,7 @@ __iw_softap_setwpsie(struct net_device *dev,
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSBeaconIE.Version = sapWPSBeaconIE.Version =
*pos; *pos;
hddLog(LOG1, "WPS version %d", hdd_notice("WPS version %d",
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSBeaconIE.Version); sapWPSBeaconIE.Version);
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
@@ -4569,7 +4560,7 @@ __iw_softap_setwpsie(struct net_device *dev,
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSBeaconIE.wpsState = sapWPSBeaconIE.wpsState =
*pos; *pos;
hddLog(LOG1, "WPS State %d", hdd_notice("WPS State %d",
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSBeaconIE.wpsState); sapWPSBeaconIE.wpsState);
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
@@ -4583,7 +4574,7 @@ __iw_softap_setwpsie(struct net_device *dev,
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSBeaconIE. sapWPSBeaconIE.
APSetupLocked = *pos; APSetupLocked = *pos;
hddLog(LOG1, "AP setup lock %d", hdd_notice("AP setup lock %d",
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSBeaconIE. sapWPSBeaconIE.
APSetupLocked); APSetupLocked);
@@ -4598,8 +4589,7 @@ __iw_softap_setwpsie(struct net_device *dev,
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSBeaconIE. sapWPSBeaconIE.
SelectedRegistra = *pos; SelectedRegistra = *pos;
hddLog(LOG1, hdd_notice("Selected Registra %d",
"Selected Registra %d",
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSBeaconIE. sapWPSBeaconIE.
SelectedRegistra); SelectedRegistra);
@@ -4615,7 +4605,7 @@ __iw_softap_setwpsie(struct net_device *dev,
sapWPSBeaconIE. sapWPSBeaconIE.
DevicePasswordID = DevicePasswordID =
(*pos << 8) | *(pos + 1); (*pos << 8) | *(pos + 1);
hddLog(LOG1, "Password ID: %x", hdd_notice("Password ID: %x",
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSBeaconIE. sapWPSBeaconIE.
DevicePasswordID); DevicePasswordID);
@@ -4632,8 +4622,7 @@ __iw_softap_setwpsie(struct net_device *dev,
sapWPSBeaconIE. sapWPSBeaconIE.
SelectedRegistraCfgMethod = SelectedRegistraCfgMethod =
(*pos << 8) | *(pos + 1); (*pos << 8) | *(pos + 1);
hddLog(LOG1, hdd_notice("Select Registra Config Methods: %x",
"Select Registra Config Methods: %x",
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSBeaconIE. sapWPSBeaconIE.
SelectedRegistraCfgMethod); SelectedRegistraCfgMethod);
@@ -4670,7 +4659,7 @@ __iw_softap_setwpsie(struct net_device *dev,
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSBeaconIE.RFBand = sapWPSBeaconIE.RFBand =
*pos; *pos;
hddLog(LOG1, "RF band: %d", hdd_notice("RF band: %d",
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSBeaconIE.RFBand); sapWPSBeaconIE.RFBand);
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
@@ -4681,8 +4670,7 @@ __iw_softap_setwpsie(struct net_device *dev,
break; break;
default: default:
hddLog(LOGW, hdd_warn("UNKNOWN TLV in WPS IE(%x)",
"UNKNOWN TLV in WPS IE(%x)",
(*pos << 8 | (*pos << 8 |
*(pos + 1))); *(pos + 1)));
ret = -EINVAL; ret = -EINVAL;
@@ -4690,13 +4678,13 @@ __iw_softap_setwpsie(struct net_device *dev,
} }
} }
} else { } else {
hddLog(LOGE, FL("WPS IE Mismatch %X"), hdd_err("WPS IE Mismatch %X",
wps_genie[0]); wps_genie[0]);
} }
break; break;
default: default:
hddLog(LOGE, FL("Set UNKNOWN IE %X"), wps_genie[0]); hdd_err("Set UNKNOWN IE %X", wps_genie[0]);
ret = -EINVAL; ret = -EINVAL;
goto exit; goto exit;
} }
@@ -4710,7 +4698,7 @@ __iw_softap_setwpsie(struct net_device *dev,
goto exit; goto exit;
} else if (memcmp(&wps_genie[2], "\x00\x50\xf2\x04", 4) } else if (memcmp(&wps_genie[2], "\x00\x50\xf2\x04", 4)
== 0) { == 0) {
hddLog(LOG1, FL("Set WPS PROBE RSP IE(len %d)"), hdd_notice("Set WPS PROBE RSP IE(len %d)",
wps_genie[1] + 2); wps_genie[1] + 2);
pos = &wps_genie[6]; pos = &wps_genie[6];
while (((size_t) pos - while (((size_t) pos -
@@ -4723,7 +4711,7 @@ __iw_softap_setwpsie(struct net_device *dev,
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSProbeRspIE.Version = sapWPSProbeRspIE.Version =
*pos; *pos;
hddLog(LOG1, "WPS version %d", hdd_notice("WPS version %d",
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSProbeRspIE. sapWPSProbeRspIE.
Version); Version);
@@ -4739,7 +4727,7 @@ __iw_softap_setwpsie(struct net_device *dev,
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSProbeRspIE.wpsState = sapWPSProbeRspIE.wpsState =
*pos; *pos;
hddLog(LOG1, "WPS State %d", hdd_notice("WPS State %d",
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSProbeRspIE. sapWPSProbeRspIE.
wpsState); wpsState);
@@ -4754,7 +4742,7 @@ __iw_softap_setwpsie(struct net_device *dev,
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSProbeRspIE. sapWPSProbeRspIE.
APSetupLocked = *pos; APSetupLocked = *pos;
hddLog(LOG1, "AP setup lock %d", hdd_notice("AP setup lock %d",
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSProbeRspIE. sapWPSProbeRspIE.
APSetupLocked); APSetupLocked);
@@ -4769,8 +4757,7 @@ __iw_softap_setwpsie(struct net_device *dev,
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSProbeRspIE. sapWPSProbeRspIE.
SelectedRegistra = *pos; SelectedRegistra = *pos;
hddLog(LOG1, hdd_notice("Selected Registra %d",
"Selected Registra %d",
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSProbeRspIE. sapWPSProbeRspIE.
SelectedRegistra); SelectedRegistra);
@@ -4786,7 +4773,7 @@ __iw_softap_setwpsie(struct net_device *dev,
sapWPSProbeRspIE. sapWPSProbeRspIE.
DevicePasswordID = DevicePasswordID =
(*pos << 8) | *(pos + 1); (*pos << 8) | *(pos + 1);
hddLog(LOG1, "Password ID: %d", hdd_notice("Password ID: %d",
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSProbeRspIE. sapWPSProbeRspIE.
DevicePasswordID); DevicePasswordID);
@@ -4803,8 +4790,7 @@ __iw_softap_setwpsie(struct net_device *dev,
sapWPSProbeRspIE. sapWPSProbeRspIE.
SelectedRegistraCfgMethod = SelectedRegistraCfgMethod =
(*pos << 8) | *(pos + 1); (*pos << 8) | *(pos + 1);
hddLog(LOG1, hdd_notice("Select Registra Config Methods: %x",
"Select Registra Config Methods: %x",
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSProbeRspIE. sapWPSProbeRspIE.
SelectedRegistraCfgMethod); SelectedRegistraCfgMethod);
@@ -4819,8 +4805,7 @@ __iw_softap_setwpsie(struct net_device *dev,
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSProbeRspIE. sapWPSProbeRspIE.
ResponseType = *pos; ResponseType = *pos;
hddLog(LOG1, hdd_notice("Config Methods: %d",
"Config Methods: %d",
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSProbeRspIE. sapWPSProbeRspIE.
ResponseType); ResponseType);
@@ -4958,8 +4943,7 @@ __iw_softap_setwpsie(struct net_device *dev,
sapWPSProbeRspIE. sapWPSProbeRspIE.
PrimaryDeviceCategory = PrimaryDeviceCategory =
(*pos << 8 | *(pos + 1)); (*pos << 8 | *(pos + 1));
hddLog(LOG1, hdd_notice("primary dev category: %d",
"primary dev category: %d",
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSProbeRspIE. sapWPSProbeRspIE.
PrimaryDeviceCategory); PrimaryDeviceCategory);
@@ -4971,8 +4955,7 @@ __iw_softap_setwpsie(struct net_device *dev,
PrimaryDeviceOUI, PrimaryDeviceOUI,
pos, pos,
HDD_WPS_DEVICE_OUI_LEN); HDD_WPS_DEVICE_OUI_LEN);
hddLog(LOG1, hdd_notice("primary dev oui: %02x, %02x, %02x, %02x",
"primary dev oui: %02x, %02x, %02x, %02x",
pos[0], pos[1], pos[2], pos[0], pos[1], pos[2],
pos[3]); pos[3]);
pos += 4; pos += 4;
@@ -4980,8 +4963,7 @@ __iw_softap_setwpsie(struct net_device *dev,
sapWPSProbeRspIE. sapWPSProbeRspIE.
DeviceSubCategory = DeviceSubCategory =
(*pos << 8 | *(pos + 1)); (*pos << 8 | *(pos + 1));
hddLog(LOG1, hdd_notice("primary dev sub category: %d",
"primary dev sub category: %d",
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSProbeRspIE. sapWPSProbeRspIE.
DeviceSubCategory); DeviceSubCategory);
@@ -5021,8 +5003,7 @@ __iw_softap_setwpsie(struct net_device *dev,
sapWPSProbeRspIE. sapWPSProbeRspIE.
ConfigMethod = ConfigMethod =
(*pos << 8) | *(pos + 1); (*pos << 8) | *(pos + 1);
hddLog(LOG1, hdd_notice("Config Methods: %d",
"Config Methods: %d",
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSProbeRspIE. sapWPSProbeRspIE.
SelectedRegistraCfgMethod); SelectedRegistraCfgMethod);
@@ -5038,7 +5019,7 @@ __iw_softap_setwpsie(struct net_device *dev,
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSProbeRspIE.RFBand = sapWPSProbeRspIE.RFBand =
*pos; *pos;
hddLog(LOG1, "RF band: %d", hdd_notice("RF band: %d",
pSap_WPSIe->sapwpsie. pSap_WPSIe->sapwpsie.
sapWPSProbeRspIE.RFBand); sapWPSProbeRspIE.RFBand);
pos += 1; pos += 1;
@@ -5050,8 +5031,7 @@ __iw_softap_setwpsie(struct net_device *dev,
} /* switch */ } /* switch */
} }
} else { } else {
hddLog(LOGE, hdd_err("WPS IE Mismatch %X", wps_genie[0]);
FL("WPS IE Mismatch %X"), wps_genie[0]);
} }
} /* switch */ } /* switch */