-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'net-hns3-add-support-ethtool-extended-link-state'
Guangbin Huang says: ==================== net: hns3: add support ethtool extended link state This series adds support for ethtool extended link state in the HNS3 ethernet driver to add one additional information for user to know why a link is not up. ==================== Link: https://lore.kernel.org/r/1629080129-46507-1-git-send-email-huangguangbin2@huawei.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
- Loading branch information
Showing
7 changed files
with
137 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
/* SPDX-License-Identifier: GPL-2.0+ */ | ||
// Copyright (c) 2021 Hisilicon Limited. | ||
|
||
#ifndef __HNS3_ETHTOOL_H | ||
#define __HNS3_ETHTOOL_H | ||
|
||
#include <linux/ethtool.h> | ||
#include <linux/netdevice.h> | ||
|
||
struct hns3_stats { | ||
char stats_string[ETH_GSTRING_LEN]; | ||
int stats_offset; | ||
}; | ||
|
||
struct hns3_sfp_type { | ||
u8 type; | ||
u8 ext_type; | ||
}; | ||
|
||
struct hns3_pflag_desc { | ||
char name[ETH_GSTRING_LEN]; | ||
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 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters