mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-06 02:50:49 +09:00
ethernet: stmmac: stmmac_ethtool: Don't support half duplex mode for multi queue
Half-Duplex can only work with single queue, return error for multi queue half duplex mode setting. Signed-off-by: David Wu <david.wu@rock-chips.com> Change-Id: I1ea4d9f2b9745890e4e0cee6dc2ca8afe82b2d96
This commit is contained in:
@@ -392,6 +392,11 @@ stmmac_ethtool_set_link_ksettings(struct net_device *dev,
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (priv->plat->tx_queues_to_use > 1 && cmd->base.duplex == DUPLEX_HALF) {
|
||||
netdev_warn(priv->dev, "Half-Duplex can only work with single queue\n");
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
return phylink_ethtool_ksettings_set(priv->phylink, cmd);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user