1use neli::attr::AttrHandle;
2use neli::consts::genl::NlAttrType;
3use neli::genl::Nlattr;
4use neli::types::{Buffer, GenlBuffer};
5use neli_proc_macros::neli_enum;
6
7pub type Attrs<'a, T> = AttrHandle<'a, GenlBuffer<T, Buffer>, Nlattr<T, Buffer>>;
8
9#[neli_enum(serialized_type = "u16")]
10pub enum NlaNested {
11 Unspec = 0,
12}
13
14impl NlAttrType for NlaNested {}
15
16#[neli_enum(serialized_type = "u16")]
20pub enum Nl80211Attr {
21 AttrUnspec = 0,
22 AttrWiphy = 1,
23 AttrWiphyName = 2,
24 AttrIfindex = 3,
25 AttrIfname = 4,
26 AttrIftype = 5,
27 AttrMac = 6,
28 AttrKeyData = 7,
29 AttrKeyIdx = 8,
30 AttrKeyCipher = 9,
31 AttrKeySeq = 10,
32 AttrKeyDefault = 11,
33 AttrBeaconInterval = 12,
34 AttrDtimPeriod = 13,
35 AttrBeaconHead = 14,
36 AttrBeaconTail = 15,
37 AttrStaAid = 16,
38 AttrStaFlags = 17,
39 AttrStaListenInterval = 18,
40 AttrStaSupportedRates = 19,
41 AttrStaVlan = 20,
42 AttrStaInfo = 21,
43 AttrWiphyBands = 22,
44 AttrMntrFlags = 23,
45 AttrMeshId = 24,
46 AttrStaPlinkAction = 25,
47 AttrMpathNextHop = 26,
48 AttrMpathInfo = 27,
49 AttrBssCtsProt = 28,
50 AttrBssShortPreamble = 29,
51 AttrBssShortSlotTime = 30,
52 AttrHtCapability = 31,
53 AttrSupportedIftypes = 32,
54 AttrRegAlpha2 = 33,
55 AttrRegRules = 34,
56 AttrMeshConfig = 35,
57 AttrBssBasicRates = 36,
58 AttrWiphyTxqParams = 37,
59 AttrWiphyFreq = 38,
60 AttrWiphyChannelType = 39,
61 AttrKeyDefaultMgmt = 40,
62 AttrMgmtSubtype = 41,
63 AttrIe = 42,
64 AttrMaxNumScanSsids = 43,
65 AttrScanFrequencies = 44,
66 AttrScanSsids = 45,
67 AttrGeneration = 46,
68 AttrBss = 47,
69 AttrRegInitiator = 48,
70 AttrRegType = 49,
71 AttrSupportedCommands = 50,
72 AttrFrame = 51,
73 AttrSsid = 52,
74 AttrAuthType = 53,
75 AttrReasonCode = 54,
76 AttrKeyType = 55,
77 AttrMaxScanIeLen = 56,
78 AttrCipherSuites = 57,
79 AttrFreqBefore = 58,
80 AttrFreqAfter = 59,
81 AttrFreqFixed = 60,
82 AttrWiphyRetryShort = 61,
83 AttrWiphyRetryLong = 62,
84 AttrWiphyFragThreshold = 63,
85 AttrWiphyRtsThreshold = 64,
86 AttrTimedOut = 65,
87 AttrUseMfp = 66,
88 AttrStaFlags2 = 67,
89 AttrControlPort = 68,
90 AttrTestdata = 69,
91 AttrPrivacy = 70,
92 AttrDisconnectedByAp = 71,
93 AttrStatusCode = 72,
94 AttrCipherSuitesPairwise = 73,
95 AttrCipherSuiteGroup = 74,
96 AttrWpaVersions = 75,
97 AttrAkmSuites = 76,
98 AttrReqIe = 77,
99 AttrRespIe = 78,
100 AttrPrevBssid = 79,
101 AttrKey = 80,
102 AttrKeys = 81,
103 AttrPid = 82,
104 Attr4addr = 83,
105 AttrSurveyInfo = 84,
106 AttrPmkid = 85,
107 AttrMaxNumPmkids = 86,
108 AttrDuration = 87,
109 AttrCookie = 88,
110 AttrWiphyCoverageClass = 89,
111 AttrTxRates = 90,
112 AttrFrameMatch = 91,
113 AttrAck = 92,
114 AttrPsState = 93,
115 AttrCqm = 94,
116 AttrLocalStateChange = 95,
117 AttrApIsolate = 96,
118 AttrWiphyTxPowerSetting = 97,
119 AttrWiphyTxPowerLevel = 98,
120 AttrTxFrameTypes = 99,
121 AttrRxFrameTypes = 100,
122 AttrFrameType = 101,
123 AttrControlPortEthertype = 102,
124 AttrControlPortNoEncrypt = 103,
125 AttrSupportIbssRsn = 104,
126 AttrWiphyAntennaTx = 105,
127 AttrWiphyAntennaRx = 106,
128 AttrMcastRate = 107,
129 AttrOffchannelTxOk = 108,
130 AttrBssHtOpmode = 109,
131 AttrKeyDefaultTypes = 110,
132 AttrMaxRemainOnChannelDuration = 111,
133 AttrMeshSetup = 112,
134 AttrWiphyAntennaAvailTx = 113,
135 AttrWiphyAntennaAvailRx = 114,
136 AttrSupportMeshAuth = 115,
137 AttrStaPlinkState = 116,
138 AttrWowlanTriggers = 117,
139 AttrWowlanTriggersSupported = 118,
140 AttrSchedScanInterval = 119,
141 AttrInterfaceCombinations = 120,
142 AttrSoftwareIftypes = 121,
143 AttrRekeyData = 122,
144 AttrMaxNumSchedScanSsids = 123,
145 AttrMaxSchedScanIeLen = 124,
146 AttrScanSuppRates = 125,
147 AttrHiddenSsid = 126,
148 AttrIeProbeResp = 127,
149 AttrIeAssocResp = 128,
150 AttrStaWme = 129,
151 AttrSupportApUapsd = 130,
152 AttrRoamSupport = 131,
153 AttrSchedScanMatch = 132,
154 AttrMaxMatchSets = 133,
155 AttrPmksaCandidate = 134,
156 AttrTxNoCckRate = 135,
157 AttrTdlsAction = 136,
158 AttrTdlsDialogToken = 137,
159 AttrTdlsOperation = 138,
160 AttrTdlsSupport = 139,
161 AttrTdlsExternalSetup = 140,
162 AttrDeviceApSme = 141,
163 AttrDontWaitForAck = 142,
164 AttrFeatureFlags = 143,
165 AttrProbeRespOffload = 144,
166 AttrProbeResp = 145,
167 AttrDfsRegion = 146,
168 AttrDisableHt = 147,
169 AttrHtCapabilityMask = 148,
170 AttrNoackMap = 149,
171 AttrInactivityTimeout = 150,
172 AttrRxSignalDbm = 151,
173 AttrBgScanPeriod = 152,
174 AttrWdev = 153,
175 AttrUserRegHintType = 154,
176 AttrConnFailedReason = 155,
177 AttrSaeData = 156,
178 AttrVhtCapability = 157,
179 AttrScanFlags = 158,
180 AttrChannelWidth = 159,
181 AttrCenterFreq1 = 160,
182 AttrCenterFreq2 = 161,
183 AttrP2pCtwindow = 162,
184 AttrP2pOppps = 163,
185 AttrLocalMeshPowerMode = 164,
186 AttrAclPolicy = 165,
187 AttrMacAddrs = 166,
188 AttrMacAclMax = 167,
189 AttrRadarEvent = 168,
190 AttrExtCapa = 169,
191 AttrExtCapaMask = 170,
192 AttrStaCapability = 171,
193 AttrStaExtCapability = 172,
194 AttrProtocolFeatures = 173,
195 AttrSplitWiphyDump = 174,
196 AttrDisableVht = 175,
197 AttrVhtCapabilityMask = 176,
198 AttrMdid = 177,
199 AttrIeRic = 178,
200 AttrCritProtId = 179,
201 AttrMaxCritProtDuration = 180,
202 AttrPeerAid = 181,
203 AttrCoalesceRule = 182,
204 AttrChSwitchCount = 183,
205 AttrChSwitchBlockTx = 184,
206 AttrCsaIes = 185,
207 AttrCsaCOffBeacon = 186,
208 AttrCsaCOffPresp = 187,
209 AttrRxmgmtFlags = 188,
210 AttrStaSupportedChannels = 189,
211 AttrStaSupportedOperClasses = 190,
212 AttrHandleDfs = 191,
213 AttrSupport5Mhz = 192,
214 AttrSupport10Mhz = 193,
215 AttrOpmodeNotif = 194,
216 AttrVendorId = 195,
217 AttrVendorSubcmd = 196,
218 AttrVendorData = 197,
219 AttrVendorEvents = 198,
220 AttrQosMap = 199,
221 AttrMacHint = 200,
222 AttrWiphyFreqHint = 201,
223 AttrMaxApAssocSta = 202,
224 AttrTdlsPeerCapability = 203,
225 AttrSocketOwner = 204,
226 AttrCsaCOffsetsTx = 205,
227 AttrMaxCsaCounters = 206,
228 AttrTdlsInitiator = 207,
229 AttrUseRrm = 208,
230 AttrWiphyDynAck = 209,
231 AttrTsid = 210,
232 AttrUserPrio = 211,
233 AttrAdmittedTime = 212,
234 AttrSmpsMode = 213,
235 AttrOperClass = 214,
236 AttrMacMask = 215,
237 AttrWiphySelfManagedReg = 216,
238 AttrExtFeatures = 217,
239 AttrSurveyRadioStats = 218,
240 AttrNetnsFd = 219,
241 AttrSchedScanDelay = 220,
242 AttrRegIndoor = 221,
243 AttrMaxNumSchedScanPlans = 222,
244 AttrMaxScanPlanInterval = 223,
245 AttrMaxScanPlanIterations = 224,
246 AttrSchedScanPlans = 225,
247 AttrPbss = 226,
248 AttrBssSelect = 227,
249 AttrStaSupportP2pPs = 228,
250 AttrPad = 229,
251 AttrIftypeExtCapa = 230,
252 AttrMuMimoGroupData = 231,
253 AttrMuMimoFollowMacAddr = 232,
254 AttrScanStartTimeTsf = 233,
255 AttrScanStartTimeTsfBssid = 234,
256 AttrMeasurementDuration = 235,
257 AttrMeasurementDurationMandatory = 236,
258 AttrMeshPeerAid = 237,
259 AttrNanMasterPref = 238,
260 AttrNanDual = 239,
261 AttrNanFunc = 240,
262 AttrNanMatch = 241,
263 AttrFilsKek = 242,
264 AttrFilsNonces = 243,
265 AttrMulticastToUnicastEnabled = 244,
266 AttrBssid = 245,
267 AttrSchedScanRelativeRssi = 246,
268 AttrSchedScanRssiAdjust = 247,
269 AttrTimeoutReason = 248,
270 AttrFilsErpUsername = 249,
271 AttrFilsErpRealm = 250,
272 AttrFilsErpNextSeqNum = 251,
273 AttrFilsErpRrk = 252,
274 AttrFilsCacheId = 253,
275 AttrPmk = 254,
276 AttrSchedScanMulti = 255,
277 AttrSchedScanMaxReqs = 256,
278 AttrWant1x4WayHs = 257,
279 AttrPmkr0Name = 258,
280 AttrPortAuthorized = 259,
281 AttrExternalAuthAction = 260,
282 AttrExternalAuthSupport = 261,
283 AttrNss = 262,
284 AttrAckSignal = 263,
285 AttrControlPortOverNl80211 = 264,
286 AttrTxqStats = 265,
287 AttrTxqLimit = 266,
288 AttrTxqMemoryLimit = 267,
289 AttrTxqQuantum = 268,
290 AttrHeCapability = 269,
291 AttrFtmResponder = 270,
292 AttrFtmResponderStats = 271,
293 AttrTimeout = 272,
294 AttrPeerMeasurements = 273,
295 AttrAirtimeWeight = 274,
296 AttrStaTxPowerSetting = 275,
297 AttrStaTxPower = 276,
298 AttrSaePassword = 277,
299 AttrTwtResponder = 278,
300 AttrHeObssPd = 279,
301 AttrWiphyEdmgChannels = 280,
302 AttrWiphyEdmgBwConfig = 281,
303 AttrVlanId = 282,
304 AttrHeBssColor = 283,
305 AttrIftypeAkmSuites = 284,
306 AttrTidConfig = 285,
307 AttrControlPortNoPreauth = 286,
308 AttrPmkLifetime = 287,
309 AttrPmkReauthThreshold = 288,
310 AttrReceiveMulticast = 289,
311 AttrWiphyFreqOffset = 290,
312 AttrCenterFreq1Offset = 291,
313 AttrScanFreqKhz = 292,
314 AttrHe6ghzCapability = 293,
315 AttrFilsDiscovery = 294,
316 AttrUnsolBcastProbeResp = 295,
317 AttrS1gCapability = 296,
318 AttrS1gCapabilityMask = 297,
319 AttrSaePwe = 298,
320 AttrReconnectRequested = 299,
321 AttrSarSpec = 300,
322 AttrDisableHe = 301,
323 AttrObssColorBitmap = 302,
324 AttrColorChangeCount = 303,
325 AttrColorChangeColor = 304,
326 AttrColorChangeElems = 305,
327 AttrMbssidConfig = 306,
328 AttrMbssidElems = 307,
329 AttrRadarBackground = 308,
330 AttrApSettingsFlags = 309,
331 AttrEhtCapability = 310,
332 AttrDisableEht = 311,
333 AttrMloLinks = 312,
334 AttrMloLinkId = 313,
335}
336
337impl NlAttrType for Nl80211Attr {}
338
339#[neli_enum(serialized_type = "u16")]
343pub enum Nl80211Iftype {
344 IftypeUnspecified = 0,
345 IftypeAdhoc = 1,
346 IftypeStation = 2,
347 IftypeAp = 3,
348 IftypeApVlan = 4,
349 IftypeWds = 5,
350 IftypeMonitor = 6,
351 IftypeMeshPoint = 7,
352 IftypeP2pClient = 8,
353 IftypeP2pGo = 9,
354 IftypeP2pDevice = 10,
355 IftypeOcb = 11,
356 IftypeNan = 12,
357}
358
359impl NlAttrType for Nl80211Iftype {}
360
361impl Nl80211Iftype {
362 pub fn from_u8(n: u8) -> Option<Nl80211Iftype> {
363 match n {
364 0 => Some(Nl80211Iftype::IftypeUnspecified),
365 1 => Some(Nl80211Iftype::IftypeAdhoc),
366 2 => Some(Nl80211Iftype::IftypeStation),
367 3 => Some(Nl80211Iftype::IftypeAp),
368 4 => Some(Nl80211Iftype::IftypeApVlan),
369 5 => Some(Nl80211Iftype::IftypeWds),
370 6 => Some(Nl80211Iftype::IftypeMonitor),
371 7 => Some(Nl80211Iftype::IftypeMeshPoint),
372 8 => Some(Nl80211Iftype::IftypeP2pClient),
373 9 => Some(Nl80211Iftype::IftypeP2pGo),
374 10 => Some(Nl80211Iftype::IftypeP2pDevice),
375 11 => Some(Nl80211Iftype::IftypeOcb),
376 12 => Some(Nl80211Iftype::IftypeNan),
377 _ => None, }
379 }
380
381 pub fn string(&self) -> &str {
382 match *self {
383 Nl80211Iftype::IftypeUnspecified => "Unspecified",
384 Nl80211Iftype::IftypeAdhoc => "Adhoc",
385 Nl80211Iftype::IftypeStation => "Station",
386 Nl80211Iftype::IftypeAp => "Ap",
387 Nl80211Iftype::IftypeApVlan => "ApVlan",
388 Nl80211Iftype::IftypeWds => "Wds",
389 Nl80211Iftype::IftypeMonitor => "Monitor",
390 Nl80211Iftype::IftypeMeshPoint => "MeshPoint",
391 Nl80211Iftype::IftypeP2pClient => "P2P Client",
392 Nl80211Iftype::IftypeP2pGo => "P2P Go",
393 Nl80211Iftype::IftypeP2pDevice => "P2P Device",
394 Nl80211Iftype::IftypeOcb => "OCB",
395 Nl80211Iftype::IftypeNan => "NAN",
396 _ => "Unknown",
397 }
398 }
399}
400
401#[neli_enum(serialized_type = "u16")]
403pub enum Nl80211StaFlags {
404 StaFlagInvalid = 0,
405 StaFlagAuthorized = 1,
406 StaFlagShortPreamble = 2,
407 StaFlagWme = 3,
408 StaFlagMfp = 4,
409 StaFlagAuthenticated = 5,
410 StaFlagTdlsPeer = 6,
411 StaFlagAssociated = 7,
412}
413
414impl NlAttrType for Nl80211StaFlags {}
415
416#[neli_enum(serialized_type = "u16")]
420pub enum Nl80211StaP2pPsStatus {
421 P2pPsUnsupported = 0,
422 P2pPsSupported = 1,
423}
424
425impl NlAttrType for Nl80211StaP2pPsStatus {}
426
427#[neli_enum(serialized_type = "u16")]
431pub enum Nl80211RateInfo {
432 RateInfoInvalid = 0,
433 RateInfoBitrate = 1,
434 RateInfoMcs = 2,
435 RateInfo40MhzWidth = 3,
436 RateInfoShortGi = 4,
437 RateInfoBitrate32 = 5,
438 RateInfoVhtMcs = 6,
439 RateInfoVhtNss = 7,
440 RateInfo80MhzWidth = 8,
441 RateInfo80p80MhzWidth = 9,
442 RateInfo160MhzWidth = 10,
443 RateInfo10MhzWidth = 11,
444 RateInfo5MhzWidth = 12,
445}
446
447impl NlAttrType for Nl80211RateInfo {}
448
449#[neli_enum(serialized_type = "u16")]
453pub enum Nl80211StaBssParam {
454 StaBssParamInvalid = 0,
455 StaBssParamCtsProt = 1,
456 StaBssParamShortPreamble = 2,
457 StaBssParamShortSlotTime = 3,
458 StaBssParamDtimPeriod = 4,
459 StaBssParamBeaconInterval = 5,
460}
461
462impl NlAttrType for Nl80211StaBssParam {}
463
464#[neli_enum(serialized_type = "u16")]
468pub enum Nl80211StaInfo {
469 StaInfoInvalid = 0,
470 StaInfoInactiveTime = 1,
471 StaInfoRxBytes = 2,
472 StaInfoTxBytes = 3,
473 StaInfoLlid = 4,
474 StaInfoPlid = 5,
475 StaInfoPlinkState = 6,
476 StaInfoSignal = 7,
477 StaInfoTxBitrate = 8,
478 StaInfoRxPackets = 9,
479 StaInfoTxPackets = 10,
480 StaInfoTxRetries = 11,
481 StaInfoTxFailed = 12,
482 StaInfoSignalAvg = 13,
483 StaInfoRxBitrate = 14,
484 StaInfoBssParam = 15,
485 StaInfoConnectedTime = 16,
486 StaInfoStaFlags = 17,
487 StaInfoBeaconLoss = 18,
488 StaInfoTOffset = 19,
489 StaInfoLocalPm = 20,
490 StaInfoPeerPm = 21,
491 StaInfoNonpeerPm = 22,
492 StaInfoRxBytes64 = 23,
493 StaInfoTxBytes64 = 24,
494 StaInfoChainSignal = 25,
495 StaInfoChainSignalAvg = 26,
496 StaInfoExpectedThroughput = 27,
497 StaInfoRxDropMisc = 28,
498 StaInfoBeaconRx = 29,
499 StaInfoBeaconSignalAvg = 30,
500 StaInfoTidStats = 31,
501 StaInfoRxDuration = 32,
502 StaInfoPad = 33,
503}
504
505impl NlAttrType for Nl80211StaInfo {}
506
507#[neli_enum(serialized_type = "u16")]
511pub enum Nl80211TidStats {
512 TidStatsInvalid = 0,
513 TidStatsRxMsdu = 1,
514 TidStatsTxMsdu = 2,
515 TidStatsTxMsduRetries = 3,
516 TidStatsTxMsduFailed = 4,
517 TidStatsPad = 5,
518}
519
520impl NlAttrType for Nl80211TidStats {}
521
522#[neli_enum(serialized_type = "u16")]
526pub enum Nl80211MpathFlags {
527 MpathFlagActive = 1 << 0,
528 MpathFlagResolving = 1 << 1,
529 MpathFlagSnValid = 1 << 2,
530 MpathFlagFixed = 1 << 3,
531 MpathFlagResolved = 1 << 4,
532}
533
534impl NlAttrType for Nl80211MpathFlags {}
535
536#[neli_enum(serialized_type = "u16")]
540pub enum Nl80211MpathInfo {
541 MpathInfoInvalid = 0,
542 MpathInfoFrameQlen = 1,
543 MpathInfoSn = 2,
544 MpathInfoMetric = 3,
545 MpathInfoExptime = 4,
546 MpathInfoFlags = 5,
547 MpathInfoDiscoveryTimeout = 6,
548 MpathInfoDiscoveryRetries = 7,
549}
550
551impl NlAttrType for Nl80211MpathInfo {}
552
553#[neli_enum(serialized_type = "u16")]
557pub enum Nl80211BandAttr {
558 BandAttrInvalid = 0,
559 BandAttrFreqs = 1,
560 BandAttrRates = 2,
561 BandAttrHtMcsSet = 3,
562 BandAttrHtCapa = 4,
563 BandAttrHtAmpduFactor = 5,
564 BandAttrHtAmpduDensity = 6,
565 BandAttrVhtMcsSet = 7,
566 BandAttrVhtCapa = 8,
567}
568
569impl NlAttrType for Nl80211BandAttr {}
570
571#[neli_enum(serialized_type = "u16")]
575pub enum Nl80211FrequencyAttr {
576 FrequencyAttrInvalid = 0,
577 FrequencyAttrFreq = 1,
578 FrequencyAttrDisabled = 2,
579 FrequencyAttrNoIr = 3,
580 FrequencyAttrNoIbss = 4,
581 FrequencyAttrRadar = 5,
582 FrequencyAttrMaxTxPower = 6,
583 FrequencyAttrDfsState = 7,
584 FrequencyAttrDfsTime = 8,
585 FrequencyAttrNoHt40Minus = 9,
586 FrequencyAttrNoHt40Plus = 10,
587 FrequencyAttrNo80mhz = 11,
588 FrequencyAttrNo160mhz = 12,
589 FrequencyAttrDfsCacTime = 13,
590 FrequencyAttrIndoorOnly = 14,
591 FrequencyAttrIrConcurrent = 15,
592 FrequencyAttrNo20mhz = 16,
593 FrequencyAttrNo10mhz = 17,
594}
595
596impl NlAttrType for Nl80211FrequencyAttr {}
597
598#[neli_enum(serialized_type = "u16")]
602pub enum Nl80211BitrateAttr {
603 BitrateAttrInvalid = 0,
604 BitrateAttrRate = 1,
605 BitrateAttr2ghzShortpreamble = 2,
606}
607
608impl NlAttrType for Nl80211BitrateAttr {}
609
610#[neli_enum(serialized_type = "u16")]
614pub enum Nl80211RegInitiator {
615 RegdomSetByCore = 0,
616 RegdomSetByUser = 1,
617 RegdomSetByDriver = 2,
618 RegdomSetByCountryIe = 3,
619}
620
621impl NlAttrType for Nl80211RegInitiator {}
622
623#[neli_enum(serialized_type = "u16")]
627pub enum Nl80211RegType {
628 RegdomTypeCountry = 0,
629 RegdomTypeWorld = 1,
630 RegdomTypeCustomWorld = 2,
631 RegdomTypeIntersection = 3,
632}
633
634impl NlAttrType for Nl80211RegType {}
635
636#[neli_enum(serialized_type = "u16")]
640pub enum Nl80211RegRuleAttr {
641 RegRuleAttrInvalid = 0,
642 AttrRegRuleFlags = 1,
643 AttrFreqRangeStart = 2,
644 AttrFreqRangeEnd = 3,
645 AttrFreqRangeMaxBw = 4,
646 AttrPowerRuleMaxAntGain = 5,
647 AttrPowerRuleMaxEirp = 6,
648 AttrDfsCacTime = 7,
649}
650
651impl NlAttrType for Nl80211RegRuleAttr {}
652
653#[neli_enum(serialized_type = "u16")]
657pub enum Nl80211SchedScanMatchAttr {
658 SchedScanMatchAttrInvalid = 0,
659 SchedScanMatchAttrSsid = 1,
660 SchedScanMatchAttrRssi = 2,
661}
662
663impl NlAttrType for Nl80211SchedScanMatchAttr {}
664
665#[neli_enum(serialized_type = "u16")]
669pub enum Nl80211RegRuleFlags {
670 RrfNoOfdm = 1 << 0,
671 RrfNoCck = 1 << 1,
672 RrfNoIndoor = 1 << 2,
673 RrfNoOutdoor = 1 << 3,
674 RrfDfs = 1 << 4,
675 RrfPtpOnly = 1 << 5,
676 RrfPtmpOnly = 1 << 6,
677 RrfNoIr = 1 << 7,
678 RrfNoIbss = 1 << 8,
679 RrfAutoBw = 1 << 11,
680 RrfIrConcurrent = 1 << 12,
681 RrfNoHt40minus = 1 << 13,
682 RrfNoHt40plus = 1 << 14,
683 RrfNo80mhz = 1 << 15, }
685
686impl NlAttrType for Nl80211RegRuleFlags {}
687
688#[neli_enum(serialized_type = "u16")]
692pub enum Nl80211DfsRegions {
693 DfsUnset = 0,
694 DfsFcc = 1,
695 DfsEtsi = 2,
696 DfsJp = 3,
697}
698
699impl NlAttrType for Nl80211DfsRegions {}
700
701#[neli_enum(serialized_type = "u16")]
705pub enum Nl80211UserRegHintType {
706 UserRegHintUser = 0,
707 UserRegHintCellBase = 1,
708 UserRegHintIndoor = 2,
709}
710
711impl NlAttrType for Nl80211UserRegHintType {}
712
713#[neli_enum(serialized_type = "u16")]
717pub enum Nl80211SurveyInfo {
718 SurveyInfoInvalid = 0,
719 SurveyInfoFrequency = 1,
720 SurveyInfoNoise = 2,
721 SurveyInfoInUse = 3,
722 SurveyInfoTime = 4,
723 SurveyInfoTimeBusy = 5,
724 SurveyInfoTimeExtBusy = 6,
725 SurveyInfoTimeRx = 7,
726 SurveyInfoTimeTx = 8,
727 SurveyInfoTimeScan = 9,
728 SurveyInfoPad = 10,
729}
730
731impl NlAttrType for Nl80211SurveyInfo {}
732
733#[neli_enum(serialized_type = "u16")]
737pub enum Nl80211MntrFlags {
738 MntrFlagInvalid = 0,
739 MntrFlagFcsfail = 1,
740 MntrFlagPlcpfail = 2,
741 MntrFlagControl = 3,
742 MntrFlagOtherBss = 4,
743 MntrFlagCookFrames = 5,
744 MntrFlagActive = 6,
745}
746
747impl NlAttrType for Nl80211MntrFlags {}
748
749#[neli_enum(serialized_type = "u16")]
753pub enum Nl80211MeshPowerMode {
754 MeshPowerUnknown = 0,
755 MeshPowerActive = 1,
756 MeshPowerLightSleep = 2,
757 MeshPowerDeepSleep = 3,
758}
759
760impl NlAttrType for Nl80211MeshPowerMode {}
761
762#[neli_enum(serialized_type = "u16")]
766pub enum Nl80211MeshconfParams {
767 MeshconfInvalid = 0,
768 MeshconfRetryTimeout = 1,
769 MeshconfConfirmTimeout = 2,
770 MeshconfHoldingTimeout = 3,
771 MeshconfMaxPeerLinks = 4,
772 MeshconfMaxRetries = 5,
773 MeshconfTtl = 6,
774 MeshconfAutoOpenPlinks = 7,
775 MeshconfHwmpMaxPreqRetries = 8,
776 MeshconfPathRefreshTime = 9,
777 MeshconfMinDiscoveryTimeout = 10,
778 MeshconfHwmpActivePathTimeout = 11,
779 MeshconfHwmpPreqMinInterval = 12,
780 MeshconfHwmpNetDiamTrvsTime = 13,
781 MeshconfHwmpRootmode = 14,
782 MeshconfElementTtl = 15,
783 MeshconfHwmpRannInterval = 16,
784 MeshconfGateAnnouncements = 17,
785 MeshconfHwmpPerrMinInterval = 18,
786 MeshconfForwarding = 19,
787 MeshconfRssiThreshold = 20,
788 MeshconfSyncOffsetMaxNeighbor = 21,
789 MeshconfHtOpmode = 22,
790 MeshconfHwmpPathToRootTimeout = 23,
791 MeshconfHwmpRootInterval = 24,
792 MeshconfHwmpConfirmationInterval = 25,
793 MeshconfPowerMode = 26,
794 MeshconfAwakeWindow = 27,
795 MeshconfPlinkTimeout = 28,
796}
797
798impl NlAttrType for Nl80211MeshconfParams {}
799
800#[neli_enum(serialized_type = "u16")]
804pub enum Nl80211MeshSetupParams {
805 MeshSetupInvalid = 0,
806 MeshSetupEnableVendorPathSel = 1,
807 MeshSetupEnableVendorMetric = 2,
808 MeshSetupIe = 3,
809 MeshSetupUserspaceAuth = 4,
810 MeshSetupUserspaceAmpe = 5,
811 MeshSetupEnableVendorSync = 6,
812 MeshSetupUserspaceMpm = 7,
813 MeshSetupAuthProtocol = 8,
814}
815
816impl NlAttrType for Nl80211MeshSetupParams {}
817
818#[neli_enum(serialized_type = "u16")]
822pub enum Nl80211TxqAttr {
823 TxqAttrInvalid = 0,
824 TxqAttrAc = 1,
825 TxqAttrTxop = 2,
826 TxqAttrCwmin = 3,
827 TxqAttrCwmax = 4,
828 TxqAttrAifs = 5,
829}
830
831impl NlAttrType for Nl80211TxqAttr {}
832
833#[neli_enum(serialized_type = "u16")]
837pub enum Nl80211Ac {
838 AcVo = 0,
839 AcVi = 1,
840 AcBe = 2,
841 AcBk = 3,
842}
843
844impl NlAttrType for Nl80211Ac {}
845
846#[neli_enum(serialized_type = "u16")]
850pub enum Nl80211ChannelType {
851 ChanNoHt = 0,
852 ChanHt20 = 1,
853 ChanHt40minus = 2,
854 ChanHt40plus = 3,
855}
856
857impl NlAttrType for Nl80211ChannelType {}
858
859#[neli_enum(serialized_type = "u16")]
863pub enum Nl80211ChanWidth {
864 ChanWidth20Noht = 0, ChanWidth20 = 1, ChanWidth40 = 2, ChanWidth80 = 3, ChanWidth80p80 = 4, ChanWidth160 = 5, ChanWidth5 = 6, ChanWidth10 = 7, ChanWidth1 = 8, ChanWidth2 = 9, ChanWidth4 = 10, ChanWidth8 = 11, ChanWidth16 = 12, ChanWidth320 = 13, }
879
880impl NlAttrType for Nl80211ChanWidth {}
881
882#[neli_enum(serialized_type = "u16")]
886pub enum Nl80211BssScanWidth {
887 BssChanWidth20 = 0,
888 BssChanWidth10 = 1,
889 BssChanWidth5 = 2,
890}
891
892impl NlAttrType for Nl80211BssScanWidth {}
893
894#[neli_enum(serialized_type = "u16")]
898pub enum Nl80211Bss {
899 BssInvalid = 0,
900 BssBssid = 1,
901 BssFrequency = 2,
902 BssTsf = 3,
903 BssBeaconInterval = 4,
904 BssCapability = 5,
905 BssInformationElements = 6,
906 BssSignalMbm = 7,
907 BssSignalUnspec = 8,
908 BssStatus = 9,
909 BssSeenMsAgo = 10,
910 BssBeaconIes = 11,
911 BssChanWidth = 12,
912 BssBeaconTsf = 13,
913 BssPrespData = 14,
914 BssLastSeenBoottime = 15,
915 BssPad = 16,
916 BssParentTsf = 17,
917 BssParentBssid = 18,
918}
919
920impl NlAttrType for Nl80211Bss {}
921
922#[neli_enum(serialized_type = "u16")]
926pub enum Nl80211BssStatus {
927 BssStatusAuthenticated = 0,
928 BssStatusAssociated = 1,
929 BssStatusIbssJoined = 2,
930}
931
932impl NlAttrType for Nl80211BssStatus {}
933
934#[neli_enum(serialized_type = "u16")]
938pub enum Nl80211AuthType {
939 AuthtypeOpenSystem = 0,
940 AuthtypeSharedKey = 1,
941 AuthtypeFt = 2,
942 AuthtypeNetworkEap = 3,
943 AuthtypeSae = 4,
944 AuthtypeNum = 5,
945 AuthtypeMax = 4,
946 AuthtypeAutomatic = 5,
947}
948
949impl NlAttrType for Nl80211AuthType {}
950
951#[neli_enum(serialized_type = "u16")]
955pub enum Nl80211KeyType {
956 KeytypeGroup = 0,
957 KeytypePairwise = 1,
958 KeytypePeerkey = 2,
959}
960
961impl NlAttrType for Nl80211KeyType {}
962
963#[neli_enum(serialized_type = "u16")]
967pub enum Nl80211Mfp {
968 MfpNo = 0,
969 MfpRequired = 1,
970}
971
972impl NlAttrType for Nl80211Mfp {}
973
974#[neli_enum(serialized_type = "u16")]
978pub enum Nl80211WpaVersions {
979 WpaVersion1 = 1 << 0,
980 WpaVersion2 = 1 << 1,
981}
982
983impl NlAttrType for Nl80211WpaVersions {}
984
985#[neli_enum(serialized_type = "u16")]
989pub enum Nl80211KeyDefaultTypes {
990 KeyDefaultTypeInvalid = 0,
991 KeyDefaultTypeUnicast = 1,
992 KeyDefaultTypeMulticast = 2,
993}
994
995impl NlAttrType for Nl80211KeyDefaultTypes {}
996
997#[neli_enum(serialized_type = "u16")]
1001pub enum Nl80211KeyAttributes {
1002 KeyInvalid = 0,
1003 KeyData = 1,
1004 KeyIdx = 2,
1005 KeyCipher = 3,
1006 KeySeq = 4,
1007 KeyDefault = 5,
1008 KeyDefaultMgmt = 6,
1009 KeyType = 7,
1010 KeyDefaultTypes = 8,
1011}
1012
1013impl NlAttrType for Nl80211KeyAttributes {}
1014
1015#[neli_enum(serialized_type = "u16")]
1019pub enum Nl80211TxRateAttributes {
1020 TxrateInvalid = 0,
1021 TxrateLegacy = 1,
1022 TxrateHt = 2,
1023 TxrateVht = 3,
1024 TxrateGi = 4,
1025}
1026
1027impl NlAttrType for Nl80211TxRateAttributes {}
1028
1029#[neli_enum(serialized_type = "u16")]
1033pub enum Nl80211TxrateGi {
1034 TxrateDefaultGi = 0,
1035 TxrateForceSgi = 1,
1036 TxrateForceLgi = 2,
1037}
1038
1039impl NlAttrType for Nl80211TxrateGi {}
1040
1041#[neli_enum(serialized_type = "u16")]
1045pub enum Nl80211Bandc {
1046 Band2ghz = 0,
1047 Band5ghz = 1,
1048 Band60ghz = 2,
1049 Band6ghz = 3,
1050 BandS1ghz = 4,
1051 BandLC = 5,
1052}
1053
1054impl NlAttrType for Nl80211Bandc {}
1055
1056#[neli_enum(serialized_type = "u16")]
1060pub enum Nl80211PsState {
1061 PsDisabled = 0,
1062 PsEnabled = 1,
1063}
1064
1065impl NlAttrType for Nl80211PsState {}
1066
1067#[neli_enum(serialized_type = "u16")]
1071pub enum Nl80211AttrCqm {
1072 AttrCqmInvalid = 0,
1073 AttrCqmRssiThold = 1,
1074 AttrCqmRssiHyst = 2,
1075 AttrCqmRssiThresholdEvent = 3,
1076 AttrCqmPktLossEvent = 4,
1077 AttrCqmTxeRate = 5,
1078 AttrCqmTxePkts = 6,
1079 AttrCqmTxeIntvl = 7,
1080 AttrCqmBeaconLossEvent = 8,
1081}
1082
1083impl NlAttrType for Nl80211AttrCqm {}
1084
1085#[neli_enum(serialized_type = "u16")]
1089pub enum Nl80211CqmRssiThresholdEvent {
1090 CqmRssiThresholdEventLow = 0,
1091 CqmRssiThresholdEventHigh = 1,
1092 CqmRssiBeaconLossEvent = 2,
1093}
1094
1095impl NlAttrType for Nl80211CqmRssiThresholdEvent {}
1096
1097#[neli_enum(serialized_type = "u16")]
1101pub enum Nl80211TxPowerSetting {
1102 TxPowerAutomatic = 0,
1103 TxPowerLimited = 1,
1104 TxPowerFixed = 2,
1105}
1106
1107impl NlAttrType for Nl80211TxPowerSetting {}
1108
1109#[neli_enum(serialized_type = "u16")]
1113pub enum Nl80211PacketPatternAttr {
1114 PktpatInvalid = 0,
1115 PktpatMask = 1,
1116 PktpatPattern = 2,
1117 PktpatOffset = 3,
1118}
1119
1120impl NlAttrType for Nl80211PacketPatternAttr {}
1121
1122#[neli_enum(serialized_type = "u16")]
1126pub enum Nl80211WowlanTriggers {
1127 WowlanTrigInvalid = 0,
1128 WowlanTrigAny = 1,
1129 WowlanTrigDisconnect = 2,
1130 WowlanTrigMagicPkt = 3,
1131 WowlanTrigPktPattern = 4,
1132 WowlanTrigGtkRekeySupported = 5,
1133 WowlanTrigGtkRekeyFailure = 6,
1134 WowlanTrigEapIdentRequest = 7,
1135 WowlanTrig4wayHandshake = 8,
1136 WowlanTrigRfkillRelease = 9,
1137 WowlanTrigWakeupPkt80211 = 10,
1138 WowlanTrigWakeupPkt80211Len = 11,
1139 WowlanTrigWakeupPkt8023 = 12,
1140 WowlanTrigWakeupPkt8023Len = 13,
1141 WowlanTrigTcpConnection = 14,
1142 WowlanTrigWakeupTcpMatch = 15,
1143 WowlanTrigWakeupTcpConnlost = 16,
1144 WowlanTrigWakeupTcpNomoretokens = 17,
1145 WowlanTrigNetDetect = 18,
1146 WowlanTrigNetDetectResults = 19,
1147}
1148
1149impl NlAttrType for Nl80211WowlanTriggers {}
1150
1151#[neli_enum(serialized_type = "u16")]
1155pub enum Nl80211WowlanTcpAttrs {
1156 WowlanTcpInvalid = 0,
1157 WowlanTcpSrcIpv4 = 1,
1158 WowlanTcpDstIpv4 = 2,
1159 WowlanTcpDstMac = 3,
1160 WowlanTcpSrcPort = 4,
1161 WowlanTcpDstPort = 5,
1162 WowlanTcpDataPayload = 6,
1163 WowlanTcpDataPayloadSeq = 7,
1164 WowlanTcpDataPayloadToken = 8,
1165 WowlanTcpDataInterval = 9,
1166 WowlanTcpWakePayload = 10,
1167 WowlanTcpWakeMask = 11,
1168}
1169
1170impl NlAttrType for Nl80211WowlanTcpAttrs {}
1171
1172#[neli_enum(serialized_type = "u16")]
1176pub enum Nl80211AttrCoalesceRule {
1177 CoalesceRuleInvalid = 0,
1178 AttrCoalesceRuleDelay = 1,
1179 AttrCoalesceRuleCondition = 2,
1180 AttrCoalesceRulePktPattern = 3,
1181}
1182
1183impl NlAttrType for Nl80211AttrCoalesceRule {}
1184
1185#[neli_enum(serialized_type = "u16")]
1189pub enum Nl80211CoalesceCondition {
1190 CoalesceConditionMatch = 0,
1191 CoalesceConditionNoMatch = 1,
1192}
1193
1194impl NlAttrType for Nl80211CoalesceCondition {}
1195
1196#[neli_enum(serialized_type = "u16")]
1200pub enum Nl80211IfaceLimitAttrs {
1201 IfaceLimitUnspec = 0,
1202 IfaceLimitMax = 1,
1203 IfaceLimitTypes = 2,
1204}
1205
1206impl NlAttrType for Nl80211IfaceLimitAttrs {}
1207
1208#[neli_enum(serialized_type = "u16")]
1212pub enum Nl80211IfCombinationAttrs {
1213 IfaceCombUnspec = 0,
1214 IfaceCombLimits = 1,
1215 IfaceCombMaxnum = 2,
1216 IfaceCombStaApBiMatch = 3,
1217 IfaceCombNumChannels = 4,
1218 IfaceCombRadarDetectWidths = 5,
1219 IfaceCombRadarDetectRegions = 6,
1220}
1221
1222impl NlAttrType for Nl80211IfCombinationAttrs {}
1223
1224#[neli_enum(serialized_type = "u16")]
1228pub enum Nl80211PlinkState {
1229 PlinkListen = 0,
1230 PlinkOpnSnt = 1,
1231 PlinkOpnRcvd = 2,
1232 PlinkCnfRcvd = 3,
1233 PlinkEstab = 4,
1234 PlinkHolding = 5,
1235 PlinkBlocked = 6,
1236}
1237
1238impl NlAttrType for Nl80211PlinkState {}
1239
1240#[neli_enum(serialized_type = "u16")]
1244pub enum PlinkActions {
1245 PlinkActionNoAction = 0,
1246 PlinkActionOpen = 1,
1247 PlinkActionBlock = 2,
1248}
1249
1250impl NlAttrType for PlinkActions {}
1251
1252#[neli_enum(serialized_type = "u16")]
1256pub enum Nl80211RekeyData {
1257 RekeyDataInvalid = 0,
1258 RekeyDataKek = 1,
1259 RekeyDataKck = 2,
1260 RekeyDataReplayCtr = 3,
1261}
1262
1263impl NlAttrType for Nl80211RekeyData {}
1264
1265#[neli_enum(serialized_type = "u16")]
1269pub enum Nl80211HiddenSsid {
1270 HiddenSsidNotInUse = 0,
1271 HiddenSsidZeroLen = 1,
1272 HiddenSsidZeroContents = 2,
1273}
1274
1275impl NlAttrType for Nl80211HiddenSsid {}
1276
1277#[neli_enum(serialized_type = "u16")]
1281pub enum Nl80211StaWmeAttr {
1282 StaWmeInvalid = 0,
1283 StaWmeUapsdQueues = 1,
1284 StaWmeMaxSp = 2,
1285}
1286
1287impl NlAttrType for Nl80211StaWmeAttr {}
1288
1289#[neli_enum(serialized_type = "u16")]
1293pub enum Nl80211PmksaCandidateAttr {
1294 PmksaCandidateInvalid = 0,
1295 PmksaCandidateIndex = 1,
1296 PmksaCandidateBssid = 2,
1297 PmksaCandidatePreauth = 3,
1298}
1299
1300impl NlAttrType for Nl80211PmksaCandidateAttr {}
1301
1302#[neli_enum(serialized_type = "u16")]
1306pub enum Nl80211TdlsOperation {
1307 TdlsDiscoveryReq = 0,
1308 TdlsSetup = 1,
1309 TdlsTeardown = 2,
1310 TdlsEnableLink = 3,
1311 TdlsDisableLink = 4,
1312}
1313
1314impl NlAttrType for Nl80211TdlsOperation {}
1315
1316#[neli_enum(serialized_type = "u16")]
1320pub enum Nl80211FeatureFlags {
1321 FeatureSkTxStatus = 1 << 0,
1322 FeatureHtIbss = 1 << 1,
1323 FeatureInactivityTimer = 1 << 2,
1324 FeatureCellBaseRegHints = 1 << 3,
1325 FeatureP2pDeviceNeedsChannel = 1 << 4,
1326 FeatureSae = 1 << 5,
1327 FeatureLowPriorityScan = 1 << 6,
1328 FeatureScanFlush = 1 << 7,
1329 FeatureApScan = 1 << 8,
1330 FeatureVifTxpower = 1 << 9,
1331 FeatureNeedObssScan = 1 << 10,
1332 FeatureP2pGoCtwin = 1 << 11,
1333 FeatureP2pGoOppps = 1 << 12,
1334 FeatureAdvertiseChanLimits = 1 << 14,
1335 FeatureFullApClientState = 1 << 15,
1336 }
1353
1354impl NlAttrType for Nl80211FeatureFlags {}
1355
1356#[neli_enum(serialized_type = "u16")]
1360pub enum Nl80211ExtFeatureIndex {
1361 ExtFeatureVhtIbss = 0,
1362 ExtFeatureRrm = 1,
1363 ExtFeatureMuMimoAirSniffer = 2,
1364 ExtFeatureScanStartTime = 3,
1365 ExtFeatureBssParentTsf = 4,
1366 ExtFeatureSetScanDwell = 5,
1367 ExtFeatureBeaconRateLegacy = 6,
1368 ExtFeatureBeaconRateHt = 7,
1369 ExtFeatureBeaconRateVht = 8,
1370}
1371
1372impl NlAttrType for Nl80211ExtFeatureIndex {}
1373
1374#[neli_enum(serialized_type = "u16")]
1378pub enum Nl80211ProbeRespOffloadSupportAttr {
1379 ProbeRespOffloadSupportWps = 1 << 0,
1380 ProbeRespOffloadSupportWps2 = 1 << 1,
1381 ProbeRespOffloadSupportP2p = 1 << 2,
1382 ProbeRespOffloadSupport80211u = 1 << 3,
1383}
1384
1385impl NlAttrType for Nl80211ProbeRespOffloadSupportAttr {}
1386
1387#[neli_enum(serialized_type = "u16")]
1391pub enum Nl80211ConnectFailedReason {
1392 ConnFailMaxClients = 0,
1393 ConnFailBlockedClient = 1,
1394}
1395
1396impl NlAttrType for Nl80211ConnectFailedReason {}
1397
1398#[neli_enum(serialized_type = "u16")]
1402pub enum Nl80211ScanFlags {
1403 ScanFlagLowPriority = 1 << 0,
1404 ScanFlagFlush = 1 << 1,
1405 ScanFlagAp = 1 << 2,
1406 ScanFlagRandomAddr = 1 << 3,
1407}
1408
1409impl NlAttrType for Nl80211ScanFlags {}
1410
1411#[neli_enum(serialized_type = "u16")]
1415pub enum Nl80211AclPolicy {
1416 AclPolicyAcceptUnlessListed = 0,
1417 AclPolicyDenyUnlessListed = 1,
1418}
1419
1420impl NlAttrType for Nl80211AclPolicy {}
1421
1422#[neli_enum(serialized_type = "u16")]
1426pub enum Nl80211SmpsMode {
1427 SmpsOff = 0,
1428 SmpsStatic = 1,
1429 SmpsDynamic = 2,
1430}
1431
1432impl NlAttrType for Nl80211SmpsMode {}
1433
1434#[neli_enum(serialized_type = "u16")]
1438pub enum Nl80211RadarEvent {
1439 RadarDetected = 0,
1440 RadarCacFinished = 1,
1441 RadarCacAborted = 2,
1442 RadarNopFinished = 3,
1443}
1444
1445impl NlAttrType for Nl80211RadarEvent {}
1446
1447#[neli_enum(serialized_type = "u16")]
1451pub enum Nl80211DfsState {
1452 DfsUsable = 0,
1453 DfsUnavailable = 1,
1454 DfsAvailable = 2,
1455}
1456
1457impl NlAttrType for Nl80211DfsState {}
1458
1459#[neli_enum(serialized_type = "u16")]
1463pub enum Nl80211ProtocolFeatures {
1464 ProtocolFeatureSplitWiphyDump = 1 << 0,
1465}
1466
1467impl NlAttrType for Nl80211ProtocolFeatures {}
1468
1469#[neli_enum(serialized_type = "u16")]
1473pub enum Nl80211CritProtoId {
1474 CritProtoUnspec = 0,
1475 CritProtoDhcp = 1,
1476 CritProtoEapol = 2,
1477 CritProtoApipa = 3,
1478}
1479
1480impl NlAttrType for Nl80211CritProtoId {}
1481
1482#[neli_enum(serialized_type = "u16")]
1486pub enum Nl80211RxmgmtFlags {
1487 RxmgmtFlagAnswered = 1 << 0,
1488}
1489
1490impl NlAttrType for Nl80211RxmgmtFlags {}
1491
1492#[neli_enum(serialized_type = "u16")]
1496pub enum Nl80211TdlsPeerCapability {
1497 TdlsPeerHt = 1 << 0,
1498 TdlsPeerVht = 1 << 1,
1499 TdlsPeerWmm = 1 << 2,
1500}
1501
1502impl NlAttrType for Nl80211TdlsPeerCapability {}
1503
1504#[neli_enum(serialized_type = "u16")]
1508pub enum Nl80211SchedScanPlan {
1509 SchedScanPlanInvalid = 0,
1510 SchedScanPlanInterval = 1,
1511 SchedScanPlanIterations = 2,
1512}
1513
1514impl NlAttrType for Nl80211SchedScanPlan {}
1515
1516#[neli_enum(serialized_type = "u16")]
1520pub enum Nl80211BssSelectAttr {
1521 BssSelectAttrInvalid = 0,
1522 BssSelectAttrRssi = 1,
1523 BssSelectAttrBandPref = 2,
1524 BssSelectAttrRssiAdjust = 3,
1525}
1526
1527impl NlAttrType for Nl80211BssSelectAttr {}
1528
1529#[neli_enum(serialized_type = "u16")]
1533pub enum Nl80211NanDualBandConf {
1534 NanBandDefault = 1 << 0,
1535 NanBand2ghz = 1 << 1,
1536 NanBand5ghz = 1 << 2,
1537}
1538
1539impl NlAttrType for Nl80211NanDualBandConf {}
1540
1541#[neli_enum(serialized_type = "u16")]
1545pub enum Nl80211NanFunctionType {
1546 NanFuncPublish = 0,
1547 NanFuncSubscribe = 1,
1548 NanFuncFollowUp = 2,
1549 NanFuncTypeAfterLast = 3,
1550 NanFuncMaxType = 2,
1551}
1552
1553impl NlAttrType for Nl80211NanFunctionType {}
1554
1555#[neli_enum(serialized_type = "u16")]
1559pub enum Nl80211NanPublishType {
1560 NanSolicitedPublish = 1 << 0,
1561 NanUnsolicitedPublish = 1 << 1,
1562}
1563
1564impl NlAttrType for Nl80211NanPublishType {}
1565
1566#[neli_enum(serialized_type = "u16")]
1570pub enum Nl80211NanFuncTermReason {
1571 NanFuncTermReasonUserRequest = 0,
1572 NanFuncTermReasonTtlExpired = 1,
1573 NanFuncTermReasonError = 2,
1574}
1575
1576impl NlAttrType for Nl80211NanFuncTermReason {}
1577
1578#[neli_enum(serialized_type = "u16")]
1582pub enum Nl80211NanFuncAttributes {
1583 NanFuncInvalid = 0,
1584 NanFuncType = 1,
1585 NanFuncServiceId = 2,
1586 NanFuncPublishType = 3,
1587 NanFuncPublishBcast = 4,
1588 NanFuncSubscribeActive = 5,
1589 NanFuncFollowUpId = 6,
1590 NanFuncFollowUpReqId = 7,
1591 NanFuncFollowUpDest = 8,
1592 NanFuncCloseRange = 9,
1593 NanFuncTtl = 10,
1594 NanFuncServiceInfo = 11,
1595 NanFuncSrf = 12,
1596 NanFuncRxMatchFilter = 13,
1597 NanFuncTxMatchFilter = 14,
1598 NanFuncInstanceId = 15,
1599 NanFuncTermReason = 16,
1600}
1601
1602impl NlAttrType for Nl80211NanFuncAttributes {}
1603
1604#[neli_enum(serialized_type = "u16")]
1608pub enum Nl80211NanSrfAttributes {
1609 NanSrfInvalid = 0,
1610 NanSrfInclude = 1,
1611 NanSrfBf = 2,
1612 NanSrfBfIdx = 3,
1613 NanSrfMacAddrs = 4,
1614}
1615
1616impl NlAttrType for Nl80211NanSrfAttributes {}
1617
1618#[neli_enum(serialized_type = "u16")]
1622pub enum Nl80211NanMatchAttributes {
1623 NanMatchInvalid = 0,
1624 NanMatchFuncLocal = 1,
1625 NanMatchFuncPeer = 2,
1626}
1627
1628impl NlAttrType for Nl80211NanMatchAttributes {}
1629
1630#[derive(Debug, Clone, PartialEq, Eq)]
1631pub enum Operstate {
1632 Up,
1633 Down,
1634 Testing,
1635 Unknown,
1636 Dormant,
1637 NotPresent,
1638 LowerLayerDown,
1639}
1640
1641impl Operstate {
1642 pub fn from_u8(value: u8) -> Self {
1644 match value {
1645 0 => Operstate::Unknown,
1646 1 => Operstate::NotPresent,
1647 2 => Operstate::Down,
1648 3 => Operstate::LowerLayerDown,
1649 4 => Operstate::Testing,
1650 5 => Operstate::Dormant,
1651 6 => Operstate::Up,
1652 _ => Operstate::Unknown, }
1654 }
1655
1656 pub fn to_string(&self) -> &str {
1658 match self {
1659 Operstate::Up => "Up",
1660 Operstate::Down => "Down",
1661 Operstate::Testing => "Testing",
1662 Operstate::Unknown => "Unknown",
1663 Operstate::Dormant => "Dormant",
1664 Operstate::NotPresent => "Not Present",
1665 Operstate::LowerLayerDown => "Lower Layer Down",
1666 }
1667 }
1668}