net/tg3: simplify conditional
Simplify: ((a && !b) || (!a && b)) => (a != b) Signed-off-by: Nicolas Kaiser <nikai@nikai.net> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
aa3bc6c68e
commit
2259dca36a
1 changed files with 1 additions and 2 deletions
|
@ -9968,8 +9968,7 @@ static int tg3_set_pauseparam(struct net_device *dev, struct ethtool_pauseparam
|
||||||
|
|
||||||
if (!(phydev->supported & SUPPORTED_Pause) ||
|
if (!(phydev->supported & SUPPORTED_Pause) ||
|
||||||
(!(phydev->supported & SUPPORTED_Asym_Pause) &&
|
(!(phydev->supported & SUPPORTED_Asym_Pause) &&
|
||||||
((epause->rx_pause && !epause->tx_pause) ||
|
(epause->rx_pause != epause->tx_pause)))
|
||||||
(!epause->rx_pause && epause->tx_pause))))
|
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
|
|
||||||
tp->link_config.flowctrl = 0;
|
tp->link_config.flowctrl = 0;
|
||||||
|
|
Loading…
Add table
Reference in a new issue