linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] mwifiex: delete unused mwifiex_get_intf_num()
@ 2019-12-10  0:39 Brian Norris
  2019-12-18 19:05 ` Kalle Valo
  0 siblings, 1 reply; 2+ messages in thread
From: Brian Norris @ 2019-12-10  0:39 UTC (permalink / raw)
  To: linux-wireless
  Cc: linux-kernel, Ganapathi Bhat, Nishant Sarmukadam,
	Amitkumar Karwar, Xinming Hu, Sharvari Harisangam, Brian Norris

Commit 7afb94da3cd8 ("mwifiex: update set_mac_address logic") fixed the
only user of this function, partly because the author seems to have
noticed that, as written, it's on the borderline between highly
misleading and buggy.

Anyway, no sense in keeping dead code around: let's drop it.

Fixes: 7afb94da3cd8 ("mwifiex: update set_mac_address logic")
Signed-off-by: Brian Norris <briannorris@chromium.org>
---
 drivers/net/wireless/marvell/mwifiex/main.h | 13 -------------
 1 file changed, 13 deletions(-)

diff --git a/drivers/net/wireless/marvell/mwifiex/main.h b/drivers/net/wireless/marvell/mwifiex/main.h
index 095837fba300..56a18a7f6853 100644
--- a/drivers/net/wireless/marvell/mwifiex/main.h
+++ b/drivers/net/wireless/marvell/mwifiex/main.h
@@ -1294,19 +1294,6 @@ mwifiex_copy_rates(u8 *dest, u32 pos, u8 *src, int len)
 	return pos;
 }
 
-/* This function return interface number with the same bss_type.
- */
-static inline u8
-mwifiex_get_intf_num(struct mwifiex_adapter *adapter, u8 bss_type)
-{
-	u8 i, num = 0;
-
-	for (i = 0; i < adapter->priv_num; i++)
-		if (adapter->priv[i] && adapter->priv[i]->bss_type == bss_type)
-			num++;
-	return num;
-}
-
 /*
  * This function returns the correct private structure pointer based
  * upon the BSS type and BSS number.
-- 
2.24.0.393.g34dc348eaf-goog


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

* Re: [PATCH] mwifiex: delete unused mwifiex_get_intf_num()
  2019-12-10  0:39 [PATCH] mwifiex: delete unused mwifiex_get_intf_num() Brian Norris
@ 2019-12-18 19:05 ` Kalle Valo
  0 siblings, 0 replies; 2+ messages in thread
From: Kalle Valo @ 2019-12-18 19:05 UTC (permalink / raw)
  To: Brian Norris
  Cc: linux-wireless, linux-kernel, Ganapathi Bhat, Nishant Sarmukadam,
	Amitkumar Karwar, Xinming Hu, Sharvari Harisangam, Brian Norris

Brian Norris <briannorris@chromium.org> wrote:

> Commit 7afb94da3cd8 ("mwifiex: update set_mac_address logic") fixed the
> only user of this function, partly because the author seems to have
> noticed that, as written, it's on the borderline between highly
> misleading and buggy.
> 
> Anyway, no sense in keeping dead code around: let's drop it.
> 
> Fixes: 7afb94da3cd8 ("mwifiex: update set_mac_address logic")
> Signed-off-by: Brian Norris <briannorris@chromium.org>

Patch applied to wireless-drivers-next.git, thanks.

1c9f329b084b mwifiex: delete unused mwifiex_get_intf_num()

-- 
https://patchwork.kernel.org/patch/11281155/

https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches

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

end of thread, other threads:[~2019-12-18 19:05 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-12-10  0:39 [PATCH] mwifiex: delete unused mwifiex_get_intf_num() Brian Norris
2019-12-18 19:05 ` 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).