linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] brcmfmac: Remove always false 'idx < 0' statement
@ 2020-01-08 13:57 YueHaibing
  2020-01-26 15:43 ` Kalle Valo
  0 siblings, 1 reply; 2+ messages in thread
From: YueHaibing @ 2020-01-08 13:57 UTC (permalink / raw)
  To: kvalo, arend.vanspriel
  Cc: linux-wireless, brcm80211-dev-list.pdl, brcm80211-dev-list,
	netdev, linux-kernel, yuehaibing

From: yuehaibing <yuehaibing@huawei.com>

idx is declared as u32, it will never less than 0.

Signed-off-by: yuehaibing <yuehaibing@huawei.com>
---
 drivers/net/wireless/broadcom/brcm80211/brcmfmac/msgbuf.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/msgbuf.c b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/msgbuf.c
index e3dd862..8bb4f1f 100644
--- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/msgbuf.c
+++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/msgbuf.c
@@ -365,7 +365,7 @@ brcmf_msgbuf_get_pktid(struct device *dev, struct brcmf_msgbuf_pktids *pktids,
 	struct brcmf_msgbuf_pktid *pktid;
 	struct sk_buff *skb;
 
-	if (idx < 0 || idx >= pktids->array_size) {
+	if (idx >= pktids->array_size) {
 		brcmf_err("Invalid packet id %d (max %d)\n", idx,
 			  pktids->array_size);
 		return NULL;
-- 
2.7.4



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

* Re: [PATCH] brcmfmac: Remove always false 'idx < 0' statement
  2020-01-08 13:57 [PATCH] brcmfmac: Remove always false 'idx < 0' statement YueHaibing
@ 2020-01-26 15:43 ` Kalle Valo
  0 siblings, 0 replies; 2+ messages in thread
From: Kalle Valo @ 2020-01-26 15:43 UTC (permalink / raw)
  To: YueHaibing
  Cc: arend.vanspriel, linux-wireless, brcm80211-dev-list.pdl,
	brcm80211-dev-list, netdev, linux-kernel, yuehaibing

YueHaibing <yuehaibing@huawei.com> wrote:

> From: yuehaibing <yuehaibing@huawei.com>
> 
> idx is declared as u32, it will never less than 0.
> 
> Signed-off-by: yuehaibing <yuehaibing@huawei.com>

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

627b0d094240 brcmfmac: Remove always false 'idx < 0' statement

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

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

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

end of thread, other threads:[~2020-01-26 15:43 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-01-08 13:57 [PATCH] brcmfmac: Remove always false 'idx < 0' statement YueHaibing
2020-01-26 15:43 ` 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).