mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager
synced 2024-09-06 17:14:02 +00:00
ethtool: add more offload features that kernel supports
New features: - ethtool.feature-macsec-hw-offload - ethtool.feature-rx-gro-list - ethtool.feature-rx-udp-gro-forwarding - ethtool.feature-tls-hw-rx-offload - ethtool.feature-tx-gso-list - ethtool.feature-tx-tunnel-remcsum-segmentation https://gitlab.freedesktop.org/NetworkManager/NetworkManager/-/merge_requests/735
This commit is contained in:
parent
4f9a7f883e
commit
f72278eff7
|
@ -460,6 +460,7 @@
|
|||
<property name="feature-l2-fwd-offload" />
|
||||
<property name="feature-loopback" />
|
||||
<property name="feature-lro" />
|
||||
<property name="feature-macsec-hw-offload" />
|
||||
<property name="feature-ntuple" />
|
||||
<property name="feature-rx" />
|
||||
<property name="feature-rxhash" />
|
||||
|
@ -467,12 +468,15 @@
|
|||
<property name="feature-rx-all" />
|
||||
<property name="feature-rx-fcs" />
|
||||
<property name="feature-rx-gro-hw" />
|
||||
<property name="feature-rx-gro-list" />
|
||||
<property name="feature-rx-udp-gro-forwarding" />
|
||||
<property name="feature-rx-udp_tunnel-port-offload" />
|
||||
<property name="feature-rx-vlan-filter" />
|
||||
<property name="feature-rx-vlan-stag-filter" />
|
||||
<property name="feature-rx-vlan-stag-hw-parse" />
|
||||
<property name="feature-sg" />
|
||||
<property name="feature-tls-hw-record" />
|
||||
<property name="feature-tls-hw-rx-offload" />
|
||||
<property name="feature-tls-hw-tx-offload" />
|
||||
<property name="feature-tso" />
|
||||
<property name="feature-tx" />
|
||||
|
@ -486,6 +490,7 @@
|
|||
<property name="feature-tx-fcoe-segmentation" />
|
||||
<property name="feature-tx-gre-csum-segmentation" />
|
||||
<property name="feature-tx-gre-segmentation" />
|
||||
<property name="feature-tx-gso-list" />
|
||||
<property name="feature-tx-gso-partial" />
|
||||
<property name="feature-tx-gso-robust" />
|
||||
<property name="feature-tx-ipxip4-segmentation" />
|
||||
|
@ -498,6 +503,7 @@
|
|||
<property name="feature-tx-tcp-ecn-segmentation" />
|
||||
<property name="feature-tx-tcp-mangleid-segmentation" />
|
||||
<property name="feature-tx-tcp-segmentation" />
|
||||
<property name="feature-tx-tunnel-remcsum-segmentation" />
|
||||
<property name="feature-tx-udp-segmentation" />
|
||||
<property name="feature-tx-udp_tnl-csum-segmentation" />
|
||||
<property name="feature-tx-udp_tnl-segmentation" />
|
||||
|
|
|
@ -5504,6 +5504,7 @@ static const NMMetaPropertyInfo *const property_infos_ETHTOOL[] = {
|
|||
PROPERTY_INFO_ETHTOOL (FEATURE_L2_FWD_OFFLOAD),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_LOOPBACK),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_LRO),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_MACSEC_HW_OFFLOAD),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_NTUPLE),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_RX),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_RXHASH),
|
||||
|
@ -5511,12 +5512,15 @@ static const NMMetaPropertyInfo *const property_infos_ETHTOOL[] = {
|
|||
PROPERTY_INFO_ETHTOOL (FEATURE_RX_ALL),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_RX_FCS),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_RX_GRO_HW),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_RX_GRO_LIST),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_RX_UDP_GRO_FORWARDING),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_RX_UDP_TUNNEL_PORT_OFFLOAD),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_RX_VLAN_FILTER),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_RX_VLAN_STAG_FILTER),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_RX_VLAN_STAG_HW_PARSE),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_SG),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_TLS_HW_RECORD),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_TLS_HW_RX_OFFLOAD),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_TLS_HW_TX_OFFLOAD),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_TSO),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_TX),
|
||||
|
@ -5530,6 +5534,7 @@ static const NMMetaPropertyInfo *const property_infos_ETHTOOL[] = {
|
|||
PROPERTY_INFO_ETHTOOL (FEATURE_TX_FCOE_SEGMENTATION),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_TX_GRE_CSUM_SEGMENTATION),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_TX_GRE_SEGMENTATION),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_TX_GSO_LIST),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_TX_GSO_PARTIAL),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_TX_GSO_ROBUST),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_TX_IPXIP4_SEGMENTATION),
|
||||
|
@ -5542,6 +5547,7 @@ static const NMMetaPropertyInfo *const property_infos_ETHTOOL[] = {
|
|||
PROPERTY_INFO_ETHTOOL (FEATURE_TX_TCP_ECN_SEGMENTATION),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_TX_TCP_MANGLEID_SEGMENTATION),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_TX_TCP_SEGMENTATION),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_TX_TUNNEL_REMCSUM_SEGMENTATION),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_TX_UDP_SEGMENTATION),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_TX_UDP_TNL_CSUM_SEGMENTATION),
|
||||
PROPERTY_INFO_ETHTOOL (FEATURE_TX_UDP_TNL_SEGMENTATION),
|
||||
|
|
|
@ -9613,6 +9613,11 @@ test_ethtool_offload(void)
|
|||
g_assert(d);
|
||||
g_assert_cmpint(d->id, ==, NM_ETHTOOL_ID_FEATURE_RXHASH);
|
||||
g_assert_cmpstr(d->optname, ==, NM_ETHTOOL_OPTNAME_FEATURE_RXHASH);
|
||||
|
||||
/* these features are NETIF_F_NEVER_CHANGE: */
|
||||
g_assert(!nm_ethtool_data_get_by_optname("feature-netns-local"));
|
||||
g_assert(!nm_ethtool_data_get_by_optname("feature-tx-lockless"));
|
||||
g_assert(!nm_ethtool_data_get_by_optname("feature-vlan-challenged"));
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
|
|
|
@ -20,6 +20,7 @@ G_BEGIN_DECLS
|
|||
#define NM_ETHTOOL_OPTNAME_FEATURE_L2_FWD_OFFLOAD "feature-l2-fwd-offload"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_LOOPBACK "feature-loopback"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_LRO "feature-lro"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_MACSEC_HW_OFFLOAD "feature-macsec-hw-offload"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_NTUPLE "feature-ntuple"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_RX "feature-rx"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_RXHASH "feature-rxhash"
|
||||
|
@ -27,12 +28,15 @@ G_BEGIN_DECLS
|
|||
#define NM_ETHTOOL_OPTNAME_FEATURE_RX_ALL "feature-rx-all"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_RX_FCS "feature-rx-fcs"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_RX_GRO_HW "feature-rx-gro-hw"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_RX_GRO_LIST "feature-rx-gro-list"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_RX_UDP_GRO_FORWARDING "feature-rx-udp-gro-forwarding"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_RX_UDP_TUNNEL_PORT_OFFLOAD "feature-rx-udp_tunnel-port-offload"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_RX_VLAN_FILTER "feature-rx-vlan-filter"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_RX_VLAN_STAG_FILTER "feature-rx-vlan-stag-filter"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_RX_VLAN_STAG_HW_PARSE "feature-rx-vlan-stag-hw-parse"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_SG "feature-sg"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_TLS_HW_RECORD "feature-tls-hw-record"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_TLS_HW_RX_OFFLOAD "feature-tls-hw-rx-offload"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_TLS_HW_TX_OFFLOAD "feature-tls-hw-tx-offload"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_TSO "feature-tso"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_TX "feature-tx"
|
||||
|
@ -46,6 +50,7 @@ G_BEGIN_DECLS
|
|||
#define NM_ETHTOOL_OPTNAME_FEATURE_TX_FCOE_SEGMENTATION "feature-tx-fcoe-segmentation"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_TX_GRE_CSUM_SEGMENTATION "feature-tx-gre-csum-segmentation"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_TX_GRE_SEGMENTATION "feature-tx-gre-segmentation"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_TX_GSO_LIST "feature-tx-gso-list"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_TX_GSO_PARTIAL "feature-tx-gso-partial"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_TX_GSO_ROBUST "feature-tx-gso-robust"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_TX_IPXIP4_SEGMENTATION "feature-tx-ipxip4-segmentation"
|
||||
|
@ -59,6 +64,8 @@ G_BEGIN_DECLS
|
|||
#define NM_ETHTOOL_OPTNAME_FEATURE_TX_TCP_MANGLEID_SEGMENTATION \
|
||||
"feature-tx-tcp-mangleid-segmentation"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_TX_TCP_SEGMENTATION "feature-tx-tcp-segmentation"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_TX_TUNNEL_REMCSUM_SEGMENTATION \
|
||||
"feature-tx-tunnel-remcsum-segmentation"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_TX_UDP_SEGMENTATION "feature-tx-udp-segmentation"
|
||||
#define NM_ETHTOOL_OPTNAME_FEATURE_TX_UDP_TNL_CSUM_SEGMENTATION \
|
||||
"feature-tx-udp_tnl-csum-segmentation"
|
||||
|
|
|
@ -54,6 +54,7 @@ typedef enum {
|
|||
NM_ETHTOOL_ID_FEATURE_L2_FWD_OFFLOAD,
|
||||
NM_ETHTOOL_ID_FEATURE_LOOPBACK,
|
||||
NM_ETHTOOL_ID_FEATURE_LRO,
|
||||
NM_ETHTOOL_ID_FEATURE_MACSEC_HW_OFFLOAD,
|
||||
NM_ETHTOOL_ID_FEATURE_NTUPLE,
|
||||
NM_ETHTOOL_ID_FEATURE_RX,
|
||||
NM_ETHTOOL_ID_FEATURE_RXHASH,
|
||||
|
@ -61,12 +62,15 @@ typedef enum {
|
|||
NM_ETHTOOL_ID_FEATURE_RX_ALL,
|
||||
NM_ETHTOOL_ID_FEATURE_RX_FCS,
|
||||
NM_ETHTOOL_ID_FEATURE_RX_GRO_HW,
|
||||
NM_ETHTOOL_ID_FEATURE_RX_GRO_LIST,
|
||||
NM_ETHTOOL_ID_FEATURE_RX_UDP_GRO_FORWARDING,
|
||||
NM_ETHTOOL_ID_FEATURE_RX_UDP_TUNNEL_PORT_OFFLOAD,
|
||||
NM_ETHTOOL_ID_FEATURE_RX_VLAN_FILTER,
|
||||
NM_ETHTOOL_ID_FEATURE_RX_VLAN_STAG_FILTER,
|
||||
NM_ETHTOOL_ID_FEATURE_RX_VLAN_STAG_HW_PARSE,
|
||||
NM_ETHTOOL_ID_FEATURE_SG,
|
||||
NM_ETHTOOL_ID_FEATURE_TLS_HW_RECORD,
|
||||
NM_ETHTOOL_ID_FEATURE_TLS_HW_RX_OFFLOAD,
|
||||
NM_ETHTOOL_ID_FEATURE_TLS_HW_TX_OFFLOAD,
|
||||
NM_ETHTOOL_ID_FEATURE_TSO,
|
||||
NM_ETHTOOL_ID_FEATURE_TX,
|
||||
|
@ -80,6 +84,7 @@ typedef enum {
|
|||
NM_ETHTOOL_ID_FEATURE_TX_FCOE_SEGMENTATION,
|
||||
NM_ETHTOOL_ID_FEATURE_TX_GRE_CSUM_SEGMENTATION,
|
||||
NM_ETHTOOL_ID_FEATURE_TX_GRE_SEGMENTATION,
|
||||
NM_ETHTOOL_ID_FEATURE_TX_GSO_LIST,
|
||||
NM_ETHTOOL_ID_FEATURE_TX_GSO_PARTIAL,
|
||||
NM_ETHTOOL_ID_FEATURE_TX_GSO_ROBUST,
|
||||
NM_ETHTOOL_ID_FEATURE_TX_IPXIP4_SEGMENTATION,
|
||||
|
@ -92,6 +97,7 @@ typedef enum {
|
|||
NM_ETHTOOL_ID_FEATURE_TX_TCP_ECN_SEGMENTATION,
|
||||
NM_ETHTOOL_ID_FEATURE_TX_TCP_MANGLEID_SEGMENTATION,
|
||||
NM_ETHTOOL_ID_FEATURE_TX_TCP_SEGMENTATION,
|
||||
NM_ETHTOOL_ID_FEATURE_TX_TUNNEL_REMCSUM_SEGMENTATION,
|
||||
NM_ETHTOOL_ID_FEATURE_TX_UDP_SEGMENTATION,
|
||||
NM_ETHTOOL_ID_FEATURE_TX_UDP_TNL_CSUM_SEGMENTATION,
|
||||
NM_ETHTOOL_ID_FEATURE_TX_UDP_TNL_SEGMENTATION,
|
||||
|
|
|
@ -51,6 +51,7 @@ const NMEthtoolData *const nm_ethtool_data[_NM_ETHTOOL_ID_NUM + 1] = {
|
|||
ETHT_DATA(FEATURE_L2_FWD_OFFLOAD),
|
||||
ETHT_DATA(FEATURE_LOOPBACK),
|
||||
ETHT_DATA(FEATURE_LRO),
|
||||
ETHT_DATA(FEATURE_MACSEC_HW_OFFLOAD),
|
||||
ETHT_DATA(FEATURE_NTUPLE),
|
||||
ETHT_DATA(FEATURE_RX),
|
||||
ETHT_DATA(FEATURE_RXHASH),
|
||||
|
@ -58,12 +59,15 @@ const NMEthtoolData *const nm_ethtool_data[_NM_ETHTOOL_ID_NUM + 1] = {
|
|||
ETHT_DATA(FEATURE_RX_ALL),
|
||||
ETHT_DATA(FEATURE_RX_FCS),
|
||||
ETHT_DATA(FEATURE_RX_GRO_HW),
|
||||
ETHT_DATA(FEATURE_RX_GRO_LIST),
|
||||
ETHT_DATA(FEATURE_RX_UDP_GRO_FORWARDING),
|
||||
ETHT_DATA(FEATURE_RX_UDP_TUNNEL_PORT_OFFLOAD),
|
||||
ETHT_DATA(FEATURE_RX_VLAN_FILTER),
|
||||
ETHT_DATA(FEATURE_RX_VLAN_STAG_FILTER),
|
||||
ETHT_DATA(FEATURE_RX_VLAN_STAG_HW_PARSE),
|
||||
ETHT_DATA(FEATURE_SG),
|
||||
ETHT_DATA(FEATURE_TLS_HW_RECORD),
|
||||
ETHT_DATA(FEATURE_TLS_HW_RX_OFFLOAD),
|
||||
ETHT_DATA(FEATURE_TLS_HW_TX_OFFLOAD),
|
||||
ETHT_DATA(FEATURE_TSO),
|
||||
ETHT_DATA(FEATURE_TX),
|
||||
|
@ -77,6 +81,7 @@ const NMEthtoolData *const nm_ethtool_data[_NM_ETHTOOL_ID_NUM + 1] = {
|
|||
ETHT_DATA(FEATURE_TX_FCOE_SEGMENTATION),
|
||||
ETHT_DATA(FEATURE_TX_GRE_CSUM_SEGMENTATION),
|
||||
ETHT_DATA(FEATURE_TX_GRE_SEGMENTATION),
|
||||
ETHT_DATA(FEATURE_TX_GSO_LIST),
|
||||
ETHT_DATA(FEATURE_TX_GSO_PARTIAL),
|
||||
ETHT_DATA(FEATURE_TX_GSO_ROBUST),
|
||||
ETHT_DATA(FEATURE_TX_IPXIP4_SEGMENTATION),
|
||||
|
@ -89,6 +94,7 @@ const NMEthtoolData *const nm_ethtool_data[_NM_ETHTOOL_ID_NUM + 1] = {
|
|||
ETHT_DATA(FEATURE_TX_TCP_ECN_SEGMENTATION),
|
||||
ETHT_DATA(FEATURE_TX_TCP_MANGLEID_SEGMENTATION),
|
||||
ETHT_DATA(FEATURE_TX_TCP_SEGMENTATION),
|
||||
ETHT_DATA(FEATURE_TX_TUNNEL_REMCSUM_SEGMENTATION),
|
||||
ETHT_DATA(FEATURE_TX_UDP_SEGMENTATION),
|
||||
ETHT_DATA(FEATURE_TX_UDP_TNL_CSUM_SEGMENTATION),
|
||||
ETHT_DATA(FEATURE_TX_UDP_TNL_SEGMENTATION),
|
||||
|
@ -134,11 +140,14 @@ static const guint8 _by_name[_NM_ETHTOOL_ID_NUM] = {
|
|||
NM_ETHTOOL_ID_FEATURE_L2_FWD_OFFLOAD,
|
||||
NM_ETHTOOL_ID_FEATURE_LOOPBACK,
|
||||
NM_ETHTOOL_ID_FEATURE_LRO,
|
||||
NM_ETHTOOL_ID_FEATURE_MACSEC_HW_OFFLOAD,
|
||||
NM_ETHTOOL_ID_FEATURE_NTUPLE,
|
||||
NM_ETHTOOL_ID_FEATURE_RX,
|
||||
NM_ETHTOOL_ID_FEATURE_RX_ALL,
|
||||
NM_ETHTOOL_ID_FEATURE_RX_FCS,
|
||||
NM_ETHTOOL_ID_FEATURE_RX_GRO_HW,
|
||||
NM_ETHTOOL_ID_FEATURE_RX_GRO_LIST,
|
||||
NM_ETHTOOL_ID_FEATURE_RX_UDP_GRO_FORWARDING,
|
||||
NM_ETHTOOL_ID_FEATURE_RX_UDP_TUNNEL_PORT_OFFLOAD,
|
||||
NM_ETHTOOL_ID_FEATURE_RX_VLAN_FILTER,
|
||||
NM_ETHTOOL_ID_FEATURE_RX_VLAN_STAG_FILTER,
|
||||
|
@ -147,6 +156,7 @@ static const guint8 _by_name[_NM_ETHTOOL_ID_NUM] = {
|
|||
NM_ETHTOOL_ID_FEATURE_RXVLAN,
|
||||
NM_ETHTOOL_ID_FEATURE_SG,
|
||||
NM_ETHTOOL_ID_FEATURE_TLS_HW_RECORD,
|
||||
NM_ETHTOOL_ID_FEATURE_TLS_HW_RX_OFFLOAD,
|
||||
NM_ETHTOOL_ID_FEATURE_TLS_HW_TX_OFFLOAD,
|
||||
NM_ETHTOOL_ID_FEATURE_TSO,
|
||||
NM_ETHTOOL_ID_FEATURE_TX,
|
||||
|
@ -159,6 +169,7 @@ static const guint8 _by_name[_NM_ETHTOOL_ID_NUM] = {
|
|||
NM_ETHTOOL_ID_FEATURE_TX_FCOE_SEGMENTATION,
|
||||
NM_ETHTOOL_ID_FEATURE_TX_GRE_CSUM_SEGMENTATION,
|
||||
NM_ETHTOOL_ID_FEATURE_TX_GRE_SEGMENTATION,
|
||||
NM_ETHTOOL_ID_FEATURE_TX_GSO_LIST,
|
||||
NM_ETHTOOL_ID_FEATURE_TX_GSO_PARTIAL,
|
||||
NM_ETHTOOL_ID_FEATURE_TX_GSO_ROBUST,
|
||||
NM_ETHTOOL_ID_FEATURE_TX_IPXIP4_SEGMENTATION,
|
||||
|
@ -171,6 +182,7 @@ static const guint8 _by_name[_NM_ETHTOOL_ID_NUM] = {
|
|||
NM_ETHTOOL_ID_FEATURE_TX_TCP_MANGLEID_SEGMENTATION,
|
||||
NM_ETHTOOL_ID_FEATURE_TX_TCP_SEGMENTATION,
|
||||
NM_ETHTOOL_ID_FEATURE_TX_TCP6_SEGMENTATION,
|
||||
NM_ETHTOOL_ID_FEATURE_TX_TUNNEL_REMCSUM_SEGMENTATION,
|
||||
NM_ETHTOOL_ID_FEATURE_TX_UDP_SEGMENTATION,
|
||||
NM_ETHTOOL_ID_FEATURE_TX_UDP_TNL_CSUM_SEGMENTATION,
|
||||
NM_ETHTOOL_ID_FEATURE_TX_UDP_TNL_SEGMENTATION,
|
||||
|
|
|
@ -468,14 +468,18 @@ static const NMEthtoolFeatureInfo _ethtool_feature_infos[_NM_ETHTOOL_ID_FEATURE_
|
|||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_HW_TC_OFFLOAD, "hw-tc-offload"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_L2_FWD_OFFLOAD, "l2-fwd-offload"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_LOOPBACK, "loopback"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_MACSEC_HW_OFFLOAD, "macsec-hw-offload"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_RX_ALL, "rx-all"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_RX_FCS, "rx-fcs"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_RX_GRO_HW, "rx-gro-hw"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_RX_GRO_LIST, "rx-gro-list"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_RX_UDP_GRO_FORWARDING, "rx-udp-gro-forwarding"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_RX_UDP_TUNNEL_PORT_OFFLOAD, "rx-udp_tunnel-port-offload"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_RX_VLAN_FILTER, "rx-vlan-filter"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_RX_VLAN_STAG_FILTER, "rx-vlan-stag-filter"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_RX_VLAN_STAG_HW_PARSE, "rx-vlan-stag-hw-parse"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_TLS_HW_RECORD, "tls-hw-record"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_TLS_HW_RX_OFFLOAD, "tls-hw-rx-offload"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_TLS_HW_TX_OFFLOAD, "tls-hw-tx-offload"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_TX_CHECKSUM_FCOE_CRC, "tx-checksum-fcoe-crc"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_TX_CHECKSUM_IPV4, "tx-checksum-ipv4"),
|
||||
|
@ -486,6 +490,7 @@ static const NMEthtoolFeatureInfo _ethtool_feature_infos[_NM_ETHTOOL_ID_FEATURE_
|
|||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_TX_FCOE_SEGMENTATION, "tx-fcoe-segmentation"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_TX_GRE_CSUM_SEGMENTATION, "tx-gre-csum-segmentation"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_TX_GRE_SEGMENTATION, "tx-gre-segmentation"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_TX_GSO_LIST, "tx-gso-list"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_TX_GSO_PARTIAL, "tx-gso-partial"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_TX_GSO_ROBUST, "tx-gso-robust"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_TX_IPXIP4_SEGMENTATION, "tx-ipxip4-segmentation"),
|
||||
|
@ -498,6 +503,8 @@ static const NMEthtoolFeatureInfo _ethtool_feature_infos[_NM_ETHTOOL_ID_FEATURE_
|
|||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_TX_TCP_ECN_SEGMENTATION, "tx-tcp-ecn-segmentation"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_TX_TCP_MANGLEID_SEGMENTATION, "tx-tcp-mangleid-segmentation"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_TX_TCP_SEGMENTATION, "tx-tcp-segmentation"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_TX_TUNNEL_REMCSUM_SEGMENTATION,
|
||||
"tx-tunnel-remcsum-segmentation"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_TX_UDP_SEGMENTATION, "tx-udp-segmentation"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_TX_UDP_TNL_CSUM_SEGMENTATION, "tx-udp_tnl-csum-segmentation"),
|
||||
ETHT_FEAT(NM_ETHTOOL_ID_FEATURE_TX_UDP_TNL_SEGMENTATION, "tx-udp_tnl-segmentation"),
|
||||
|
@ -539,8 +546,15 @@ _ASSERT_ethtool_feature_infos(void)
|
|||
|
||||
n += inf->n_kernel_names;
|
||||
for (k = 0; k < inf->n_kernel_names; k++) {
|
||||
g_assert(nm_utils_strv_find_first((char **) inf->kernel_names, k, inf->kernel_names[k])
|
||||
< 0);
|
||||
const char *name = inf->kernel_names[k];
|
||||
|
||||
g_assert(nm_utils_strv_find_first((char **) inf->kernel_names, k, name) < 0);
|
||||
|
||||
/* these offload features are only informational and cannot be set from user-space
|
||||
* (NETIF_F_NEVER_CHANGE). We should not track them in _ethtool_feature_infos. */
|
||||
g_assert(!nm_streq(name, "netns-local"));
|
||||
g_assert(!nm_streq(name, "tx-lockless"));
|
||||
g_assert(!nm_streq(name, "vlan-challenged"));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -544,6 +544,7 @@ const char *const _nm_ethtool_ifcfg_names[] = {
|
|||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_L2_FWD_OFFLOAD, "l2-fwd-offload"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_LOOPBACK, "loopback"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_LRO, "lro"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_MACSEC_HW_OFFLOAD, "macsec-hw-offload"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_NTUPLE, "ntuple"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_RX, "rx"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_RXHASH, "rxhash"),
|
||||
|
@ -551,12 +552,15 @@ const char *const _nm_ethtool_ifcfg_names[] = {
|
|||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_RX_ALL, "rx-all"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_RX_FCS, "rx-fcs"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_RX_GRO_HW, "rx-gro-hw"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_RX_GRO_LIST, "rx-gro-list"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_RX_UDP_GRO_FORWARDING, "rx-udp-gro-forwarding"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_RX_UDP_TUNNEL_PORT_OFFLOAD, "rx-udp_tunnel-port-offload"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_RX_VLAN_FILTER, "rx-vlan-filter"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_RX_VLAN_STAG_FILTER, "rx-vlan-stag-filter"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_RX_VLAN_STAG_HW_PARSE, "rx-vlan-stag-hw-parse"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_SG, "sg"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_TLS_HW_RECORD, "tls-hw-record"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_TLS_HW_RX_OFFLOAD, "tls-hw-rx-offload"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_TLS_HW_TX_OFFLOAD, "tls-hw-tx-offload"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_TSO, "tso"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_TX, "tx"),
|
||||
|
@ -570,6 +574,7 @@ const char *const _nm_ethtool_ifcfg_names[] = {
|
|||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_TX_FCOE_SEGMENTATION, "tx-fcoe-segmentation"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_TX_GRE_CSUM_SEGMENTATION, "tx-gre-csum-segmentation"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_TX_GRE_SEGMENTATION, "tx-gre-segmentation"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_TX_GSO_LIST, "tx-gso-list"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_TX_GSO_PARTIAL, "tx-gso-partial"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_TX_GSO_ROBUST, "tx-gso-robust"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_TX_IPXIP4_SEGMENTATION, "tx-ipxip4-segmentation"),
|
||||
|
@ -582,6 +587,8 @@ const char *const _nm_ethtool_ifcfg_names[] = {
|
|||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_TX_TCP_ECN_SEGMENTATION, "tx-tcp-ecn-segmentation"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_TX_TCP_MANGLEID_SEGMENTATION, "tx-tcp-mangleid-segmentation"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_TX_TCP_SEGMENTATION, "tx-tcp-segmentation"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_TX_TUNNEL_REMCSUM_SEGMENTATION,
|
||||
"tx-tunnel-remcsum-segmentation"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_TX_UDP_SEGMENTATION, "tx-udp-segmentation"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_TX_UDP_TNL_CSUM_SEGMENTATION, "tx-udp_tnl-csum-segmentation"),
|
||||
ETHT_NAME(NM_ETHTOOL_ID_FEATURE_TX_UDP_TNL_SEGMENTATION, "tx-udp_tnl-segmentation"),
|
||||
|
@ -648,6 +655,7 @@ static NM_UTILS_STRING_TABLE_LOOKUP_DEFINE(
|
|||
{"l2-fwd-offload", NM_ETHTOOL_ID_FEATURE_L2_FWD_OFFLOAD},
|
||||
{"loopback", NM_ETHTOOL_ID_FEATURE_LOOPBACK},
|
||||
{"lro", NM_ETHTOOL_ID_FEATURE_LRO},
|
||||
{"macsec-hw-offload", NM_ETHTOOL_ID_FEATURE_MACSEC_HW_OFFLOAD},
|
||||
{"ntuple", NM_ETHTOOL_ID_FEATURE_NTUPLE},
|
||||
{"rx", NM_ETHTOOL_ID_FEATURE_RX},
|
||||
{"rx-all", NM_ETHTOOL_ID_FEATURE_RX_ALL},
|
||||
|
@ -655,9 +663,11 @@ static NM_UTILS_STRING_TABLE_LOOKUP_DEFINE(
|
|||
{"rx-fcs", NM_ETHTOOL_ID_FEATURE_RX_FCS},
|
||||
{"rx-gro", NM_ETHTOOL_ID_FEATURE_GRO}, // kernel-only name
|
||||
{"rx-gro-hw", NM_ETHTOOL_ID_FEATURE_RX_GRO_HW},
|
||||
{"rx-gro-list", NM_ETHTOOL_ID_FEATURE_RX_GRO_LIST},
|
||||
{"rx-hashing", NM_ETHTOOL_ID_FEATURE_RXHASH}, // kernel-only name
|
||||
{"rx-lro", NM_ETHTOOL_ID_FEATURE_LRO}, // kernel-only name
|
||||
{"rx-ntuple-filter", NM_ETHTOOL_ID_FEATURE_NTUPLE}, // kernel-only name
|
||||
{"rx-udp-gro-forwarding", NM_ETHTOOL_ID_FEATURE_RX_UDP_GRO_FORWARDING},
|
||||
{"rx-udp_tunnel-port-offload", NM_ETHTOOL_ID_FEATURE_RX_UDP_TUNNEL_PORT_OFFLOAD},
|
||||
{"rx-vlan-filter", NM_ETHTOOL_ID_FEATURE_RX_VLAN_FILTER},
|
||||
{"rx-vlan-hw-parse", NM_ETHTOOL_ID_FEATURE_RXVLAN}, // kernel-only name
|
||||
|
@ -667,6 +677,7 @@ static NM_UTILS_STRING_TABLE_LOOKUP_DEFINE(
|
|||
{"rxvlan", NM_ETHTOOL_ID_FEATURE_RXVLAN},
|
||||
{"sg", NM_ETHTOOL_ID_FEATURE_SG},
|
||||
{"tls-hw-record", NM_ETHTOOL_ID_FEATURE_TLS_HW_RECORD},
|
||||
{"tls-hw-rx-offload", NM_ETHTOOL_ID_FEATURE_TLS_HW_RX_OFFLOAD},
|
||||
{"tls-hw-tx-offload", NM_ETHTOOL_ID_FEATURE_TLS_HW_TX_OFFLOAD},
|
||||
{"tso", NM_ETHTOOL_ID_FEATURE_TSO},
|
||||
{"tx", NM_ETHTOOL_ID_FEATURE_TX},
|
||||
|
@ -680,6 +691,7 @@ static NM_UTILS_STRING_TABLE_LOOKUP_DEFINE(
|
|||
{"tx-generic-segmentation", NM_ETHTOOL_ID_FEATURE_GSO}, // kernel-only name
|
||||
{"tx-gre-csum-segmentation", NM_ETHTOOL_ID_FEATURE_TX_GRE_CSUM_SEGMENTATION},
|
||||
{"tx-gre-segmentation", NM_ETHTOOL_ID_FEATURE_TX_GRE_SEGMENTATION},
|
||||
{"tx-gso-list", NM_ETHTOOL_ID_FEATURE_TX_GSO_LIST},
|
||||
{"tx-gso-partial", NM_ETHTOOL_ID_FEATURE_TX_GSO_PARTIAL},
|
||||
{"tx-gso-robust", NM_ETHTOOL_ID_FEATURE_TX_GSO_ROBUST},
|
||||
{"tx-ipxip4-segmentation", NM_ETHTOOL_ID_FEATURE_TX_IPXIP4_SEGMENTATION},
|
||||
|
@ -692,6 +704,7 @@ static NM_UTILS_STRING_TABLE_LOOKUP_DEFINE(
|
|||
{"tx-tcp-mangleid-segmentation", NM_ETHTOOL_ID_FEATURE_TX_TCP_MANGLEID_SEGMENTATION},
|
||||
{"tx-tcp-segmentation", NM_ETHTOOL_ID_FEATURE_TX_TCP_SEGMENTATION},
|
||||
{"tx-tcp6-segmentation", NM_ETHTOOL_ID_FEATURE_TX_TCP6_SEGMENTATION},
|
||||
{"tx-tunnel-remcsum-segmentation", NM_ETHTOOL_ID_FEATURE_TX_TUNNEL_REMCSUM_SEGMENTATION},
|
||||
{"tx-udp-segmentation", NM_ETHTOOL_ID_FEATURE_TX_UDP_SEGMENTATION},
|
||||
{"tx-udp_tnl-csum-segmentation", NM_ETHTOOL_ID_FEATURE_TX_UDP_TNL_CSUM_SEGMENTATION},
|
||||
{"tx-udp_tnl-segmentation", NM_ETHTOOL_ID_FEATURE_TX_UDP_TNL_SEGMENTATION},
|
||||
|
|
Loading…
Reference in a new issue