Commit a7cf7bae authored by Moritz Muehlenhoff's avatar Moritz Muehlenhoff Committed by Greg Kroah-Hartman

Staging: wlan-ng: Replace WLAN_LOG_DEBUG() with printk(KERN_DEBUG

Signed-off-by: default avatarMoritz Muehlenhoff <jmm@debian.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 16910554
This diff is collapsed.
......@@ -129,12 +129,12 @@ int skb_ether_to_p80211( wlandevice_t *wlandev, u32 ethconv, struct sk_buff *skb
memcpy(&e_hdr, skb->data, sizeof(e_hdr));
if (skb->len <= 0) {
WLAN_LOG_DEBUG(1, "zero-length skb!\n");
pr_debug("zero-length skb!\n");
return 1;
}
if ( ethconv == WLAN_ETHCONV_ENCAP ) { /* simplest case */
WLAN_LOG_DEBUG(3, "ENCAP len: %d\n", skb->len);
pr_debug("ENCAP len: %d\n", skb->len);
/* here, we don't care what kind of ether frm. Just stick it */
/* in the 80211 payload */
/* which is to say, leave the skb alone. */
......@@ -142,7 +142,7 @@ int skb_ether_to_p80211( wlandevice_t *wlandev, u32 ethconv, struct sk_buff *skb
/* step 1: classify ether frame, DIX or 802.3? */
proto = ntohs(e_hdr.type);
if ( proto <= 1500 ) {
WLAN_LOG_DEBUG(3, "802.3 len: %d\n", skb->len);
pr_debug("802.3 len: %d\n", skb->len);
/* codes <= 1500 reserved for 802.3 lengths */
/* it's 802.3, pass ether payload unchanged, */
......@@ -152,7 +152,7 @@ int skb_ether_to_p80211( wlandevice_t *wlandev, u32 ethconv, struct sk_buff *skb
/* leave off any PAD octets. */
skb_trim(skb, proto);
} else {
WLAN_LOG_DEBUG(3, "DIXII len: %d\n", skb->len);
pr_debug("DIXII len: %d\n", skb->len);
/* it's DIXII, time for some conversion */
/* trim off ethernet header */
......@@ -327,7 +327,7 @@ int skb_p80211_to_ether( wlandevice_t *wlandev, u32 ethconv, struct sk_buff *skb
skb->data + payload_offset,
skb->data + payload_offset + payload_length - 4))) {
/* de-wep failed, drop skb. */
WLAN_LOG_DEBUG(1, "Host de-WEP failed, dropping frame (%d).\n", foo);
pr_debug("Host de-WEP failed, dropping frame (%d).\n", foo);
wlandev->rx.decrypt_err++;
return 2;
}
......@@ -352,7 +352,7 @@ int skb_p80211_to_ether( wlandevice_t *wlandev, u32 ethconv, struct sk_buff *skb
( e_llc->dsap != 0xaa || e_llc->ssap != 0xaa ) &&
((memcmp(daddr, e_hdr->daddr, WLAN_ETHADDR_LEN) == 0) ||
(memcmp(saddr, e_hdr->saddr, WLAN_ETHADDR_LEN) == 0))) {
WLAN_LOG_DEBUG(3, "802.3 ENCAP len: %d\n", payload_length);
pr_debug("802.3 ENCAP len: %d\n", payload_length);
/* 802.3 Encapsulated */
/* Test for an overlength frame */
if ( payload_length > (netdev->mtu + WLAN_ETHHDR_LEN)) {
......@@ -377,7 +377,7 @@ int skb_p80211_to_ether( wlandevice_t *wlandev, u32 ethconv, struct sk_buff *skb
(p80211_stt_findproto(le16_to_cpu(e_snap->type)))) ||
(memcmp( e_snap->oui, oui_rfc1042, WLAN_IEEE_OUI_LEN)!=0)))
{
WLAN_LOG_DEBUG(3, "SNAP+RFC1042 len: %d\n", payload_length);
pr_debug("SNAP+RFC1042 len: %d\n", payload_length);
/* it's a SNAP + RFC1042 frame && protocol is in STT */
/* build 802.3 + RFC1042 */
......@@ -406,7 +406,7 @@ int skb_p80211_to_ether( wlandevice_t *wlandev, u32 ethconv, struct sk_buff *skb
(e_llc->dsap == 0xaa) &&
(e_llc->ssap == 0xaa) &&
(e_llc->ctl == 0x03) ) {
WLAN_LOG_DEBUG(3, "802.1h/RFC1042 len: %d\n", payload_length);
pr_debug("802.1h/RFC1042 len: %d\n", payload_length);
/* it's an 802.1h frame || (an RFC1042 && protocol is not in STT) */
/* build a DIXII + RFC894 */
......@@ -440,7 +440,7 @@ int skb_p80211_to_ether( wlandevice_t *wlandev, u32 ethconv, struct sk_buff *skb
/* chop off the 802.11 CRC */
skb_trim(skb, skb->len - WLAN_CRC_LEN);
} else {
WLAN_LOG_DEBUG(3, "NON-ENCAP len: %d\n", payload_length);
pr_debug("NON-ENCAP len: %d\n", payload_length);
/* any NON-ENCAP */
/* it's a generic 80211+LLC or IPX 'Raw 802.3' */
/* build an 802.3 frame */
......@@ -546,17 +546,17 @@ p80211skb_rxmeta_detach(struct sk_buff *skb)
/* Sanity checks */
if ( skb==NULL ) { /* bad skb */
WLAN_LOG_DEBUG(1, "Called w/ null skb.\n");
pr_debug("Called w/ null skb.\n");
goto exit;
}
frmmeta = P80211SKB_FRMMETA(skb);
if ( frmmeta == NULL ) { /* no magic */
WLAN_LOG_DEBUG(1, "Called w/ bad frmmeta magic.\n");
pr_debug("Called w/ bad frmmeta magic.\n");
goto exit;
}
rxmeta = frmmeta->rx;
if ( rxmeta == NULL ) { /* bad meta ptr */
WLAN_LOG_DEBUG(1, "Called w/ bad rxmeta ptr.\n");
pr_debug("Called w/ bad rxmeta ptr.\n");
goto exit;
}
......
......@@ -344,7 +344,7 @@ static void p80211netdev_rx_bh(unsigned long arg)
netif_rx_ni(skb);
continue;
}
WLAN_LOG_DEBUG(1, "p80211_to_ether failed.\n");
pr_debug( "p80211_to_ether failed.\n");
}
}
dev_kfree_skb(skb);
......@@ -392,7 +392,7 @@ static int p80211knetdev_hard_start_xmit( struct sk_buff *skb, netdevice_t *netd
memset(&p80211_wep, 0, sizeof(p80211_metawep_t));
if ( netif_queue_stopped(netdev) ) {
WLAN_LOG_DEBUG(1, "called when queue stopped.\n");
pr_debug("called when queue stopped.\n");
result = 1;
goto failed;
}
......@@ -433,7 +433,7 @@ static int p80211knetdev_hard_start_xmit( struct sk_buff *skb, netdevice_t *netd
} else {
if ( skb_ether_to_p80211(wlandev, wlandev->ethconv, skb, &p80211_hdr, &p80211_wep) != 0 ) {
/* convert failed */
WLAN_LOG_DEBUG(1, "ether_to_80211(%d) failed.\n",
pr_debug("ether_to_80211(%d) failed.\n",
wlandev->ethconv);
result = 1;
goto failed;
......@@ -459,17 +459,17 @@ static int p80211knetdev_hard_start_xmit( struct sk_buff *skb, netdevice_t *netd
result = 0;
} else if ( txresult == 1 ) {
/* success, no more avail */
WLAN_LOG_DEBUG(3, "txframe success, no more bufs\n");
pr_debug("txframe success, no more bufs\n");
/* netdev->tbusy = 1; don't set here, irqhdlr */
/* may have already cleared it */
result = 0;
} else if ( txresult == 2 ) {
/* alloc failure, drop frame */
WLAN_LOG_DEBUG(3, "txframe returned alloc_fail\n");
pr_debug("txframe returned alloc_fail\n");
result = 1;
} else {
/* buffer full or queue busy, drop frame. */
WLAN_LOG_DEBUG(3, "txframe returned full or busy\n");
pr_debug("txframe returned full or busy\n");
result = 1;
}
......@@ -593,7 +593,7 @@ static int p80211knetdev_do_ioctl(netdevice_t *dev, struct ifreq *ifr, int cmd)
wlandevice_t *wlandev = dev->ml_priv;
u8 *msgbuf;
WLAN_LOG_DEBUG(2, "rx'd ioctl, cmd=%d, len=%d\n", cmd, req->len);
pr_debug("rx'd ioctl, cmd=%d, len=%d\n", cmd, req->len);
#ifdef SIOCETHTOOL
if (cmd == SIOCETHTOOL) {
......@@ -992,7 +992,7 @@ static int p80211_rx_typedrop( wlandevice_t *wlandev, u16 fc)
ftype = WLAN_GET_FC_FTYPE(fc);
fstype = WLAN_GET_FC_FSTYPE(fc);
#if 0
WLAN_LOG_DEBUG(4,
pr_debug(
"rx_typedrop : ftype=%d fstype=%d.\n", ftype, fstype);
#endif
switch ( ftype ) {
......@@ -1002,7 +1002,7 @@ static int p80211_rx_typedrop( wlandevice_t *wlandev, u16 fc)
drop = 1;
break;
}
WLAN_LOG_DEBUG(3, "rx'd mgmt:\n");
pr_debug("rx'd mgmt:\n");
wlandev->rx.mgmt++;
switch( fstype ) {
case WLAN_FSTYPE_ASSOCREQ:
......@@ -1064,7 +1064,7 @@ static int p80211_rx_typedrop( wlandevice_t *wlandev, u16 fc)
drop = 1;
break;
}
WLAN_LOG_DEBUG(3, "rx'd ctl:\n");
pr_debug("rx'd ctl:\n");
wlandev->rx.ctl++;
switch( fstype ) {
case WLAN_FSTYPE_PSPOLL:
......@@ -1116,19 +1116,19 @@ static int p80211_rx_typedrop( wlandevice_t *wlandev, u16 fc)
wlandev->rx.data__cfack_cfpoll++;
break;
case WLAN_FSTYPE_NULL:
WLAN_LOG_DEBUG(3, "rx'd data:null\n");
pr_debug("rx'd data:null\n");
wlandev->rx.null++;
break;
case WLAN_FSTYPE_CFACK:
WLAN_LOG_DEBUG(3, "rx'd data:cfack\n");
pr_debug("rx'd data:cfack\n");
wlandev->rx.cfack++;
break;
case WLAN_FSTYPE_CFPOLL:
WLAN_LOG_DEBUG(3, "rx'd data:cfpoll\n");
pr_debug("rx'd data:cfpoll\n");
wlandev->rx.cfpoll++;
break;
case WLAN_FSTYPE_CFACK_CFPOLL:
WLAN_LOG_DEBUG(3, "rx'd data:cfack_cfpoll\n");
pr_debug("rx'd data:cfack_cfpoll\n");
wlandev->rx.cfack_cfpoll++;
break;
default:
......
......@@ -740,9 +740,9 @@ static int p80211wext_siwessid(netdevice_t *dev,
memcpy(msg.ssid.data.data, essid, length);
msg.ssid.data.len = length;
WLAN_LOG_DEBUG(1,"autojoin_ssid for %s \n",essid);
pr_debug("autojoin_ssid for %s \n",essid);
result = p80211req_dorequest(wlandev, (u8*)&msg);
WLAN_LOG_DEBUG(1,"autojoin_ssid %d\n",result);
pr_debug("autojoin_ssid %d\n",result);
if (result) {
err = -EFAULT;
......@@ -1331,12 +1331,12 @@ wext_translate_bss(struct iw_request_info *info, char *current_ev,
size = min_t(unsigned short, IW_ESSID_MAX_SIZE, bss->ssid.data.len);
memset(&essid, 0, sizeof (essid));
memcpy(&essid, bss->ssid.data.data, size);
WLAN_LOG_DEBUG(1, " essid size = %d\n", size);
pr_debug(" essid size = %d\n", size);
iwe.u.data.length = size;
iwe.u.data.flags = 1;
iwe.cmd = SIOCGIWESSID;
current_ev = iwe_stream_add_point(info, current_ev, end_buf, &iwe, &essid[0]);
WLAN_LOG_DEBUG(1, " essid size OK.\n");
pr_debug(" essid size OK.\n");
}
switch (bss->bsstype.data) {
......@@ -1441,7 +1441,7 @@ static int p80211wext_set_encodeext(struct net_device *dev,
struct iw_point *encoding = &wrqu->encoding;
int idx = encoding->flags & IW_ENCODE_INDEX;
WLAN_LOG_DEBUG(1,"set_encode_ext flags[%d] alg[%d] keylen[%d]\n",ext->ext_flags,(int)ext->alg,(int)ext->key_len);
pr_debug("set_encode_ext flags[%d] alg[%d] keylen[%d]\n",ext->ext_flags,(int)ext->alg,(int)ext->key_len);
if ( ext->ext_flags & IW_ENCODE_EXT_GROUP_KEY ) {
......@@ -1453,7 +1453,7 @@ static int p80211wext_set_encodeext(struct net_device *dev,
} else
idx--;
}
WLAN_LOG_DEBUG(1,"setting default key (%d)\n",idx);
pr_debug("setting default key (%d)\n",idx);
result = p80211wext_dorequest(wlandev, DIDmib_dot11smt_dot11PrivacyTable_dot11WEPDefaultKeyID, idx);
if ( result )
return -EFAULT;
......@@ -1462,7 +1462,7 @@ static int p80211wext_set_encodeext(struct net_device *dev,
if ( ext->ext_flags & IW_ENCODE_EXT_SET_TX_KEY ) {
if (!(ext->alg & IW_ENCODE_ALG_WEP)) {
WLAN_LOG_DEBUG(1,"asked to set a non wep key :(");
pr_debug("asked to set a non wep key :(");
return -EINVAL;
}
if (idx) {
......@@ -1471,7 +1471,7 @@ static int p80211wext_set_encodeext(struct net_device *dev,
else
idx--;
}
WLAN_LOG_DEBUG(1,"Set WEP key (%d)\n",idx);
pr_debug("Set WEP key (%d)\n",idx);
wlandev->wep_keylens[idx] = ext->key_len;
memcpy(wlandev->wep_keys[idx], ext->key, ext->key_len);
......@@ -1497,7 +1497,7 @@ static int p80211wext_set_encodeext(struct net_device *dev,
}
msg.msgcode = DIDmsg_dot11req_mibset;
result = p80211req_dorequest(wlandev,(u8*)&msg);
WLAN_LOG_DEBUG(1,"result (%d)\n",result);
pr_debug("result (%d)\n",result);
}
return result;
}
......@@ -1516,22 +1516,22 @@ static int p80211wext_get_encodeext(struct net_device *dev,
int max_len;
int idx;
WLAN_LOG_DEBUG(1,"get_encode_ext flags[%d] alg[%d] keylen[%d]\n",ext->ext_flags,(int)ext->alg,(int)ext->key_len);
pr_debug("get_encode_ext flags[%d] alg[%d] keylen[%d]\n",ext->ext_flags,(int)ext->alg,(int)ext->key_len);
max_len = encoding->length - sizeof(*ext);
if ( max_len <= 0) {
WLAN_LOG_DEBUG(1,"get_encodeext max_len [%d] invalid\n",max_len);
pr_debug("get_encodeext max_len [%d] invalid\n",max_len);
result = -EINVAL;
goto exit;
}
idx = encoding->flags & IW_ENCODE_INDEX;
WLAN_LOG_DEBUG(1,"get_encode_ext index [%d]\n",idx);
pr_debug("get_encode_ext index [%d]\n",idx);
if (idx) {
if (idx < 1 || idx > NUM_WEPKEYS ) {
WLAN_LOG_DEBUG(1,"get_encode_ext invalid key index [%d]\n",idx);
pr_debug("get_encode_ext invalid key index [%d]\n",idx);
result = -EINVAL;
goto exit;
}
......@@ -1563,11 +1563,11 @@ static int p80211_wext_set_iwauth (struct net_device *dev,
struct iw_param *param = &wrqu->param;
int result =0;
WLAN_LOG_DEBUG(1,"set_iwauth flags[%d]\n",(int)param->flags & IW_AUTH_INDEX );
pr_debug("set_iwauth flags[%d]\n",(int)param->flags & IW_AUTH_INDEX );
switch (param->flags & IW_AUTH_INDEX) {
case IW_AUTH_DROP_UNENCRYPTED:
WLAN_LOG_DEBUG(1,"drop_unencrypted %d\n",param->value);
pr_debug("drop_unencrypted %d\n",param->value);
if (param->value)
result = p80211wext_dorequest(wlandev, DIDmib_dot11smt_dot11PrivacyTable_dot11ExcludeUnencrypted, P80211ENUM_truth_true);
else
......@@ -1575,7 +1575,7 @@ static int p80211_wext_set_iwauth (struct net_device *dev,
break;
case IW_AUTH_PRIVACY_INVOKED:
WLAN_LOG_DEBUG(1,"privacy invoked %d\n",param->value);
pr_debug("privacy invoked %d\n",param->value);
if ( param->value)
result = p80211wext_dorequest(wlandev, DIDmib_dot11smt_dot11PrivacyTable_dot11PrivacyInvoked, P80211ENUM_truth_true);
else
......@@ -1585,14 +1585,14 @@ static int p80211_wext_set_iwauth (struct net_device *dev,
case IW_AUTH_80211_AUTH_ALG:
if ( param->value & IW_AUTH_ALG_OPEN_SYSTEM ) {
WLAN_LOG_DEBUG(1,"set open_system\n");
pr_debug("set open_system\n");
wlandev->hostwep &= ~HOSTWEP_SHAREDKEY;
} else if ( param->value & IW_AUTH_ALG_SHARED_KEY) {
WLAN_LOG_DEBUG(1,"set shared key\n");
pr_debug("set shared key\n");
wlandev->hostwep |= HOSTWEP_SHAREDKEY;
} else {
/* don't know what to do know :( */
WLAN_LOG_DEBUG(1,"unknown AUTH_ALG (%d)\n",param->value);
pr_debug("unknown AUTH_ALG (%d)\n",param->value);
result = -EINVAL;
}
break;
......@@ -1615,7 +1615,7 @@ static int p80211_wext_get_iwauth (struct net_device *dev,
struct iw_param *param = &wrqu->param;
int result =0;
WLAN_LOG_DEBUG(1,"get_iwauth flags[%d]\n",(int)param->flags & IW_AUTH_INDEX );
pr_debug("get_iwauth flags[%d]\n",(int)param->flags & IW_AUTH_INDEX );
switch (param->flags & IW_AUTH_INDEX) {
case IW_AUTH_DROP_UNENCRYPTED:
......
......@@ -284,8 +284,6 @@ int prism2mgmt_scan(wlandevice_t *wlandev, void *msgp)
/* Issue the scan request */
hw->scanflag = 0;
WLAN_HEX_DUMP(5,"hscanreq", &scanreq, sizeof(scanreq));
result = hfa384x_drvr_setconfig( hw,
HFA384x_RID_HOSTSCAN, &scanreq,
sizeof(hfa384x_HostScanRequest_data_t));
......@@ -385,7 +383,7 @@ int prism2mgmt_scan_results(wlandevice_t *wlandev, void *msgp)
if (count > 32) count = 32;
if (req->bssindex.data >= count) {
WLAN_LOG_DEBUG(0, "requested index (%d) out of range (%d)\n",
pr_debug("requested index (%d) out of range (%d)\n",
req->bssindex.data, count);
result = 2;
req->resultcode.data = P80211ENUM_resultcode_invalid_parameters;
......@@ -667,7 +665,7 @@ int prism2mgmt_start(wlandevice_t *wlandev, void *msgp)
goto done;
failed:
WLAN_LOG_DEBUG(1, "Failed to set a config option, result=%d\n", result);
pr_debug("Failed to set a config option, result=%d\n", result);
msg->resultcode.data = P80211ENUM_resultcode_invalid_parameters;
done:
......@@ -1108,7 +1106,7 @@ int prism2mgmt_wlansniff(wlandevice_t *wlandev, void *msgp)
/* Disable monitor mode */
result = hfa384x_cmd_monitor(hw, HFA384x_MONITOR_DISABLE);
if ( result ) {
WLAN_LOG_DEBUG(1,
pr_debug(
"failed to disable monitor mode, result=%d\n",
result);
goto failed;
......@@ -1116,7 +1114,7 @@ int prism2mgmt_wlansniff(wlandevice_t *wlandev, void *msgp)
/* Disable port 0 */
result = hfa384x_drvr_disable(hw, 0);
if ( result ) {
WLAN_LOG_DEBUG(1,
pr_debug(
"failed to disable port 0 after sniffing, result=%d\n",
result);
goto failed;
......@@ -1129,7 +1127,7 @@ int prism2mgmt_wlansniff(wlandevice_t *wlandev, void *msgp)
HFA384x_RID_CNFWEPFLAGS,
hw->presniff_wepflags);
if ( result ) {
WLAN_LOG_DEBUG(1,
pr_debug(
"failed to restore wepflags=0x%04x, result=%d\n",
hw->presniff_wepflags,
result);
......@@ -1142,7 +1140,7 @@ int prism2mgmt_wlansniff(wlandevice_t *wlandev, void *msgp)
result = hfa384x_drvr_setconfig16(hw,
HFA384x_RID_CNFPORTTYPE, word);
if ( result ) {
WLAN_LOG_DEBUG(1,
pr_debug(
"failed to restore porttype, result=%d\n",
result);
goto failed;
......@@ -1151,7 +1149,7 @@ int prism2mgmt_wlansniff(wlandevice_t *wlandev, void *msgp)
/* Enable the port */
result = hfa384x_drvr_enable(hw, 0);
if ( result ) {
WLAN_LOG_DEBUG(1, "failed to enable port to presniff setting, result=%d\n", result);
pr_debug("failed to enable port to presniff setting, result=%d\n", result);
goto failed;
}
} else {
......@@ -1173,7 +1171,7 @@ int prism2mgmt_wlansniff(wlandevice_t *wlandev, void *msgp)
HFA384x_RID_CNFPORTTYPE,
&(hw->presniff_port_type));
if ( result ) {
WLAN_LOG_DEBUG(1,"failed to read porttype, result=%d\n", result);
pr_debug("failed to read porttype, result=%d\n", result);
goto failed;
}
/* Save the wepflags state */
......@@ -1181,13 +1179,13 @@ int prism2mgmt_wlansniff(wlandevice_t *wlandev, void *msgp)
HFA384x_RID_CNFWEPFLAGS,
&(hw->presniff_wepflags));
if ( result ) {
WLAN_LOG_DEBUG(1,"failed to read wepflags, result=%d\n", result);
pr_debug("failed to read wepflags, result=%d\n", result);
goto failed;
}
hfa384x_drvr_stop(hw);
result = hfa384x_drvr_start(hw);
if ( result ) {
WLAN_LOG_DEBUG(1,
pr_debug(
"failed to restart the card for sniffing, result=%d\n",
result);
goto failed;
......@@ -1196,7 +1194,7 @@ int prism2mgmt_wlansniff(wlandevice_t *wlandev, void *msgp)
/* Disable the port */
result = hfa384x_drvr_disable(hw, 0);
if ( result ) {
WLAN_LOG_DEBUG(1,
pr_debug(
"failed to enable port for sniffing, result=%d\n",
result);
goto failed;
......@@ -1213,7 +1211,7 @@ int prism2mgmt_wlansniff(wlandevice_t *wlandev, void *msgp)
hw->sniff_channel=word;
if ( result ) {
WLAN_LOG_DEBUG(1,
pr_debug(
"failed to set channel %d, result=%d\n",
word,
result);
......@@ -1227,7 +1225,7 @@ int prism2mgmt_wlansniff(wlandevice_t *wlandev, void *msgp)
result = hfa384x_drvr_setconfig16(hw,
HFA384x_RID_CNFPORTTYPE, word);
if ( result ) {
WLAN_LOG_DEBUG(1,
pr_debug(
"failed to set porttype %d, result=%d\n",
word,
result);
......@@ -1241,7 +1239,7 @@ int prism2mgmt_wlansniff(wlandevice_t *wlandev, void *msgp)
}
if ( result ) {
WLAN_LOG_DEBUG(1,
pr_debug(
"failed to set wepflags=0x%04x, result=%d\n",
word,
result);
......@@ -1266,7 +1264,7 @@ int prism2mgmt_wlansniff(wlandevice_t *wlandev, void *msgp)
/* Enable the port */
result = hfa384x_drvr_enable(hw, 0);
if ( result ) {
WLAN_LOG_DEBUG(1,
pr_debug(
"failed to enable port for sniffing, result=%d\n",
result);
goto failed;
......@@ -1274,7 +1272,7 @@ int prism2mgmt_wlansniff(wlandevice_t *wlandev, void *msgp)
/* Enable monitor mode */
result = hfa384x_cmd_monitor(hw, HFA384x_MONITOR_ENABLE);
if ( result ) {
WLAN_LOG_DEBUG(1,
pr_debug(
"failed to enable monitor mode, result=%d\n",
result);
goto failed;
......
......@@ -366,7 +366,7 @@ int prism2mgmt_mibset_mibget(wlandevice_t *wlandev, void *msgp)
if (msg->resultcode.data == P80211ENUM_resultcode_success) {
if (result != 0) {
WLAN_LOG_DEBUG(1, "get/set failure, result=%d\n",
pr_debug("get/set failure, result=%d\n",
result);
msg->resultcode.data =
P80211ENUM_resultcode_implementation_failure;
......@@ -1067,7 +1067,7 @@ void prism2mgmt_set_oprateset(u16 *rate, p80211pstrd_t *pstr)
*rate |= BIT(3);
break;
default:
WLAN_LOG_DEBUG(1, "Unrecoginzed Rate of %d\n",
pr_debug("Unrecoginzed Rate of %d\n",
*datarate);
break;
}
......
......@@ -65,6 +65,7 @@
#include <linux/netdevice.h>
#include <linux/workqueue.h>
#include <linux/byteorder/generic.h>
#include <linux/ctype.h>
#include <asm/io.h>
#include <linux/delay.h>
......@@ -342,46 +343,46 @@ static int prism2sta_mlmerequest(wlandevice_t *wlandev, p80211msg_t *msg)
switch( msg->msgcode )
{
case DIDmsg_dot11req_mibget :
WLAN_LOG_DEBUG(2,"Received mibget request\n");
pr_debug("Received mibget request\n");
result = prism2mgmt_mibset_mibget(wlandev, msg);
break;
case DIDmsg_dot11req_mibset :
WLAN_LOG_DEBUG(2,"Received mibset request\n");
pr_debug("Received mibset request\n");
result = prism2mgmt_mibset_mibget(wlandev, msg);
break;
case DIDmsg_dot11req_scan :
WLAN_LOG_DEBUG(2,"Received scan request\n");
pr_debug("Received scan request\n");
result = prism2mgmt_scan(wlandev, msg);
break;
case DIDmsg_dot11req_scan_results :
WLAN_LOG_DEBUG(2,"Received scan_results request\n");
pr_debug("Received scan_results request\n");
result = prism2mgmt_scan_results(wlandev, msg);
break;
case DIDmsg_dot11req_start :
WLAN_LOG_DEBUG(2,"Received mlme start request\n");
pr_debug("Received mlme start request\n");
result = prism2mgmt_start(wlandev, msg);
break;
/*
* Prism2 specific messages
*/
case DIDmsg_p2req_readpda :
WLAN_LOG_DEBUG(2,"Received mlme readpda request\n");
pr_debug("Received mlme readpda request\n");
result = prism2mgmt_readpda(wlandev, msg);
break;
case DIDmsg_p2req_ramdl_state :
WLAN_LOG_DEBUG(2,"Received mlme ramdl_state request\n");
pr_debug("Received mlme ramdl_state request\n");
result = prism2mgmt_ramdl_state(wlandev, msg);
break;
case DIDmsg_p2req_ramdl_write :
WLAN_LOG_DEBUG(2,"Received mlme ramdl_write request\n");
pr_debug("Received mlme ramdl_write request\n");
result = prism2mgmt_ramdl_write(wlandev, msg);
break;
case DIDmsg_p2req_flashdl_state :
WLAN_LOG_DEBUG(2,"Received mlme flashdl_state request\n");
pr_debug("Received mlme flashdl_state request\n");
result = prism2mgmt_flashdl_state(wlandev, msg);
break;
case DIDmsg_p2req_flashdl_write :
WLAN_LOG_DEBUG(2,"Received mlme flashdl_write request\n");
pr_debug("Received mlme flashdl_write request\n");
result = prism2mgmt_flashdl_write(wlandev, msg);
break;
/*
......@@ -392,7 +393,7 @@ static int prism2sta_mlmerequest(wlandevice_t *wlandev, p80211msg_t *msg)
case DIDmsg_lnxreq_ifstate :
{
p80211msg_lnxreq_ifstate_t *ifstatemsg;
WLAN_LOG_DEBUG(2,"Received mlme ifstate request\n");
pr_debug("Received mlme ifstate request\n");
ifstatemsg = (p80211msg_lnxreq_ifstate_t*)msg;
result = prism2sta_ifstate(wlandev, ifstatemsg->ifstate.data);
ifstatemsg->resultcode.status =
......@@ -402,17 +403,17 @@ static int prism2sta_mlmerequest(wlandevice_t *wlandev, p80211msg_t *msg)
}
break;
case DIDmsg_lnxreq_wlansniff :
WLAN_LOG_DEBUG(2,"Received mlme wlansniff request\n");
pr_debug("Received mlme wlansniff request\n");
result = prism2mgmt_wlansniff(wlandev, msg);
break;
case DIDmsg_lnxreq_autojoin :
WLAN_LOG_DEBUG(2,"Received mlme autojoin request\n");
pr_debug("Received mlme autojoin request\n");
result = prism2mgmt_autojoin(wlandev, msg);
break;
case DIDmsg_lnxreq_commsquality: {
p80211msg_lnxreq_commsquality_t *qualmsg;
WLAN_LOG_DEBUG(2,"Received commsquality request\n");
pr_debug("Received commsquality request\n");
qualmsg = (p80211msg_lnxreq_commsquality_t*) msg;
......@@ -464,7 +465,7 @@ u32 prism2sta_ifstate(wlandevice_t *wlandev, u32 ifstate)
result = P80211ENUM_resultcode_implementation_failure;
WLAN_LOG_DEBUG(2, "Current MSD state(%d), requesting(%d)\n",
pr_debug("Current MSD state(%d), requesting(%d)\n",
wlandev->msdstate, ifstate);
switch (ifstate)
{
......@@ -1002,7 +1003,7 @@ static int prism2sta_setmulticast(wlandevice_t *wlandev, netdevice_t *dev)
----------------------------------------------------------------*/
static void prism2sta_inf_handover(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf)
{
WLAN_LOG_DEBUG(2,"received infoframe:HANDOVER (unhandled)\n");
pr_debug("received infoframe:HANDOVER (unhandled)\n");
return;
}
......@@ -1089,15 +1090,15 @@ static void prism2sta_inf_scanresults(wlandevice_t *wlandev,
nbss /= sizeof(hfa384x_ScanResultSub_t);
/* Print em */
WLAN_LOG_DEBUG(1,"rx scanresults, reason=%d, nbss=%d:\n",
pr_debug("rx scanresults, reason=%d, nbss=%d:\n",
inf->info.scanresult.scanreason, nbss);
for ( i = 0; i < nbss; i++) {
WLAN_LOG_DEBUG(1, "chid=%d anl=%d sl=%d bcnint=%d\n",
pr_debug("chid=%d anl=%d sl=%d bcnint=%d\n",
sr->result[i].chid,
sr->result[i].anl,
sr->result[i].sl,
sr->result[i].bcnint);
WLAN_LOG_DEBUG(1, " capinfo=0x%04x proberesp_rate=%d\n",
pr_debug(" capinfo=0x%04x proberesp_rate=%d\n",
sr->result[i].capinfo,
sr->result[i].proberesp_rate);
}
......@@ -1138,7 +1139,7 @@ static void prism2sta_inf_hostscanresults(wlandevice_t *wlandev,
int nbss;
nbss = (inf->framelen - 3) / 32;
WLAN_LOG_DEBUG(1, "Received %d hostscan results\n", nbss);
pr_debug("Received %d hostscan results\n", nbss);
if (nbss > 32)
nbss = 32;
......@@ -1191,7 +1192,7 @@ static void prism2sta_inf_chinforesults(wlandevice_t *wlandev,
chinforesult->anl = hfa384x2host_16(inf->info.chinforesult.result[n].anl);
chinforesult->pnl = hfa384x2host_16(inf->info.chinforesult.result[n].pnl);
chinforesult->active = hfa384x2host_16(inf->info.chinforesult.result[n].active);
WLAN_LOG_DEBUG(2, "chinfo: channel %d, %s level (avg/peak)=%d/%d dB, pcf %d\n",
pr_debug("chinfo: channel %d, %s level (avg/peak)=%d/%d dB, pcf %d\n",
channel+1,
chinforesult->active &
HFA384x_CHINFORESULT_BSSACTIVE ? "signal" : "noise",
......@@ -1276,7 +1277,7 @@ void prism2sta_processing_defer(struct work_struct *data)
HFA384x_RID_CURRENTBSSID,
wlandev->bssid, WLAN_BSSID_LEN);
if ( result ) {
WLAN_LOG_DEBUG(1,
pr_debug(
"getconfig(0x%02x) failed, result = %d\n",
HFA384x_RID_CURRENTBSSID, result);
goto failed;
......@@ -1286,7 +1287,7 @@ void prism2sta_processing_defer(struct work_struct *data)
HFA384x_RID_CURRENTSSID,
&ssid, sizeof(ssid));
if ( result ) {
WLAN_LOG_DEBUG(1,
pr_debug(
"getconfig(0x%02x) failed, result = %d\n",
HFA384x_RID_CURRENTSSID, result);
goto failed;
......@@ -1298,7 +1299,7 @@ void prism2sta_processing_defer(struct work_struct *data)
result = hfa384x_drvr_getconfig16(hw,
HFA384x_RID_PORTSTATUS, &portstatus);
if ( result ) {
WLAN_LOG_DEBUG(1,
pr_debug(
"getconfig(0x%02x) failed, result = %d\n",
HFA384x_RID_PORTSTATUS, result);
goto failed;
......@@ -1362,7 +1363,7 @@ void prism2sta_processing_defer(struct work_struct *data)
HFA384x_RID_CURRENTBSSID,
wlandev->bssid, WLAN_BSSID_LEN);
if ( result ) {
WLAN_LOG_DEBUG(1,
pr_debug(
"getconfig(0x%02x) failed, result = %d\n",
HFA384x_RID_CURRENTBSSID, result);
goto failed;
......@@ -1372,7 +1373,7 @@ void prism2sta_processing_defer(struct work_struct *data)
HFA384x_RID_CURRENTSSID,
&ssid, sizeof(ssid));
if ( result ) {
WLAN_LOG_DEBUG(1,
pr_debug(
"getconfig(0x%02x) failed, result = %d\n",
HFA384x_RID_CURRENTSSID, result);
goto failed;
......@@ -1852,7 +1853,7 @@ void prism2sta_ev_info(wlandevice_t *wlandev, hfa384x_InfFrame_t *inf)
----------------------------------------------------------------*/
void prism2sta_ev_txexc(wlandevice_t *wlandev, u16 status)
{
WLAN_LOG_DEBUG(3, "TxExc status=0x%x.\n", status);
pr_debug("TxExc status=0x%x.\n", status);
return;
}
......@@ -1876,7 +1877,7 @@ void prism2sta_ev_txexc(wlandevice_t *wlandev, u16 status)
----------------------------------------------------------------*/
void prism2sta_ev_tx(wlandevice_t *wlandev, u16 status)
{
WLAN_LOG_DEBUG(4, "Tx Complete, status=0x%04x\n", status);
pr_debug("Tx Complete, status=0x%04x\n", status);
/* update linux network stats */
wlandev->linux_stats.tx_packets++;
return;
......@@ -2018,7 +2019,7 @@ void prism2sta_commsqual_defer(struct work_struct *data)
// ASL_currBSS; // level
// qual.ANL_currFC; // noise
WLAN_LOG_DEBUG(3, "commsqual %d %d %d\n",
pr_debug("commsqual %d %d %d\n",
hfa384x2host_16(hw->qual.CQ_currBSS),
hfa384x2host_16(hw->qual.ASL_currBSS),
hfa384x2host_16(hw->qual.ANL_currFC));
......@@ -2029,7 +2030,7 @@ void prism2sta_commsqual_defer(struct work_struct *data)
HFA384x_RID_CURRENTBSSID,
wlandev->bssid, WLAN_BSSID_LEN);
if ( result ) {
WLAN_LOG_DEBUG(1,
pr_debug(
"getconfig(0x%02x) failed, result = %d\n",
HFA384x_RID_CURRENTBSSID, result);
goto done;
......@@ -2039,7 +2040,7 @@ void prism2sta_commsqual_defer(struct work_struct *data)
HFA384x_RID_CURRENTSSID,
&ssid, sizeof(ssid));
if ( result ) {
WLAN_LOG_DEBUG(1,
pr_debug(
"getconfig(0x%02x) failed, result = %d\n",
HFA384x_RID_CURRENTSSID, result);
goto done;
......
......@@ -48,20 +48,4 @@
#ifndef _WLAN_COMPAT_H
#define _WLAN_COMPAT_H
/*=============================================================*/
/*------ OS Portability Macros --------------------------------*/
/*=============================================================*/
#include <linux/hardirq.h>
#include <linux/ctype.h>
#define WLAN_HEX_DUMP( l, s, p, n)
#define WLAN_LOG_DEBUG(l, s, args...)
/*=============================================================*/
/*--- Variables -----------------------------------------------*/
/*=============================================================*/
#endif /* _WLAN_COMPAT_H */
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment