mt76x2: add a polling delay in mt76x2_mac_stop routine
Subsystems (2)
A message that is not in the archive (sent off-list or not yet received): [email protected]
PATCH 1/1 mt76x2: add a polling delay in mt76x2_mac_stop routine
Add a usleep_range in mt76x2_mac_stop routine in order to add a polling delay checking values of MT_MAC_STATUS and IBI_R12 registers
Signed-off-by Lorenzo Bianconi <[email protected]>
--- drivers/net/wireless/mediatek/mt76/mt76x2_init.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-)
drivers/net/wireless/mediatek/mt76/mt76x2_init.c +5 -5
@@ -370,12 +370,12 @@ void mt76x2_mac_stop(struct mt76x2_dev *dev, bool force)/* Wait for MAC to become idle */ for (i =0 ; i <300 ; i++) { -if (mt76_rr (dev,MT_MAC_STATUS ) & - (MT_MAC_STATUS_RX |MT_MAC_STATUS_TX )) -continue ; - -if (mt76_rr (dev,MT_BBP (IBI ,12 ))) +if ((mt76_rr (dev,MT_MAC_STATUS ) & + (MT_MAC_STATUS_RX |MT_MAC_STATUS_TX )) || +mt76_rr (dev,MT_BBP (IBI ,12 ))) { +usleep_range (10 ,20 );continue ; + } stopped = true;break ;
Signature · 1 line
2.14.3
Quoted 4 lines · Lorenzo Bianconi
Add a
usleep_rangeinmt76x2_mac_stoproutine in order to add a polling delay checking values ofMT_MAC_STATUSandIBI_R12registersSigned-off-by Lorenzo Bianconi <[email protected]>
Acked-by Felix Fietkau <[email protected]>
Quoted 5 lines · Lorenzo Bianconi
Add a
usleep_rangeinmt76x2_mac_stoproutine in order to add a polling delay checking values ofMT_MAC_STATUSandIBI_R12registersSigned-off-by Lorenzo Bianconi <[email protected]>Acked-by Felix Fietkau <[email protected]>
Patch applied to wireless-drivers-next.git, thanks.
6823dc0d91e5 mt76x2: add a polling delay in mt76x2_mac_stop routine
Signature · 3 lines
https://patchwork.kernel.org/patch/10391839/ https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches