aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/hisilicon/hns3/hns3_ethtool.h
diff options
context:
space:
mode:
authorGuangbin Huang <huangguangbin2@huawei.com>2021-08-16 10:15:29 +0800
committerJakub Kicinski <kuba@kernel.org>2021-08-16 15:12:14 -0700
commitf5c2b9f0fc078308a88de807d60cd4e352a165fc (patch)
tree7cfa1584bf38a0b9b601a165c0a471b0b969244f /drivers/net/ethernet/hisilicon/hns3/hns3_ethtool.h
parentnet: hns3: add header file hns3_ethtoo.h (diff)
downloadlinux-dev-f5c2b9f0fc078308a88de807d60cd4e352a165fc.tar.xz
linux-dev-f5c2b9f0fc078308a88de807d60cd4e352a165fc.zip
net: hns3: add support ethtool extended link state
In order to know the reason of link up failure, add supporting ethtool extended link state. Driver reads the link status code from firmware if in link down state and converts it to ethtool extended link state. Signed-off-by: Guangbin Huang <huangguangbin2@huawei.com> Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'drivers/net/ethernet/hisilicon/hns3/hns3_ethtool.h')
-rw-r--r--drivers/net/ethernet/hisilicon/hns3/hns3_ethtool.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3_ethtool.h b/drivers/net/ethernet/hisilicon/hns3/hns3_ethtool.h
index 2f186607c6e0..822d6fcbc73b 100644
--- a/drivers/net/ethernet/hisilicon/hns3/hns3_ethtool.h
+++ b/drivers/net/ethernet/hisilicon/hns3/hns3_ethtool.h
@@ -22,4 +22,10 @@ struct hns3_pflag_desc {
void (*handler)(struct net_device *netdev, bool enable);
};
+struct hns3_ethtool_link_ext_state_mapping {
+ u32 status_code;
+ enum ethtool_link_ext_state link_ext_state;
+ u8 link_ext_substate;
+};
+
#endif