Debian Codegraph @

upstream/debian-trixie/man8/devlink-dev.8

raw
1 .TH DEVLINK\-DEV 8 "14 Mar 2016" "iproute2" "Linux"
2 .SH NAME
3 devlink-dev \- devlink device configuration
4 .SH SYNOPSIS
5 .sp
6 .ad l
7 .in +8
8 .ti -8
9 .B devlink
10 .RI "[ " OPTIONS " ]"
11 .B dev
12 .RI " { " COMMAND " | "
13 .BR help " }"
14 .sp
15
16 .ti -8
17 .IR OPTIONS " := { "
18 \fB\-V\fR[\fIersion\fR] |
19 \fB\-n\fR[\fIno-nice-names\fR] }
20
21 .ti -8
22 .B devlink dev show
23 .RI "[ " DEV " ]"
24
25 .ti -8
26 .B devlink dev help
27
28 .ti -8
29 .B devlink dev eswitch set
30 .I DEV
31 [
32 .BR mode " { " legacy " | " switchdev " } "
33 ] [
34 .BR inline-mode " { " none " | " link " | " network " | " transport " } "
35 ] [
36 .BR encap-mode " { " none " | " basic " } "
37 ]
38
39 .ti -8
40 .B devlink dev eswitch show
41 .I DEV
42
43 .ti -8
44 .B devlink dev param set
45 .I DEV
46 .B name
47 .I PARAMETER
48 .B value
49 .I VALUE
50 .BR cmode " { " runtime " | " driverinit " | " permanent " } "
51
52 .ti -8
53 .B devlink dev param show
54 [
55 .I DEV
56 .B name
57 .I PARAMETER
58 ]
59
60 .ti -8
61 .B devlink dev reload
62 .I DEV
63 [
64 .B netns
65 .RI "{ " PID " | " NAME " | " ID " }"
66 ] [
67 .BR action " { " driver_reinit " | " fw_activate " }"
68 ] [
69 .B limit no_reset
70 ]
71
72 .ti -8
73 .B devlink dev info
74 [
75 .I DEV
76 ]
77
78 .ti -8
79 .B devlink dev flash
80 .I DEV
81 .B file
82 .I PATH
83 [
84 .B target
85 .I ID
86 ]
87
88 .ti -8
89 .B devlink dev selftests show
90 [
91 .I DEV
92 ]
93
94 .ti -8
95 .B devlink dev selftests run
96 .I DEV
97 [
98 .B id
99 .I ID...
100 ]
101
102 .SH "DESCRIPTION"
103 .SS devlink dev show - display devlink device attributes
104
105 .PP
106 .I "DEV"
107 - specifies the devlink device to show.
108 If this argument is omitted all devices are listed.
109
110 .in +4
111 Format is:
112 .in +2
113 BUS_NAME/BUS_ADDRESS
114
115 .SS devlink dev eswitch show - display devlink device eswitch attributes
116 .SS devlink dev eswitch set - sets devlink device eswitch attributes
117
118 .TP
119 .BR mode " { " legacy " | " switchdev " } "
120 Set eswitch mode
121
122 .I legacy
123 - Legacy SRIOV
124
125 .I switchdev
126 - SRIOV switchdev offloads
127
128 .TP
129 .BR inline-mode " { " none " | " link " | " network " | " transport " } "
130 Some HWs need the VF driver to put part of the packet headers on the TX descriptor so the e-switch can do proper matching and steering.
131
132 .I none
133 - None
134
135 .I link
136 - L2 mode
137
138 .I network
139 - L3 mode
140
141 .I transport
142 - L4 mode
143
144 .TP
145 .BR encap-mode " { " none " | " basic " } "
146 Set eswitch encapsulation support
147
148 .I none
149 - Disable encapsulation support
150
151 .I basic
152 - Enable encapsulation support
153
154 .SS devlink dev param set - set new value to devlink device configuration parameter
155
156 .TP
157 .BI name " PARAMETER"
158 Specify parameter name to set.
159
160 .TP
161 .BI value " VALUE"
162 New value to set.
163
164 .TP
165 .BR cmode " { " runtime " | " driverinit " | " permanent " } "
166 Configuration mode in which the new value is set.
167
168 .I runtime
169 - Set new value while driver is running. This configuration mode doesn't require any reset to apply the new value.
170
171 .I driverinit
172 - Set new value which will be applied during driver initialization. This configuration mode requires restart driver by devlink reload command to apply the new value.
173
174 .I permanent
175 - New value is written to device's non-volatile memory. This configuration mode requires hard reset to apply the new value.
176
177 .SS devlink dev param show - display devlink device supported configuration parameters attributes
178
179 .B name
180 .I PARAMETER
181 Specify parameter name to show.
182 If this argument is omitted all parameters supported by devlink devices are listed.
183
184 .SS devlink dev reload - perform hot reload of the driver.
185
186 .PP
187 .I "DEV"
188 - Specifies the devlink device to reload.
189
190 .B netns
191 .RI { " PID " | " NAME " | " ID " }
192 - Specifies the network namespace to reload into, either by pid, name or id.
193
194 .BR action " { " driver_reinit " | " fw_activate " }"
195 - Specifies the reload action required.
196 If this argument is omitted
197 .I driver_reinit
198 action will be used.
199 Note that even though user asks for a specific action, the driver implementation
200 might require to perform another action alongside with it. For example, some
201 driver do not support driver reinitialization being performed without fw
202 activation. Therefore, the devlink reload command returns the list of actions
203 which were actrually performed.
204
205 .I driver_reinit
206 - Driver entities re-initialization, applying devlink-param and
207 devlink-resource values.
208
209 .I fw_activate
210 - Activates new firmware if such image is stored and pending activation. If no
211 limitation specified this action may involve firmware reset. If no new image
212 pending this action will reload current firmware image.
213
214 .B limit no_reset
215 - Specifies limitation on reload action.
216 If this argument is omitted limit is unspecified and the reload action is not
217 limited. In such case driver implementation may include reset or downtime as
218 needed to perform the actions.
219
220 .I no_reset
221 - No reset allowed, no down time allowed, no link flap and no configuration is
222 lost.
223
224 .SS devlink dev info - display device information.
225 Display device information provided by the driver. This command can be used
226 to query versions of the hardware components or device components which
227 can't be updated (
228 .I fixed
229 ) as well as device firmware which can be updated. For firmware components
230 .I running
231 displays the versions of firmware currently loaded into the device, while
232 .I stored
233 reports the versions in device's flash.
234 .I Running
235 and
236 .I stored
237 versions may differ after flash has been updated, but before reboot.
238
239 .PP
240 .I "DEV"
241 - specifies the devlink device to show.
242 If this argument is omitted all devices are listed.
243
244 .SS devlink dev flash - write device's non-volatile memory.
245
246 .PP
247 .I "DEV"
248 - specifies the devlink device to write to.
249
250 .B file
251 .I PATH
252 - Path to the file which will be written into device's flash. The path needs
253 to be relative to one of the directories searched by the kernel firmware loader,
254 such as /lib/firmware.
255
256 .B component
257 .I NAME
258 - If device stores multiple firmware images in non-volatile memory, this
259 parameter may be used to indicate which firmware image should be written.
260 The value of
261 .I NAME
262 should match the component names from
263 .B "devlink dev info"
264 and may be driver-dependent.
265
266 .SS devlink dev selftests show - shows supported selftests on devlink device.
267
268 .PP
269 .I "DEV"
270 - specifies the devlink device.
271 If this argument is omitted all selftests for devlink devices are listed.
272
273 .SS devlink dev selftests run - runs selftests on devlink device.
274
275 .PP
276 .I "DEV"
277 - specifies the devlink device to execute selftests.
278
279 .B id
280 .I ID...
281 - The value of
282 .I ID(s)
283 should match the selftests shown in
284 .B "devlink dev selftests show"
285 to execute selftests on the devlink device.
286 If this argument is omitted all selftests supported by devlink devices are executed.
287
288 .SH "EXAMPLES"
289 .PP
290 devlink dev show
291 .RS 4
292 Shows the state of all devlink devices on the system.
293 .RE
294 .PP
295 devlink dev show pci/0000:01:00.0
296 .RS 4
297 Shows the state of specified devlink device.
298 .RE
299 .PP
300 devlink dev eswitch show pci/0000:01:00.0
301 .RS 4
302 Shows the eswitch mode of specified devlink device.
303 .RE
304 .PP
305 devlink dev eswitch set pci/0000:01:00.0 mode switchdev
306 .RS 4
307 Sets the eswitch mode of specified devlink device to switchdev.
308 .RE
309 .PP
310 devlink dev param show pci/0000:01:00.0 name max_macs
311 .RS 4
312 Shows the parameter max_macs attributes.
313 .RE
314 .PP
315 devlink dev param set pci/0000:01:00.0 name internal_error_reset value true cmode runtime
316 .RS 4
317 Sets the parameter internal_error_reset of specified devlink device to true.
318 .RE
319 .PP
320 devlink dev reload pci/0000:01:00.0
321 .RS 4
322 Performs hot reload of specified devlink device.
323 .RE
324 .PP
325 devlink dev flash pci/0000:01:00.0 file firmware.bin
326 .RS 4
327 Flashes the specified devlink device with provided firmware file name. If the driver supports it, user gets updates about the flash status. For example:
328 .br
329 Preparing to flash
330 .br
331 Flashing 100%
332 .br
333 Flashing done
334 .RE
335 .PP
336 devlink dev selftests show pci/0000:01:00.0
337 .RS 4
338 Shows the supported selftests by the devlink device.
339 .RE
340 .PP
341 devlink dev selftests run pci/0000:01:00.0 id flash
342 .RS 4
343 Perform a flash test on the devlink device.
344 .RE
345
346 .SH SEE ALSO
347 .BR devlink (8),
348 .BR devlink-port (8),
349 .BR devlink-sb (8),
350 .BR devlink-monitor (8),
351 .br
352
353 .SH AUTHOR
354 Jiri Pirko <[email protected]>