]>
Commit | Line | Data |
---|---|---|
a3c4b484 JP |
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] | | |
43f35be4 | 19 | \fB\-n\fR[\fIno-nice-names\fR] } |
a3c4b484 JP |
20 | |
21 | .ti -8 | |
22 | .B devlink dev show | |
23 | .RI "[ " DEV " ]" | |
24 | ||
25 | .ti -8 | |
26 | .B devlink dev help | |
27 | ||
f57856fa OG |
28 | .ti -8 |
29 | .BR "devlink dev eswitch set" | |
30 | .IR DEV | |
31 | .RI "[ " | |
32 | .BR mode " { " legacy " | " switchdev " } " | |
33 | .RI "]" | |
6566ca8c RD |
34 | .RI "[ " |
35 | .BR inline-mode " { " none " | " link " | " network " | " transport " } " | |
36 | .RI "]" | |
d315b706 RD |
37 | .RI "[ " |
38 | .BR encap " { " disable " | " enable " } " | |
39 | .RI "]" | |
f57856fa OG |
40 | |
41 | .ti -8 | |
42 | .BR "devlink dev eswitch show" | |
43 | .IR DEV | |
44 | ||
13925ae9 MS |
45 | .ti -8 |
46 | .BR "devlink dev param set" | |
47 | .IR DEV | |
48 | .BR name | |
49 | .IR PARAMETER | |
50 | .BR value | |
51 | .IR VALUE | |
52 | .BR cmode " { " runtime " | " driverinit " | " permanent " } " | |
53 | ||
54 | .ti -8 | |
55 | .BR "devlink dev param show" | |
56 | .RI "[ " | |
57 | .IR DEV | |
58 | .BR name | |
59 | .IR PARAMETER | |
60 | .RI "]" | |
61 | ||
58b48c5d AS |
62 | .ti -8 |
63 | .BR "devlink dev reload" | |
64 | .IR DEV | |
08e8e1ca JP |
65 | .RI "[ " |
66 | .BI "netns { " PID " | " NAME " | " ID " } | |
67 | .RI "]" | |
58b48c5d | 68 | |
05bc89e9 JK |
69 | .ti -8 |
70 | .BR "devlink dev info" | |
71 | .RI "[ " | |
72 | .IR DEV | |
73 | .RI "]" | |
74 | ||
d326d79c JK |
75 | .ti -8 |
76 | .BR "devlink dev flash" | |
77 | .IR DEV | |
78 | .BR file | |
79 | .IR PATH | |
80 | .RI "[" | |
81 | .BR target | |
82 | .IR ID | |
83 | .RI "]" | |
84 | ||
a3c4b484 JP |
85 | .SH "DESCRIPTION" |
86 | .SS devlink dev show - display devlink device attributes | |
87 | ||
88 | .PP | |
89 | .I "DEV" | |
90 | - specifies the devlink device to show. | |
91 | If this argument is omitted all devices are listed. | |
92 | ||
93 | .in +4 | |
94 | Format is: | |
95 | .in +2 | |
96 | BUS_NAME/BUS_ADDRESS | |
97 | ||
f57856fa OG |
98 | .SS devlink dev eswitch show - display devlink device eswitch attributes |
99 | .SS devlink dev eswitch set - sets devlink device eswitch attributes | |
100 | ||
101 | .TP | |
102 | .BR mode " { " legacy " | " switchdev " } " | |
a93b6bb3 | 103 | Set eswitch mode |
f57856fa OG |
104 | |
105 | .I legacy | |
106 | - Legacy SRIOV | |
107 | ||
108 | .I switchdev | |
109 | - SRIOV switchdev offloads | |
110 | ||
6566ca8c RD |
111 | .TP |
112 | .BR inline-mode " { " none " | " link " | " network " | " transport " } " | |
113 | 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. | |
114 | ||
115 | .I none | |
116 | - None | |
117 | ||
118 | .I link | |
119 | - L2 mode | |
120 | ||
121 | .I network | |
122 | - L3 mode | |
123 | ||
124 | .I transport | |
125 | - L4 mode | |
126 | ||
d315b706 RD |
127 | .TP |
128 | .BR encap " { " disable " | " enable " } " | |
129 | Set eswitch encapsulation support | |
130 | ||
131 | .I disable | |
132 | - Disable encapsulation support | |
133 | ||
134 | .I enable | |
135 | - Enable encapsulation support | |
136 | ||
13925ae9 MS |
137 | .SS devlink dev param set - set new value to devlink device configuration parameter |
138 | ||
139 | .TP | |
140 | .BI name " PARAMETER" | |
141 | Specify parameter name to set. | |
142 | ||
143 | .TP | |
144 | .BI value " VALUE" | |
145 | New value to set. | |
146 | ||
147 | .TP | |
148 | .BR cmode " { " runtime " | " driverinit " | " permanent " } " | |
149 | Configuration mode in which the new value is set. | |
150 | ||
151 | .I runtime | |
152 | - Set new value while driver is running. This configuration mode doesn't require any reset to apply the new value. | |
153 | ||
154 | .I driverinit | |
155 | - 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. | |
156 | ||
157 | .I permanent | |
158 | - New value is written to device's non-volatile memory. This configuration mode requires hard reset to apply the new value. | |
159 | ||
160 | .SS devlink dev param show - display devlink device supported configuration parameters attributes | |
161 | ||
162 | .BR name | |
163 | .IR PARAMETER | |
164 | Specify parameter name to show. | |
165 | If this argument is omitted all parameters supported by devlink devices are listed. | |
166 | ||
58b48c5d AS |
167 | .SS devlink dev reload - perform hot reload of the driver. |
168 | ||
169 | .PP | |
170 | .I "DEV" | |
171 | - Specifies the devlink device to reload. | |
172 | ||
08e8e1ca JP |
173 | .BR netns |
174 | .BI { " PID " | " NAME " | " ID " } | |
175 | - Specifies the network namespace to reload into, either by pid, name or id. | |
176 | ||
05bc89e9 JK |
177 | .SS devlink dev info - display device information. |
178 | Display device information provided by the driver. This command can be used | |
179 | to query versions of the hardware components or device components which | |
180 | can't be updated ( | |
181 | .I fixed | |
182 | ) as well as device firmware which can be updated. For firmware components | |
183 | .I running | |
184 | displays the versions of firmware currently loaded into the device, while | |
185 | .I stored | |
186 | reports the versions in device's flash. | |
187 | .I Running | |
188 | and | |
189 | .I stored | |
190 | versions may differ after flash has been updated, but before reboot. | |
191 | ||
192 | .PP | |
193 | .I "DEV" | |
194 | - specifies the devlink device to show. | |
195 | If this argument is omitted all devices are listed. | |
196 | ||
d326d79c JK |
197 | .SS devlink dev flash - write device's non-volatile memory. |
198 | ||
199 | .PP | |
200 | .I "DEV" | |
201 | - specifies the devlink device to write to. | |
202 | ||
203 | .BR file | |
204 | .I PATH | |
205 | - Path to the file which will be written into device's flash. The path needs | |
206 | to be relative to one of the directories searched by the kernel firmware loaded, | |
207 | such as /lib/firmware. | |
208 | ||
209 | .BR component | |
210 | .I NAME | |
211 | - If device stores multiple firmware images in non-volatile memory, this | |
212 | parameter may be used to indicate which firmware image should be written. | |
213 | The value of | |
214 | .I NAME | |
215 | should match the component names from | |
216 | .B "devlink dev info" | |
217 | and may be driver-dependent. | |
218 | ||
a3c4b484 JP |
219 | .SH "EXAMPLES" |
220 | .PP | |
221 | devlink dev show | |
222 | .RS 4 | |
223 | Shows the state of all devlink devices on the system. | |
224 | .RE | |
225 | .PP | |
226 | devlink dev show pci/0000:01:00.0 | |
227 | .RS 4 | |
228 | Shows the state of specified devlink device. | |
f57856fa OG |
229 | .RE |
230 | .PP | |
231 | devlink dev eswitch show pci/0000:01:00.0 | |
232 | .RS 4 | |
233 | Shows the eswitch mode of specified devlink device. | |
234 | .RE | |
235 | .PP | |
236 | devlink dev eswitch set pci/0000:01:00.0 mode switchdev | |
237 | .RS 4 | |
238 | Sets the eswitch mode of specified devlink device to switchdev. | |
58b48c5d AS |
239 | .RE |
240 | .PP | |
13925ae9 MS |
241 | devlink dev param show pci/0000:01:00.0 name max_macs |
242 | .RS 4 | |
243 | Shows the parameter max_macs attributes. | |
244 | .RE | |
245 | .PP | |
246 | devlink dev param set pci/0000:01:00.0 name internal_error_reset value true cmode runtime | |
247 | .RS 4 | |
248 | Sets the parameter internal_error_reset of specified devlink device to true. | |
249 | .RE | |
250 | .PP | |
58b48c5d AS |
251 | devlink dev reload pci/0000:01:00.0 |
252 | .RS 4 | |
253 | Performs hot reload of specified devlink device. | |
9b13cddf JP |
254 | .RE |
255 | .PP | |
256 | devlink dev flash pci/0000:01:00.0 file firmware.bin | |
257 | .RS 4 | |
258 | Flashes the specified devlink device with provided firmware file name. If the driver supports it, user gets updates about the flash status. For example: | |
259 | .br | |
260 | Preparing to flash | |
261 | .br | |
262 | Flashing 100% | |
263 | .br | |
264 | Flashing done | |
9ab56784 | 265 | .RE |
a3c4b484 JP |
266 | |
267 | .SH SEE ALSO | |
268 | .BR devlink (8), | |
269 | .BR devlink-port (8), | |
4bf138d6 | 270 | .BR devlink-sb (8), |
a3c4b484 JP |
271 | .BR devlink-monitor (8), |
272 | .br | |
273 | ||
274 | .SH AUTHOR | |
275 | Jiri Pirko <jiri@mellanox.com> |