Message ID | 1483707918-31480-2-git-send-email-sgruszka@redhat.com (mailing list archive) |
---|---|
State | Accepted |
Commit | 480b468625da1f054c487f7168e9a9bdc1bf869b |
Delegated to: | Kalle Valo |
Headers | show |
Stanislaw Gruszka <sgruszka@redhat.com> wrote: > On rt2800usb, if we do not get TX status from HW, we assume frames were > posted and after entry->last_action timeout, we forcibly provide TX > status to mac80211. So it's not possible to detect hardware TX hung > based on the timeout. Additionally TXRQ_PCNT tells on number of frames > in the Packet Buffer (buffer between bus interface and chip MAC > subsystem), which can be non zero on normal conditions. To check HW hung > we will need provide some different mechanism, for now remove watchdog > as current implementation is wrong and not useful. > > Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com> 8 patches applied to wireless-drivers-next.git, thanks. 480b468625da rt2800usb: remove watchdog cfe82fbd8423 rt2800: increase TX timeout 15ec51b25e05 rt2x00: save conf settings before reset tuner 01d97ef4b25f rt2800: change default retry settings e4019e7f9530 rt2800: tune TX_RTS_CFG config 170122169676 rt2800usb: mark tx failure on timeout 51583248187c rt2x00: do not flush empty queue 66ecec02e851 rt2800: set max_psdu to 3 on usb devices
diff --git a/drivers/net/wireless/ralink/rt2x00/rt2800usb.c b/drivers/net/wireless/ralink/rt2x00/rt2800usb.c index f38c440..8ec22c0 100644 --- a/drivers/net/wireless/ralink/rt2x00/rt2800usb.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800usb.c @@ -436,47 +436,6 @@ static int rt2800usb_set_device_state(struct rt2x00_dev *rt2x00dev, } /* - * Watchdog handlers - */ -static void rt2800usb_watchdog(struct rt2x00_dev *rt2x00dev) -{ - unsigned int i; - u32 reg; - - rt2x00usb_register_read(rt2x00dev, TXRXQ_PCNT, ®); - if (rt2x00_get_field32(reg, TXRXQ_PCNT_TX0Q)) { - rt2x00_warn(rt2x00dev, "TX HW queue 0 timed out, invoke forced kick\n"); - - rt2x00usb_register_write(rt2x00dev, PBF_CFG, 0xf40012); - - for (i = 0; i < 10; i++) { - udelay(10); - if (!rt2x00_get_field32(reg, TXRXQ_PCNT_TX0Q)) - break; - } - - rt2x00usb_register_write(rt2x00dev, PBF_CFG, 0xf40006); - } - - rt2x00usb_register_read(rt2x00dev, TXRXQ_PCNT, ®); - if (rt2x00_get_field32(reg, TXRXQ_PCNT_TX1Q)) { - rt2x00_warn(rt2x00dev, "TX HW queue 1 timed out, invoke forced kick\n"); - - rt2x00usb_register_write(rt2x00dev, PBF_CFG, 0xf4000a); - - for (i = 0; i < 10; i++) { - udelay(10); - if (!rt2x00_get_field32(reg, TXRXQ_PCNT_TX1Q)) - break; - } - - rt2x00usb_register_write(rt2x00dev, PBF_CFG, 0xf40006); - } - - rt2x00usb_watchdog(rt2x00dev); -} - -/* * TX descriptor initialization */ static __le32 *rt2800usb_get_txwi(struct queue_entry *entry) @@ -877,7 +836,6 @@ static const struct rt2x00lib_ops rt2800usb_rt2x00_ops = { .link_tuner = rt2800_link_tuner, .gain_calibration = rt2800_gain_calibration, .vco_calibration = rt2800_vco_calibration, - .watchdog = rt2800usb_watchdog, .start_queue = rt2800usb_start_queue, .kick_queue = rt2x00usb_kick_queue, .stop_queue = rt2800usb_stop_queue,
On rt2800usb, if we do not get TX status from HW, we assume frames were posted and after entry->last_action timeout, we forcibly provide TX status to mac80211. So it's not possible to detect hardware TX hung based on the timeout. Additionally TXRQ_PCNT tells on number of frames in the Packet Buffer (buffer between bus interface and chip MAC subsystem), which can be non zero on normal conditions. To check HW hung we will need provide some different mechanism, for now remove watchdog as current implementation is wrong and not useful. Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com> --- drivers/net/wireless/ralink/rt2x00/rt2800usb.c | 42 -------------------------- 1 file changed, 42 deletions(-)