mirror of
https://github.com/proski/madwifi
synced 2024-11-25 15:59:39 +03:00
Debugging updates:
* Updated register dump based on ath5k database (refresh the list) * Added a generic debug iwpriv delegation method to if_ath * Added some functions to help diagnose lost ath_buf pointers [resultant fixes will be checked in subsequent commits] git-svn-id: http://madwifi-project.org/svn/madwifi/trunk@3497 0192ed92-7a03-0410-a25b-9323aeb14dbd
This commit is contained in:
parent
eaa447863a
commit
43de3ce1a0
1009
ath/if_ath.c
1009
ath/if_ath.c
File diff suppressed because it is too large
Load Diff
@ -1529,6 +1529,7 @@ static inline void ath_hal_dump_map(struct ath_hal *ah)
|
||||
}
|
||||
|
||||
#include "if_ath_hal_wrappers.h"
|
||||
#include "if_ath_hal_extensions.h"
|
||||
|
||||
#endif /* #ifndef _IF_ATH_HAL_H_ */
|
||||
/* *** THIS IS A GENERATED FILE -- DO NOT EDIT *** */
|
||||
|
@ -452,6 +452,8 @@ struct ath_buf {
|
||||
u_int32_t bf_queueage; /* "age" of txq when this buffer placed on stageq */
|
||||
dma_addr_t bf_skbaddrff[ATH_TXDESC - 1]; /* extra addrs for FF */
|
||||
#endif
|
||||
int bf_taken_at_line; /* XXX: Want full alloc backtrace */
|
||||
const char* bf_taken_at_func;
|
||||
};
|
||||
|
||||
/*
|
||||
@ -477,6 +479,8 @@ struct ath_descdma {
|
||||
struct ath_desc *dd_desc; /* descriptors */
|
||||
dma_addr_t dd_desc_paddr; /* physical addr of dd_desc */
|
||||
size_t dd_desc_len; /* size of dd_desc */
|
||||
unsigned int dd_ndesc;
|
||||
unsigned int dd_nbuf;
|
||||
struct ath_buf *dd_bufptr; /* associated buffers */
|
||||
};
|
||||
|
||||
@ -718,7 +722,7 @@ struct ath_softc {
|
||||
u_int sc_ledpin; /* GPIO pin for driving LED */
|
||||
u_int sc_ledon; /* pin setting for LED on */
|
||||
u_int sc_ledidle; /* idle polling interval */
|
||||
int sc_ledevent; /* time of last LED event */
|
||||
long unsigned int sc_ledevent; /* time of last LED event */
|
||||
u_int8_t sc_rxrate; /* current rx rate for LED */
|
||||
u_int8_t sc_txrate; /* current tx rate for LED */
|
||||
u_int16_t sc_ledoff; /* off time for current blink */
|
||||
@ -751,6 +755,7 @@ struct ath_softc {
|
||||
u_int8_t sc_grppoll_str[GRPPOLL_RATE_STR_LEN];
|
||||
struct ath_descdma sc_bdma; /* beacon descriptors */
|
||||
ath_bufhead sc_bbuf; /* beacon buffers */
|
||||
spinlock_t sc_bbuflock; /* beacon buffers lock */
|
||||
u_int sc_bhalq; /* HAL q for outgoing beacons */
|
||||
u_int sc_bmisscount; /* missed beacon transmits */
|
||||
u_int32_t sc_ant_tx[8]; /* recent tx frames/antenna */
|
||||
@ -759,6 +764,7 @@ struct ath_softc {
|
||||
struct ath_txq *sc_xrtxq; /* tx q for XR data */
|
||||
struct ath_descdma sc_grppolldma; /* TX descriptors for grppoll */
|
||||
ath_bufhead sc_grppollbuf; /* transmit buffers for grouppoll */
|
||||
spinlock_t sc_grppollbuflock; /* grouppoll lock */
|
||||
u_int16_t sc_xrpollint; /* xr poll interval */
|
||||
u_int16_t sc_xrpollcount; /* xr poll count */
|
||||
struct ath_txq *sc_uapsdq; /* tx q for uapsd */
|
||||
|
@ -642,6 +642,13 @@ enum {
|
||||
IEEE80211_PARAM_BEACON_MISS_THRESH = 73, /* Beacon miss threshold (in beacons) */
|
||||
IEEE80211_PARAM_BEACON_MISS_THRESH_MS = 74, /* Beacon miss threshold (in ms) */
|
||||
IEEE80211_PARAM_RSSI_EWMA = 75,
|
||||
IEEE80211_PARAM_DRAINTXQ = 76, /* Drain transmit queues */
|
||||
IEEE80211_PARAM_STOP_QUEUE = 77, /* Stop the device queue (for testing) */
|
||||
IEEE80211_PARAM_TXTIMEOUT = 78, /* Simulate Transmit timeout */
|
||||
IEEE80211_PARAM_ATHRESET = 79, /* Force device reset */
|
||||
IEEE80211_PARAM_RESETTXBUFS = 80, /* Reset transmit DMA */
|
||||
IEEE80211_PARAM_SCANBUFS = 81, /* Heap analysis for TX DMA */
|
||||
IEEE80211_PARAM_LEAKTXBUFS = 82, /* Leak tx buffers */
|
||||
};
|
||||
|
||||
#define SIOCG80211STATS (SIOCDEVPRIVATE+2)
|
||||
|
@ -55,6 +55,7 @@ extern const char *ieee80211_ctl_subtype_name[];
|
||||
extern const char *ieee80211_state_name[IEEE80211_S_MAX];
|
||||
extern const char *ieee80211_wme_acnames[];
|
||||
extern const char *ieee80211_phymode_name[];
|
||||
extern const char *ieee80211_opmode_name[];
|
||||
|
||||
void ieee80211_proto_attach(struct ieee80211com *);
|
||||
void ieee80211_proto_detach(struct ieee80211com *);
|
||||
|
@ -518,6 +518,7 @@ struct ieee80211com {
|
||||
unsigned int (*ic_write_register)(struct ieee80211com *, unsigned int, unsigned int);
|
||||
unsigned int (*ic_read_register)(struct ieee80211com *, unsigned int, unsigned int*);
|
||||
#endif /* #ifdef ATH_REVERSE_ENGINEERING */
|
||||
int (*ic_debug_ath_iwpriv)(struct ieee80211com *, unsigned int param, unsigned int value);
|
||||
};
|
||||
|
||||
#define MAX_PROC_IEEE80211_SIZE 16383
|
||||
|
@ -372,6 +372,9 @@ ieee80211_ioctl_siwrate(struct net_device *dev, struct iw_request_info *info,
|
||||
retv = ifmedia_ioctl(vap->iv_dev, &ifr, &vap->iv_media, SIOCSIFMEDIA);
|
||||
if (retv == -ENETRESET)
|
||||
retv = IS_UP_AUTO(vap) ? ieee80211_open(vap->iv_dev) : 0;
|
||||
if (retv)
|
||||
IEEE80211_DPRINTF(vap, IEEE80211_MSG_DEBUG, "%s returns %d\n",
|
||||
__func__, retv);
|
||||
return retv;
|
||||
}
|
||||
|
||||
@ -767,7 +770,8 @@ ieee80211_ioctl_siwfreq(struct net_device *dev, struct iw_request_info *info,
|
||||
* effect when we are transitioned to RUN state later. */
|
||||
if (IS_UP(vap->iv_dev) &&
|
||||
(0 == (vap->iv_des_chan->ic_flags & CHANNEL_DFS))) {
|
||||
pre_announced_chanswitch(dev, ieee80211_chan2ieee(ic, vap->iv_des_chan),
|
||||
pre_announced_chanswitch(dev,
|
||||
ieee80211_chan2ieee(ic, vap->iv_des_chan),
|
||||
IEEE80211_DEFAULT_CHANCHANGE_TBTT_COUNT);
|
||||
}
|
||||
else if (vap->iv_state == IEEE80211_S_RUN) {
|
||||
@ -2575,6 +2579,16 @@ ieee80211_ioctl_setparam(struct net_device *dev, struct iw_request_info *info,
|
||||
} else
|
||||
retv = EINVAL;
|
||||
break;
|
||||
case IEEE80211_PARAM_DRAINTXQ: /* fallthrough */
|
||||
case IEEE80211_PARAM_STOP_QUEUE: /* fallthrough */
|
||||
case IEEE80211_PARAM_ATHRESET: /* fallthrough */
|
||||
case IEEE80211_PARAM_TXTIMEOUT: /* fallthrough */
|
||||
case IEEE80211_PARAM_RESETTXBUFS: /* fallthrough */
|
||||
case IEEE80211_PARAM_SCANBUFS: /* fallthrough */
|
||||
case IEEE80211_PARAM_LEAKTXBUFS: /* fallthrough */
|
||||
retv = ic->ic_debug_ath_iwpriv(ic, param, value);
|
||||
break;
|
||||
|
||||
case IEEE80211_PARAM_BEACON_MISS_THRESH_MS:
|
||||
if ((vap->iv_opmode != IEEE80211_M_IBSS) &&
|
||||
(vap->iv_opmode != IEEE80211_M_STA))
|
||||
@ -5582,11 +5596,24 @@ static const struct iw_priv_args ieee80211_priv_args[] = {
|
||||
0, IW_PRIV_TYPE_APPIEBUF, "getiebuf" },
|
||||
{ IEEE80211_IOCTL_FILTERFRAME,
|
||||
IW_PRIV_TYPE_FILTER , 0, "setfilter" },
|
||||
|
||||
{ IEEE80211_PARAM_RSSI_EWMA,
|
||||
IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, 0, "rssi_ewma" },
|
||||
{ IEEE80211_PARAM_RSSI_EWMA,
|
||||
0, IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, "get_rssi_ewma" },
|
||||
{ IEEE80211_PARAM_DRAINTXQ,
|
||||
IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, 0, "debug_draintxq" },
|
||||
{ IEEE80211_PARAM_STOP_QUEUE,
|
||||
IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, 0, "debug_stopq" },
|
||||
{ IEEE80211_PARAM_TXTIMEOUT,
|
||||
IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, 0, "debug_txtimeout" },
|
||||
{ IEEE80211_PARAM_ATHRESET,
|
||||
IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, 0, "debug_athreset" },
|
||||
{ IEEE80211_PARAM_RESETTXBUFS,
|
||||
IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, 0, "debug_newtxbufs" },
|
||||
{ IEEE80211_PARAM_SCANBUFS,
|
||||
IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, 0, "debug_scanbufs" },
|
||||
{ IEEE80211_PARAM_LEAKTXBUFS,
|
||||
IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, 0, "debug_leaktxbufs" },
|
||||
|
||||
#ifdef ATH_REVERSE_ENGINEERING
|
||||
/*
|
||||
|
Loading…
Reference in New Issue
Block a user