clean up the WLAN_LOG_????n thingeys.
This commit is contained in:
parent
40f3443b7e
commit
9380676de7
1
CHANGES
1
CHANGES
|
@ -42,6 +42,7 @@
|
|||
*
|
||||
* --------------------------------------------------------------------
|
||||
0.1.16
|
||||
- Eliminated most of the WLAN_LOG_???n macros.
|
||||
- Minor fixups in /etc/wlan/shared
|
||||
- Cleaned up some of the error messages in the conversion code.
|
||||
- changed the "Host de-WEP failed" error to a debug message, as the
|
||||
|
|
2
TODO
2
TODO
|
@ -43,7 +43,6 @@
|
|||
* --------------------------------------------------------------------
|
||||
|
||||
Linux WLAN NG TODO
|
||||
- Configure options depend on kernel version/pcmcia stuff/etc?
|
||||
- Make the command-completion interrupt driven vs busywaiting.
|
||||
- Possibly hook up DMA on the Rx side for PCI devices
|
||||
- [USB] Remove driver's port-reset when new primary firmware becomes
|
||||
|
@ -92,6 +91,5 @@ Linux WLAN NG TODO
|
|||
reassociate
|
||||
- Add event handling scripts for the events above
|
||||
- Add AP support for power managing stations
|
||||
- [PCMCIA] Improve PCMCIA event scripts
|
||||
- Add a HOWTO document for users
|
||||
- Add a HOWTO document for programmers
|
||||
|
|
|
@ -97,9 +97,6 @@
|
|||
#define WLAN_HPPAARCH 10
|
||||
#define WLAN_SPARCARCH 11
|
||||
#define WLAN_SHARCH 12
|
||||
/* WLAN_OS */
|
||||
#define WLAN_LINUX_KERNEL 1
|
||||
#define WLAN_LINUX_USER 2
|
||||
/* WLAN_HOSTIF (generally set on the command line, not detected) */
|
||||
#define WLAN_PCMCIA 1
|
||||
#define WLAN_ISA 2
|
||||
|
@ -112,13 +109,6 @@
|
|||
/* isn't a real PCMCIA host interface adapter providing all the */
|
||||
/* card&socket services. */
|
||||
|
||||
/* Lets try to figure out what we've got. Kernel mode or User mode? */
|
||||
#if defined(__KERNEL__)
|
||||
#define WLAN_OS WLAN_LINUX_KERNEL
|
||||
#else
|
||||
#define WLAN_OS WLAN_LINUX_USER
|
||||
#endif
|
||||
|
||||
#ifdef __powerpc__
|
||||
#ifndef __ppc__
|
||||
#define __ppc__
|
||||
|
@ -284,112 +274,41 @@ typedef signed long long INT64;
|
|||
#define WLAN_DBVAR wlan_debug
|
||||
#endif
|
||||
|
||||
#if (WLAN_OS == WLAN_LINUX_KERNEL)
|
||||
#define WLAN_LOG_ERROR0(x) printk(KERN_ERR "%s: " x , __FUNCTION__ );
|
||||
#define WLAN_LOG_ERROR1(x,n) printk(KERN_ERR "%s: " x , __FUNCTION__ , (n));
|
||||
#define WLAN_LOG_ERROR2(x,n1,n2) printk(KERN_ERR "%s: " x , __FUNCTION__ , (n1), (n2));
|
||||
#define WLAN_LOG_ERROR3(x,n1,n2,n3) printk(KERN_ERR "%s: " x , __FUNCTION__, (n1), (n2), (n3));
|
||||
#define WLAN_LOG_ERROR4(x,n1,n2,n3,n4) printk(KERN_ERR "%s: " x , __FUNCTION__, (n1), (n2), (n3), (n4));
|
||||
#define WLAN_LOG_ERROR0(x) printk(KERN_ERR "%s: " x , __FUNCTION__ );
|
||||
#define WLAN_LOG_ERROR(x,args...) printk(KERN_ERR "%s: " x , __FUNCTION__ , args);
|
||||
|
||||
#define WLAN_LOG_WARNING0(x) printk(KERN_WARNING "%s: " x , __FUNCTION__);
|
||||
#define WLAN_LOG_WARNING1(x,n) printk(KERN_WARNING "%s: " x , __FUNCTION__, (n));
|
||||
#define WLAN_LOG_WARNING2(x,n1,n2) printk(KERN_WARNING "%s: " x , __FUNCTION__, (n1), (n2));
|
||||
#define WLAN_LOG_WARNING3(x,n1,n2,n3) printk(KERN_WARNING "%s: " x , __FUNCTION__, (n1), (n2), (n3));
|
||||
#define WLAN_LOG_WARNING4(x,n1,n2,n3,n4) printk(KERN_WARNING "%s: " x , __FUNCTION__ , (n1), (n2), (n3), (n4));
|
||||
#define WLAN_LOG_WARNING0(x) printk(KERN_WARNING "%s: " x , __FUNCTION__);
|
||||
#define WLAN_LOG_WARNING(x,args...) printk(KERN_WARNING "%s: " x , __FUNCTION__, args);
|
||||
|
||||
#define WLAN_LOG_NOTICE0(x) printk(KERN_NOTICE "%s: " x , __FUNCTION__);
|
||||
#define WLAN_LOG_NOTICE1(x,n) printk(KERN_NOTICE "%s: " x , __FUNCTION__, (n));
|
||||
#define WLAN_LOG_NOTICE2(x,n1,n2) printk(KERN_NOTICE "%s: " x , __FUNCTION__, (n1), (n2));
|
||||
#define WLAN_LOG_NOTICE3(x,n1,n2,n3) printk(KERN_NOTICE "%s: " x , __FUNCTION__, (n1), (n2), (n3));
|
||||
#define WLAN_LOG_NOTICE4(x,n1,n2,n3,n4) printk(KERN_NOTICE "%s: " x , __FUNCTION__, (n1), (n2), (n3), (n4));
|
||||
#define WLAN_LOG_NOTICE0(x) printk(KERN_NOTICE "%s: " x , __FUNCTION__);
|
||||
#define WLAN_LOG_NOTICE(x, args...) printk(KERN_NOTICE "%s: " x , __FUNCTION__, args);
|
||||
|
||||
#define WLAN_LOG_INFO0(x) printk(KERN_INFO x);
|
||||
#define WLAN_LOG_INFO1(x,n) printk(KERN_INFO x, (n));
|
||||
#define WLAN_LOG_INFO2(x,n1,n2) printk(KERN_INFO x, (n1), (n2));
|
||||
#define WLAN_LOG_INFO3(x,n1,n2,n3) printk(KERN_INFO x, (n1), (n2), (n3));
|
||||
#define WLAN_LOG_INFO4(x,n1,n2,n3,n4) printk(KERN_INFO x, (n1), (n2), (n3), (n4));
|
||||
#define WLAN_LOG_INFO5(x,n1,n2,n3,n4,n5) printk(KERN_INFO x, (n1), (n2), (n3), (n4), (n5));
|
||||
#define WLAN_LOG_INFO(args... ) printk(KERN_INFO args)
|
||||
|
||||
#if defined(WLAN_INCLUDE_DEBUG)
|
||||
#define WLAN_ASSERT(c) if ((!(c)) && WLAN_DBVAR >= 1) { \
|
||||
WLAN_LOG_DEBUG0(1, "Assertion failure!\n"); }
|
||||
#define WLAN_HEX_DUMP( l, x, p, n) if( WLAN_DBVAR >= (l) ){ \
|
||||
int __i__; \
|
||||
printk(KERN_DEBUG x ":"); \
|
||||
for( __i__=0; __i__ < (n); __i__++) \
|
||||
printk( " %02x", ((UINT8*)(p))[__i__]); \
|
||||
printk("\n"); }
|
||||
#if defined(WLAN_INCLUDE_DEBUG)
|
||||
#define WLAN_ASSERT(c) if ((!(c)) && WLAN_DBVAR >= 1) { \
|
||||
WLAN_LOG_DEBUG0(1, "Assertion failure!\n"); }
|
||||
#define WLAN_HEX_DUMP( l, x, p, n) if( WLAN_DBVAR >= (l) ){ \
|
||||
int __i__; \
|
||||
printk(KERN_DEBUG x ":"); \
|
||||
for( __i__=0; __i__ < (n); __i__++) \
|
||||
printk( " %02x", ((UINT8*)(p))[__i__]); \
|
||||
printk("\n"); }
|
||||
#define DBFENTER { if ( WLAN_DBVAR >= 5 ){ WLAN_LOG_DEBUG0(3,"---->\n"); } }
|
||||
#define DBFEXIT { if ( WLAN_DBVAR >= 5 ){ WLAN_LOG_DEBUG0(3,"<----\n"); } }
|
||||
|
||||
#define DBFENTER { if ( WLAN_DBVAR >= 4 ){ WLAN_LOG_DEBUG0(3,"Enter\n"); } }
|
||||
#define DBFEXIT { if ( WLAN_DBVAR >= 4 ){ WLAN_LOG_DEBUG0(3,"Exit\n"); } }
|
||||
|
||||
#define WLAN_LOG_DEBUG0(l,x) if ( WLAN_DBVAR >= (l)) printk(KERN_DEBUG "%s: " x , __FUNCTION__ );
|
||||
#define WLAN_LOG_DEBUG1(l,x,n) if ( WLAN_DBVAR >= (l)) printk(KERN_DEBUG "%s: " x , __FUNCTION__ , (n));
|
||||
#define WLAN_LOG_DEBUG2(l,x,n1,n2) if ( WLAN_DBVAR >= (l)) printk(KERN_DEBUG "%s: " x , __FUNCTION__ , (n1), (n2));
|
||||
#define WLAN_LOG_DEBUG3(l,x,n1,n2,n3) if ( WLAN_DBVAR >= (l)) printk(KERN_DEBUG "%s: " x , __FUNCTION__ , (n1), (n2), (n3));
|
||||
#define WLAN_LOG_DEBUG4(l,x,n1,n2,n3,n4) if ( WLAN_DBVAR >= (l)) printk(KERN_DEBUG "%s: " x , __FUNCTION__ , (n1), (n2), (n3), (n4));
|
||||
#define WLAN_LOG_DEBUG5(l,x,n1,n2,n3,n4,n5) if ( WLAN_DBVAR >= (l)) printk(KERN_DEBUG "%s: " x , __FUNCTION__ , (n1), (n2), (n3), (n4), (n5));
|
||||
#define WLAN_LOG_DEBUG6(l,x,n1,n2,n3,n4,n5,n6) if ( WLAN_DBVAR >= (l)) printk(KERN_DEBUG "%s: " x , __FUNCTION__ , (n1), (n2), (n3), (n4), (n5), (n6));
|
||||
#else
|
||||
#define WLAN_ASSERT(c)
|
||||
#define WLAN_HEX_DUMP( l, s, p, n)
|
||||
|
||||
#define DBFENTER
|
||||
#define DBFEXIT
|
||||
|
||||
#define WLAN_LOG_DEBUG0(l, s)
|
||||
#define WLAN_LOG_DEBUG1(l, s,n)
|
||||
#define WLAN_LOG_DEBUG2(l, s,n1,n2)
|
||||
#define WLAN_LOG_DEBUG3(l, s,n1,n2,n3)
|
||||
#define WLAN_LOG_DEBUG4(l, s,n1,n2,n3,n4)
|
||||
#define WLAN_LOG_DEBUG5(l, s,n1,n2,n3,n4,n5)
|
||||
#endif
|
||||
#define WLAN_LOG_DEBUG0(l,x) if ( WLAN_DBVAR >= (l)) printk(KERN_DEBUG "%s: " x , __FUNCTION__ );
|
||||
#define WLAN_LOG_DEBUG(l,x,args...) if ( WLAN_DBVAR >= (l)) printk(KERN_DEBUG "%s: " x , __FUNCTION__, args );
|
||||
#else
|
||||
#define WLAN_LOG_ERROR0(s)
|
||||
#define WLAN_LOG_ERROR1(s,n)
|
||||
#define WLAN_LOG_ERROR2(s,n1,n2)
|
||||
#define WLAN_LOG_ERROR3(s,n1,n2,n3)
|
||||
#define WLAN_LOG_ERROR4(s,n1,n2,n3,n4)
|
||||
#define WLAN_ASSERT(c)
|
||||
#define WLAN_HEX_DUMP( l, s, p, n)
|
||||
#define DBFENTER
|
||||
#define DBFEXIT
|
||||
|
||||
#define WLAN_LOG_WARNING0(s)
|
||||
#define WLAN_LOG_WARNING1(s,n)
|
||||
#define WLAN_LOG_WARNING2(s,n1,n2)
|
||||
#define WLAN_LOG_WARNING3(s,n1,n2,n3)
|
||||
#define WLAN_LOG_WARNING4(s,n1,n2,n3,n4)
|
||||
|
||||
#define WLAN_LOG_NOTICE0(s)
|
||||
#define WLAN_LOG_NOTICE1(s,n)
|
||||
#define WLAN_LOG_NOTICE2(s,n1,n2)
|
||||
#define WLAN_LOG_NOTICE3(s,n1,n2,n3)
|
||||
#define WLAN_LOG_NOTICE4(s,n1,n2,n3,n4)
|
||||
|
||||
#define WLAN_ASSERT(c)
|
||||
#define WLAN_HEX_DUMP( l, s, p, n)
|
||||
|
||||
#define DBFENTER
|
||||
#define DBFEXIT
|
||||
|
||||
#define WLAN_LOG_INFO0(s)
|
||||
#define WLAN_LOG_INFO1(s,n)
|
||||
#define WLAN_LOG_INFO2(s,n1,n2)
|
||||
#define WLAN_LOG_INFO3(s,n1,n2,n3)
|
||||
#define WLAN_LOG_INFO4(s,n1,n2,n3,n4)
|
||||
#define WLAN_LOG_INFO5(s,n1,n2,n3,n4,n5)
|
||||
|
||||
#define WLAN_LOG_DEBUG0(l, s)
|
||||
#define WLAN_LOG_DEBUG1(l, s,n)
|
||||
#define WLAN_LOG_DEBUG2(l, s,n1,n2)
|
||||
#define WLAN_LOG_DEBUG3(l, s,n1,n2,n3)
|
||||
#define WLAN_LOG_DEBUG4(l, s,n1,n2,n3,n4)
|
||||
#define WLAN_LOG_DEBUG5(l, s,n1,n2,n3,n4,n5)
|
||||
#define WLAN_LOG_DEBUG0(l, s)
|
||||
#define WLAN_LOG_DEBUG(l, s,n)
|
||||
#endif
|
||||
|
||||
#define wlan_ms_per_tick (1000UL / (wlan_ticks_per_sec))
|
||||
#define wlan_ms_to_ticks(n) ( (n) / (wlan_ms_per_tick))
|
||||
#define wlan_tu2ticks(n) ( (n) / (wlan_ms_per_tick))
|
||||
#define WLAN_INT_DISABLE(n) { save_flags((n)); cli(); }
|
||||
#define WLAN_INT_ENABLE(n) { sti(); restore_flags((n)); }
|
||||
|
||||
#ifdef CONFIG_MODVERSIONS
|
||||
#define MODVERSIONS 1
|
||||
#include <linux/modversions.h>
|
||||
|
|
|
@ -154,7 +154,7 @@ int skb_ether_to_p80211( wlandevice_t *wlandev, UINT32 ethconv, struct sk_buff *
|
|||
}
|
||||
|
||||
if ( ethconv == WLAN_ETHCONV_ENCAP ) { /* simplest case */
|
||||
WLAN_LOG_DEBUG1(3, "ENCAP len: %d\n", skb->len);
|
||||
WLAN_LOG_DEBUG(3, "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. */
|
||||
|
@ -162,7 +162,7 @@ int skb_ether_to_p80211( wlandevice_t *wlandev, UINT32 ethconv, struct sk_buff *
|
|||
/* step 1: classify ether frame, DIX or 802.3? */
|
||||
proto = ntohs(e_hdr.type);
|
||||
if ( proto <= 1500 ) {
|
||||
WLAN_LOG_DEBUG1(3, "802.3 len: %d\n", skb->len);
|
||||
WLAN_LOG_DEBUG(3, "802.3 len: %d\n", skb->len);
|
||||
/* codes <= 1500 reserved for 802.3 lengths */
|
||||
/* it's 802.3, pass ether payload unchanged, */
|
||||
|
||||
|
@ -172,7 +172,7 @@ int skb_ether_to_p80211( wlandevice_t *wlandev, UINT32 ethconv, struct sk_buff *
|
|||
/* leave off any PAD octets. */
|
||||
skb_trim(skb, proto);
|
||||
} else {
|
||||
WLAN_LOG_DEBUG1(3, "DIXII len: %d\n", skb->len);
|
||||
WLAN_LOG_DEBUG(3, "DIXII len: %d\n", skb->len);
|
||||
/* it's DIXII, time for some conversion */
|
||||
|
||||
/* trim off ethernet header */
|
||||
|
@ -240,7 +240,7 @@ int skb_ether_to_p80211( wlandevice_t *wlandev, UINT32 ethconv, struct sk_buff *
|
|||
skb->len,
|
||||
(wlandev->hostwep & HOSTWEP_DEFAULTKEY_MASK),
|
||||
p80211_wep->iv, p80211_wep->icv))) {
|
||||
WLAN_LOG_WARNING1("Host en-WEP failed, dropping frame (%d).\n", foo);
|
||||
WLAN_LOG_WARNING("Host en-WEP failed, dropping frame (%d).\n", foo);
|
||||
return 2;
|
||||
}
|
||||
fc |= host2ieee16(WLAN_SET_FC_ISWEP(1));
|
||||
|
@ -324,7 +324,7 @@ int skb_p80211_to_ether( wlandevice_t *wlandev, UINT32 ethconv, struct sk_buff *
|
|||
/* perform de-wep if necessary.. */
|
||||
if ((wlandev->hostwep & HOSTWEP_PRIVACYINVOKED) && WLAN_GET_FC_ISWEP(fc) && (wlandev->hostwep & HOSTWEP_DECRYPT)) {
|
||||
if (payload_length <= 8) {
|
||||
WLAN_LOG_ERROR1("WEP frame too short (%u).\n",
|
||||
WLAN_LOG_ERROR("WEP frame too short (%u).\n",
|
||||
skb->len);
|
||||
return 1;
|
||||
}
|
||||
|
@ -333,7 +333,7 @@ int skb_p80211_to_ether( wlandevice_t *wlandev, UINT32 ethconv, struct sk_buff *
|
|||
skb->data + payload_offset,
|
||||
skb->data + payload_offset + payload_length - 4))) {
|
||||
/* de-wep failed, drop skb. */
|
||||
WLAN_LOG_DEBUG1(1, "Host de-WEP failed, dropping frame (%d).\n", foo);
|
||||
WLAN_LOG_DEBUG(1, "Host de-WEP failed, dropping frame (%d).\n", foo);
|
||||
wlandev->rx.decrypt_err++;
|
||||
return 2;
|
||||
}
|
||||
|
@ -358,13 +358,13 @@ int skb_p80211_to_ether( wlandevice_t *wlandev, UINT32 ethconv, struct sk_buff *
|
|||
( 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_DEBUG1(3, "802.3 ENCAP len: %d\n", payload_length);
|
||||
WLAN_LOG_DEBUG(3, "802.3 ENCAP len: %d\n", payload_length);
|
||||
/* 802.3 Encapsulated */
|
||||
/* Test for an overlength frame */
|
||||
if ( payload_length > WLAN_MAX_ETHFRM_LEN) {
|
||||
/* A bogus length ethfrm has been encap'd. */
|
||||
/* Is someone trying an oflow attack? */
|
||||
WLAN_LOG_ERROR2("ENCAP frame too large (%d > %d)\n",
|
||||
WLAN_LOG_ERROR("ENCAP frame too large (%d > %d)\n",
|
||||
payload_length, WLAN_MAX_ETHFRM_LEN);
|
||||
return 1;
|
||||
}
|
||||
|
@ -383,7 +383,7 @@ int skb_p80211_to_ether( wlandevice_t *wlandev, UINT32 ethconv, struct sk_buff *
|
|||
(p80211_stt_findproto(ieee2host16(e_snap->type)))) ||
|
||||
(memcmp( e_snap->oui, oui_rfc1042, WLAN_IEEE_OUI_LEN)!=0)))
|
||||
{
|
||||
WLAN_LOG_DEBUG1(3, "SNAP+RFC1042 len: %d\n", payload_length);
|
||||
WLAN_LOG_DEBUG(3, "SNAP+RFC1042 len: %d\n", payload_length);
|
||||
/* it's a SNAP + RFC1042 frame && protocol is in STT */
|
||||
/* build 802.3 + RFC1042 */
|
||||
|
||||
|
@ -391,7 +391,7 @@ int skb_p80211_to_ether( wlandevice_t *wlandev, UINT32 ethconv, struct sk_buff *
|
|||
if ( payload_length + WLAN_ETHHDR_LEN > WLAN_MAX_ETHFRM_LEN ) {
|
||||
/* A bogus length ethfrm has been sent. */
|
||||
/* Is someone trying an oflow attack? */
|
||||
WLAN_LOG_ERROR2("SNAP frame too large (%d > %d)\n",
|
||||
WLAN_LOG_ERROR("SNAP frame too large (%d > %d)\n",
|
||||
payload_length, WLAN_MAX_ETHFRM_LEN);
|
||||
return 1;
|
||||
}
|
||||
|
@ -412,7 +412,7 @@ int skb_p80211_to_ether( wlandevice_t *wlandev, UINT32 ethconv, struct sk_buff *
|
|||
(e_llc->dsap == 0xaa) &&
|
||||
(e_llc->ssap == 0xaa) &&
|
||||
(e_llc->ctl == 0x03) ) {
|
||||
WLAN_LOG_DEBUG1(3, "802.1h/RFC1042 len: %d\n", payload_length);
|
||||
WLAN_LOG_DEBUG(3, "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 */
|
||||
|
||||
|
@ -420,7 +420,7 @@ int skb_p80211_to_ether( wlandevice_t *wlandev, UINT32 ethconv, struct sk_buff *
|
|||
if ( payload_length - sizeof(wlan_llc_t) - sizeof(wlan_snap_t) + WLAN_ETHHDR_LEN > WLAN_MAX_ETHFRM_LEN) {
|
||||
/* A bogus length ethfrm has been sent. */
|
||||
/* Is someone trying an oflow attack? */
|
||||
WLAN_LOG_ERROR2("DIXII frame too large (%d > %d)\n",
|
||||
WLAN_LOG_ERROR("DIXII frame too large (%d > %d)\n",
|
||||
payload_length - sizeof(wlan_llc_t) - sizeof(wlan_snap_t),
|
||||
WLAN_MAX_ETHFRM_LEN - WLAN_ETHHDR_LEN);
|
||||
return 1;
|
||||
|
@ -444,7 +444,7 @@ int skb_p80211_to_ether( wlandevice_t *wlandev, UINT32 ethconv, struct sk_buff *
|
|||
/* chop off the 802.11 CRC */
|
||||
skb_trim(skb, skb->len - WLAN_CRC_LEN);
|
||||
} else {
|
||||
WLAN_LOG_DEBUG1(3, "NON-ENCAP len: %d\n", payload_length);
|
||||
WLAN_LOG_DEBUG(3, "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 */
|
||||
|
@ -454,7 +454,7 @@ int skb_p80211_to_ether( wlandevice_t *wlandev, UINT32 ethconv, struct sk_buff *
|
|||
if ( payload_length + WLAN_ETHHDR_LEN > WLAN_MAX_ETHFRM_LEN) {
|
||||
/* A bogus length ethfrm has been sent. */
|
||||
/* Is someone trying an oflow attack? */
|
||||
WLAN_LOG_ERROR2("OTHER frame too large (%d > %d)\n",
|
||||
WLAN_LOG_ERROR("OTHER frame too large (%d > %d)\n",
|
||||
payload_length,
|
||||
WLAN_MAX_ETHFRM_LEN - WLAN_ETHHDR_LEN);
|
||||
return 1;
|
||||
|
|
|
@ -246,7 +246,7 @@ void wlan_mgmt_decode_beacon( wlan_fr_beacon_t *f )
|
|||
f->tim = (wlan_ie_tim_t*)ie_ptr;
|
||||
break;
|
||||
default:
|
||||
WLAN_LOG_WARNING1(
|
||||
WLAN_LOG_WARNING(
|
||||
"Unrecognized EID=%dd in beacon decode.\n",ie_ptr->eid);
|
||||
WLAN_HEX_DUMP(3, "frm w/ bad eid:", f->buf, f->len );
|
||||
break;
|
||||
|
@ -520,7 +520,7 @@ void wlan_mgmt_decode_assocreq( wlan_fr_assocreq_t *f )
|
|||
f->supp_rates = (wlan_ie_supp_rates_t*)ie_ptr;
|
||||
break;
|
||||
default:
|
||||
WLAN_LOG_WARNING1(
|
||||
WLAN_LOG_WARNING(
|
||||
"Unrecognized EID=%dd in assocreq decode.\n",
|
||||
ie_ptr->eid);
|
||||
WLAN_HEX_DUMP(3, "frm w/ bad eid:", f->buf, f->len );
|
||||
|
@ -727,7 +727,7 @@ void wlan_mgmt_decode_reassocreq( wlan_fr_reassocreq_t *f )
|
|||
f->supp_rates = (wlan_ie_supp_rates_t*)ie_ptr;
|
||||
break;
|
||||
default:
|
||||
WLAN_LOG_WARNING1(
|
||||
WLAN_LOG_WARNING(
|
||||
"Unrecognized EID=%dd in reassocreq decode.\n",
|
||||
ie_ptr->eid);
|
||||
WLAN_HEX_DUMP(3, "frm w/ bad eid:", f->buf, f->len );
|
||||
|
@ -920,7 +920,7 @@ void wlan_mgmt_decode_probereq( wlan_fr_probereq_t *f )
|
|||
f->supp_rates = (wlan_ie_supp_rates_t*)ie_ptr;
|
||||
break;
|
||||
default:
|
||||
WLAN_LOG_WARNING1(
|
||||
WLAN_LOG_WARNING(
|
||||
"Unrecognized EID=%dd in probereq decode.\n",
|
||||
ie_ptr->eid);
|
||||
WLAN_HEX_DUMP(3, "frm w/ bad eid:", f->buf, f->len );
|
||||
|
@ -1045,7 +1045,7 @@ void wlan_mgmt_decode_proberesp( wlan_fr_proberesp_t *f )
|
|||
f->ibss_parms = (wlan_ie_ibss_parms_t*)ie_ptr;
|
||||
break;
|
||||
default:
|
||||
WLAN_LOG_WARNING2(
|
||||
WLAN_LOG_WARNING(
|
||||
"Bad EID=%dd in proberesp, off=%d .\n",
|
||||
ie_ptr->eid, f->buf - (UINT8*)ie_ptr);
|
||||
WLAN_HEX_DUMP(3, "frm w/ bad eid:", f->buf, f->len );
|
||||
|
|
|
@ -517,7 +517,7 @@ int p80211knetdev_hard_start_xmit( struct sk_buff *skb, netdevice_t *netdev)
|
|||
} else {
|
||||
if ( skb_ether_to_p80211(wlandev, wlandev->ethconv, skb, &p80211_hdr, &p80211_wep) != 0 ) {
|
||||
/* convert failed */
|
||||
WLAN_LOG_DEBUG1(1, "ether_to_80211(%d) failed.\n",
|
||||
WLAN_LOG_DEBUG(1, "ether_to_80211(%d) failed.\n",
|
||||
wlandev->ethconv);
|
||||
result = 1;
|
||||
goto failed;
|
||||
|
@ -664,7 +664,7 @@ int p80211knetdev_do_ioctl(netdevice_t *dev, struct ifreq *ifr, int cmd)
|
|||
UINT8 *msgbuf;
|
||||
DBFENTER;
|
||||
|
||||
WLAN_LOG_DEBUG2(2, "rx'd ioctl, cmd=%d, len=%d\n", cmd, req->len);
|
||||
WLAN_LOG_DEBUG(2, "rx'd ioctl, cmd=%d, len=%d\n", cmd, req->len);
|
||||
|
||||
#if WIRELESS_EXT < 13
|
||||
/* Is this a wireless extensions ioctl? */
|
||||
|
@ -1173,7 +1173,7 @@ int wlandev_get_index(wlandevice_t *wlandev)
|
|||
for ( i = 0; i < MAX_WLAN_DEVICES; i++) {
|
||||
if ( wlandev_index[i] == NULL ) {
|
||||
sprintf(wlandev->name, "wlan%d", i);
|
||||
WLAN_LOG_DEBUG1(1,"Loading device '%s'...\n", wlandev->name);
|
||||
WLAN_LOG_DEBUG(1,"Loading device '%s'...\n", wlandev->name);
|
||||
wlandev_index[i] = wlandev;
|
||||
return i;
|
||||
}
|
||||
|
|
|
@ -713,7 +713,7 @@ int p80211wext_support_ioctl(netdevice_t *dev, struct ifreq *ifr, int cmd)
|
|||
goto exit;
|
||||
}
|
||||
|
||||
WLAN_LOG_DEBUG1(1, "Received wireless extension ioctl #%d.\n", cmd);
|
||||
WLAN_LOG_DEBUG(1, "Received wireless extension ioctl #%d.\n", cmd);
|
||||
|
||||
switch (cmd) {
|
||||
#if WIRELESS_EXT < 13
|
||||
|
|
|
@ -655,13 +655,13 @@ int hfa384x_drvr_readpda(hfa384x_t *hw, void *buf, UINT len)
|
|||
/* Check for aux available */
|
||||
result = hfa384x_cmd_aux_enable(hw);
|
||||
if ( result ) {
|
||||
WLAN_LOG_DEBUG1(1,"aux_enable() failed. result=%d\n", result);
|
||||
WLAN_LOG_DEBUG(1,"aux_enable() failed. result=%d\n", result);
|
||||
goto failed;
|
||||
}
|
||||
|
||||
/* Read the pda from each known address. */
|
||||
for ( i = 0; i < (sizeof(pdaloc)/sizeof(pdaloc[0])); i++) {
|
||||
WLAN_LOG_DEBUG2( 3, "Checking PDA@(0x%08lx,%s)\n",
|
||||
WLAN_LOG_DEBUG( 3, "Checking PDA@(0x%08lx,%s)\n",
|
||||
pdaloc[i].cardaddr,
|
||||
pdaloc[i].auxctl == HFA384x_AUX_CTL_NV ?
|
||||
"CTL_NV" : "CTL_EXTDS");
|
||||
|
@ -695,7 +695,7 @@ int hfa384x_drvr_readpda(hfa384x_t *hw, void *buf, UINT len)
|
|||
(currpdr + 2) * sizeof(UINT16));
|
||||
pdacrc =hfa384x2host_16(pda[currpdr+2]);
|
||||
if ( crc != pdacrc ) {
|
||||
WLAN_LOG_DEBUG2(3,
|
||||
WLAN_LOG_DEBUG(3,
|
||||
"PDA crc failed:"
|
||||
"calc_crc=0x%04x,"
|
||||
"pdr_crc=0x%04x.\n",
|
||||
|
@ -703,7 +703,7 @@ int hfa384x_drvr_readpda(hfa384x_t *hw, void *buf, UINT len)
|
|||
pdaok = 0;
|
||||
}
|
||||
} else {
|
||||
WLAN_LOG_DEBUG1(3,
|
||||
WLAN_LOG_DEBUG(3,
|
||||
"END record detected w/ "
|
||||
"len(%d) != 2, assuming bad PDA\n",
|
||||
pdrlen);
|
||||
|
@ -715,12 +715,12 @@ int hfa384x_drvr_readpda(hfa384x_t *hw, void *buf, UINT len)
|
|||
|
||||
/* Test the record length */
|
||||
if ( pdrlen > HFA384x_PDR_LEN_MAX || pdrlen == 0) {
|
||||
WLAN_LOG_DEBUG4(3,
|
||||
WLAN_LOG_DEBUG(3,
|
||||
"pdrlen for address #%d "
|
||||
"at %#lx:%#x:%d\n",
|
||||
i, pdaloc[i].cardaddr,
|
||||
pdaloc[i].auxctl, pdrlen);
|
||||
WLAN_LOG_DEBUG1(3,"pdrlen invalid=%d\n",
|
||||
WLAN_LOG_DEBUG(3,"pdrlen invalid=%d\n",
|
||||
pdrlen);
|
||||
pdaok = 0;
|
||||
break;
|
||||
|
@ -740,7 +740,7 @@ int hfa384x_drvr_readpda(hfa384x_t *hw, void *buf, UINT len)
|
|||
}
|
||||
}
|
||||
if ( pdaok ) {
|
||||
WLAN_LOG_INFO2(
|
||||
WLAN_LOG_INFO(
|
||||
"PDA Read from 0x%08lx in %s space.\n",
|
||||
pdaloc[i].cardaddr,
|
||||
pdaloc[i].auxctl == 0 ? "EXTDS" :
|
||||
|
@ -852,13 +852,13 @@ int hfa384x_drvr_ramdl_enable(hfa384x_t *hw, UINT32 exeaddr)
|
|||
hw->dltimeout = hfa384x2host_16(hw->dltimeout);
|
||||
|
||||
#if 0
|
||||
WLAN_LOG_DEBUG1(1,"ramdl_enable, exeaddr=0x%08x\n", exeaddr);
|
||||
WLAN_LOG_DEBUG(1,"ramdl_enable, exeaddr=0x%08x\n", exeaddr);
|
||||
hw->dlstate = HFA384x_DLSTATE_RAMENABLED;
|
||||
#endif
|
||||
|
||||
/* Enable the aux port */
|
||||
if ( (result = hfa384x_cmd_aux_enable(hw)) ) {
|
||||
WLAN_LOG_DEBUG1(1,"Aux enable failed, result=%d.\n", result);
|
||||
WLAN_LOG_DEBUG(1,"Aux enable failed, result=%d.\n", result);
|
||||
return result;
|
||||
}
|
||||
|
||||
|
@ -872,7 +872,7 @@ hw->dlstate = HFA384x_DLSTATE_RAMENABLED;
|
|||
/* Set the download state */
|
||||
hw->dlstate = HFA384x_DLSTATE_RAMENABLED;
|
||||
} else {
|
||||
WLAN_LOG_DEBUG3(1,"cmd_download(0x%04x, 0x%04x) failed, result=%d.\n",
|
||||
WLAN_LOG_DEBUG(1,"cmd_download(0x%04x, 0x%04x) failed, result=%d.\n",
|
||||
lowaddr,hiaddr, result);
|
||||
/* Disable the aux port */
|
||||
hfa384x_cmd_aux_disable(hw);
|
||||
|
@ -961,7 +961,7 @@ int hfa384x_drvr_ramdl_write(hfa384x_t *hw, UINT32 daddr, void* buf, UINT32 len)
|
|||
return -EINVAL;
|
||||
}
|
||||
|
||||
WLAN_LOG_INFO2("Writing %ld bytes to ram @0x%06lx\n", len, daddr);
|
||||
WLAN_LOG_INFO("Writing %ld bytes to ram @0x%06lx\n", len, daddr);
|
||||
#if 0
|
||||
WLAN_HEX_DUMP(1, "dldata", buf, len);
|
||||
#endif
|
||||
|
@ -1146,7 +1146,7 @@ int hfa384x_drvr_flashdl_write(hfa384x_t *hw, UINT32 daddr, void* buf, UINT32 le
|
|||
return -EINVAL;
|
||||
}
|
||||
|
||||
WLAN_LOG_INFO2("Download %ld bytes to flash @0x%06lx\n", len, daddr);
|
||||
WLAN_LOG_INFO("Download %ld bytes to flash @0x%06lx\n", len, daddr);
|
||||
|
||||
/* Need a flat address for arithmetic */
|
||||
dlbufaddr = HFA384x_ADDR_AUX_MKFLAT(
|
||||
|
@ -1155,7 +1155,7 @@ int hfa384x_drvr_flashdl_write(hfa384x_t *hw, UINT32 daddr, void* buf, UINT32 le
|
|||
verbuf = kmalloc(hw->bufinfo.len, GFP_KERNEL);
|
||||
|
||||
#if 0
|
||||
WLAN_LOG_WARNING3("dlbuf@0x%06lx len=%d to=%d\n", dlbufaddr, hw->bufinfo.len, hw->dltimeout);
|
||||
WLAN_LOG_WARNING("dlbuf@0x%06lx len=%d to=%d\n", dlbufaddr, hw->bufinfo.len, hw->dltimeout);
|
||||
#endif
|
||||
/* Figure out how many times to to the flash prog */
|
||||
nwrites = len / hw->bufinfo.len;
|
||||
|
@ -1174,7 +1174,7 @@ WLAN_LOG_WARNING3("dlbuf@0x%06lx len=%d to=%d\n", dlbufaddr, hw->bufinfo.len, hw
|
|||
currdaddr = daddr + (hw->bufinfo.len * i);
|
||||
destlo = HFA384x_ADDR_CMD_MKOFF(currdaddr);
|
||||
desthi = HFA384x_ADDR_CMD_MKPAGE(currdaddr);
|
||||
WLAN_LOG_INFO2("Writing %ld bytes to flash @0x%06lx\n", currlen, currdaddr);
|
||||
WLAN_LOG_INFO("Writing %ld bytes to flash @0x%06lx\n", currlen, currdaddr);
|
||||
#if 0
|
||||
WLAN_HEX_DUMP(1, "dldata", buf+(hw->bufinfo.len*i), currlen);
|
||||
#endif
|
||||
|
@ -1182,7 +1182,7 @@ WLAN_HEX_DUMP(1, "dldata", buf+(hw->bufinfo.len*i), currlen);
|
|||
result = hfa384x_cmd_download(hw, HFA384x_PROGMODE_NV,
|
||||
destlo, desthi, currlen);
|
||||
if ( result ) {
|
||||
WLAN_LOG_ERROR4("download(NV,lo=%x,hi=%x,len=%lx) "
|
||||
WLAN_LOG_ERROR("download(NV,lo=%x,hi=%x,len=%lx) "
|
||||
"cmd failed, result=%d. Aborting d/l\n",
|
||||
destlo, desthi, currlen, result);
|
||||
goto exit_proc;
|
||||
|
@ -1193,7 +1193,7 @@ WLAN_HEX_DUMP(1, "dldata", buf+(hw->bufinfo.len*i), currlen);
|
|||
/* set the download 'write flash' mode */
|
||||
result = hfa384x_cmd_download(hw, HFA384x_PROGMODE_NVWRITE, 0,0,0);
|
||||
if ( result ) {
|
||||
WLAN_LOG_ERROR4(
|
||||
WLAN_LOG_ERROR(
|
||||
"download(NVWRITE,lo=%x,hi=%x,len=%lx) "
|
||||
"cmd failed, result=%d. Aborting d/l\n",
|
||||
destlo, desthi, currlen, result);
|
||||
|
@ -1708,7 +1708,7 @@ int hfa384x_cmd_notify(hfa384x_t *hw, UINT16 reclaim, UINT16 fid,
|
|||
/* Copy the record to FID */
|
||||
result = hfa384x_copy_to_bap(hw, HFA384x_BAP_PROC, hw->infofid, 0, buf, len);
|
||||
if ( result ) {
|
||||
WLAN_LOG_DEBUG3(1,
|
||||
WLAN_LOG_DEBUG(1,
|
||||
"copy_to_bap(%04x, 0, %d) failed, result=0x%x\n",
|
||||
hw->infofid, len, result);
|
||||
result = -EIO;
|
||||
|
@ -1836,7 +1836,7 @@ int hfa384x_cmd_access(hfa384x_t *hw, UINT16 write, UINT16 rid,
|
|||
|
||||
result = hfa384x_docmd_wait(hw, &cmd);
|
||||
if ( result ) {
|
||||
WLAN_LOG_ERROR2("Call to hfa384x_docmd_wait failed (%d %d)\n",
|
||||
WLAN_LOG_ERROR("Call to hfa384x_docmd_wait failed (%d %d)\n",
|
||||
result, cmd.resp0);
|
||||
goto fail;
|
||||
}
|
||||
|
@ -1850,7 +1850,7 @@ int hfa384x_cmd_access(hfa384x_t *hw, UINT16 write, UINT16 rid,
|
|||
|
||||
/* Validate the record length */
|
||||
if ( ((hfa384x2host_16(rec.reclen)-1)*2) != len ) { /* note body len calculation in bytes */
|
||||
WLAN_LOG_DEBUG3(1, "RID len mismatch, rid=0x%04x hlen=%d fwlen=%d\n",
|
||||
WLAN_LOG_DEBUG(1, "RID len mismatch, rid=0x%04x hlen=%d fwlen=%d\n",
|
||||
rid, len, (hfa384x2host_16(rec.reclen)-1)*2);
|
||||
result = -ENODATA;
|
||||
goto fail;
|
||||
|
@ -2227,8 +2227,8 @@ hfa384x_drvr_mmi_write(hfa384x_t *hw, UINT32 addr, UINT32 data)
|
|||
cmd.parm1 = (UINT16) data;
|
||||
cmd.parm2 = 0;
|
||||
|
||||
WLAN_LOG_DEBUG1(1,"mmi write : addr = 0x%08lx\n", addr);
|
||||
WLAN_LOG_DEBUG1(1,"mmi write : data = 0x%08lx\n", data);
|
||||
WLAN_LOG_DEBUG(1,"mmi write : addr = 0x%08lx\n", addr);
|
||||
WLAN_LOG_DEBUG(1,"mmi write : data = 0x%08lx\n", data);
|
||||
|
||||
/* Do i need a host2hfa... conversion ? */
|
||||
result = hfa384x_docmd_wait(hw, &cmd);
|
||||
|
@ -2380,7 +2380,7 @@ int hfa384x_copy_from_bap(hfa384x_t *hw, UINT16 bap, UINT16 id, UINT16 offset,
|
|||
#endif
|
||||
|
||||
if (result) {
|
||||
WLAN_LOG_DEBUG3(1,
|
||||
WLAN_LOG_DEBUG(1,
|
||||
"copy_from_bap(0x%04x, 0, %d) failed, result=0x%x\n",
|
||||
reg, len, result);
|
||||
}
|
||||
|
@ -2605,7 +2605,7 @@ hfa384x_copy_from_aux(
|
|||
DBFENTER;
|
||||
|
||||
if ( !(hw->auxen) ) {
|
||||
WLAN_LOG_DEBUG1(1,
|
||||
WLAN_LOG_DEBUG(1,
|
||||
"Attempt to read 0x%04lx when aux not enabled\n",
|
||||
cardaddr);
|
||||
return;
|
||||
|
@ -2674,7 +2674,7 @@ hfa384x_copy_to_aux(
|
|||
DBFENTER;
|
||||
|
||||
if ( !(hw->auxen) ) {
|
||||
WLAN_LOG_DEBUG1(1,
|
||||
WLAN_LOG_DEBUG(1,
|
||||
"Attempt to read 0x%04lx when aux not enabled\n",
|
||||
cardaddr);
|
||||
return;
|
||||
|
@ -2763,7 +2763,7 @@ int hfa384x_docmd_wait( hfa384x_t *hw, hfa384x_metacmd_t *cmd)
|
|||
printk("counter(1)=%d\n", counter);
|
||||
#endif
|
||||
if (HFA384x_CMD_ISBUSY(reg)) {
|
||||
WLAN_LOG_ERROR1("hfa384x_cmd timeout(1), reg=0x%0hx.\n", reg);
|
||||
WLAN_LOG_ERROR("hfa384x_cmd timeout(1), reg=0x%0hx.\n", reg);
|
||||
goto failed;
|
||||
}
|
||||
if (!HFA384x_CMD_ISBUSY(reg)) {
|
||||
|
@ -2809,7 +2809,7 @@ int hfa384x_docmd_wait( hfa384x_t *hw, hfa384x_metacmd_t *cmd)
|
|||
HFA384x_EVACK);
|
||||
result = HFA384x_STATUS_RESULT_GET(cmd->status);
|
||||
} else {
|
||||
WLAN_LOG_ERROR1("hfa384x_cmd timeout(2), reg=0x%0hx.\n", reg);
|
||||
WLAN_LOG_ERROR("hfa384x_cmd timeout(2), reg=0x%0hx.\n", reg);
|
||||
}
|
||||
#endif /* CMD_IRQ */
|
||||
}
|
||||
|
@ -2958,7 +2958,7 @@ int hfa384x_corereset(hfa384x_t *hw, int holdtime, int settletime)
|
|||
((dev_link_t*)hw->membase)->handle,
|
||||
®);
|
||||
if (result != CS_SUCCESS ) {
|
||||
WLAN_LOG_ERROR1(
|
||||
WLAN_LOG_ERROR(
|
||||
":0: AccessConfigurationRegister(CS_READ) failed,"
|
||||
"result=%d.\n", result);
|
||||
result = -EIO;
|
||||
|
@ -2973,7 +2973,7 @@ int hfa384x_corereset(hfa384x_t *hw, int holdtime, int settletime)
|
|||
((dev_link_t*)hw->membase)->handle,
|
||||
®);
|
||||
if (result != CS_SUCCESS ) {
|
||||
WLAN_LOG_ERROR1(
|
||||
WLAN_LOG_ERROR(
|
||||
":1: AccessConfigurationRegister(CS_WRITE) failed,"
|
||||
"result=%d.\n", result);
|
||||
result = -EIO;
|
||||
|
@ -2990,7 +2990,7 @@ int hfa384x_corereset(hfa384x_t *hw, int holdtime, int settletime)
|
|||
((dev_link_t*)hw->membase)->handle,
|
||||
®);
|
||||
if (result != CS_SUCCESS ) {
|
||||
WLAN_LOG_ERROR1(
|
||||
WLAN_LOG_ERROR(
|
||||
":2: AccessConfigurationRegister(CS_WRITE) failed,"
|
||||
"result=%d.\n", result);
|
||||
result = -EIO;
|
||||
|
@ -3008,7 +3008,7 @@ int hfa384x_corereset(hfa384x_t *hw, int holdtime, int settletime)
|
|||
((dev_link_t*)hw->membase)->handle,
|
||||
®);
|
||||
if (result != CS_SUCCESS ) {
|
||||
WLAN_LOG_ERROR1(
|
||||
WLAN_LOG_ERROR(
|
||||
":2: AccessConfigurationRegister(CS_WRITE) failed,"
|
||||
"result=%d.\n", result);
|
||||
result = -EIO;
|
||||
|
@ -3144,7 +3144,7 @@ int hfa384x_drvr_start(hfa384x_t *hw)
|
|||
|
||||
txfid_queue_add(hw, reg);
|
||||
|
||||
WLAN_LOG_DEBUG2(4,"hw->txfid_queue[%d]=0x%04x\n",i,reg);
|
||||
WLAN_LOG_DEBUG(4,"hw->txfid_queue[%d]=0x%04x\n",i,reg);
|
||||
|
||||
reg = HFA384x_EVACK_ALLOC_SET(1);
|
||||
hfa384x_setreg(hw, reg, HFA384x_EVACK);
|
||||
|
@ -3171,7 +3171,7 @@ int hfa384x_drvr_start(hfa384x_t *hw)
|
|||
hw->infofid = hfa384x_getreg(hw, HFA384x_ALLOCFID);
|
||||
reg = HFA384x_EVACK_ALLOC_SET(1);
|
||||
hfa384x_setreg(hw, reg, HFA384x_EVACK);
|
||||
WLAN_LOG_DEBUG1(4,"hw->infofid=0x%04x\n", hw->infofid);
|
||||
WLAN_LOG_DEBUG(4,"hw->infofid=0x%04x\n", hw->infofid);
|
||||
|
||||
/* Set swsupport regs to magic # for card presence detection */
|
||||
hfa384x_setreg(hw, HFA384x_DRVR_MAGIC, HFA384x_SWSUPPORT0);
|
||||
|
@ -3195,7 +3195,7 @@ int hfa384x_drvr_start(hfa384x_t *hw)
|
|||
|
||||
goto done;
|
||||
failed:
|
||||
WLAN_LOG_ERROR1("Failed, result=%d\n", result);
|
||||
WLAN_LOG_ERROR("Failed, result=%d\n", result);
|
||||
done:
|
||||
DBFEXIT;
|
||||
return result;
|
||||
|
@ -3345,7 +3345,7 @@ int hfa384x_drvr_txframe(hfa384x_t *hw, struct sk_buff *skb, p80211_hdr_t *p8021
|
|||
}
|
||||
|
||||
if ( result ) {
|
||||
WLAN_LOG_DEBUG4(1,
|
||||
WLAN_LOG_DEBUG(1,
|
||||
"copy_to_bap(%04x, %d, %d) failed, result=0x%x\n",
|
||||
fid,
|
||||
sizeof(txdesc),
|
||||
|
@ -3365,7 +3365,7 @@ int hfa384x_drvr_txframe(hfa384x_t *hw, struct sk_buff *skb, p80211_hdr_t *p8021
|
|||
if ( result != 0 ) {
|
||||
txfid_queue_add(hw, fid);
|
||||
|
||||
WLAN_LOG_DEBUG2(1,"cmd_tx(%04x) failed, result=%d\n",
|
||||
WLAN_LOG_DEBUG(1,"cmd_tx(%04x) failed, result=%d\n",
|
||||
fid, result);
|
||||
result = 3;
|
||||
goto failed;
|
||||
|
@ -3451,7 +3451,7 @@ void hfa384x_interrupt(int irq, void *dev_id, struct pt_regs *regs)
|
|||
/* Check swsupport reg magic # for card presence */
|
||||
reg = hfa384x_getreg(hw, HFA384x_SWSUPPORT0);
|
||||
if ( reg != HFA384x_DRVR_MAGIC) {
|
||||
WLAN_LOG_DEBUG1(2, "irq=%d, no magic. Card removed?.\n", irq);
|
||||
WLAN_LOG_DEBUG(2, "irq=%d, no magic. Card removed?.\n", irq);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -3524,7 +3524,7 @@ void hfa384x_interrupt(int irq, void *dev_id, struct pt_regs *regs)
|
|||
/* Check swsupport reg magic # for card presence */
|
||||
reg = hfa384x_getreg(hw, HFA384x_SWSUPPORT0);
|
||||
if ( reg != HFA384x_DRVR_MAGIC) {
|
||||
WLAN_LOG_DEBUG1(2, "irq=%d, no magic. Card removed?.\n", irq);
|
||||
WLAN_LOG_DEBUG(2, "irq=%d, no magic. Card removed?.\n", irq);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -3681,7 +3681,7 @@ void hfa384x_int_info(wlandevice_t *wlandev)
|
|||
result = hfa384x_copy_from_bap( hw,
|
||||
HFA384x_BAP_INT, reg, 0, &inf.framelen, sizeof(UINT16));
|
||||
if ( result ) {
|
||||
WLAN_LOG_DEBUG3(1,
|
||||
WLAN_LOG_DEBUG(1,
|
||||
"copy_from_bap(0x%04x, 0, %d) failed, result=0x%x\n",
|
||||
reg, sizeof(inf), result);
|
||||
goto failed;
|
||||
|
@ -3693,7 +3693,7 @@ void hfa384x_int_info(wlandevice_t *wlandev)
|
|||
HFA384x_BAP_INT, reg, sizeof(UINT16),
|
||||
&(inf.infotype), inf.framelen * sizeof(UINT16));
|
||||
if ( result ) {
|
||||
WLAN_LOG_DEBUG3(1,
|
||||
WLAN_LOG_DEBUG(1,
|
||||
"copy_from_bap(0x%04x, 0, %d) failed, result=0x%x\n",
|
||||
reg, sizeof(inf), result);
|
||||
goto failed;
|
||||
|
@ -3736,7 +3736,7 @@ void hfa384x_int_txexc(wlandevice_t *wlandev)
|
|||
fid = hfa384x_getreg(hw, HFA384x_TXCOMPLFID);
|
||||
result = hfa384x_copy_from_bap(hw, HFA384x_BAP_INT, fid, 0, &status, sizeof(status));
|
||||
if ( result ) {
|
||||
WLAN_LOG_DEBUG3(1,
|
||||
WLAN_LOG_DEBUG(1,
|
||||
"copy_from_bap(0x%04x, 0, %d) failed, result=0x%x\n",
|
||||
fid, sizeof(status), result);
|
||||
goto failed;
|
||||
|
@ -3776,7 +3776,7 @@ void hfa384x_int_tx(wlandevice_t *wlandev)
|
|||
fid = hfa384x_getreg(hw, HFA384x_TXCOMPLFID);
|
||||
result = hfa384x_copy_from_bap(hw, HFA384x_BAP_INT, fid, 0, &status, sizeof(status));
|
||||
if ( result ) {
|
||||
WLAN_LOG_DEBUG3(1,
|
||||
WLAN_LOG_DEBUG(1,
|
||||
"copy_from_bap(0x%04x, 0, %d) failed, result=0x%x\n",
|
||||
fid, sizeof(status), result);
|
||||
goto failed;
|
||||
|
@ -3829,7 +3829,7 @@ void hfa384x_int_rx(wlandevice_t *wlandev)
|
|||
&rxdesc,
|
||||
sizeof(rxdesc));
|
||||
if ( result ) {
|
||||
WLAN_LOG_DEBUG4(1,
|
||||
WLAN_LOG_DEBUG(1,
|
||||
"copy_from_bap(0x%04x, %d, %d) failed, result=0x%x\n",
|
||||
rxfid,
|
||||
0,
|
||||
|
@ -3856,7 +3856,7 @@ void hfa384x_int_rx(wlandevice_t *wlandev)
|
|||
result = hfa384x_int_rx_typedrop(wlandev, ieee2host16(rxdesc.frame_control));
|
||||
if (result) {
|
||||
if (result != 1)
|
||||
WLAN_LOG_WARNING1("Invalid frame type, fc=%04x, dropped.\n",rxdesc.frame_control);
|
||||
WLAN_LOG_WARNING("Invalid frame type, fc=%04x, dropped.\n",rxdesc.frame_control);
|
||||
|
||||
goto done;
|
||||
}
|
||||
|
@ -3921,7 +3921,7 @@ void hfa384x_int_rx(wlandevice_t *wlandev)
|
|||
HFA384x_BAP_INT, rxfid, HFA384x_RX_DATA_OFF,
|
||||
datap, rxdesc.data_len);
|
||||
if ( result ) {
|
||||
WLAN_LOG_DEBUG4(1,
|
||||
WLAN_LOG_DEBUG(1,
|
||||
"copy_from_bap(0x%04x, %d, %d) failed, result=0x%x\n",
|
||||
rxfid,
|
||||
HFA384x_RX_DATA_OFF,
|
||||
|
@ -3950,7 +3950,7 @@ void hfa384x_int_rx(wlandevice_t *wlandev)
|
|||
break;
|
||||
|
||||
default:
|
||||
WLAN_LOG_WARNING1("Received frame on unsupported port=%d\n",
|
||||
WLAN_LOG_WARNING("Received frame on unsupported port=%d\n",
|
||||
HFA384x_RXSTATUS_MACPORT_GET(rxdesc.status) );
|
||||
goto done;
|
||||
break;
|
||||
|
@ -4034,7 +4034,7 @@ void hfa384x_int_rxmonitor( wlandevice_t *wlandev, UINT16 rxfid, hfa384x_rx_fram
|
|||
datalen = 0;
|
||||
break;
|
||||
default:
|
||||
WLAN_LOG_DEBUG1(1, "unknown frm: fc=0x%04x\n", fc);
|
||||
WLAN_LOG_DEBUG(1, "unknown frm: fc=0x%04x\n", fc);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -4046,12 +4046,12 @@ void hfa384x_int_rxmonitor( wlandevice_t *wlandev, UINT16 rxfid, hfa384x_rx_fram
|
|||
if ( skblen >
|
||||
(sizeof(p80211msg_lnxind_wlansniffrm_t) +
|
||||
WLAN_HDR_A4_LEN + WLAN_DATA_MAXLEN + WLAN_CRC_LEN) ) {
|
||||
WLAN_LOG_DEBUG1(1, "overlen frm: len=%d\n",
|
||||
WLAN_LOG_DEBUG(1, "overlen frm: len=%d\n",
|
||||
skblen - sizeof(p80211msg_lnxind_wlansniffrm_t));
|
||||
}
|
||||
|
||||
if ( (skb = dev_alloc_skb(skblen)) == NULL ) {
|
||||
WLAN_LOG_ERROR1("alloc_skb failed trying to allocate %d bytes\n", skblen);
|
||||
WLAN_LOG_ERROR("alloc_skb failed trying to allocate %d bytes\n", skblen);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -4215,7 +4215,7 @@ int hfa384x_int_rx_typedrop( wlandevice_t *wlandev, UINT16 fc)
|
|||
ftype = WLAN_GET_FC_FTYPE(fc);
|
||||
fstype = WLAN_GET_FC_FSTYPE(fc);
|
||||
#if 0
|
||||
WLAN_LOG_DEBUG2(4,
|
||||
WLAN_LOG_DEBUG(4,
|
||||
"rx_typedrop : ftype=%d fstype=%d.\n", ftype, fstype);
|
||||
#endif
|
||||
switch ( ftype ) {
|
||||
|
@ -4396,7 +4396,7 @@ void hfa384x_int_alloc(wlandevice_t *wlandev)
|
|||
fid = hfa384x_getreg(hw, HFA384x_ALLOCFID);
|
||||
|
||||
if ( fid != hw->infofid ) { /* It's a transmit fid */
|
||||
WLAN_LOG_DEBUG1(5, "int_alloc(%#x)\n", fid);
|
||||
WLAN_LOG_DEBUG(5, "int_alloc(%#x)\n", fid);
|
||||
result = txfid_queue_add(hw, fid);
|
||||
if (result != -1) {
|
||||
prism2sta_ev_alloc(wlandev);
|
||||
|
@ -4456,7 +4456,7 @@ int hfa384x_drvr_handover( hfa384x_t *hw, UINT8 *addr)
|
|||
result = hfa384x_cmd_notify(hw, 1, hw->infofid, &rec, len);
|
||||
|
||||
if ( result != 0 ) {
|
||||
WLAN_LOG_DEBUG2(1,"cmd_notify(%04x) failed, result=%d",
|
||||
WLAN_LOG_DEBUG(1,"cmd_notify(%04x) failed, result=%d",
|
||||
hw->infofid, result);
|
||||
result = -EIO;
|
||||
goto failed;
|
||||
|
|
|
@ -328,20 +328,20 @@ hfa384x_isgood_pdrcode(UINT16 pdrcode);
|
|||
void
|
||||
dbprint_urb(struct urb* urb)
|
||||
{
|
||||
WLAN_LOG_DEBUG1(3,"urb->pipe=0x%08x\n", urb->pipe);
|
||||
WLAN_LOG_DEBUG1(3,"urb->status=0x%08x\n", urb->status);
|
||||
WLAN_LOG_DEBUG1(3,"urb->transfer_flags=0x%08x\n", urb->transfer_flags);
|
||||
WLAN_LOG_DEBUG1(3,"urb->transfer_buffer=0x%08x\n", (UINT)urb->transfer_buffer);
|
||||
WLAN_LOG_DEBUG1(3,"urb->transfer_buffer_length=0x%08x\n", urb->transfer_buffer_length);
|
||||
WLAN_LOG_DEBUG1(3,"urb->actual_length=0x%08x\n", urb->actual_length);
|
||||
WLAN_LOG_DEBUG1(3,"urb->bandwidth=0x%08x\n", urb->bandwidth);
|
||||
WLAN_LOG_DEBUG1(3,"urb->setup_packet(ctl)=0x%08x\n", (UINT)urb->setup_packet);
|
||||
WLAN_LOG_DEBUG1(3,"urb->start_frame(iso/irq)=0x%08x\n", urb->start_frame);
|
||||
WLAN_LOG_DEBUG1(3,"urb->interval(irq)=0x%08x\n", urb->interval);
|
||||
WLAN_LOG_DEBUG1(3,"urb->error_count(iso)=0x%08x\n", urb->error_count);
|
||||
WLAN_LOG_DEBUG1(3,"urb->timeout=0x%08x\n", urb->timeout);
|
||||
WLAN_LOG_DEBUG1(3,"urb->context=0x%08x\n", (UINT)urb->context);
|
||||
WLAN_LOG_DEBUG1(3,"urb->complete=0x%08x\n", (UINT)urb->complete);
|
||||
WLAN_LOG_DEBUG(3,"urb->pipe=0x%08x\n", urb->pipe);
|
||||
WLAN_LOG_DEBUG(3,"urb->status=0x%08x\n", urb->status);
|
||||
WLAN_LOG_DEBUG(3,"urb->transfer_flags=0x%08x\n", urb->transfer_flags);
|
||||
WLAN_LOG_DEBUG(3,"urb->transfer_buffer=0x%08x\n", (UINT)urb->transfer_buffer);
|
||||
WLAN_LOG_DEBUG(3,"urb->transfer_buffer_length=0x%08x\n", urb->transfer_buffer_length);
|
||||
WLAN_LOG_DEBUG(3,"urb->actual_length=0x%08x\n", urb->actual_length);
|
||||
WLAN_LOG_DEBUG(3,"urb->bandwidth=0x%08x\n", urb->bandwidth);
|
||||
WLAN_LOG_DEBUG(3,"urb->setup_packet(ctl)=0x%08x\n", (UINT)urb->setup_packet);
|
||||
WLAN_LOG_DEBUG(3,"urb->start_frame(iso/irq)=0x%08x\n", urb->start_frame);
|
||||
WLAN_LOG_DEBUG(3,"urb->interval(irq)=0x%08x\n", urb->interval);
|
||||
WLAN_LOG_DEBUG(3,"urb->error_count(iso)=0x%08x\n", urb->error_count);
|
||||
WLAN_LOG_DEBUG(3,"urb->timeout=0x%08x\n", urb->timeout);
|
||||
WLAN_LOG_DEBUG(3,"urb->context=0x%08x\n", (UINT)urb->context);
|
||||
WLAN_LOG_DEBUG(3,"urb->complete=0x%08x\n", (UINT)urb->complete);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
@ -675,7 +675,7 @@ hfa384x_cmd_initialize(hfa384x_t *hw)
|
|||
result = hfa384x_docmd(hw, DOWAIT, &cmd, NULL, NULL);
|
||||
|
||||
|
||||
WLAN_LOG_DEBUG4(3,"cmdresp.init: "
|
||||
WLAN_LOG_DEBUG(3,"cmdresp.init: "
|
||||
"status=0x%04x, resp0=0x%04x, "
|
||||
"resp1=0x%04x, resp2=0x%04x\n",
|
||||
cmd.status, cmd.resp0, cmd.resp1, cmd.resp2);
|
||||
|
@ -950,7 +950,7 @@ int hfa384x_cmd_download(hfa384x_t *hw, UINT16 mode, UINT16 lowaddr,
|
|||
hfa384x_metacmd_t cmd;
|
||||
|
||||
DBFENTER;
|
||||
WLAN_LOG_DEBUG4(5,
|
||||
WLAN_LOG_DEBUG(5,
|
||||
"mode=%d, lowaddr=0x%04x, highaddr=0x%04x, codelen=%d\n",
|
||||
mode, lowaddr, highaddr, codelen);
|
||||
|
||||
|
@ -1094,7 +1094,7 @@ int hfa384x_corereset( hfa384x_t *hw, int holdtime, int settletime)
|
|||
/* Set the device address */
|
||||
result=usb_set_address(hw->usb);
|
||||
if (result < 0) {
|
||||
WLAN_LOG_ERROR1("reset_usbdev: Dev not accepting address, "
|
||||
WLAN_LOG_ERROR("reset_usbdev: Dev not accepting address, "
|
||||
"result=%d\n", result);
|
||||
clear_bit(hw->usb->devnum, &hw->usb->bus->devmap.devicemap);
|
||||
hw->usb->devnum = -1;
|
||||
|
@ -1106,11 +1106,11 @@ int hfa384x_corereset( hfa384x_t *hw, int holdtime, int settletime)
|
|||
/* Assume we're reusing the original descriptor data */
|
||||
|
||||
/* Set the configuration. */
|
||||
WLAN_LOG_DEBUG1(3, "Setting Configuration %d\n",
|
||||
WLAN_LOG_DEBUG(3, "Setting Configuration %d\n",
|
||||
hw->usb->config[0].bConfigurationValue);
|
||||
result=usb_set_configuration(hw->usb, hw->usb->config[0].bConfigurationValue);
|
||||
if ( result ) {
|
||||
WLAN_LOG_ERROR1("usb_set_configuration() failed, result=%d.\n",
|
||||
WLAN_LOG_ERROR("usb_set_configuration() failed, result=%d.\n",
|
||||
result);
|
||||
goto done;
|
||||
}
|
||||
|
@ -1182,7 +1182,7 @@ hfa384x_docmd(
|
|||
ctlx->outbuf.cmdreq.parm1 = host2hfa384x_16(cmd->parm1);
|
||||
ctlx->outbuf.cmdreq.parm2 = host2hfa384x_16(cmd->parm2);
|
||||
|
||||
WLAN_LOG_DEBUG4(4, "cmdreq: cmd=0x%04x "
|
||||
WLAN_LOG_DEBUG(4, "cmdreq: cmd=0x%04x "
|
||||
"parm0=0x%04x parm1=0x%04x parm2=0x%04x\n",
|
||||
cmd->cmd,
|
||||
cmd->parm0,
|
||||
|
@ -1214,7 +1214,7 @@ hfa384x_docmd(
|
|||
cmd->resp0 = hfa384x2host_16(ctlx->inbuf.cmdresp.resp0);
|
||||
cmd->resp1 = hfa384x2host_16(ctlx->inbuf.cmdresp.resp1);
|
||||
cmd->resp2 = hfa384x2host_16(ctlx->inbuf.cmdresp.resp2);
|
||||
WLAN_LOG_DEBUG4(4, "cmdresp:status=0x%04x "
|
||||
WLAN_LOG_DEBUG(4, "cmdresp:status=0x%04x "
|
||||
"resp0=0x%04x resp1=0x%04x resp2=0x%04x\n",
|
||||
cmd->status,
|
||||
cmd->resp0,
|
||||
|
@ -1343,7 +1343,7 @@ hfa384x_dorrid(
|
|||
/* Validate the length, note body len calculation in bytes */
|
||||
maclen = ((hfa384x2host_16(ctlx->inbuf.rridresp.frmlen)-1)*2);
|
||||
if ( maclen != riddatalen ) {
|
||||
WLAN_LOG_WARNING3(
|
||||
WLAN_LOG_WARNING(
|
||||
"RID len mismatch, rid=0x%04x hlen=%d fwlen=%d\n",
|
||||
rid, riddatalen, maclen);
|
||||
result = -ENODATA;
|
||||
|
@ -1582,14 +1582,14 @@ hfa384x_dormem(
|
|||
ctlx->outbuf.rmemreq.offset = host2hfa384x_16(offset);
|
||||
ctlx->outbuf.rmemreq.page = host2hfa384x_16(page);
|
||||
|
||||
WLAN_LOG_DEBUG4(4,
|
||||
WLAN_LOG_DEBUG(4,
|
||||
"type=0x%04x frmlen=%d offset=0x%04x page=0x%04x\n",
|
||||
ctlx->outbuf.rmemreq.type,
|
||||
ctlx->outbuf.rmemreq.frmlen,
|
||||
ctlx->outbuf.rmemreq.offset,
|
||||
ctlx->outbuf.rmemreq.page);
|
||||
|
||||
WLAN_LOG_DEBUG1(4,"pktsize=%d\n",
|
||||
WLAN_LOG_DEBUG(4,"pktsize=%d\n",
|
||||
ROUNDUP64(sizeof(ctlx->outbuf.rmemreq)));
|
||||
|
||||
/* Fill the out packet */
|
||||
|
@ -1610,7 +1610,7 @@ hfa384x_dormem(
|
|||
/* On reawakening, check the ctlx status */
|
||||
switch(ctlx->state) {
|
||||
case HFA384x_USBCTLX_COMPLETE:
|
||||
WLAN_LOG_DEBUG1(4,"rmemresp:len=%d\n",
|
||||
WLAN_LOG_DEBUG(4,"rmemresp:len=%d\n",
|
||||
ctlx->inbuf.rmemresp.frmlen);
|
||||
memcpy(data, ctlx->inbuf.rmemresp.data, len);
|
||||
result = 0;
|
||||
|
@ -1698,7 +1698,7 @@ hfa384x_dowmem(
|
|||
hfa384x_usbctlx_t *ctlx;
|
||||
|
||||
DBFENTER;
|
||||
WLAN_LOG_DEBUG3(5, "page=0x%04x offset=0x%04x len=%d\n",
|
||||
WLAN_LOG_DEBUG(5, "page=0x%04x offset=0x%04x len=%d\n",
|
||||
page,offset,len);
|
||||
|
||||
ctlx = kmalloc(sizeof(*ctlx), GFP_ATOMIC);
|
||||
|
@ -2061,20 +2061,20 @@ hfa384x_drvr_flashdl_write(
|
|||
int j;
|
||||
|
||||
DBFENTER;
|
||||
WLAN_LOG_DEBUG2(5,"daddr=0x%08lx len=%ld\n", daddr, len);
|
||||
WLAN_LOG_DEBUG(5,"daddr=0x%08lx len=%ld\n", daddr, len);
|
||||
|
||||
/* Check that we're in the flash download state */
|
||||
if ( hw->dlstate != HFA384x_DLSTATE_FLASHENABLED ) {
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
WLAN_LOG_INFO2("Download %ld bytes to flash @0x%06lx\n", len, daddr);
|
||||
WLAN_LOG_INFO("Download %ld bytes to flash @0x%06lx\n", len, daddr);
|
||||
|
||||
/* Convert to flat address for arithmetic */
|
||||
/* NOTE: dlbuffer RID stores the address in AUX format */
|
||||
dlbufaddr = HFA384x_ADDR_AUX_MKFLAT(
|
||||
hw->bufinfo.page, hw->bufinfo.offset);
|
||||
WLAN_LOG_DEBUG3(5,
|
||||
WLAN_LOG_DEBUG(5,
|
||||
"dlbuf.page=0x%04x dlbuf.offset=0x%04x dlbufaddr=0x%08lx\n",
|
||||
hw->bufinfo.page, hw->bufinfo.offset, dlbufaddr);
|
||||
|
||||
|
@ -2086,7 +2086,7 @@ hfa384x_drvr_flashdl_write(
|
|||
}
|
||||
|
||||
#if 0
|
||||
WLAN_LOG_WARNING3("dlbuf@0x%06lx len=%d to=%d\n", dlbufaddr, hw->bufinfo.len, hw->dltimeout);
|
||||
WLAN_LOG_WARNING("dlbuf@0x%06lx len=%d to=%d\n", dlbufaddr, hw->bufinfo.len, hw->dltimeout);
|
||||
#endif
|
||||
/* Calculations to determine how many fills of the dlbuffer to do
|
||||
* and how many USB wmemreq's to do for each fill. At this point
|
||||
|
@ -2113,14 +2113,14 @@ WLAN_LOG_WARNING3("dlbuf@0x%06lx len=%d to=%d\n", dlbufaddr, hw->bufinfo.len, hw
|
|||
burnlo = HFA384x_ADDR_CMD_MKOFF(burndaddr);
|
||||
burnhi = HFA384x_ADDR_CMD_MKPAGE(burndaddr);
|
||||
|
||||
WLAN_LOG_INFO2("Writing %ld bytes to flash @0x%06lx\n",
|
||||
WLAN_LOG_INFO("Writing %ld bytes to flash @0x%06lx\n",
|
||||
burnlen, burndaddr);
|
||||
|
||||
/* Set the download mode */
|
||||
result = hfa384x_cmd_download(hw, HFA384x_PROGMODE_NV,
|
||||
burnlo, burnhi, burnlen);
|
||||
if ( result ) {
|
||||
WLAN_LOG_ERROR4("download(NV,lo=%x,hi=%x,len=%lx) "
|
||||
WLAN_LOG_ERROR("download(NV,lo=%x,hi=%x,len=%lx) "
|
||||
"cmd failed, result=%d. Aborting d/l\n",
|
||||
burnlo, burnhi, burnlen, result);
|
||||
goto exit_proc;
|
||||
|
@ -2154,7 +2154,7 @@ WLAN_LOG_WARNING3("dlbuf@0x%06lx len=%d to=%d\n", dlbufaddr, hw->bufinfo.len, hw
|
|||
|
||||
Comment out for debugging, assume the write was successful.
|
||||
if (result) {
|
||||
WLAN_LOG_ERROR1(
|
||||
WLAN_LOG_ERROR(
|
||||
"Write to dl buffer failed, "
|
||||
"result=0x%04x. Aborting.\n",
|
||||
result);
|
||||
|
@ -2169,7 +2169,7 @@ Comment out for debugging, assume the write was successful.
|
|||
HFA384x_PROGMODE_NVWRITE,
|
||||
0,0,0);
|
||||
if ( result ) {
|
||||
WLAN_LOG_ERROR4(
|
||||
WLAN_LOG_ERROR(
|
||||
"download(NVWRITE,lo=%x,hi=%x,len=%lx) "
|
||||
"cmd failed, result=%d. Aborting d/l\n",
|
||||
burnlo, burnhi, burnlen, result);
|
||||
|
@ -2463,8 +2463,8 @@ hfa384x_drvr_mmi_write(hfa384x_t *hw, UINT32 addr, UINT32 data)
|
|||
UINT16 param1 = (UINT16) data;
|
||||
DBFENTER;
|
||||
|
||||
WLAN_LOG_DEBUG1(1,"mmi write : addr = 0x%08lx\n", addr);
|
||||
WLAN_LOG_DEBUG1(1,"mmi write : data = 0x%08lx\n", data);
|
||||
WLAN_LOG_DEBUG(1,"mmi write : addr = 0x%08lx\n", addr);
|
||||
WLAN_LOG_DEBUG(1,"mmi write : data = 0x%08lx\n", data);
|
||||
|
||||
/* Do i need a host2hfa... conversion ? */
|
||||
result = hfa384x_docmd_wait(hw, cmd_code, param0, param1, 0);
|
||||
|
@ -2563,7 +2563,7 @@ hfa384x_drvr_ramdl_enable(hfa384x_t *hw, UINT32 exeaddr)
|
|||
return -EINVAL;
|
||||
}
|
||||
|
||||
WLAN_LOG_DEBUG1(3,"ramdl_enable, exeaddr=0x%08lx\n", exeaddr);
|
||||
WLAN_LOG_DEBUG(3,"ramdl_enable, exeaddr=0x%08lx\n", exeaddr);
|
||||
|
||||
/* Call the download(1,addr) function */
|
||||
lowaddr = HFA384x_ADDR_CMD_MKOFF(exeaddr);
|
||||
|
@ -2576,7 +2576,7 @@ hfa384x_drvr_ramdl_enable(hfa384x_t *hw, UINT32 exeaddr)
|
|||
/* Set the download state */
|
||||
hw->dlstate = HFA384x_DLSTATE_RAMENABLED;
|
||||
} else {
|
||||
WLAN_LOG_DEBUG3(1,
|
||||
WLAN_LOG_DEBUG(1,
|
||||
"cmd_download(0x%04x, 0x%04x) failed, result=%d.\n",
|
||||
lowaddr,
|
||||
hiaddr,
|
||||
|
@ -2631,7 +2631,7 @@ hfa384x_drvr_ramdl_write(hfa384x_t *hw, UINT32 daddr, void* buf, UINT32 len)
|
|||
return -EINVAL;
|
||||
}
|
||||
|
||||
WLAN_LOG_INFO2("Writing %ld bytes to ram @0x%06lx\n", len, daddr);
|
||||
WLAN_LOG_INFO("Writing %ld bytes to ram @0x%06lx\n", len, daddr);
|
||||
|
||||
/* How many dowmem calls? */
|
||||
nwrites = len / HFA384x_USB_RWMEM_MAXLEN;
|
||||
|
@ -2735,7 +2735,7 @@ int hfa384x_drvr_readpda(hfa384x_t *hw, void *buf, UINT len)
|
|||
NULL, NULL);
|
||||
|
||||
if (result) {
|
||||
WLAN_LOG_WARNING1(
|
||||
WLAN_LOG_WARNING(
|
||||
"Read from index %d failed, continuing\n",
|
||||
i );
|
||||
if ( i >= (sizeof(pdaloc)/sizeof(pdaloc[0])) ){
|
||||
|
@ -2753,14 +2753,14 @@ int hfa384x_drvr_readpda(hfa384x_t *hw, void *buf, UINT len)
|
|||
pdrcode = hfa384x2host_16(pda[currpdr+1]);
|
||||
/* Test the record length */
|
||||
if ( pdrlen > HFA384x_PDR_LEN_MAX || pdrlen == 0) {
|
||||
WLAN_LOG_ERROR1("pdrlen invalid=%d\n",
|
||||
WLAN_LOG_ERROR("pdrlen invalid=%d\n",
|
||||
pdrlen);
|
||||
pdaok = 0;
|
||||
break;
|
||||
}
|
||||
/* Test the code */
|
||||
if ( !hfa384x_isgood_pdrcode(pdrcode) ) {
|
||||
WLAN_LOG_ERROR1("pdrcode invalid=%d\n",
|
||||
WLAN_LOG_ERROR("pdrcode invalid=%d\n",
|
||||
pdrcode);
|
||||
pdaok = 0;
|
||||
break;
|
||||
|
@ -2777,7 +2777,7 @@ int hfa384x_drvr_readpda(hfa384x_t *hw, void *buf, UINT len)
|
|||
}
|
||||
}
|
||||
if ( pdaok ) {
|
||||
WLAN_LOG_DEBUG2(2,
|
||||
WLAN_LOG_DEBUG(2,
|
||||
"PDA Read from 0x%08lx in %s space.\n",
|
||||
pdaloc[i].cardaddr,
|
||||
pdaloc[i].auxctl == 0 ? "EXTDS" :
|
||||
|
@ -2991,7 +2991,7 @@ int hfa384x_drvr_start(hfa384x_t *hw)
|
|||
hw->rx_urb.transfer_flags |= USB_ASYNC_UNLINK;
|
||||
|
||||
if ((result = usb_submit_urb(&hw->rx_urb))) {
|
||||
WLAN_LOG_ERROR1(
|
||||
WLAN_LOG_ERROR(
|
||||
"Fatal, usb_submit_urb() failed, result=%d\n",
|
||||
result);
|
||||
goto done;
|
||||
|
@ -3004,7 +3004,7 @@ int hfa384x_drvr_start(hfa384x_t *hw)
|
|||
if (result != 0) {
|
||||
usb_unlink_urb(&hw->rx_urb);
|
||||
hw->rxurb_posted = 0;
|
||||
WLAN_LOG_ERROR1(
|
||||
WLAN_LOG_ERROR(
|
||||
"cmd_initialize() failed, result=%d\n",
|
||||
result);
|
||||
goto done;
|
||||
|
@ -3175,7 +3175,7 @@ int hfa384x_drvr_txframe(hfa384x_t *hw, struct sk_buff *skb, p80211_hdr_t *p8021
|
|||
hw->tx_urb.transfer_flags |= USB_QUEUE_BULK;
|
||||
|
||||
if ( (result = usb_submit_urb(&hw->tx_urb)) ) {
|
||||
WLAN_LOG_ERROR1(
|
||||
WLAN_LOG_ERROR(
|
||||
"submit_urb() failed, result=%d\n", result);
|
||||
#if 0
|
||||
hw->usbflags &= ~HFA384x_USBFLAG_TXURB_BUSY;
|
||||
|
@ -3218,7 +3218,7 @@ hfa384x_rx_typedrop( wlandevice_t *wlandev, UINT16 fc)
|
|||
ftype = WLAN_GET_FC_FTYPE(fc);
|
||||
fstype = WLAN_GET_FC_FSTYPE(fc);
|
||||
#if 0
|
||||
WLAN_LOG_DEBUG2(4,
|
||||
WLAN_LOG_DEBUG(4,
|
||||
"rx_typedrop : ftype=%d fstype=%d.\n", ftype, fstype);
|
||||
#endif
|
||||
switch ( ftype ) {
|
||||
|
@ -3437,7 +3437,7 @@ void hfa384x_usbctlx_complete(hfa384x_usbctlx_t *ctlx)
|
|||
hfa384x_cbrmem(hw, ctlx);
|
||||
break;
|
||||
default:
|
||||
WLAN_LOG_ERROR1(
|
||||
WLAN_LOG_ERROR(
|
||||
"unknown reqtype=%d, ignored.\n",
|
||||
ctlx->outbuf.type);
|
||||
kfree(ctlx);
|
||||
|
@ -3604,7 +3604,7 @@ hfa384x_usbctlxq_run(
|
|||
head->state == HFA384x_USBCTLX_QUEUED) {
|
||||
result = usb_submit_urb(&head->outurb);
|
||||
if (result) {
|
||||
WLAN_LOG_ERROR1(
|
||||
WLAN_LOG_ERROR(
|
||||
"Fatal, failed to submit command urb. error=%d\n",
|
||||
result);
|
||||
head->state = HFA384x_USBCTLX_REQSUBMIT_FAIL;
|
||||