netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] b43legacy: Remove the unused function prev_slot()
@ 2023-03-30  2:18 Jiapeng Chong
  2023-03-30 14:12 ` Simon Horman
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Jiapeng Chong @ 2023-03-30  2:18 UTC (permalink / raw)
  To: Larry.Finger
  Cc: kvalo, davem, edumazet, kuba, pabeni, linux-wireless, b43-dev,
	netdev, linux-kernel, Jiapeng Chong, Abaci Robot

The function prev_slot is defined in the dma.c file, but not called
elsewhere, so remove this unused function.

drivers/net/wireless/broadcom/b43legacy/dma.c:130:19: warning: unused function 'prev_slot'.

Reported-by: Abaci Robot <abaci@linux.alibaba.com>
Link: https://bugzilla.openanolis.cn/show_bug.cgi?id=4642
Signed-off-by: Jiapeng Chong <jiapeng.chong@linux.alibaba.com>
---
 drivers/net/wireless/broadcom/b43legacy/dma.c | 8 --------
 1 file changed, 8 deletions(-)

diff --git a/drivers/net/wireless/broadcom/b43legacy/dma.c b/drivers/net/wireless/broadcom/b43legacy/dma.c
index 6869f2bf1bae..60e41de72f29 100644
--- a/drivers/net/wireless/broadcom/b43legacy/dma.c
+++ b/drivers/net/wireless/broadcom/b43legacy/dma.c
@@ -127,14 +127,6 @@ static inline int next_slot(struct b43legacy_dmaring *ring, int slot)
 	return slot + 1;
 }
 
-static inline int prev_slot(struct b43legacy_dmaring *ring, int slot)
-{
-	B43legacy_WARN_ON(!(slot >= 0 && slot <= ring->nr_slots - 1));
-	if (slot == 0)
-		return ring->nr_slots - 1;
-	return slot - 1;
-}
-
 #ifdef CONFIG_B43LEGACY_DEBUG
 static void update_max_used_slots(struct b43legacy_dmaring *ring,
 				  int current_used_slots)
-- 
2.20.1.7.g153144c


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

* Re: [PATCH] b43legacy: Remove the unused function prev_slot()
  2023-03-30  2:18 [PATCH] b43legacy: Remove the unused function prev_slot() Jiapeng Chong
@ 2023-03-30 14:12 ` Simon Horman
  2023-03-30 15:46 ` Larry Finger
  2023-04-03 13:42 ` wifi: " Kalle Valo
  2 siblings, 0 replies; 4+ messages in thread
From: Simon Horman @ 2023-03-30 14:12 UTC (permalink / raw)
  To: Jiapeng Chong
  Cc: Larry.Finger, kvalo, davem, edumazet, kuba, pabeni,
	linux-wireless, b43-dev, netdev, linux-kernel, Abaci Robot

On Thu, Mar 30, 2023 at 10:18:41AM +0800, Jiapeng Chong wrote:
> The function prev_slot is defined in the dma.c file, but not called
> elsewhere, so remove this unused function.
> 
> drivers/net/wireless/broadcom/b43legacy/dma.c:130:19: warning: unused function 'prev_slot'.
> 
> Reported-by: Abaci Robot <abaci@linux.alibaba.com>
> Link: https://bugzilla.openanolis.cn/show_bug.cgi?id=4642
> Signed-off-by: Jiapeng Chong <jiapeng.chong@linux.alibaba.com>

Reviewed-by: Simon Horman <simon.horman@corigine.com>


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

* Re: [PATCH] b43legacy: Remove the unused function prev_slot()
  2023-03-30  2:18 [PATCH] b43legacy: Remove the unused function prev_slot() Jiapeng Chong
  2023-03-30 14:12 ` Simon Horman
@ 2023-03-30 15:46 ` Larry Finger
  2023-04-03 13:42 ` wifi: " Kalle Valo
  2 siblings, 0 replies; 4+ messages in thread
From: Larry Finger @ 2023-03-30 15:46 UTC (permalink / raw)
  To: Jiapeng Chong
  Cc: kvalo, davem, edumazet, kuba, pabeni, linux-wireless, b43-dev,
	netdev, linux-kernel, Abaci Robot

On 3/29/23 21:18, Jiapeng Chong wrote:
> The function prev_slot is defined in the dma.c file, but not called
> elsewhere, so remove this unused function.
> 
> drivers/net/wireless/broadcom/b43legacy/dma.c:130:19: warning: unused function 'prev_slot'.
> 
> Reported-by: Abaci Robot <abaci@linux.alibaba.com>
> Link: https://bugzilla.openanolis.cn/show_bug.cgi?id=4642
> Signed-off-by: Jiapeng Chong <jiapeng.chong@linux.alibaba.com>
> ---
>   drivers/net/wireless/broadcom/b43legacy/dma.c | 8 --------
>   1 file changed, 8 deletions(-)

Acked-by: Larry Finger <Larry.Finger@lwfinger.net>

Thanks,

Larry


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

* Re: wifi: b43legacy: Remove the unused function prev_slot()
  2023-03-30  2:18 [PATCH] b43legacy: Remove the unused function prev_slot() Jiapeng Chong
  2023-03-30 14:12 ` Simon Horman
  2023-03-30 15:46 ` Larry Finger
@ 2023-04-03 13:42 ` Kalle Valo
  2 siblings, 0 replies; 4+ messages in thread
From: Kalle Valo @ 2023-04-03 13:42 UTC (permalink / raw)
  To: Jiapeng Chong
  Cc: Larry.Finger, davem, edumazet, kuba, pabeni, linux-wireless,
	b43-dev, netdev, linux-kernel, Jiapeng Chong, Abaci Robot

Jiapeng Chong <jiapeng.chong@linux.alibaba.com> wrote:

> The function prev_slot is defined in the dma.c file, but not called
> elsewhere, so remove this unused function.
> 
> drivers/net/wireless/broadcom/b43legacy/dma.c:130:19: warning: unused function 'prev_slot'.
> 
> Reported-by: Abaci Robot <abaci@linux.alibaba.com>
> Link: https://bugzilla.openanolis.cn/show_bug.cgi?id=4642
> Signed-off-by: Jiapeng Chong <jiapeng.chong@linux.alibaba.com>
> Reviewed-by: Simon Horman <simon.horman@corigine.com>
> Acked-by: Larry Finger <Larry.Finger@lwfinger.net>

Patch applied to wireless-next.git, thanks.

e83ce86aa7d9 wifi: b43legacy: Remove the unused function prev_slot()

-- 
https://patchwork.kernel.org/project/linux-wireless/patch/20230330021841.67724-1-jiapeng.chong@linux.alibaba.com/

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


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

end of thread, other threads:[~2023-04-03 13:42 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-03-30  2:18 [PATCH] b43legacy: Remove the unused function prev_slot() Jiapeng Chong
2023-03-30 14:12 ` Simon Horman
2023-03-30 15:46 ` Larry Finger
2023-04-03 13:42 ` wifi: " 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).