From 4a4a52d49d11f5c4a0df8b9806c8c5563801f753 Mon Sep 17 00:00:00 2001 From: yuehaibing Date: Wed, 8 Jan 2020 22:08:22 +0800 Subject: [PATCH] vmxnet3: Remove always false conditional statement param->rx_mini_pending is __u32 variable, it will never be less than zero. Signed-off-by: yuehaibing Signed-off-by: David S. Miller --- 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 0a38c76688ab..1e4b9ba70983 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; }