linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ath9k/ath10k: remove unnecessary channel_switch_beacon callbacks
@ 2014-05-16 13:55 Luca Coelho
  2014-05-16 14:26 ` Kalle Valo
  2014-05-23  8:32 ` Kalle Valo
  0 siblings, 2 replies; 5+ messages in thread
From: Luca Coelho @ 2014-05-16 13:55 UTC (permalink / raw)
  To: ath10k, ath9k-devel; +Cc: linux-wireless, michal.kazior

From: Luciano Coelho <luciano.coelho@intel.com>

The channel_switch_beacon callback is optional, so it doesn't have to
be defined if it's not going to do anything useful with it.  Both
ath9k and ath10k define the callback and just returns.  This commit
removes them.

Cc: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Luciano Coelho <luciano.coelho@intel.com>
---

I'm plannnig to remove the channel_switch_beacon callback (actually,
replace it with a more generic one that can be used for STA and other
iftypes too) and ath9k/ath10k are the only (non) users of it. ;)

 drivers/net/wireless/ath/ath10k/mac.c | 9 ---------
 drivers/net/wireless/ath/ath9k/main.c | 9 ---------
 2 files changed, 18 deletions(-)

diff --git a/drivers/net/wireless/ath/ath10k/mac.c b/drivers/net/wireless/ath/ath10k/mac.c
index d1df993..a1c4e5e 100644
--- a/drivers/net/wireless/ath/ath10k/mac.c
+++ b/drivers/net/wireless/ath/ath10k/mac.c
@@ -4035,14 +4035,6 @@ static int ath10k_set_bitrate_mask(struct ieee80211_hw *hw,
 					   fixed_nss, force_sgi);
 }
 
-static void ath10k_channel_switch_beacon(struct ieee80211_hw *hw,
-					 struct ieee80211_vif *vif,
-					 struct cfg80211_chan_def *chandef)
-{
-	/* there's no need to do anything here. vif->csa_active is enough */
-	return;
-}
-
 static void ath10k_sta_rc_update(struct ieee80211_hw *hw,
 				 struct ieee80211_vif *vif,
 				 struct ieee80211_sta *sta,
@@ -4158,7 +4150,6 @@ static const struct ieee80211_ops ath10k_ops = {
 	.restart_complete		= ath10k_restart_complete,
 	.get_survey			= ath10k_get_survey,
 	.set_bitrate_mask		= ath10k_set_bitrate_mask,
-	.channel_switch_beacon		= ath10k_channel_switch_beacon,
 	.sta_rc_update			= ath10k_sta_rc_update,
 	.get_tsf			= ath10k_get_tsf,
 #ifdef CONFIG_PM
diff --git a/drivers/net/wireless/ath/ath9k/main.c b/drivers/net/wireless/ath/ath9k/main.c
index 49265c6..8dc9c77 100644
--- a/drivers/net/wireless/ath/ath9k/main.c
+++ b/drivers/net/wireless/ath/ath9k/main.c
@@ -2085,14 +2085,6 @@ static void ath9k_sw_scan_complete(struct ieee80211_hw *hw)
 	clear_bit(ATH_OP_SCANNING, &common->op_flags);
 }
 
-static void ath9k_channel_switch_beacon(struct ieee80211_hw *hw,
-					struct ieee80211_vif *vif,
-					struct cfg80211_chan_def *chandef)
-{
-	/* depend on vif->csa_active only */
-	return;
-}
-
 struct ieee80211_ops ath9k_ops = {
 	.tx 		    = ath9k_tx,
 	.start 		    = ath9k_start,
@@ -2140,5 +2132,4 @@ struct ieee80211_ops ath9k_ops = {
 #endif
 	.sw_scan_start	    = ath9k_sw_scan_start,
 	.sw_scan_complete   = ath9k_sw_scan_complete,
-	.channel_switch_beacon     = ath9k_channel_switch_beacon,
 };
-- 
2.0.0.rc0


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH] ath9k/ath10k: remove unnecessary channel_switch_beacon callbacks
  2014-05-16 13:55 [PATCH] ath9k/ath10k: remove unnecessary channel_switch_beacon callbacks Luca Coelho
@ 2014-05-16 14:26 ` Kalle Valo
  2014-05-16 15:34   ` John W. Linville
  2014-05-23  8:32 ` Kalle Valo
  1 sibling, 1 reply; 5+ messages in thread
From: Kalle Valo @ 2014-05-16 14:26 UTC (permalink / raw)
  To: Luca Coelho; +Cc: ath10k, ath9k-devel, linux-wireless, michal.kazior

Luca Coelho <luca@coelho.fi> writes:

> From: Luciano Coelho <luciano.coelho@intel.com>
>
> The channel_switch_beacon callback is optional, so it doesn't have to
> be defined if it's not going to do anything useful with it.  Both
> ath9k and ath10k define the callback and just returns.  This commit
> removes them.
>
> Cc: Michal Kazior <michal.kazior@tieto.com>
> Signed-off-by: Luciano Coelho <luciano.coelho@intel.com>
> ---
>
> I'm plannnig to remove the channel_switch_beacon callback (actually,
> replace it with a more generic one that can be used for STA and other
> iftypes too) and ath9k/ath10k are the only (non) users of it. ;)

John, I'm planning to take this as I think we will get less conflicts
that way. But let me know if you want it instead.

-- 
Kalle Valo

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] ath9k/ath10k: remove unnecessary channel_switch_beacon callbacks
  2014-05-16 14:26 ` Kalle Valo
@ 2014-05-16 15:34   ` John W. Linville
  2014-05-16 15:54     ` Kalle Valo
  0 siblings, 1 reply; 5+ messages in thread
From: John W. Linville @ 2014-05-16 15:34 UTC (permalink / raw)
  To: Kalle Valo
  Cc: Luca Coelho, ath10k, ath9k-devel, linux-wireless, michal.kazior

On Fri, May 16, 2014 at 05:26:13PM +0300, Kalle Valo wrote:
> Luca Coelho <luca@coelho.fi> writes:
> 
> > From: Luciano Coelho <luciano.coelho@intel.com>
> >
> > The channel_switch_beacon callback is optional, so it doesn't have to
> > be defined if it's not going to do anything useful with it.  Both
> > ath9k and ath10k define the callback and just returns.  This commit
> > removes them.
> >
> > Cc: Michal Kazior <michal.kazior@tieto.com>
> > Signed-off-by: Luciano Coelho <luciano.coelho@intel.com>
> > ---
> >
> > I'm plannnig to remove the channel_switch_beacon callback (actually,
> > replace it with a more generic one that can be used for STA and other
> > iftypes too) and ath9k/ath10k are the only (non) users of it. ;)
> 
> John, I'm planning to take this as I think we will get less conflicts
> that way. But let me know if you want it instead.

