Shiji Yang <yangshiji66@xxxxxxxxxxx> wrote: > When I tried to fix the watchdog of rt2800, I found that sometimes > the watchdog can not reset the hung device. This is because the > queue is not completely stuck, it just becomes very slow. The MTK > vendor driver for the new chip MT7603/MT7612 has a DMA busy watchdog > to detect device hangs by checking DMA busy status. This watchdog > implementation is something similar to it. To reduce unnecessary > reset, we can check the INT_SOURCE_CSR register together as I found > that when the radio hung, the RX/TX coherent interrupt will always > stuck at triggered state. > > The 'watchdog' module parameter has been extended to control all > watchdogs(0=disabled, 1=hang watchdog, 2=DMA watchdog, 3=both). This > new watchdog function is a slight schedule and it won't affect the > transmission speed. So we can turn on it by default. Due to the > INT_SOURCE_CSR register is invalid on rt2800 USB NICs, the DMA busy > watchdog will be automatically disabled for them. > > Tested on MT7620 and RT5350. > > Signed-off-by: Shiji Yang <yangshiji66@xxxxxxxxxxx> > Acked-by: Stanislaw Gruszka <stf_xl@xxxxx> 3 patches applied to wireless-next.git, thanks. b1275cdd7456 wifi: rt2x00: introduce DMA busy check watchdog for rt2800 570beb6285fd wifi: rt2x00: disable RTS threshold for rt2800 by default a11d965a218f wifi: rt2x00: restart beacon queue when hardware reset -- https://patchwork.kernel.org/project/linux-wireless/patch/TYAP286MB0315D7462CE08A119A99DE34BCA4A@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx/ https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches