@@ -1188,6 +1188,51 @@ s! {
1188
1188
pub struct host_cpu_load_info {
1189
1189
pub cpu_ticks: [ :: natural_t; CPU_STATE_MAX as usize ] ,
1190
1190
}
1191
+
1192
+ // net/if_mib.h
1193
+ pub struct ifmibdata {
1194
+ /// Name of interface
1195
+ pub ifmd_name: [ :: c_char; :: IFNAMSIZ ] ,
1196
+ /// Number of promiscuous listeners
1197
+ pub ifmd_pcount: :: c_uint,
1198
+ /// Interface flags
1199
+ pub ifmd_flags: :: c_uint,
1200
+ /// Instantaneous length of send queue
1201
+ pub ifmd_snd_len: :: c_uint,
1202
+ /// Maximum length of send queue
1203
+ pub ifmd_snd_maxlen: :: c_uint,
1204
+ /// Number of drops in send queue
1205
+ pub ifmd_snd_drops: :: c_uint,
1206
+ /// For future expansion
1207
+ pub ifmd_filler: [ :: c_uint; 4 ] ,
1208
+ /// Generic information and statistics
1209
+ pub ifmd_data: if_data64,
1210
+ }
1211
+
1212
+ pub struct ifs_iso_8802_3 {
1213
+ pub dot3StatsAlignmentErrors: u32 ,
1214
+ pub dot3StatsFCSErrors: u32 ,
1215
+ pub dot3StatsSingleCollisionFrames: u32 ,
1216
+ pub dot3StatsMultipleCollisionFrames: u32 ,
1217
+ pub dot3StatsSQETestErrors: u32 ,
1218
+ pub dot3StatsDeferredTransmissions: u32 ,
1219
+ pub dot3StatsLateCollisions: u32 ,
1220
+ pub dot3StatsExcessiveCollisions: u32 ,
1221
+ pub dot3StatsInternalMacTransmitErrors: u32 ,
1222
+ pub dot3StatsCarrierSenseErrors: u32 ,
1223
+ pub dot3StatsFrameTooLongs: u32 ,
1224
+ pub dot3StatsInternalMacReceiveErrors: u32 ,
1225
+ pub dot3StatsEtherChipSet: u32 ,
1226
+ pub dot3StatsMissedFrames: u32 ,
1227
+ pub dot3StatsCollFrequencies: [ u32 ; 16 ] ,
1228
+ pub dot3Compliance: u32 ,
1229
+ }
1230
+
1231
+ pub struct if_family_id {
1232
+ pub iffmid_len: u32 ,
1233
+ pub iffmid_id: u32 ,
1234
+ pub iffmid_str: [ :: c_char; 1 ] ,
1235
+ }
1191
1236
}
1192
1237
1193
1238
s_no_extra_traits ! {
@@ -5529,6 +5574,32 @@ pub const HOST_VM_INFO64_COUNT: mach_msg_type_number_t =
5529
5574
( :: mem:: size_of :: < vm_statistics64_data_t > ( ) / :: mem:: size_of :: < integer_t > ( ) )
5530
5575
as mach_msg_type_number_t ;
5531
5576
5577
+ // bsd/net/if_mib.h
5578
+ /// Non-interface-specific
5579
+ pub const IFMIB_SYSTEM : :: c_int = 1 ;
5580
+ /// Per-interface data table
5581
+ pub const IFMIB_IFDATA : :: c_int = 2 ;
5582
+ /// All interfaces data at once
5583
+ pub const IFMIB_IFALLDATA : :: c_int = 3 ;
5584
+
5585
+ /// Generic stats for all kinds of ifaces
5586
+ pub const IFDATA_GENERAL : :: c_int = 1 ;
5587
+ /// Specific to the type of interface
5588
+ pub const IFDATA_LINKSPECIFIC : :: c_int = 2 ;
5589
+ /// Addresses assigned to interface
5590
+ pub const IFDATA_ADDRS : :: c_int = 3 ;
5591
+ /// Multicast addresses assigned to interface
5592
+ pub const IFDATA_MULTIADDRS : :: c_int = 4 ;
5593
+
5594
+ /// Number of interfaces configured
5595
+ pub const IFMIB_IFCOUNT : :: c_int = 1 ;
5596
+
5597
+ /// Functions not specific to a type of iface
5598
+ pub const NETLINK_GENERIC : :: c_int = 0 ;
5599
+
5600
+ pub const DOT3COMPLIANCE_STATS : :: c_int = 1 ;
5601
+ pub const DOT3COMPLIANCE_COLLS : :: c_int = 2 ;
5602
+
5532
5603
f ! {
5533
5604
pub fn CMSG_NXTHDR ( mhdr: * const :: msghdr,
5534
5605
cmsg: * const :: cmsghdr) -> * mut :: cmsghdr {
0 commit comments