mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-12-24 13:13:57 +08:00
net/mlx5e: Remove unnecessary checks when setting num channels
Boundaries checks for the number of RX and TX should be checked by the caller and not in the driver. Signed-off-by: Eran Ben Elisha <eranbe@mellanox.com> Signed-off-by: Tariq Toukan <tariqt@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
e91ef71dfe
commit
639e9e9416
@ -554,16 +554,6 @@ static int mlx5e_set_channels(struct net_device *dev,
|
||||
__func__);
|
||||
return -EINVAL;
|
||||
}
|
||||
if (ch->rx_count || ch->tx_count) {
|
||||
netdev_info(dev, "%s: separate rx/tx count not supported\n",
|
||||
__func__);
|
||||
return -EINVAL;
|
||||
}
|
||||
if (count > ncv) {
|
||||
netdev_info(dev, "%s: count (%d) > max (%d)\n",
|
||||
__func__, count, ncv);
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
if (priv->params.num_channels == count)
|
||||
return 0;
|
||||
|
Loading…
Reference in New Issue
Block a user