]> git.baikalelectronics.ru Git - kernel.git/commitdiff
mt76: mt76x02: remove enable from mt76x02_edcca_init signature
authorLorenzo Bianconi <lorenzo@kernel.org>
Sat, 11 May 2019 10:17:51 +0000 (12:17 +0200)
committerFelix Fietkau <nbd@nbd.name>
Tue, 25 Jun 2019 10:55:27 +0000 (12:55 +0200)
Remove enable parameter from mt76x02_edcca_init routine signature since
it is always true

Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
Signed-off-by: Felix Fietkau <nbd@nbd.name>
drivers/net/wireless/mediatek/mt76/mt76x0/main.c
drivers/net/wireless/mediatek/mt76/mt76x02_debugfs.c
drivers/net/wireless/mediatek/mt76/mt76x02_dfs.c
drivers/net/wireless/mediatek/mt76/mt76x02_mac.c
drivers/net/wireless/mediatek/mt76/mt76x02_mac.h
drivers/net/wireless/mediatek/mt76/mt76x2/pci_phy.c
drivers/net/wireless/mediatek/mt76/mt76x2/usb_main.c
drivers/net/wireless/mediatek/mt76/mt76x2/usb_phy.c

index 691984037f98183782db707b8021cec3cf169e8e..800ebbfc30553ecbe3739d938e829ca510148980 100644 (file)
@@ -33,7 +33,7 @@ mt76x0_set_channel(struct mt76x02_dev *dev, struct cfg80211_chan_def *chandef)
        mt76_rr(dev, MT_CH_IDLE);
        mt76_rr(dev, MT_CH_BUSY);
 
-       mt76x02_edcca_init(dev, true);
+       mt76x02_edcca_init(dev);
 
        if (mt76_is_mmio(dev)) {
                mt76x02_dfs_init_params(dev);
index b1d6fd4861e3236b9cb255277c01b9a2f01b1fca..7853078e8ca4ba1a23e57da3afc2351f42165557 100644 (file)
@@ -125,7 +125,7 @@ mt76_edcca_set(void *data, u64 val)
        dev->ed_monitor_enabled = !!val;
        dev->ed_monitor = dev->ed_monitor_enabled &&
                          region == NL80211_DFS_ETSI;
-       mt76x02_edcca_init(dev, true);
+       mt76x02_edcca_init(dev);
 
        return 0;
 }
index 17d12d212d1ba1d0a3eb8f65b9e0ecef42908406..84b845647881385b26ba3bd48a7f1f1680df85de 100644 (file)
@@ -887,7 +887,7 @@ mt76x02_dfs_set_domain(struct mt76x02_dev *dev,
 
                dev->ed_monitor = dev->ed_monitor_enabled &&
                                  region == NL80211_DFS_ETSI;
-               mt76x02_edcca_init(dev, true);
+               mt76x02_edcca_init(dev);
 
                dfs_pd->region = region;
                mt76x02_dfs_init_params(dev);
index 56510a1a843a8aaf787ad0deb4c63f6f15c59a77..ee4a86971be74668f58948791d5147de5e663741 100644 (file)
@@ -945,12 +945,12 @@ mt76x02_edcca_tx_enable(struct mt76x02_dev *dev, bool enable)
        dev->ed_tx_blocked = !enable;
 }
 
-void mt76x02_edcca_init(struct mt76x02_dev *dev, bool enable)
+void mt76x02_edcca_init(struct mt76x02_dev *dev)
 {
        dev->ed_trigger = 0;
        dev->ed_silent = 0;
 
-       if (dev->ed_monitor && enable) {
+       if (dev->ed_monitor) {
                struct ieee80211_channel *chan = dev->mt76.chandef.chan;
                u8 ed_th = chan->band == NL80211_BAND_5GHZ ? 0x0e : 0x20;
 
index e4a9e0d0924b76dcf278cda3356d5690faa5b4d3..cb39da79527ad7a894a2f1cd67399e385a668a88 100644 (file)
@@ -209,5 +209,5 @@ int mt76x02_mac_set_beacon(struct mt76x02_dev *dev, u8 vif_idx,
 void mt76x02_mac_set_beacon_enable(struct mt76x02_dev *dev,
                                   struct ieee80211_vif *vif, bool val);
 
-void mt76x02_edcca_init(struct mt76x02_dev *dev, bool enable);
+void mt76x02_edcca_init(struct mt76x02_dev *dev);
 #endif
index cc1aebcb069666ea44186e94dc1016c7ee48450f..7a39a390a7ac879b2c2ac73985508d4055d87b84 100644 (file)
@@ -74,7 +74,7 @@ mt76x2_phy_channel_calibrate(struct mt76x02_dev *dev, bool mac_stopped)
                mt76x2_mac_resume(dev);
 
        mt76x2_apply_gain_adj(dev);
-       mt76x02_edcca_init(dev, true);
+       mt76x02_edcca_init(dev);
 
        dev->cal.channel_cal_done = true;
 }
index 97bcf6494ec1754b1748e9ede4740c6bfc7f78a5..6657693edc3ec668dbbd6db3c3d75087f405ffdb 100644 (file)
@@ -59,7 +59,7 @@ mt76x2u_set_channel(struct mt76x02_dev *dev,
        err = mt76x2u_phy_set_channel(dev, chandef);
 
        mt76x2_mac_resume(dev);
-       mt76x02_edcca_init(dev, true);
+       mt76x02_edcca_init(dev);
 
        dev->beacon_ops->pre_tbtt_enable(dev, true);
 
index 07f67cb6854cd2708381c83c0b689af1fb3e9c76..c7208c5375ac1cd7c8a8933f331f0726a0bdff76 100644 (file)
@@ -45,7 +45,7 @@ mt76x2u_phy_channel_calibrate(struct mt76x02_dev *dev, bool mac_stopped)
        if (!mac_stopped)
                mt76x2_mac_resume(dev);
        mt76x2_apply_gain_adj(dev);
-       mt76x02_edcca_init(dev, true);
+       mt76x02_edcca_init(dev);
 
        dev->cal.channel_cal_done = true;
 }