diff mbox series

mt7603: wait for pre_tbtt_tasklet before scanning

Message ID e7bc3645ce73a15ef9fa16a40f2bdb8577494769.1556280002.git.lorenzo@kernel.org (mailing list archive)
State Superseded
Delegated to: Felix Fietkau
Headers show
Series mt7603: wait for pre_tbtt_tasklet before scanning | expand

Commit Message

Lorenzo Bianconi April 26, 2019, 12:40 p.m. UTC
Disable pre_tbtt_tasklet tasklet before performing frequency scanning

Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
---
 drivers/net/wireless/mediatek/mt76/mt7603/main.c | 2 ++
 1 file changed, 2 insertions(+)

Comments

Lorenzo Bianconi April 28, 2019, 8:57 p.m. UTC | #1
>
> Disable pre_tbtt_tasklet tasklet before performing frequency scanning
>

Hi Felix,

please drop this patch and 'mt76: move common beacon code in mt76
module' series, I will send a v2 rebasing on a new patch

Regards,
Lorenzo

> Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
> ---
>  drivers/net/wireless/mediatek/mt76/mt7603/main.c | 2 ++
>  1 file changed, 2 insertions(+)
>
> diff --git a/drivers/net/wireless/mediatek/mt76/mt7603/main.c b/drivers/net/wireless/mediatek/mt76/mt7603/main.c
> index 18a33d921601..184ed4cead0a 100644
> --- a/drivers/net/wireless/mediatek/mt76/mt7603/main.c
> +++ b/drivers/net/wireless/mediatek/mt76/mt7603/main.c
> @@ -535,6 +535,7 @@ mt7603_sw_scan(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
>         struct mt7603_dev *dev = hw->priv;
>
>         set_bit(MT76_SCANNING, &dev->mt76.state);
> +       tasklet_disable(&dev->pre_tbtt_tasklet);
>         mt7603_beacon_set_timer(dev, -1, 0);
>  }
>
> @@ -545,6 +546,7 @@ mt7603_sw_scan_complete(struct ieee80211_hw *hw, struct ieee80211_vif *vif)
>
>         clear_bit(MT76_SCANNING, &dev->mt76.state);
>         mt7603_beacon_set_timer(dev, -1, dev->beacon_int);
> +       tasklet_enable(&dev->pre_tbtt_tasklet);
>  }
>
>  static void
> --
> 2.20.1
>
diff mbox series

Patch

diff --git a/drivers/net/wireless/mediatek/mt76/mt7603/main.c b/drivers/net/wireless/mediatek/mt76/mt7603/main.c
index 18a33d921601..184ed4cead0a 100644
--- a/drivers/net/wireless/mediatek/mt76/mt7603/main.c
+++ b/drivers/net/wireless/mediatek/mt76/mt7603/main.c
@@ -535,6 +535,7 @@  mt7603_sw_scan(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
 	struct mt7603_dev *dev = hw->priv;
 
 	set_bit(MT76_SCANNING, &dev->mt76.state);
+	tasklet_disable(&dev->pre_tbtt_tasklet);
 	mt7603_beacon_set_timer(dev, -1, 0);
 }
 
@@ -545,6 +546,7 @@  mt7603_sw_scan_complete(struct ieee80211_hw *hw, struct ieee80211_vif *vif)
 
 	clear_bit(MT76_SCANNING, &dev->mt76.state);
 	mt7603_beacon_set_timer(dev, -1, dev->beacon_int);
+	tasklet_enable(&dev->pre_tbtt_tasklet);
 }
 
 static void