diff options
author | Christiano F. Haesbaert <haesbaert@cvs.openbsd.org> | 2011-11-02 02:03:48 +0000 |
---|---|---|
committer | Christiano F. Haesbaert <haesbaert@cvs.openbsd.org> | 2011-11-02 02:03:48 +0000 |
commit | aa90c31e9bb7b52921496766edc083f5cb15c6df (patch) | |
tree | dffdd51ee2dee45ab0d78a990a5aa9476b9a551b /sys/net/if.h | |
parent | 502d09447316d90435e67ad00c1656165c581cc7 (diff) |
Expose if_capabilities to userland so that ifconfig can display the
device hardware features.
Tune ifconfig to show them with 'hwfeatures' argument.
While here, kill some old unused capabilities and respect 80 columns
in brconfig.h.
ok mcbride@, henning@, mpf@.
Diffstat (limited to 'sys/net/if.h')
-rw-r--r-- | sys/net/if.h | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/sys/net/if.h b/sys/net/if.h index fb521924cdb..ebef78c1268 100644 --- a/sys/net/if.h +++ b/sys/net/if.h @@ -1,4 +1,4 @@ -/* $OpenBSD: if.h,v 1.129 2011/10/07 17:10:08 henning Exp $ */ +/* $OpenBSD: if.h,v 1.130 2011/11/02 02:03:47 haesbaert Exp $ */ /* $NetBSD: if.h,v 1.23 1996/05/07 02:40:27 thorpej Exp $ */ /* @@ -142,6 +142,7 @@ struct if_data { u_int64_t ifi_omcasts; /* packets sent via multicast */ u_int64_t ifi_iqdrops; /* dropped on input, this interface */ u_int64_t ifi_noproto; /* destined for unsupported protocol */ + u_int32_t ifi_capabilities; /* interface capabilities */ struct timeval ifi_lastchange; /* last operational state change */ struct mclpool ifi_mclpool[MCLPOOLS]; @@ -264,7 +265,6 @@ struct ifnet { /* and the entries */ int if_xflags; /* extra softnet flags */ struct if_data if_data; /* stats and other data about if */ u_int32_t if_hardmtu; /* maximum MTU device supports */ - int if_capabilities; /* interface capabilities */ u_int if_rdomain; /* routing instance */ char if_description[IFDESCRSIZE]; /* interface description */ u_short if_rtlabelid; /* next route label */ @@ -311,6 +311,7 @@ struct ifnet { /* and the entries */ #define if_iqdrops if_data.ifi_iqdrops #define if_noproto if_data.ifi_noproto #define if_lastchange if_data.ifi_lastchange +#define if_capabilities if_data.ifi_capabilities #define IFF_UP 0x1 /* interface is up */ #define IFF_BROADCAST 0x2 /* broadcast address valid */ @@ -360,8 +361,6 @@ struct ifnet { /* and the entries */ #define IFCAP_IPCOMP 0x00000040 /* can do IPcomp */ #define IFCAP_CSUM_TCPv6 0x00000080 /* can do IPv6/TCP checksums */ #define IFCAP_CSUM_UDPv6 0x00000100 /* can do IPv6/UDP checksums */ -#define IFCAP_CSUM_TCPv4_Rx 0x00000200 /* can do IPv4/TCP (Rx only) */ -#define IFCAP_CSUM_UDPv4_Rx 0x00000400 /* can do IPv4/UDP (Rx only) */ #define IFCAP_WOL 0x00008000 /* can do wake on lan */ /* |