No, that's good.  You will take the ath9k part too, right?

-- 
John W. Linville		Someday the world will need a hero, and you
linville@tuxdriver.com			might be all we have.  Be ready.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] ath9k/ath10k: remove unnecessary channel_switch_beacon callbacks
  2014-05-16 15:34   ` John W. Linville
@ 2014-05-16 15:54     ` Kalle Valo
  0 siblings, 0 replies; 5+ messages in thread
From: Kalle Valo @ 2014-05-16 15:54 UTC (permalink / raw)
  To: John W. Linville
  Cc: linux-wireless, ath9k-devel, Luca Coelho, michal.kazior, ath10k

"John W. Linville" <linville@tuxdriver.com> writes:

>> John, I'm planning to take this as I think we will get less conflicts
>> that way. But let me know if you want it instead.
>
> No, that's good.  You will take the ath9k part too, right?

Yes. I'll take the full patch.

-- 
Kalle Valo

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] ath9k/ath10k: remove unnecessary channel_switch_beacon callbacks
  2014-05-16 13:55 [PATCH] ath9k/ath10k: remove unnecessary channel_switch_beacon callbacks Luca Coelho
  2014-05-16 14:26 ` Kalle Valo
@ 2014-05-23  8:32 ` Kalle Valo
  1 sibling, 0 replies; 5+ messages in thread
From: Kalle Valo @ 2014-05-23  8:32 UTC (permalink / raw)
  To: Luca Coelho; +Cc: ath10k, ath9k-devel, linux-wireless, michal.kazior

Luca Coelho <luca@coelho.fi> writes:

> From: Luciano Coelho <luciano.coelho@intel.com>
>
> The channel_switch_beacon callback is optional, so it doesn't have to
> be defined if it's not going to do anything useful with it.  Both
> ath9k and ath10k define the callback and just returns.  This commit
> removes them.
>
> Cc: Michal Kazior <michal.kazior@tieto.com>
> Signed-off-by: Luciano Coelho <luciano.coelho@intel.com>

Thanks, applied.

-- 
Kalle Valo

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2014-05-23  8:32 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-05-16 13:55 [PATCH] ath9k/ath10k: remove unnecessary channel_switch_beacon callbacks Luca Coelho
2014-05-16 14:26 ` Kalle Valo
2014-05-16 15:34   ` John W. Linville
2014-05-16 15:54     ` Kalle Valo
2014-05-23  8:32 ` Kalle Valo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).