mfd-const 0.23.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- mfd_const/__init__.py +14 -0
- mfd_const/_internal_data_structures.py +17 -0
- mfd_const/mfd_const.py +6 -0
- mfd_const/network.py +981 -0
- mfd_const/qos.py +53 -0
- mfd_const/release.py +14 -0
- mfd_const-0.23.0.dist-info/METADATA +72 -0
- mfd_const-0.23.0.dist-info/RECORD +12 -0
- mfd_const-0.23.0.dist-info/WHEEL +5 -0
- mfd_const-0.23.0.dist-info/licenses/AUTHORS.md +7 -0
- mfd_const-0.23.0.dist-info/licenses/LICENSE.md +8 -0
- mfd_const-0.23.0.dist-info/top_level.txt +1 -0
mfd_const/__init__.py
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
# Copyright (C) 2025 Intel Corporation
|
|
2
|
+
# SPDX-License-Identifier: MIT
|
|
3
|
+
"""Module for MFD Const."""
|
|
4
|
+
|
|
5
|
+
from .network import (
|
|
6
|
+
family_to_full_name,
|
|
7
|
+
Family,
|
|
8
|
+
Speed,
|
|
9
|
+
SPEED_IDS,
|
|
10
|
+
DEVICE_IDS,
|
|
11
|
+
FREEBSD_ADVERTISE_SPEED,
|
|
12
|
+
MANAGEMENT_NETWORK,
|
|
13
|
+
)
|
|
14
|
+
from .release import Milestone
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# Copyright (C) 2025 Intel Corporation
|
|
2
|
+
# SPDX-License-Identifier: MIT
|
|
3
|
+
"""Internal usage only data structures."""
|
|
4
|
+
|
|
5
|
+
from collections.abc import Hashable
|
|
6
|
+
from typing import Any
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
class InternalDict(dict):
|
|
10
|
+
"""Dict, but with extended KeyError msg, when key not found."""
|
|
11
|
+
|
|
12
|
+
def __getitem__(self, item: Hashable) -> Any:
|
|
13
|
+
"""Get item."""
|
|
14
|
+
if item not in self:
|
|
15
|
+
raise KeyError(f"Key '{item}' not found!\nPlease extend dict located in mfd-const to use new key.")
|
|
16
|
+
|
|
17
|
+
return super().__getitem__(item)
|
mfd_const/mfd_const.py
ADDED
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
# Copyright (C) 2025 Intel Corporation
|
|
2
|
+
# SPDX-License-Identifier: MIT
|
|
3
|
+
"""Main module."""
|
|
4
|
+
|
|
5
|
+
# To keep backward compatibility let's leave here those imports for now
|
|
6
|
+
from .network import SPEED_IDS, DEVICE_IDS, FREEBSD_ADVERTISE_SPEED, MANAGEMENT_NETWORK, MEV_IDs # noqa: F401
|
mfd_const/network.py
ADDED
|
@@ -0,0 +1,981 @@
|
|
|
1
|
+
# Copyright (C) 2025 Intel Corporation
|
|
2
|
+
# SPDX-License-Identifier: MIT
|
|
3
|
+
"""Network module."""
|
|
4
|
+
|
|
5
|
+
import re
|
|
6
|
+
from enum import Enum, auto
|
|
7
|
+
from ipaddress import IPv4Network
|
|
8
|
+
from typing import Any
|
|
9
|
+
|
|
10
|
+
from mfd_typing import DeviceID
|
|
11
|
+
|
|
12
|
+
from mfd_const._internal_data_structures import InternalDict
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
class Family(Enum):
|
|
16
|
+
"""Family Enum."""
|
|
17
|
+
|
|
18
|
+
FVL = auto()
|
|
19
|
+
NNT = auto()
|
|
20
|
+
TVL = auto()
|
|
21
|
+
SGVL = auto()
|
|
22
|
+
AVOTON = auto()
|
|
23
|
+
LKV = auto()
|
|
24
|
+
PVL = auto()
|
|
25
|
+
SPVL = auto()
|
|
26
|
+
FPK = auto()
|
|
27
|
+
CPK = auto()
|
|
28
|
+
CPK_SMBM = auto()
|
|
29
|
+
CVL = auto()
|
|
30
|
+
CNV = auto()
|
|
31
|
+
MEV = auto()
|
|
32
|
+
NNTQ = auto()
|
|
33
|
+
HVL = auto()
|
|
34
|
+
MPK = auto()
|
|
35
|
+
VF = auto()
|
|
36
|
+
HTWL = auto()
|
|
37
|
+
I350 = auto()
|
|
38
|
+
I225 = auto()
|
|
39
|
+
I710 = auto()
|
|
40
|
+
RRC = auto()
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
family_to_full_name = InternalDict(
|
|
44
|
+
{
|
|
45
|
+
Family.CVL: "Columbiaville",
|
|
46
|
+
Family.FVL: "Fortville",
|
|
47
|
+
Family.CNV: "Connorsville",
|
|
48
|
+
Family.LKV: "Linkville",
|
|
49
|
+
}
|
|
50
|
+
)
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
class Speed(Enum):
|
|
54
|
+
"""Speed Enum."""
|
|
55
|
+
|
|
56
|
+
VF_G1 = "1G_VF"
|
|
57
|
+
VF_G10 = "10G_VF"
|
|
58
|
+
VF_G40 = "40G_VF"
|
|
59
|
+
VF_G100 = "100G_VF"
|
|
60
|
+
|
|
61
|
+
G1 = "@1G"
|
|
62
|
+
G2 = "@2G"
|
|
63
|
+
G10 = "@10G"
|
|
64
|
+
G40 = "@40G"
|
|
65
|
+
G100 = "@100G"
|
|
66
|
+
G200 = "@200G"
|
|
67
|
+
|
|
68
|
+
def __hash__(self) -> int:
|
|
69
|
+
"""Return hash representation."""
|
|
70
|
+
return hash(self._name_)
|
|
71
|
+
|
|
72
|
+
def __eq__(self, other: Any):
|
|
73
|
+
"""Equal."""
|
|
74
|
+
if not isinstance(other, type(self)):
|
|
75
|
+
raise TypeError("Compared values need to be both members of Speed Enum class.")
|
|
76
|
+
|
|
77
|
+
return self is other
|
|
78
|
+
|
|
79
|
+
def __gt__(self, other: Any):
|
|
80
|
+
"""Greater than."""
|
|
81
|
+
if not isinstance(other, type(self)):
|
|
82
|
+
raise TypeError("Compared values need to be both members of Speed Enum class.")
|
|
83
|
+
|
|
84
|
+
speed_pattern = r"\D*(?P<speed>\d+)\D*"
|
|
85
|
+
self_speed_match = re.match(speed_pattern, self.value)
|
|
86
|
+
other_speed_match = re.match(speed_pattern, other.value)
|
|
87
|
+
if not self_speed_match or not other_speed_match:
|
|
88
|
+
raise ValueError(
|
|
89
|
+
f"Compared value was not matched to pattern.\nself={self}, other={other}, pattern={speed_pattern}"
|
|
90
|
+
)
|
|
91
|
+
|
|
92
|
+
return int(self_speed_match.group("speed")) > int(other_speed_match.group("speed"))
|
|
93
|
+
|
|
94
|
+
def __ge__(self, other: Any):
|
|
95
|
+
"""Greater or equal."""
|
|
96
|
+
return (self == other) or (self > other)
|
|
97
|
+
|
|
98
|
+
|
|
99
|
+
MEV_SIMICS_IDs = ["0xF002", "0xF003", "0xF00C"]
|
|
100
|
+
MEV_NRB_IDs = ["0x1452"]
|
|
101
|
+
MEV_IDs = MEV_NRB_IDs + MEV_SIMICS_IDs + ["0x145C"]
|
|
102
|
+
|
|
103
|
+
DEVICE_IDS = {
|
|
104
|
+
Family.FVL.name: [
|
|
105
|
+
"0x154B",
|
|
106
|
+
"0x154C",
|
|
107
|
+
"0x1571",
|
|
108
|
+
"0x1572",
|
|
109
|
+
"0x1573",
|
|
110
|
+
"0x1580",
|
|
111
|
+
"0x1581",
|
|
112
|
+
"0x1582",
|
|
113
|
+
"0x1583",
|
|
114
|
+
"0x1584",
|
|
115
|
+
"0x1585",
|
|
116
|
+
"0x1586",
|
|
117
|
+
"0x1587",
|
|
118
|
+
"0x1588",
|
|
119
|
+
"0x1589",
|
|
120
|
+
"0x158A",
|
|
121
|
+
"0x158B",
|
|
122
|
+
"0x15FF",
|
|
123
|
+
"0x0DD2",
|
|
124
|
+
],
|
|
125
|
+
Family.NNT.name: [
|
|
126
|
+
"0x10B6",
|
|
127
|
+
"0x10C6",
|
|
128
|
+
"0x10C7",
|
|
129
|
+
"0x10C8",
|
|
130
|
+
"0x10D8",
|
|
131
|
+
"0x10DB",
|
|
132
|
+
"0x10DD",
|
|
133
|
+
"0x10EC",
|
|
134
|
+
"0x10F1",
|
|
135
|
+
"0x10F4",
|
|
136
|
+
"0x10F7",
|
|
137
|
+
"0x10FB",
|
|
138
|
+
"0x10F9",
|
|
139
|
+
"0x10E1",
|
|
140
|
+
"0x1514",
|
|
141
|
+
"0x1507",
|
|
142
|
+
"0x10F8",
|
|
143
|
+
"0x10FC",
|
|
144
|
+
"0x1517",
|
|
145
|
+
"0x151C",
|
|
146
|
+
"0x10FA",
|
|
147
|
+
"0x1529",
|
|
148
|
+
"0x152A",
|
|
149
|
+
"0x10ED",
|
|
150
|
+
"0x152E",
|
|
151
|
+
"0x154F",
|
|
152
|
+
"0x1551",
|
|
153
|
+
"0x154D",
|
|
154
|
+
"0x1558",
|
|
155
|
+
"0x154A",
|
|
156
|
+
"0x155F",
|
|
157
|
+
"0x155D",
|
|
158
|
+
"0x1557",
|
|
159
|
+
],
|
|
160
|
+
Family.TVL.name: [
|
|
161
|
+
"0x1512",
|
|
162
|
+
"0x1515",
|
|
163
|
+
"0x1530",
|
|
164
|
+
"0x1528",
|
|
165
|
+
"0x155C",
|
|
166
|
+
"0x155E",
|
|
167
|
+
"0x1560",
|
|
168
|
+
],
|
|
169
|
+
Family.SGVL.name: ["0x1562", "0x1563", "0x15D1"],
|
|
170
|
+
Family.AVOTON.name: ["0x1F41"],
|
|
171
|
+
Family.LKV.name: [
|
|
172
|
+
"0x57AF",
|
|
173
|
+
"0x57B0",
|
|
174
|
+
"0x57B1",
|
|
175
|
+
],
|
|
176
|
+
Family.PVL.name: [
|
|
177
|
+
"0x151F",
|
|
178
|
+
"0x1522",
|
|
179
|
+
"0x1523",
|
|
180
|
+
"0x1521",
|
|
181
|
+
"0x1524",
|
|
182
|
+
"0x1520",
|
|
183
|
+
"0x152F",
|
|
184
|
+
],
|
|
185
|
+
Family.SPVL.name: [
|
|
186
|
+
"0x1533",
|
|
187
|
+
"0x1534",
|
|
188
|
+
"0x1536",
|
|
189
|
+
"0x1537",
|
|
190
|
+
"0x1538",
|
|
191
|
+
"0x1531",
|
|
192
|
+
"0x157B",
|
|
193
|
+
"0x157C",
|
|
194
|
+
],
|
|
195
|
+
Family.FPK.name: [
|
|
196
|
+
"0x0DDA",
|
|
197
|
+
"0x374C",
|
|
198
|
+
"0x37D0",
|
|
199
|
+
"0x37D1",
|
|
200
|
+
"0x37D2",
|
|
201
|
+
"0x37D3",
|
|
202
|
+
"0x37CC",
|
|
203
|
+
"0x37CE",
|
|
204
|
+
"0x37CF",
|
|
205
|
+
],
|
|
206
|
+
Family.CPK.name: [
|
|
207
|
+
"0xF0A5",
|
|
208
|
+
"0xF0A6",
|
|
209
|
+
"0x18E4",
|
|
210
|
+
"0x18ED",
|
|
211
|
+
"0x1890",
|
|
212
|
+
"0x1891",
|
|
213
|
+
"0x1892",
|
|
214
|
+
"0x1897",
|
|
215
|
+
"0x1898",
|
|
216
|
+
"0x189A",
|
|
217
|
+
"0x151D",
|
|
218
|
+
"0x124C",
|
|
219
|
+
"0x124D",
|
|
220
|
+
"0x188A",
|
|
221
|
+
"0x188B",
|
|
222
|
+
"0x188C",
|
|
223
|
+
"0x579C",
|
|
224
|
+
"0x579D",
|
|
225
|
+
"0x579E",
|
|
226
|
+
"0x579F",
|
|
227
|
+
"0x0DBD",
|
|
228
|
+
],
|
|
229
|
+
Family.CPK_SMBM.name: [
|
|
230
|
+
"0x188F",
|
|
231
|
+
"0x1895",
|
|
232
|
+
"0x0DCD",
|
|
233
|
+
],
|
|
234
|
+
Family.CVL.name: [
|
|
235
|
+
"0x1590",
|
|
236
|
+
"0x1591",
|
|
237
|
+
"0x1592",
|
|
238
|
+
"0x1593",
|
|
239
|
+
"0x1599",
|
|
240
|
+
"0x159B",
|
|
241
|
+
],
|
|
242
|
+
Family.CNV.name: [
|
|
243
|
+
"0x12D0",
|
|
244
|
+
"0x12D1",
|
|
245
|
+
"0x12D2",
|
|
246
|
+
"0x12D3",
|
|
247
|
+
"0x12D4",
|
|
248
|
+
"0x12D9",
|
|
249
|
+
"0xF0A8",
|
|
250
|
+
],
|
|
251
|
+
Family.MEV.name: MEV_IDs,
|
|
252
|
+
Family.NNTQ.name: ["0x1558"],
|
|
253
|
+
Family.HVL.name: [
|
|
254
|
+
"0x15C2",
|
|
255
|
+
"0x15C3",
|
|
256
|
+
"0x15C4",
|
|
257
|
+
"0x15C6",
|
|
258
|
+
"0x15C7",
|
|
259
|
+
"0x15C8",
|
|
260
|
+
"0x15CA",
|
|
261
|
+
"0x15CC",
|
|
262
|
+
"0x15CE",
|
|
263
|
+
"0x15E4",
|
|
264
|
+
"0x15E5",
|
|
265
|
+
],
|
|
266
|
+
Family.MPK.name: [
|
|
267
|
+
"0x15A7",
|
|
268
|
+
"0x15AA",
|
|
269
|
+
"0x15AB",
|
|
270
|
+
"0x15AC",
|
|
271
|
+
"0x15AD",
|
|
272
|
+
"0x15AE",
|
|
273
|
+
],
|
|
274
|
+
Family.HTWL.name: ["0x10D3", "0x10F6"],
|
|
275
|
+
Family.I350.name: ["0x1521", "0x1522", "0x1523", "0x1524"],
|
|
276
|
+
Family.I225.name: ["0x15F2", "0x15F3"],
|
|
277
|
+
Family.I710.name: ["0x0DD2"],
|
|
278
|
+
Family.RRC.name: ["0x15A4"],
|
|
279
|
+
Family.VF.name: [
|
|
280
|
+
"0x10ED",
|
|
281
|
+
"0x152E",
|
|
282
|
+
"0x1515",
|
|
283
|
+
"0x1530",
|
|
284
|
+
"0x1564",
|
|
285
|
+
"0x1565",
|
|
286
|
+
"0x15C5",
|
|
287
|
+
"0x15B4",
|
|
288
|
+
"0x15A8",
|
|
289
|
+
"0x15A9",
|
|
290
|
+
"0x154C",
|
|
291
|
+
"0x1571",
|
|
292
|
+
"0x374D",
|
|
293
|
+
"0x37CD",
|
|
294
|
+
"0x3759",
|
|
295
|
+
"0x37D9",
|
|
296
|
+
"0xF0A3",
|
|
297
|
+
"0xF0A4",
|
|
298
|
+
"0x1889",
|
|
299
|
+
"0x0DD5",
|
|
300
|
+
],
|
|
301
|
+
Speed.VF_G1.value: ["0x10CA", "0x1520"],
|
|
302
|
+
Speed.VF_G10.value: [
|
|
303
|
+
"0x10ED",
|
|
304
|
+
"0x1515",
|
|
305
|
+
"0x1530",
|
|
306
|
+
"0x1564",
|
|
307
|
+
"0x1565",
|
|
308
|
+
"0x152E",
|
|
309
|
+
"0x15A8",
|
|
310
|
+
"0x15C5",
|
|
311
|
+
"0x15A9",
|
|
312
|
+
"0x15B4",
|
|
313
|
+
"0x57AD",
|
|
314
|
+
],
|
|
315
|
+
Speed.VF_G40.value: [
|
|
316
|
+
"0x154C",
|
|
317
|
+
"0x1571",
|
|
318
|
+
"0x374D",
|
|
319
|
+
"0x3759",
|
|
320
|
+
"0x37CD",
|
|
321
|
+
"0x37D9",
|
|
322
|
+
"0xF0A3",
|
|
323
|
+
"0xF0A4",
|
|
324
|
+
"0xF0FB",
|
|
325
|
+
"0xFAFB",
|
|
326
|
+
"0x1889",
|
|
327
|
+
],
|
|
328
|
+
Speed.VF_G100.value: ["0x1889", "0x0DD5"],
|
|
329
|
+
"8254X": ["0x100F"],
|
|
330
|
+
"8256X": [
|
|
331
|
+
"0x1049",
|
|
332
|
+
"0x104A",
|
|
333
|
+
"0x104B",
|
|
334
|
+
"0x104D",
|
|
335
|
+
"0x10BD",
|
|
336
|
+
"0x294C",
|
|
337
|
+
"0x10BF",
|
|
338
|
+
"0x10CB",
|
|
339
|
+
"0x10CC",
|
|
340
|
+
"0x10CD",
|
|
341
|
+
"0x10CE",
|
|
342
|
+
"0x10DE",
|
|
343
|
+
"0x10DF",
|
|
344
|
+
"0x10E5",
|
|
345
|
+
"0x10F5",
|
|
346
|
+
"0x1501",
|
|
347
|
+
"0x1525",
|
|
348
|
+
],
|
|
349
|
+
"8257X": [
|
|
350
|
+
"0x105E",
|
|
351
|
+
"0x105F",
|
|
352
|
+
"0x1060",
|
|
353
|
+
"0x10A0",
|
|
354
|
+
"0x10A1",
|
|
355
|
+
"0x10A4",
|
|
356
|
+
"0x10A5",
|
|
357
|
+
"0x10BC",
|
|
358
|
+
"0x10D5",
|
|
359
|
+
"0x10D9",
|
|
360
|
+
"0x10DA",
|
|
361
|
+
"0x107D",
|
|
362
|
+
"0x107E",
|
|
363
|
+
"0x107F",
|
|
364
|
+
"0x10B9",
|
|
365
|
+
"0x108B",
|
|
366
|
+
"0x108C",
|
|
367
|
+
"0x108E",
|
|
368
|
+
"0x109A",
|
|
369
|
+
"0x10B0",
|
|
370
|
+
"0x10B2",
|
|
371
|
+
"0x10B3",
|
|
372
|
+
"0x10B4",
|
|
373
|
+
"0x10D3",
|
|
374
|
+
"0x10D4",
|
|
375
|
+
"0x10F6",
|
|
376
|
+
"0x10EA",
|
|
377
|
+
"0x10EB",
|
|
378
|
+
"0x10EF",
|
|
379
|
+
"0x10F0",
|
|
380
|
+
"0x1502",
|
|
381
|
+
"0x1503",
|
|
382
|
+
"0x10A7",
|
|
383
|
+
"0x10A9",
|
|
384
|
+
"0x10D6",
|
|
385
|
+
"0x10E2",
|
|
386
|
+
"0x10C9",
|
|
387
|
+
"0x10E6",
|
|
388
|
+
"0x10E7",
|
|
389
|
+
"0x10E8",
|
|
390
|
+
"0x150A",
|
|
391
|
+
"0x150D",
|
|
392
|
+
"0x1518",
|
|
393
|
+
"0x1526",
|
|
394
|
+
],
|
|
395
|
+
"82580": [
|
|
396
|
+
"0x150E",
|
|
397
|
+
"0x150F",
|
|
398
|
+
"0x1510",
|
|
399
|
+
"0x1511",
|
|
400
|
+
"0x1516",
|
|
401
|
+
"0x1527",
|
|
402
|
+
],
|
|
403
|
+
}
|
|
404
|
+
|
|
405
|
+
SPEED_IDS = {
|
|
406
|
+
Speed.G1.value: DEVICE_IDS[Family.PVL.name]
|
|
407
|
+
+ DEVICE_IDS["8256X"]
|
|
408
|
+
+ DEVICE_IDS["8257X"]
|
|
409
|
+
+ DEVICE_IDS["82580"]
|
|
410
|
+
+ DEVICE_IDS[Family.SPVL.name]
|
|
411
|
+
+ DEVICE_IDS[Family.I350.name]
|
|
412
|
+
+ DEVICE_IDS[Family.AVOTON.name]
|
|
413
|
+
+ DEVICE_IDS[Speed.VF_G1.value],
|
|
414
|
+
Speed.G2.value: DEVICE_IDS[Family.I225.name],
|
|
415
|
+
Speed.G10.value: DEVICE_IDS[Family.NNT.name]
|
|
416
|
+
+ DEVICE_IDS[Family.TVL.name]
|
|
417
|
+
+ DEVICE_IDS[Family.SGVL.name]
|
|
418
|
+
+ DEVICE_IDS[Family.HVL.name]
|
|
419
|
+
+ DEVICE_IDS[Family.MPK.name]
|
|
420
|
+
+ DEVICE_IDS[Family.NNTQ.name]
|
|
421
|
+
+ DEVICE_IDS[Family.LKV.name]
|
|
422
|
+
+ DEVICE_IDS[Speed.VF_G10.value],
|
|
423
|
+
Speed.G40.value: DEVICE_IDS[Family.FVL.name]
|
|
424
|
+
+ DEVICE_IDS[Family.FPK.name]
|
|
425
|
+
+ DEVICE_IDS[Family.RRC.name]
|
|
426
|
+
+ DEVICE_IDS[Family.I710.name]
|
|
427
|
+
+ DEVICE_IDS[Speed.VF_G40.value],
|
|
428
|
+
Speed.G100.value: DEVICE_IDS[Family.CPK.name]
|
|
429
|
+
+ DEVICE_IDS[Family.CVL.name]
|
|
430
|
+
+ DEVICE_IDS[Family.CNV.name]
|
|
431
|
+
+ DEVICE_IDS[Speed.VF_G100.value],
|
|
432
|
+
Speed.G200.value: DEVICE_IDS[Family.MEV.name],
|
|
433
|
+
}
|
|
434
|
+
|
|
435
|
+
FREEBSD_ADVERTISE_SPEED = {
|
|
436
|
+
"10Mb": {"ice": 0x1, "ix": 0x8},
|
|
437
|
+
"100Mb": {"ice": 0x2, "ixl": 0x1, "ix": 0x1},
|
|
438
|
+
"1G": {"ice": 0x4, "ixl": 0x2, "ix": 0x2},
|
|
439
|
+
"2.5G": {"ice": 0x8, "ixl": 0x40, "ix": 0x10},
|
|
440
|
+
"5G": {"ice": 0x10, "ixl": 0x80, "ix": 0x20},
|
|
441
|
+
"10G": {"ice": 0x20, "ixl": 0x4, "ix": 0x4},
|
|
442
|
+
"20G": {"ice": 0x40, "ixl": 0x8},
|
|
443
|
+
"25G": {"ice": 0x80, "ixl": 0x10},
|
|
444
|
+
"40G": {"ice": 0x100, "ixl": 0x20},
|
|
445
|
+
"50G": {"ice": 0x200},
|
|
446
|
+
"100G": {"ice": 0x400},
|
|
447
|
+
"Unknown": {"ice": 0x8000},
|
|
448
|
+
}
|
|
449
|
+
|
|
450
|
+
DEVID_CLASS_MAP_NICINSTALLER = {
|
|
451
|
+
"1G_E1000": (
|
|
452
|
+
"82566",
|
|
453
|
+
"82567",
|
|
454
|
+
"82571",
|
|
455
|
+
"82572",
|
|
456
|
+
"82573",
|
|
457
|
+
"82574",
|
|
458
|
+
"82577",
|
|
459
|
+
"82578",
|
|
460
|
+
"82579",
|
|
461
|
+
DeviceID(0x100F),
|
|
462
|
+
),
|
|
463
|
+
"1G": (
|
|
464
|
+
"82575",
|
|
465
|
+
"82576",
|
|
466
|
+
"82580",
|
|
467
|
+
"I350",
|
|
468
|
+
DeviceID(0x1521),
|
|
469
|
+
DeviceID(0x11BC),
|
|
470
|
+
DeviceID(0x1533),
|
|
471
|
+
DeviceID(0x1F41),
|
|
472
|
+
),
|
|
473
|
+
"1G_VF": (DeviceID(0x152F), DeviceID(0x1520)),
|
|
474
|
+
"2G": (DeviceID(0x15F2), DeviceID(0x15F3)),
|
|
475
|
+
"10G": (
|
|
476
|
+
DeviceID(0x10B6),
|
|
477
|
+
DeviceID(0x10C6),
|
|
478
|
+
DeviceID(0x10C7),
|
|
479
|
+
DeviceID(0x10C8),
|
|
480
|
+
DeviceID(0x10D8),
|
|
481
|
+
DeviceID(0x10DB),
|
|
482
|
+
DeviceID(0x10DD),
|
|
483
|
+
DeviceID(0x10E1),
|
|
484
|
+
DeviceID(0x10EC),
|
|
485
|
+
DeviceID(0x10F1),
|
|
486
|
+
DeviceID(0x10F4),
|
|
487
|
+
DeviceID(0x10F7),
|
|
488
|
+
DeviceID(0x10F8),
|
|
489
|
+
DeviceID(0x10F9),
|
|
490
|
+
DeviceID(0x10FA),
|
|
491
|
+
DeviceID(0x10FB),
|
|
492
|
+
DeviceID(0x10FC),
|
|
493
|
+
DeviceID(0x1306),
|
|
494
|
+
DeviceID(0x1307),
|
|
495
|
+
DeviceID(0x1507),
|
|
496
|
+
DeviceID(0x1508),
|
|
497
|
+
DeviceID(0x150B),
|
|
498
|
+
DeviceID(0x1512),
|
|
499
|
+
DeviceID(0x1514),
|
|
500
|
+
DeviceID(0x1517),
|
|
501
|
+
DeviceID(0x151C),
|
|
502
|
+
DeviceID(0x152A),
|
|
503
|
+
DeviceID(0x1529),
|
|
504
|
+
DeviceID(0x154A),
|
|
505
|
+
DeviceID(0x154D),
|
|
506
|
+
DeviceID(0x1557),
|
|
507
|
+
DeviceID(0x1558),
|
|
508
|
+
DeviceID(0x154F),
|
|
509
|
+
DeviceID(0x155D),
|
|
510
|
+
DeviceID(0x1528),
|
|
511
|
+
DeviceID(0x155C),
|
|
512
|
+
DeviceID(0x1560),
|
|
513
|
+
DeviceID(0x1562),
|
|
514
|
+
DeviceID(0x1563),
|
|
515
|
+
DeviceID(0x15A7),
|
|
516
|
+
DeviceID(0x15AA),
|
|
517
|
+
DeviceID(0x15AB),
|
|
518
|
+
DeviceID(0x15AC),
|
|
519
|
+
DeviceID(0x15AD),
|
|
520
|
+
DeviceID(0x15AE),
|
|
521
|
+
DeviceID(0x15C2),
|
|
522
|
+
DeviceID(0x15C3),
|
|
523
|
+
DeviceID(0x15C4),
|
|
524
|
+
DeviceID(0x15C6),
|
|
525
|
+
DeviceID(0x15C7),
|
|
526
|
+
DeviceID(0x15C8),
|
|
527
|
+
DeviceID(0x15CA),
|
|
528
|
+
DeviceID(0x15CC),
|
|
529
|
+
DeviceID(0x15CE),
|
|
530
|
+
DeviceID(0x15D1),
|
|
531
|
+
DeviceID(0x15E4),
|
|
532
|
+
DeviceID(0x15E5),
|
|
533
|
+
DeviceID(0xF0C2),
|
|
534
|
+
DeviceID(0xF0C4),
|
|
535
|
+
DeviceID(0xF0C6),
|
|
536
|
+
DeviceID(0xF0C7),
|
|
537
|
+
DeviceID(0xF0C9),
|
|
538
|
+
DeviceID(0x57AF),
|
|
539
|
+
DeviceID(0x57B0),
|
|
540
|
+
DeviceID(0x57B1),
|
|
541
|
+
),
|
|
542
|
+
"10G_VF": (
|
|
543
|
+
DeviceID(0x10ED),
|
|
544
|
+
DeviceID(0x1515),
|
|
545
|
+
DeviceID(0x152E),
|
|
546
|
+
DeviceID(0x1530),
|
|
547
|
+
DeviceID(0x1564),
|
|
548
|
+
DeviceID(0x1565),
|
|
549
|
+
DeviceID(0x15A8),
|
|
550
|
+
DeviceID(0x15A9),
|
|
551
|
+
DeviceID(0x15B4),
|
|
552
|
+
DeviceID(0x15C5),
|
|
553
|
+
DeviceID(0x57AD),
|
|
554
|
+
),
|
|
555
|
+
"40G": (
|
|
556
|
+
DeviceID(0x0DD2),
|
|
557
|
+
DeviceID(0x0DDA),
|
|
558
|
+
DeviceID(0x1572),
|
|
559
|
+
DeviceID(0x1573),
|
|
560
|
+
DeviceID(0x1574),
|
|
561
|
+
DeviceID(0x1580),
|
|
562
|
+
DeviceID(0x1581),
|
|
563
|
+
DeviceID(0x1582),
|
|
564
|
+
DeviceID(0x1583),
|
|
565
|
+
DeviceID(0x1584),
|
|
566
|
+
DeviceID(0x1585),
|
|
567
|
+
DeviceID(0x1586),
|
|
568
|
+
DeviceID(0x1587),
|
|
569
|
+
DeviceID(0x1588),
|
|
570
|
+
DeviceID(0x1589),
|
|
571
|
+
DeviceID(0x158A),
|
|
572
|
+
DeviceID(0x158B),
|
|
573
|
+
DeviceID(0x374C),
|
|
574
|
+
DeviceID(0x37CC),
|
|
575
|
+
DeviceID(0x37CE),
|
|
576
|
+
DeviceID(0x37CF),
|
|
577
|
+
DeviceID(0x37D0),
|
|
578
|
+
DeviceID(0x37D1),
|
|
579
|
+
DeviceID(0x37D2),
|
|
580
|
+
DeviceID(0x37D3),
|
|
581
|
+
DeviceID(0xF0A2),
|
|
582
|
+
DeviceID(0xFAFA),
|
|
583
|
+
DeviceID(0x154B),
|
|
584
|
+
DeviceID(0x15FF),
|
|
585
|
+
),
|
|
586
|
+
"40G_VF": (
|
|
587
|
+
DeviceID(0x154C),
|
|
588
|
+
DeviceID(0x1571),
|
|
589
|
+
DeviceID(0x3759),
|
|
590
|
+
DeviceID(0x374D),
|
|
591
|
+
DeviceID(0x37CD),
|
|
592
|
+
DeviceID(0x37D9),
|
|
593
|
+
DeviceID(0xF0A3),
|
|
594
|
+
DeviceID(0xF0A4),
|
|
595
|
+
DeviceID(0xFAFB),
|
|
596
|
+
),
|
|
597
|
+
"100G": (
|
|
598
|
+
DeviceID(0x12D0),
|
|
599
|
+
DeviceID(0x12D1),
|
|
600
|
+
DeviceID(0x12D2),
|
|
601
|
+
DeviceID(0x12D3),
|
|
602
|
+
DeviceID(0x12D4),
|
|
603
|
+
DeviceID(0x12D9),
|
|
604
|
+
DeviceID(0x1590),
|
|
605
|
+
DeviceID(0x1591),
|
|
606
|
+
DeviceID(0x1592),
|
|
607
|
+
DeviceID(0x1593),
|
|
608
|
+
DeviceID(0x1599),
|
|
609
|
+
DeviceID(0x159B),
|
|
610
|
+
DeviceID(0x18E4),
|
|
611
|
+
DeviceID(0x18ED),
|
|
612
|
+
DeviceID(0x1891),
|
|
613
|
+
DeviceID(0x1892),
|
|
614
|
+
DeviceID(0xF0A5),
|
|
615
|
+
DeviceID(0xF0A6),
|
|
616
|
+
DeviceID(0xF0A8),
|
|
617
|
+
),
|
|
618
|
+
"100G_CPK": (
|
|
619
|
+
DeviceID(0xF0A5),
|
|
620
|
+
DeviceID(0xF0A6),
|
|
621
|
+
DeviceID(0x18E4),
|
|
622
|
+
DeviceID(0x18ED),
|
|
623
|
+
DeviceID(0x1890),
|
|
624
|
+
DeviceID(0x1891),
|
|
625
|
+
DeviceID(0x1892),
|
|
626
|
+
DeviceID(0x1897),
|
|
627
|
+
DeviceID(0x1898),
|
|
628
|
+
DeviceID(0x189A),
|
|
629
|
+
DeviceID(0x151D),
|
|
630
|
+
DeviceID(0x124C),
|
|
631
|
+
DeviceID(0x124D),
|
|
632
|
+
DeviceID(0x188A),
|
|
633
|
+
DeviceID(0x188B),
|
|
634
|
+
DeviceID(0x188C),
|
|
635
|
+
DeviceID(0x579C),
|
|
636
|
+
DeviceID(0x579D),
|
|
637
|
+
DeviceID(0x579E),
|
|
638
|
+
DeviceID(0x579F),
|
|
639
|
+
),
|
|
640
|
+
"100G_CPK_SMBM": (DeviceID(0x188F), DeviceID(0x1895), DeviceID(0x0DCD)),
|
|
641
|
+
"100G_VF": (DeviceID(0x18ED), DeviceID(0x1889), DeviceID(0x0DBD)),
|
|
642
|
+
"200G": (DeviceID(0xF002), DeviceID(0xF00C), DeviceID(0x1452)),
|
|
643
|
+
}
|
|
644
|
+
|
|
645
|
+
DRIVER_DIRECTORY_MAP = {
|
|
646
|
+
"e1000e": "PRO1000",
|
|
647
|
+
"e2f": "PRO2500",
|
|
648
|
+
"em": "PRO1000",
|
|
649
|
+
"fm10k": "PRO40GB",
|
|
650
|
+
"i40e": "PRO40GB",
|
|
651
|
+
"iavf": "PROAVF",
|
|
652
|
+
"ice": "PROCGB",
|
|
653
|
+
"ice_sw": "PROCGB",
|
|
654
|
+
"ice_swx": "PROCGB",
|
|
655
|
+
"idpf": "PROCCGB",
|
|
656
|
+
"igb": "PRO1000",
|
|
657
|
+
"igbvf": "PRO1000",
|
|
658
|
+
"igc": "PRO2500",
|
|
659
|
+
"ix": "PROXGB",
|
|
660
|
+
"ixgbe": "PROXGB",
|
|
661
|
+
"ixgbevf": "PROXGB",
|
|
662
|
+
"ixl": "PRO40GB",
|
|
663
|
+
"ixv": "PROXGB",
|
|
664
|
+
"scea": "PROCCGB",
|
|
665
|
+
"v1q": "PRO1000",
|
|
666
|
+
"vx": "PROXGB",
|
|
667
|
+
}
|
|
668
|
+
|
|
669
|
+
DRIVER_DEVICE_ID_MAP = {
|
|
670
|
+
"e1000e": {
|
|
671
|
+
DeviceID(0x1049),
|
|
672
|
+
DeviceID(0x104A),
|
|
673
|
+
DeviceID(0x104B),
|
|
674
|
+
DeviceID(0x104D),
|
|
675
|
+
DeviceID(0x10BD),
|
|
676
|
+
DeviceID(0x294C),
|
|
677
|
+
DeviceID(0x10BF),
|
|
678
|
+
DeviceID(0x10CB),
|
|
679
|
+
DeviceID(0x10CC),
|
|
680
|
+
DeviceID(0x10CD),
|
|
681
|
+
DeviceID(0x10CE),
|
|
682
|
+
DeviceID(0x10DE),
|
|
683
|
+
DeviceID(0x10DF),
|
|
684
|
+
DeviceID(0x10E5),
|
|
685
|
+
DeviceID(0x10F5),
|
|
686
|
+
DeviceID(0x1501),
|
|
687
|
+
DeviceID(0x1525),
|
|
688
|
+
DeviceID(0x105E),
|
|
689
|
+
DeviceID(0x105F),
|
|
690
|
+
DeviceID(0x1060),
|
|
691
|
+
DeviceID(0x10A0),
|
|
692
|
+
DeviceID(0x10A1),
|
|
693
|
+
DeviceID(0x10A4),
|
|
694
|
+
DeviceID(0x10A5),
|
|
695
|
+
DeviceID(0x10BC),
|
|
696
|
+
DeviceID(0x10D5),
|
|
697
|
+
DeviceID(0x10D9),
|
|
698
|
+
DeviceID(0x10DA),
|
|
699
|
+
DeviceID(0x107D),
|
|
700
|
+
DeviceID(0x107E),
|
|
701
|
+
DeviceID(0x107F),
|
|
702
|
+
DeviceID(0x10B9),
|
|
703
|
+
DeviceID(0x108B),
|
|
704
|
+
DeviceID(0x108C),
|
|
705
|
+
DeviceID(0x108E),
|
|
706
|
+
DeviceID(0x109A),
|
|
707
|
+
DeviceID(0x10B0),
|
|
708
|
+
DeviceID(0x10B2),
|
|
709
|
+
DeviceID(0x10B3),
|
|
710
|
+
DeviceID(0x10B4),
|
|
711
|
+
DeviceID(0x10D3),
|
|
712
|
+
DeviceID(0x10D4),
|
|
713
|
+
DeviceID(0x10F6),
|
|
714
|
+
DeviceID(0x10EA),
|
|
715
|
+
DeviceID(0x10EB),
|
|
716
|
+
DeviceID(0x10EF),
|
|
717
|
+
DeviceID(0x10F0),
|
|
718
|
+
DeviceID(0x100F),
|
|
719
|
+
DeviceID(0x1502),
|
|
720
|
+
DeviceID(0x1503),
|
|
721
|
+
}, # on BSD em
|
|
722
|
+
"igb": {
|
|
723
|
+
DeviceID(0x10A7),
|
|
724
|
+
DeviceID(0x10A9),
|
|
725
|
+
DeviceID(0x10D6),
|
|
726
|
+
DeviceID(0x10E2),
|
|
727
|
+
DeviceID(0x10C9),
|
|
728
|
+
DeviceID(0x10E6),
|
|
729
|
+
DeviceID(0x10E7),
|
|
730
|
+
DeviceID(0x10E8),
|
|
731
|
+
DeviceID(0x150A),
|
|
732
|
+
DeviceID(0x150D),
|
|
733
|
+
DeviceID(0x1518),
|
|
734
|
+
DeviceID(0x1526),
|
|
735
|
+
DeviceID(0x150E),
|
|
736
|
+
DeviceID(0x150F),
|
|
737
|
+
DeviceID(0x1510),
|
|
738
|
+
DeviceID(0x1511),
|
|
739
|
+
DeviceID(0x1516),
|
|
740
|
+
DeviceID(0x1527),
|
|
741
|
+
DeviceID(0x1521),
|
|
742
|
+
DeviceID(0x1522),
|
|
743
|
+
DeviceID(0x1523),
|
|
744
|
+
DeviceID(0x1524),
|
|
745
|
+
DeviceID(0x11BC),
|
|
746
|
+
DeviceID(0x1533),
|
|
747
|
+
DeviceID(0x1F41),
|
|
748
|
+
},
|
|
749
|
+
"igbvf": {DeviceID(0x10CA), DeviceID(0x1520), DeviceID(0x152F)}, # on Windows v1q
|
|
750
|
+
"igc": {DeviceID(0x15F2), DeviceID(0x15F3)}, # on Windows e2f
|
|
751
|
+
"ixgbe": {
|
|
752
|
+
DeviceID(0x10B6),
|
|
753
|
+
DeviceID(0x10C6),
|
|
754
|
+
DeviceID(0x10C7),
|
|
755
|
+
DeviceID(0x10C8),
|
|
756
|
+
DeviceID(0x10D8),
|
|
757
|
+
DeviceID(0x10DB),
|
|
758
|
+
DeviceID(0x10DD),
|
|
759
|
+
DeviceID(0x10E1),
|
|
760
|
+
DeviceID(0x10EC),
|
|
761
|
+
DeviceID(0x10F1),
|
|
762
|
+
DeviceID(0x10F4),
|
|
763
|
+
DeviceID(0x10F7),
|
|
764
|
+
DeviceID(0x10F8),
|
|
765
|
+
DeviceID(0x10F9),
|
|
766
|
+
DeviceID(0x10FA),
|
|
767
|
+
DeviceID(0x10FB),
|
|
768
|
+
DeviceID(0x10FC),
|
|
769
|
+
DeviceID(0x1306),
|
|
770
|
+
DeviceID(0x1307),
|
|
771
|
+
DeviceID(0x1507),
|
|
772
|
+
DeviceID(0x1508),
|
|
773
|
+
DeviceID(0x150B),
|
|
774
|
+
DeviceID(0x1512),
|
|
775
|
+
DeviceID(0x1514),
|
|
776
|
+
DeviceID(0x1517),
|
|
777
|
+
DeviceID(0x151C),
|
|
778
|
+
DeviceID(0x1528),
|
|
779
|
+
DeviceID(0x1529),
|
|
780
|
+
DeviceID(0x152A),
|
|
781
|
+
DeviceID(0x154A),
|
|
782
|
+
DeviceID(0x154D),
|
|
783
|
+
DeviceID(0x154F),
|
|
784
|
+
DeviceID(0x1557),
|
|
785
|
+
DeviceID(0x1558),
|
|
786
|
+
DeviceID(0x155C),
|
|
787
|
+
DeviceID(0x155D),
|
|
788
|
+
DeviceID(0x1560),
|
|
789
|
+
DeviceID(0x1562),
|
|
790
|
+
DeviceID(0x1563),
|
|
791
|
+
DeviceID(0x15A7),
|
|
792
|
+
DeviceID(0x15AA),
|
|
793
|
+
DeviceID(0x15AB),
|
|
794
|
+
DeviceID(0x15AC),
|
|
795
|
+
DeviceID(0x15AD),
|
|
796
|
+
DeviceID(0x15AE),
|
|
797
|
+
DeviceID(0x15C2),
|
|
798
|
+
DeviceID(0x15C3),
|
|
799
|
+
DeviceID(0x15C4),
|
|
800
|
+
DeviceID(0x15C6),
|
|
801
|
+
DeviceID(0x15C7),
|
|
802
|
+
DeviceID(0x15C8),
|
|
803
|
+
DeviceID(0x15CA),
|
|
804
|
+
DeviceID(0x15CC),
|
|
805
|
+
DeviceID(0x15CE),
|
|
806
|
+
DeviceID(0x15D1),
|
|
807
|
+
DeviceID(0x15E4),
|
|
808
|
+
DeviceID(0x15E5),
|
|
809
|
+
DeviceID(0x57AF),
|
|
810
|
+
DeviceID(0x57B0),
|
|
811
|
+
DeviceID(0x57B1),
|
|
812
|
+
DeviceID(0xF0C2),
|
|
813
|
+
DeviceID(0xF0C4),
|
|
814
|
+
DeviceID(0xF0C6),
|
|
815
|
+
DeviceID(0xF0C7),
|
|
816
|
+
DeviceID(0xF0C9),
|
|
817
|
+
}, # on BSD ix, on Windows ix
|
|
818
|
+
"ixgbevf": {
|
|
819
|
+
DeviceID(0x10ED),
|
|
820
|
+
DeviceID(0x1515),
|
|
821
|
+
DeviceID(0x152E),
|
|
822
|
+
DeviceID(0x1530),
|
|
823
|
+
DeviceID(0x1564),
|
|
824
|
+
DeviceID(0x1565),
|
|
825
|
+
DeviceID(0x15A8),
|
|
826
|
+
DeviceID(0x15A9),
|
|
827
|
+
DeviceID(0x15B4),
|
|
828
|
+
DeviceID(0x15C5),
|
|
829
|
+
DeviceID(0x57AD),
|
|
830
|
+
}, # on BSD ixv, on Windows vx
|
|
831
|
+
"i40e": {
|
|
832
|
+
DeviceID(0x0DD2),
|
|
833
|
+
DeviceID(0x0DDA),
|
|
834
|
+
DeviceID(0x154B),
|
|
835
|
+
DeviceID(0x1572),
|
|
836
|
+
DeviceID(0x1573),
|
|
837
|
+
DeviceID(0x1574),
|
|
838
|
+
DeviceID(0x1580),
|
|
839
|
+
DeviceID(0x1581),
|
|
840
|
+
DeviceID(0x1582),
|
|
841
|
+
DeviceID(0x1583),
|
|
842
|
+
DeviceID(0x1584),
|
|
843
|
+
DeviceID(0x1585),
|
|
844
|
+
DeviceID(0x1586),
|
|
845
|
+
DeviceID(0x1587),
|
|
846
|
+
DeviceID(0x1588),
|
|
847
|
+
DeviceID(0x1589),
|
|
848
|
+
DeviceID(0x158A),
|
|
849
|
+
DeviceID(0x158B),
|
|
850
|
+
DeviceID(0x15FF),
|
|
851
|
+
DeviceID(0x374C),
|
|
852
|
+
DeviceID(0x37CC),
|
|
853
|
+
DeviceID(0x37CE),
|
|
854
|
+
DeviceID(0x37CF),
|
|
855
|
+
DeviceID(0x37D0),
|
|
856
|
+
DeviceID(0x37D1),
|
|
857
|
+
DeviceID(0x37D2),
|
|
858
|
+
DeviceID(0x37D3),
|
|
859
|
+
DeviceID(0xF0A2),
|
|
860
|
+
DeviceID(0xFAFA),
|
|
861
|
+
}, # on BSD ixl
|
|
862
|
+
"fm10k": {DeviceID(0x15A4)},
|
|
863
|
+
"ice_sw": {
|
|
864
|
+
DeviceID(0x18ED),
|
|
865
|
+
},
|
|
866
|
+
"ice_swx": {
|
|
867
|
+
DeviceID(0x188F),
|
|
868
|
+
DeviceID(0x1895),
|
|
869
|
+
DeviceID(0x0DCD),
|
|
870
|
+
},
|
|
871
|
+
"ice": {
|
|
872
|
+
DeviceID(0x124C),
|
|
873
|
+
DeviceID(0x124D),
|
|
874
|
+
DeviceID(0x124E),
|
|
875
|
+
DeviceID(0x124F),
|
|
876
|
+
DeviceID(0x12D0),
|
|
877
|
+
DeviceID(0x12D1),
|
|
878
|
+
DeviceID(0x12D2),
|
|
879
|
+
DeviceID(0x12D3),
|
|
880
|
+
DeviceID(0x12D4),
|
|
881
|
+
DeviceID(0x12D9),
|
|
882
|
+
DeviceID(0x151D),
|
|
883
|
+
DeviceID(0x1590),
|
|
884
|
+
DeviceID(0x1591),
|
|
885
|
+
DeviceID(0x1592),
|
|
886
|
+
DeviceID(0x1593),
|
|
887
|
+
DeviceID(0x1599),
|
|
888
|
+
DeviceID(0x159B),
|
|
889
|
+
DeviceID(0x188A),
|
|
890
|
+
DeviceID(0x188B),
|
|
891
|
+
DeviceID(0x188C),
|
|
892
|
+
DeviceID(0x188D),
|
|
893
|
+
DeviceID(0x188E),
|
|
894
|
+
DeviceID(0x1890),
|
|
895
|
+
DeviceID(0x1891),
|
|
896
|
+
DeviceID(0x1892),
|
|
897
|
+
DeviceID(0x1893),
|
|
898
|
+
DeviceID(0x1894),
|
|
899
|
+
DeviceID(0x1897),
|
|
900
|
+
DeviceID(0x1898),
|
|
901
|
+
DeviceID(0x1899),
|
|
902
|
+
DeviceID(0x189A),
|
|
903
|
+
DeviceID(0x18E4),
|
|
904
|
+
DeviceID(0x18ED),
|
|
905
|
+
DeviceID(0x579C),
|
|
906
|
+
DeviceID(0x579D),
|
|
907
|
+
DeviceID(0x579E),
|
|
908
|
+
DeviceID(0x579F),
|
|
909
|
+
DeviceID(0xF0A5),
|
|
910
|
+
DeviceID(0xF0A6),
|
|
911
|
+
DeviceID(0xF0A8),
|
|
912
|
+
}, # CPK part on Windows scea
|
|
913
|
+
"idpf": {DeviceID(0xF002), DeviceID(0xF00C), DeviceID(0x1452), DeviceID(0x145C)},
|
|
914
|
+
"iavf": {
|
|
915
|
+
DeviceID(0x154C),
|
|
916
|
+
DeviceID(0x1571),
|
|
917
|
+
DeviceID(0x374D),
|
|
918
|
+
DeviceID(0x3759),
|
|
919
|
+
DeviceID(0x37CD),
|
|
920
|
+
DeviceID(0x37D9),
|
|
921
|
+
DeviceID(0xF0A3),
|
|
922
|
+
DeviceID(0xF0A4),
|
|
923
|
+
DeviceID(0xF0FB),
|
|
924
|
+
DeviceID(0x1889),
|
|
925
|
+
},
|
|
926
|
+
}
|
|
927
|
+
|
|
928
|
+
WINDOWS_DRIVER_DEVICE_ID_MAP = {
|
|
929
|
+
"scea": {
|
|
930
|
+
DeviceID(0x124C),
|
|
931
|
+
DeviceID(0x124D),
|
|
932
|
+
DeviceID(0x151D),
|
|
933
|
+
DeviceID(0x188A),
|
|
934
|
+
DeviceID(0x188B),
|
|
935
|
+
DeviceID(0x188C),
|
|
936
|
+
DeviceID(0x1890),
|
|
937
|
+
DeviceID(0x1891),
|
|
938
|
+
DeviceID(0x1892),
|
|
939
|
+
DeviceID(0x1897),
|
|
940
|
+
DeviceID(0x1898),
|
|
941
|
+
DeviceID(0x189A),
|
|
942
|
+
DeviceID(0x18E4),
|
|
943
|
+
DeviceID(0x18ED),
|
|
944
|
+
DeviceID(0x579C),
|
|
945
|
+
DeviceID(0x579D),
|
|
946
|
+
DeviceID(0x579E),
|
|
947
|
+
DeviceID(0x579F),
|
|
948
|
+
DeviceID(0xF0A5),
|
|
949
|
+
DeviceID(0xF0A6),
|
|
950
|
+
},
|
|
951
|
+
}
|
|
952
|
+
|
|
953
|
+
MANAGEMENT_NETWORK = [
|
|
954
|
+
IPv4Network("10.166.28.0/23"),
|
|
955
|
+
IPv4Network("10.102.0.0/16"),
|
|
956
|
+
IPv4Network("10.12.0.0/16"),
|
|
957
|
+
IPv4Network("172.31.0.0/16"),
|
|
958
|
+
]
|
|
959
|
+
|
|
960
|
+
|
|
961
|
+
class FreeBSDDriverNames(Enum):
|
|
962
|
+
"""FreeBSD Driver Name Enum."""
|
|
963
|
+
|
|
964
|
+
IXV = "ixv"
|
|
965
|
+
IGB = "igb"
|
|
966
|
+
IX = "ix"
|
|
967
|
+
IXL = "ixl"
|
|
968
|
+
IAVF = "iavf"
|
|
969
|
+
ICE = "ice"
|
|
970
|
+
|
|
971
|
+
|
|
972
|
+
DESIGNED_NUMBER_VFS_BY_SPEED = {
|
|
973
|
+
Speed.G1: 28,
|
|
974
|
+
Speed.G10: 126,
|
|
975
|
+
Speed.G40: 128,
|
|
976
|
+
Speed.G100: 256,
|
|
977
|
+
Speed.G200: 1024,
|
|
978
|
+
}
|
|
979
|
+
|
|
980
|
+
# Supported Reset types
|
|
981
|
+
SUPPORTED_ADAPTER_RESET_TYPES = {"global": "GLOBR", "core": "CORER", "pf": "PFR"}
|
mfd_const/qos.py
ADDED
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
# Copyright (C) 2025 Intel Corporation
|
|
2
|
+
# SPDX-License-Identifier: MIT
|
|
3
|
+
"""Main module for QoS Consts."""
|
|
4
|
+
|
|
5
|
+
# for QoS mapping
|
|
6
|
+
LOCAL_ETS = "ETS"
|
|
7
|
+
LOCAL_PFC = "PFC"
|
|
8
|
+
LOCAL_APP = "APP"
|
|
9
|
+
REMOTE_ETS = "Remote_ETS"
|
|
10
|
+
REMOTE_PFC = "Remote_PFC"
|
|
11
|
+
REMOTE_APP = "Remote_APP"
|
|
12
|
+
|
|
13
|
+
# temporary path for copying tools from SUT/Controller to any host under test
|
|
14
|
+
DCB_TOOL_PATH_LNX = r"/tmp/tools/dcb"
|
|
15
|
+
|
|
16
|
+
# adapters features names
|
|
17
|
+
NIC_REGISTRY_BASE_PATH_DCB = r"HKLM:\SYSTEM\ControlSet001\Control\Class\{4d36e972-e325-11ce-bfc1-08002be10318}\%s"
|
|
18
|
+
|
|
19
|
+
LOCAL_DEFAULT_MAP = {
|
|
20
|
+
LOCAL_ETS: {"0": {"TSA": "ETS", "Bandwidth": 100, "Priorities": [0, 1, 2, 3, 4, 5, 6, 7]}},
|
|
21
|
+
LOCAL_PFC: [False, False, False, False, False, False, False, False],
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
LOCAL_ISCSI_MAP = {
|
|
25
|
+
LOCAL_ETS: {
|
|
26
|
+
"0": {"TSA": "ETS", "Bandwidth": 20, "Priorities": [0, 1, 2, 5, 6, 7]},
|
|
27
|
+
"1": {"TSA": "ETS", "Bandwidth": 20, "Priorities": [3]},
|
|
28
|
+
"2": {"TSA": "ETS", "Bandwidth": 60, "Priorities": [4]},
|
|
29
|
+
},
|
|
30
|
+
LOCAL_PFC: [False, False, False, True, True, False, False, False],
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
SAN_DCB_MAP = {
|
|
34
|
+
LOCAL_ETS: {
|
|
35
|
+
"0": {"TSA": "ETS", "Bandwidth": 40, "Priorities": [0, 1, 2, 5, 6, 7]},
|
|
36
|
+
"1": {"TSA": "ETS", "Bandwidth": 30, "Priorities": [3]},
|
|
37
|
+
"2": {"TSA": "ETS", "Bandwidth": 30, "Priorities": [4]},
|
|
38
|
+
},
|
|
39
|
+
LOCAL_PFC: [False, False, False, True, True, False, False, False],
|
|
40
|
+
LOCAL_APP: {"3260": {"Priority": 4, "Protocol": "TCP"}},
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
ALT_SAN_DCB = {
|
|
44
|
+
LOCAL_ETS: {
|
|
45
|
+
"0": {"TSA": "ETS", "Bandwidth": 10, "Priorities": [0, 1, 2, 5, 6, 7]},
|
|
46
|
+
"1": {"TSA": "ETS", "Bandwidth": 30, "Priorities": [3]},
|
|
47
|
+
"2": {"TSA": "ETS", "Bandwidth": 60, "Priorities": [4]},
|
|
48
|
+
},
|
|
49
|
+
LOCAL_PFC: [False, False, False, True, True, False, False, False],
|
|
50
|
+
LOCAL_APP: {"3260": {"Priority": 4, "Protocol": "TCP"}},
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
ISCSI_POLICY = {"UP4": {"Template": "iSCSI", "PriorityValue": "4"}}
|
mfd_const/release.py
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
# Copyright (C) 2025 Intel Corporation
|
|
2
|
+
# SPDX-License-Identifier: MIT
|
|
3
|
+
"""Module for release details."""
|
|
4
|
+
|
|
5
|
+
from enum import Enum
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
class Milestone(Enum):
|
|
9
|
+
"""Enum for milestone values."""
|
|
10
|
+
|
|
11
|
+
ALPHA = "Alpha"
|
|
12
|
+
BETA = "Beta"
|
|
13
|
+
PC = "PC"
|
|
14
|
+
PV = "PV"
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: mfd-const
|
|
3
|
+
Version: 0.23.0
|
|
4
|
+
Summary: Module for keeping const values.
|
|
5
|
+
Project-URL: Homepage, https://github.com/intel/mfd
|
|
6
|
+
Project-URL: Repository, https://github.com/intel/mfd-const
|
|
7
|
+
Project-URL: Issues, https://github.com/intel/mfd-const/issues
|
|
8
|
+
Project-URL: Changelog, https://github.com/intel/mfd-const/blob/main/CHANGELOG.md
|
|
9
|
+
Requires-Python: <3.14,>=3.10
|
|
10
|
+
Description-Content-Type: text/markdown
|
|
11
|
+
License-File: LICENSE.md
|
|
12
|
+
License-File: AUTHORS.md
|
|
13
|
+
Requires-Dist: mfd-typing>=1.23
|
|
14
|
+
Dynamic: license-file
|
|
15
|
+
|
|
16
|
+
> [!IMPORTANT]
|
|
17
|
+
> This project is under development. All source code and features on the main branch are for the purpose of testing or evaluation and not production ready.
|
|
18
|
+
# MFD Const
|
|
19
|
+
|
|
20
|
+
Module for keeping const values.
|
|
21
|
+
|
|
22
|
+
## Available data structures
|
|
23
|
+
* `DEVICE_IDS` - family: device_id mapping like "CPK": ["0xF0A5", "0xF0A5"]
|
|
24
|
+
* `DEVID_CLASS_MAP_NICINSTALLER` - speed: device_id mapping.
|
|
25
|
+
* `DRIVER_DIRECTORY_MAP` - driver: directory mapping like "ice": "PROCGB"
|
|
26
|
+
* `DRIVER_DEVICE_ID_MAP` - driver: device_id mapping like "ice": {DeviceID(0x124C), DeviceID(0x124D)}
|
|
27
|
+
* `SPEED_IDS`- speed: device_id mapping like "@1G": DEVICE_IDS["PVL"]
|
|
28
|
+
* `Family` - Enum class of available families like `Family.PVL`
|
|
29
|
+
* `family_to_full_name` - Dict with mapping Family to full name like `Family.CVL: "Columbiaville"`
|
|
30
|
+
* `Speed`- Enum class of available speeds like `Speed.G100`
|
|
31
|
+
* `FREEBSD_ADVERTISE_SPEED`- advertise_speed: speed mapping like "1G": {"ice": 0x4, "ixl": 0x2, "ix": 0x2}
|
|
32
|
+
* `MANAGEMENT_NETWORK` - list of networks used for management connection
|
|
33
|
+
* `LOCAL_DEFAULT_MAP` (`qos.py`) - QoS Default map for DCB local settings
|
|
34
|
+
* `LOCAL_ISCSI_MAP` (`qos.py`) - ISCSI map for QoS
|
|
35
|
+
* `SAN_DCB_MAP` (`qos.py`) - SAN DCB map for QoS
|
|
36
|
+
* `ALT_SAN_DCB` (`qos.py`) - ALT SAN DCB map for QoS
|
|
37
|
+
* `ISCSI_POLICY` (`qos.py`) - ISCSI Policy
|
|
38
|
+
* `FreeBSDDriverNames` - Enum class of FreeBSD Driver Names
|
|
39
|
+
* `DESIGNED_NUMBER_VFS_BY_SPEED` - Designed number of VFs for every speed class, like for 100G NIC is designed 256 VFs
|
|
40
|
+
* `SUPPORTED_ADAPTER_RESET_TYPES` - Supporting reset types for NIC.
|
|
41
|
+
* `Milestone` - Enum class of available milestones like `Milestone.PV`
|
|
42
|
+
|
|
43
|
+
## Usage
|
|
44
|
+
|
|
45
|
+
```python
|
|
46
|
+
from mfd_const import SPEED_IDS
|
|
47
|
+
logger.info(f"Device ids for 1G == {SPEED_IDS['@1G']}")
|
|
48
|
+
|
|
49
|
+
from mfd_const import FREEBSD_ADVERTISE_SPEED
|
|
50
|
+
logger.info(f"Value for 1G advertise speed on ix driver is: {FREEBSD_ADVERTISE_SPEED['1G']['ix']}")
|
|
51
|
+
|
|
52
|
+
from mfd_const import MANAGEMENT_NETWORK
|
|
53
|
+
from ipaddress import IPv4Interface
|
|
54
|
+
ip = IPv4Interface("10.10.10.10")
|
|
55
|
+
for mng_sub in MANAGEMENT_NETWORK:
|
|
56
|
+
if ip in mng_sub:
|
|
57
|
+
logger.info(f"{ip} is management IP.")
|
|
58
|
+
|
|
59
|
+
# To apply DCB settings related to QOS, please use the flags as below.
|
|
60
|
+
from mfd_const.qos import (LOCAL_PFC, LOCAL_DEFAULT_MAP)
|
|
61
|
+
res = dcb.verify_dcb(LOCAL_DEFAULT_MAP)
|
|
62
|
+
if res:
|
|
63
|
+
logger.info("DCB Configuration sustains the local settings")
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
## qos
|
|
67
|
+
Temporary path for copying tools from SUT/Controller to any host under test
|
|
68
|
+
`DCB_TOOL_PATH_LNX : Path for dcbnl.py - Netlink message generation/parsing script`
|
|
69
|
+
|
|
70
|
+
## Issue reporting
|
|
71
|
+
|
|
72
|
+
If you encounter any bugs or have suggestions for improvements, you're welcome to contribute directly or open an issue [here](https://github.com/intel/mfd-const/issues).
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
mfd_const/__init__.py,sha256=53h3e86CCTa8XhQrA4GNyIvJ-0q8QQxnizbrrxNqaOk,287
|
|
2
|
+
mfd_const/_internal_data_structures.py,sha256=YGI1U73crCeFXY3pCrimnDG4go-Vt1YTHPKhZTC4mB4,528
|
|
3
|
+
mfd_const/mfd_const.py,sha256=xXd8wk2y3wj1e-huZorz7q1nqjT8fkNbVInG4Ykdirw,273
|
|
4
|
+
mfd_const/network.py,sha256=LvEJt9jm7gOEUY8Ria006pgYWanc1MGLcML0-Kfv7_k,22719
|
|
5
|
+
mfd_const/qos.py,sha256=ETP95D8l1ShwWvIZPV9bDemDgvZI5H4rxXKqSSDS3j4,1875
|
|
6
|
+
mfd_const/release.py,sha256=Ovj66Z4d_6i2f2_YPkLRwBg0V-GFrA1edWRDdb_lhrs,256
|
|
7
|
+
mfd_const-0.23.0.dist-info/licenses/AUTHORS.md,sha256=J4h6eTr4h150r7TOQljn8TLgtQRV1A7CSw_LhYLNC3s,255
|
|
8
|
+
mfd_const-0.23.0.dist-info/licenses/LICENSE.md,sha256=WOf_4_WDB4iXqQS77WHhRCKATy-GRxRwYwgTMDGZQdM,1089
|
|
9
|
+
mfd_const-0.23.0.dist-info/METADATA,sha256=YTXBHeg4HMvwV9nikz1tyFRY7XWfgo0oMIcPOIEMLMI,3233
|
|
10
|
+
mfd_const-0.23.0.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
11
|
+
mfd_const-0.23.0.dist-info/top_level.txt,sha256=uY4pppx6GgxiOqtuTkrKK-dMuDOk-_Fz2yBm85sz6qs,10
|
|
12
|
+
mfd_const-0.23.0.dist-info/RECORD,,
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
The MIT License (MIT)
|
|
2
|
+
Copyright © 2025 Intel Corporation
|
|
3
|
+
|
|
4
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
|
5
|
+
|
|
6
|
+
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
|
7
|
+
|
|
8
|
+
THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
mfd_const
|