+ struct net_event_data link_data;
+ u_int32_t proto_family;
+ u_int32_t proto_remaining_count;
+};
+
+#ifdef PRIVATE
+/*
+ * Link Quality Metrics
+ *
+ * IFNET_LQM_THRESH_OFF Metric is not available; device is off.
+ * IFNET_LQM_THRESH_UNKNOWN Metric is not (yet) known.
+ * IFNET_LQM_THRESH_BAD Link quality is considered bad by driver.
+ * IFNET_LQM_THRESH_POOR Link quality is considered poor by driver.
+ * IFNET_LQM_THRESH_GOOD Link quality is considered good by driver.
+ */
+enum {
+ IFNET_LQM_THRESH_OFF = (-2),
+ IFNET_LQM_THRESH_UNKNOWN = (-1),
+ IFNET_LQM_THRESH_BAD = 10,
+ IFNET_LQM_THRESH_POOR = 50,
+ IFNET_LQM_THRESH_GOOD = 100
+};
+#ifdef XNU_KERNEL_PRIVATE
+#define IFNET_LQM_MIN IFNET_LQM_THRESH_OFF
+#define IFNET_LQM_MAX IFNET_LQM_THRESH_GOOD
+#endif /* XNU_KERNEL_PRIVATE */
+
+/*
+ * DLIL KEV_DL_LINK_QUALITY_METRIC_CHANGED structure
+ */
+struct kev_dl_link_quality_metric_data {
+ struct net_event_data link_data;
+ int link_quality_metric;
+};
+
+#define IF_DESCSIZE 128
+
+/*
+ * Structure for SIOC[SG]IFDESC
+ */
+struct if_descreq {
+ char ifdr_name[IFNAMSIZ]; /* interface name */
+ u_int32_t ifdr_len; /* up to IF_DESCSIZE */
+ u_int8_t ifdr_desc[IF_DESCSIZE]; /* opaque data */
+};
+
+/*
+ * Output packet scheduling models
+ *
+ * IFNET_SCHED_MODEL_NORMAL The default output packet scheduling model
+ * where the driver or media does not require strict scheduling
+ * strategy, and that the networking stack is free to choose the
+ * most appropriate scheduling and queueing algorithm, including
+ * shaping traffics.
+ * IFNET_SCHED_MODEL_DRIVER_MANAGED The alternative output packet
+ * scheduling model where the driver or media requires strict
+ * scheduling strategy (e.g. 802.11 WMM), and that the networking
+ * stack is only responsible for creating multiple queues for the
+ * corresponding service classes.
+ */
+enum {
+ IFNET_SCHED_MODEL_NORMAL = 0,
+ IFNET_SCHED_MODEL_DRIVER_MANAGED = 1,
+#ifdef XNU_KERNEL_PRIVATE
+ IFNET_SCHED_MODEL_MAX = 2,
+#endif /* XNU_KERNEL_PRIVATE */
+};
+
+/*
+ * Values for iflpr_flags
+ */
+#define IFLPRF_ALTQ 0x1 /* configured via PF/ALTQ */
+#define IFLPRF_DRVMANAGED 0x2 /* output queue scheduled by drv */
+
+/*
+ * Structure for SIOCGIFLINKPARAMS
+ */
+struct if_linkparamsreq {
+ char iflpr_name[IFNAMSIZ]; /* interface name */
+ u_int32_t iflpr_flags;
+ u_int32_t iflpr_output_sched;
+ u_int64_t iflpr_output_tbr_rate;
+ u_int32_t iflpr_output_tbr_percent;
+ struct if_bandwidths iflpr_output_bw;
+ struct if_bandwidths iflpr_input_bw;
+ struct if_latencies iflpr_output_lt;
+ struct if_latencies iflpr_input_lt;