From: Saeed Mahameed Date: Tue, 27 Jan 2015 13:58:06 +0000 (+0200) Subject: net/mlx4_en: Use ethtool cmd->autoneg as a hint for ethtool set settings X-Git-Tag: fixes-v4.0-rc1~150^2~113^2~3 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5a228c03d849c86c10ee69d9951695b0649f82ce;p=pandora-kernel.git net/mlx4_en: Use ethtool cmd->autoneg as a hint for ethtool set settings Use cmd->autoneg as a user hint to decide what to set in ethtool set settings callback. When cmd->autoneg == AUTONEG_ENABLE set according to ethtool->advertise otherwise, set according to ethtool->speed. Usage: - ethtool -s eth speed 56000 autoneg off - ethtool -s eth advertise 0x800000 autoneg on While we're here: - Move proto_admin masking outcome check to be adjacent to the operation. - Move en_warn("port reset..") print to "port reset" block. Fixes: 312df74 ("net/mlx4_en: mlx4_en_set_settings() always fails when autoneg is set") Signed-off-by: Saeed Mahameed Signed-off-by: Amir Vadai Signed-off-by: David S. Miller --- Reading git-diff-tree failed