Blame man/man8/devlink-dev.8

Packit Service 3880ab
.TH DEVLINK\-DEV 8 "14 Mar 2016" "iproute2" "Linux"
Packit Service 3880ab
.SH NAME
Packit Service 3880ab
devlink-dev \- devlink device configuration
Packit Service 3880ab
.SH SYNOPSIS
Packit Service 3880ab
.sp
Packit Service 3880ab
.ad l
Packit Service 3880ab
.in +8
Packit Service 3880ab
.ti -8
Packit Service 3880ab
.B devlink
Packit Service 3880ab
.RI "[ " OPTIONS " ]"
Packit Service 3880ab
.B dev
Packit Service 3880ab
.RI  " { " COMMAND " | "
Packit Service 3880ab
.BR help " }"
Packit Service 3880ab
.sp
Packit Service 3880ab
Packit Service 3880ab
.ti -8
Packit Service 3880ab
.IR OPTIONS " := { "
Packit Service 3880ab
\fB\-V\fR[\fIersion\fR] |
Packit Service 3880ab
\fB\-n\fR[\fIno-nice-names\fR] }
Packit Service 3880ab
Packit Service 3880ab
.ti -8
Packit Service 3880ab
.B devlink dev show
Packit Service 3880ab
.RI "[ " DEV " ]"
Packit Service 3880ab
Packit Service 3880ab
.ti -8
Packit Service 3880ab
.B devlink dev help
Packit Service 3880ab
Packit Service 3880ab
.ti -8
Packit Service 3880ab
.B devlink dev eswitch set
Packit Service 3880ab
.I DEV
Packit Service 3880ab
[
Packit Service 3880ab
.BR mode " { " legacy " | " switchdev " } "
Packit Service 3880ab
] [
Packit Service 3880ab
.BR inline-mode " { " none " | " link " | " network " | " transport " } "
Packit Service 3880ab
] [
Packit Service 3880ab
.BR encap-mode " { " none " | " basic " } "
Packit Service 3880ab
]
Packit Service 3880ab
Packit Service 3880ab
.ti -8
Packit Service 3880ab
.B devlink dev eswitch show
Packit Service 3880ab
.I DEV
Packit Service 3880ab
Packit Service 3880ab
.ti -8
Packit Service 3880ab
.B devlink dev param set
Packit Service 3880ab
.I DEV
Packit Service 3880ab
.B name
Packit Service 3880ab
.I PARAMETER
Packit Service 3880ab
.B value
Packit Service 3880ab
.I VALUE
Packit Service 3880ab
.BR cmode " { " runtime " | " driverinit " | " permanent " } "
Packit Service 3880ab
Packit Service 3880ab
.ti -8
Packit Service 3880ab
.B devlink dev param show
Packit Service 3880ab
[
Packit Service 3880ab
.I DEV
Packit Service 3880ab
.B name
Packit Service 3880ab
.I PARAMETER
Packit Service 3880ab
]
Packit Service 3880ab
Packit Service 3880ab
.ti -8
Packit Service 3880ab
.B devlink dev reload
Packit Service 3880ab
.I DEV
Packit Service 3880ab
[
Packit Service 3880ab
.B netns
Packit Service 3880ab
.RI "{ " PID " | " NAME " | " ID " }"
Packit Service 3880ab
]
Packit Service 3880ab
Packit Service 3880ab
.ti -8
Packit Service 3880ab
.B devlink dev info
Packit Service 3880ab
[
Packit Service 3880ab
.I DEV
Packit Service 3880ab
]
Packit Service 3880ab
Packit Service 3880ab
.ti -8
Packit Service 3880ab
.B devlink dev flash
Packit Service 3880ab
.I DEV
Packit Service 3880ab
.B file
Packit Service 3880ab
.I PATH
Packit Service 3880ab
[
Packit Service 3880ab
.B target
Packit Service 3880ab
.I ID
Packit Service 3880ab
]
Packit Service 3880ab
Packit Service 3880ab
.SH "DESCRIPTION"
Packit Service 3880ab
.SS devlink dev show - display devlink device attributes
Packit Service 3880ab
Packit Service 3880ab
.PP
Packit Service 3880ab
.I "DEV"
Packit Service 3880ab
- specifies the devlink device to show.
Packit Service 3880ab
If this argument is omitted all devices are listed.
Packit Service 3880ab
Packit Service 3880ab
.in +4
Packit Service 3880ab
Format is:
Packit Service 3880ab
.in +2
Packit Service 3880ab
BUS_NAME/BUS_ADDRESS
Packit Service 3880ab
Packit Service 3880ab
.SS devlink dev eswitch show - display devlink device eswitch attributes
Packit Service 3880ab
.SS devlink dev eswitch set  - sets devlink device eswitch attributes
Packit Service 3880ab
Packit Service 3880ab
.TP
Packit Service 3880ab
.BR mode " { " legacy " | " switchdev " } "
Packit Service 3880ab
Set eswitch mode
Packit Service 3880ab
Packit Service 3880ab
.I legacy
Packit Service 3880ab
- Legacy SRIOV
Packit Service 3880ab
Packit Service 3880ab
.I switchdev
Packit Service 3880ab
- SRIOV switchdev offloads
Packit Service 3880ab
Packit Service 3880ab
.TP
Packit Service 3880ab
.BR inline-mode " { " none " | " link " | " network " | " transport " } "
Packit Service 3880ab
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.
Packit Service 3880ab
Packit Service 3880ab
.I none
Packit Service 3880ab
- None
Packit Service 3880ab
Packit Service 3880ab
.I link
Packit Service 3880ab
- L2 mode
Packit Service 3880ab
Packit Service 3880ab
.I network
Packit Service 3880ab
- L3 mode
Packit Service 3880ab
Packit Service 3880ab
.I transport
Packit Service 3880ab
- L4 mode
Packit Service 3880ab
Packit Service 3880ab
.TP
Packit Service 3880ab
.BR encap-mode " { " none " | " basic " } "
Packit Service 3880ab
Set eswitch encapsulation support
Packit Service 3880ab
Packit Service 3880ab
.I none
Packit Service 3880ab
- Disable encapsulation support
Packit Service 3880ab
Packit Service 3880ab
.I basic
Packit Service 3880ab
- Enable encapsulation support
Packit Service 3880ab
Packit Service 3880ab
.SS devlink dev param set  - set new value to devlink device configuration parameter
Packit Service 3880ab
Packit Service 3880ab
.TP
Packit Service 3880ab
.BI name " PARAMETER"
Packit Service 3880ab
Specify parameter name to set.
Packit Service 3880ab
Packit Service 3880ab
.TP
Packit Service 3880ab
.BI value " VALUE"
Packit Service 3880ab
New value to set.
Packit Service 3880ab
Packit Service 3880ab
.TP
Packit Service 3880ab
.BR cmode " { " runtime " | " driverinit " | " permanent " } "
Packit Service 3880ab
Configuration mode in which the new value is set.
Packit Service 3880ab
Packit Service 3880ab
.I runtime
Packit Service 3880ab
- Set new value while driver is running. This configuration mode doesn't require any reset to apply the new value.
Packit Service 3880ab
Packit Service 3880ab
.I driverinit
Packit Service 3880ab
- 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.
Packit Service 3880ab
Packit Service 3880ab
.I permanent
Packit Service 3880ab
- New value is written to device's non-volatile memory. This configuration mode requires hard reset to apply the new value.
Packit Service 3880ab
Packit Service 3880ab
.SS devlink dev param show - display devlink device supported configuration parameters attributes
Packit Service 3880ab
Packit Service 3880ab
.B name
Packit Service 3880ab
.I PARAMETER
Packit Service 3880ab
Specify parameter name to show.
Packit Service 3880ab
If this argument is omitted all parameters supported by devlink devices are listed.
Packit Service 3880ab
Packit Service 3880ab
.SS devlink dev reload - perform hot reload of the driver.
Packit Service 3880ab
Packit Service 3880ab
.PP
Packit Service 3880ab
.I "DEV"
Packit Service 3880ab
- Specifies the devlink device to reload.
Packit Service 3880ab
Packit Service 3880ab
.B netns
Packit Service 3880ab
.RI { " PID " | " NAME " | " ID " }
Packit Service 3880ab
- Specifies the network namespace to reload into, either by pid, name or id.
Packit Service 3880ab
Packit Service 3880ab
.SS devlink dev info - display device information.
Packit Service 3880ab
Display device information provided by the driver. This command can be used
Packit Service 3880ab
to query versions of the hardware components or device components which
Packit Service 3880ab
can't be updated (
Packit Service 3880ab
.I fixed
Packit Service 3880ab
) as well as device firmware which can be updated. For firmware components
Packit Service 3880ab
.I running
Packit Service 3880ab
displays the versions of firmware currently loaded into the device, while
Packit Service 3880ab
.I stored
Packit Service 3880ab
reports the versions in device's flash.
Packit Service 3880ab
.I Running
Packit Service 3880ab
and
Packit Service 3880ab
.I stored
Packit Service 3880ab
versions may differ after flash has been updated, but before reboot.
Packit Service 3880ab
Packit Service 3880ab
.PP
Packit Service 3880ab
.I "DEV"
Packit Service 3880ab
- specifies the devlink device to show.
Packit Service 3880ab
If this argument is omitted all devices are listed.
Packit Service 3880ab
Packit Service 3880ab
.SS devlink dev flash - write device's non-volatile memory.
Packit Service 3880ab
Packit Service 3880ab
.PP
Packit Service 3880ab
.I "DEV"
Packit Service 3880ab
- specifies the devlink device to write to.
Packit Service 3880ab
Packit Service 3880ab
.B file
Packit Service 3880ab
.I PATH
Packit Service 3880ab
- Path to the file which will be written into device's flash. The path needs
Packit Service 3880ab
to be relative to one of the directories searched by the kernel firmware loaded,
Packit Service 3880ab
such as /lib/firmware.
Packit Service 3880ab
Packit Service 3880ab
.B component
Packit Service 3880ab
.I NAME
Packit Service 3880ab
- If device stores multiple firmware images in non-volatile memory, this
Packit Service 3880ab
parameter may be used to indicate which firmware image should be written.
Packit Service 3880ab
The value of
Packit Service 3880ab
.I NAME
Packit Service 3880ab
should match the component names from
Packit Service 3880ab
.B "devlink dev info"
Packit Service 3880ab
and may be driver-dependent.
Packit Service 3880ab
Packit Service 3880ab
.SH "EXAMPLES"
Packit Service 3880ab
.PP
Packit Service 3880ab
devlink dev show
Packit Service 3880ab
.RS 4
Packit Service 3880ab
Shows the state of all devlink devices on the system.
Packit Service 3880ab
.RE
Packit Service 3880ab
.PP
Packit Service 3880ab
devlink dev show pci/0000:01:00.0
Packit Service 3880ab
.RS 4
Packit Service 3880ab
Shows the state of specified devlink device.
Packit Service 3880ab
.RE
Packit Service 3880ab
.PP
Packit Service 3880ab
devlink dev eswitch show pci/0000:01:00.0
Packit Service 3880ab
.RS 4
Packit Service 3880ab
Shows the eswitch mode of specified devlink device.
Packit Service 3880ab
.RE
Packit Service 3880ab
.PP
Packit Service 3880ab
devlink dev eswitch set pci/0000:01:00.0 mode switchdev
Packit Service 3880ab
.RS 4
Packit Service 3880ab
Sets the eswitch mode of specified devlink device to switchdev.
Packit Service 3880ab
.RE
Packit Service 3880ab
.PP
Packit Service 3880ab
devlink dev param show pci/0000:01:00.0 name max_macs
Packit Service 3880ab
.RS 4
Packit Service 3880ab
Shows the parameter max_macs attributes.
Packit Service 3880ab
.RE
Packit Service 3880ab
.PP
Packit Service 3880ab
devlink dev param set pci/0000:01:00.0 name internal_error_reset value true cmode runtime
Packit Service 3880ab
.RS 4
Packit Service 3880ab
Sets the parameter internal_error_reset of specified devlink device to true.
Packit Service 3880ab
.RE
Packit Service 3880ab
.PP
Packit Service 3880ab
devlink dev reload pci/0000:01:00.0
Packit Service 3880ab
.RS 4
Packit Service 3880ab
Performs hot reload of specified devlink device.
Packit Service 3880ab
.RE
Packit Service 3880ab
.PP
Packit Service 3880ab
devlink dev flash pci/0000:01:00.0 file firmware.bin
Packit Service 3880ab
.RS 4
Packit Service 3880ab
Flashes the specified devlink device with provided firmware file name. If the driver supports it, user gets updates about the flash status. For example:
Packit Service 3880ab
.br
Packit Service 3880ab
Preparing to flash
Packit Service 3880ab
.br
Packit Service 3880ab
Flashing 100%
Packit Service 3880ab
.br
Packit Service 3880ab
Flashing done
Packit Service 3880ab
.RE
Packit Service 3880ab
Packit Service 3880ab
.SH SEE ALSO
Packit Service 3880ab
.BR devlink (8),
Packit Service 3880ab
.BR devlink-port (8),
Packit Service 3880ab
.BR devlink-sb (8),
Packit Service 3880ab
.BR devlink-monitor (8),
Packit Service 3880ab
.br
Packit Service 3880ab
Packit Service 3880ab
.SH AUTHOR
Packit Service 3880ab
Jiri Pirko <jiri@mellanox.com>