* [PATCH net-next] vmxnet3: Remove always false conditional statement
@ 2020-01-08 14:08 YueHaibing
2020-01-09 0:07 ` David Miller
0 siblings, 1 reply; 2+ messages in thread
From: YueHaibing @ 2020-01-08 14:08 UTC (permalink / raw)
To: doshir, pv-drivers, davem; +Cc: netdev, linux-kernel, yuehaibing
From: yuehaibing <yuehaibing@huawei.com>
param->rx_mini_pending is __u32 variable, it will never
be less than zero.
Signed-off-by: yuehaibing <yuehaibing@huawei.com>
---
drivers/net/vmxnet3/vmxnet3_ethtool.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/net/vmxnet3/vmxnet3_ethtool.c b/drivers/net/vmxnet3/vmxnet3_ethtool.c
index 0a38c76..1e4b9ba 100644
--- a/drivers/net/vmxnet3/vmxnet3_ethtool.c
+++ b/drivers/net/vmxnet3/vmxnet3_ethtool.c
@@ -555,10 +555,8 @@ vmxnet3_set_ringparam(struct net_device *netdev,
}
if (VMXNET3_VERSION_GE_3(adapter)) {
- if (param->rx_mini_pending < 0 ||
- param->rx_mini_pending > VMXNET3_RXDATA_DESC_MAX_SIZE) {
+ if (param->rx_mini_pending > VMXNET3_RXDATA_DESC_MAX_SIZE)
return -EINVAL;
- }
} else if (param->rx_mini_pending != 0) {
return -EINVAL;
}
--
2.7.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH net-next] vmxnet3: Remove always false conditional statement
2020-01-08 14:08 [PATCH net-next] vmxnet3: Remove always false conditional statement YueHaibing
@ 2020-01-09 0:07 ` David Miller
0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2020-01-09 0:07 UTC (permalink / raw)
To: yuehaibing; +Cc: doshir, pv-drivers, netdev, linux-kernel
From: YueHaibing <yuehaibing@huawei.com>
Date: Wed, 8 Jan 2020 22:08:22 +0800
> From: yuehaibing <yuehaibing@huawei.com>
>
> param->rx_mini_pending is __u32 variable, it will never
> be less than zero.
>
> Signed-off-by: yuehaibing <yuehaibing@huawei.com>
Applied, thanks.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-01-09 0:07 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-01-08 14:08 [PATCH net-next] vmxnet3: Remove always false conditional statement YueHaibing
2020-01-09 0:07 ` David Miller
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).