471 lines
8.7 KiB
HTML
471 lines
8.7 KiB
HTML
|
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
|
<HTML><HEAD><TITLE>Man page of DEVLINK-DEV</TITLE>
|
|
</HEAD><BODY>
|
|
<H1>DEVLINK-DEV</H1>
|
|
Section: Linux (8)<BR>Updated: 14 Mar 2016<BR><A HREF="#index">Index</A>
|
|
<A HREF="/cgi-bin/man/man2html">Return to Main Contents</A><HR>
|
|
|
|
<A NAME="lbAB"> </A>
|
|
<H2>NAME</H2>
|
|
|
|
devlink-dev - devlink device configuration
|
|
<A NAME="lbAC"> </A>
|
|
<H2>SYNOPSIS</H2>
|
|
|
|
<P>
|
|
|
|
|
|
<BR>
|
|
|
|
<B>devlink</B>
|
|
|
|
[ <I>OPTIONS</I> ]
|
|
|
|
<B>dev</B>
|
|
|
|
{ <I>COMMAND</I> |
|
|
|
|
<B>help</B> }
|
|
|
|
<P>
|
|
<P>
|
|
<BR>
|
|
|
|
<I>OPTIONS</I> := {
|
|
|
|
<B>-V</B>[<I>ersion</I>] |
|
|
<B>-n</B>[<I>no-nice-names</I>] }
|
|
<P>
|
|
<BR>
|
|
|
|
<B>devlink dev show</B>
|
|
|
|
[ <I>DEV</I> ]
|
|
|
|
<P>
|
|
<BR>
|
|
|
|
<B>devlink dev help</B>
|
|
|
|
<P>
|
|
<BR>
|
|
|
|
<B>devlink dev eswitch set</B>
|
|
|
|
<I>DEV</I>
|
|
|
|
[
|
|
|
|
<B>mode</B> { <B>legacy</B> | <B>switchdev</B> }
|
|
|
|
]
|
|
|
|
[
|
|
|
|
<B>inline-mode</B> { <B>none</B> | <B>link</B> | <B>network</B> | <B>transport</B> }
|
|
|
|
]
|
|
|
|
[
|
|
|
|
<B>encap</B> { <B>disable</B> | <B>enable</B> }
|
|
|
|
]
|
|
|
|
<P>
|
|
<BR>
|
|
|
|
<B>devlink dev eswitch show</B>
|
|
|
|
<I>DEV</I>
|
|
|
|
<P>
|
|
<BR>
|
|
|
|
<B>devlink dev param set</B>
|
|
|
|
<I>DEV</I>
|
|
|
|
<B>name</B>
|
|
|
|
<I>PARAMETER</I>
|
|
|
|
<B>value</B>
|
|
|
|
<I>VALUE</I>
|
|
|
|
<B>cmode</B> { <B>runtime</B> | <B>driverinit</B> | <B>permanent</B> }
|
|
|
|
<P>
|
|
<BR>
|
|
|
|
<B>devlink dev param show</B>
|
|
|
|
[
|
|
|
|
<I>DEV</I>
|
|
|
|
<B>name</B>
|
|
|
|
<I>PARAMETER</I>
|
|
|
|
]
|
|
|
|
<P>
|
|
<BR>
|
|
|
|
<B>devlink dev reload</B>
|
|
|
|
<I>DEV</I>
|
|
|
|
[
|
|
|
|
<B>netns { </B><I>PID</I><B> | </B><I>NAME</I><B> | </B><I>ID</I><B> }</B>
|
|
|
|
]
|
|
|
|
<P>
|
|
<BR>
|
|
|
|
<B>devlink dev info</B>
|
|
|
|
[
|
|
|
|
<I>DEV</I>
|
|
|
|
]
|
|
|
|
<P>
|
|
<BR>
|
|
|
|
<B>devlink dev flash</B>
|
|
|
|
<I>DEV</I>
|
|
|
|
<B>file</B>
|
|
|
|
<I>PATH</I>
|
|
|
|
[
|
|
|
|
<B>target</B>
|
|
|
|
<I>ID</I>
|
|
|
|
]
|
|
|
|
<P>
|
|
<A NAME="lbAD"> </A>
|
|
<H2>DESCRIPTION</H2>
|
|
|
|
<A NAME="lbAE"> </A>
|
|
<H3>devlink dev show - display devlink device attributes</H3>
|
|
|
|
<P>
|
|
<P>
|
|
|
|
<I>DEV</I>
|
|
|
|
- specifies the devlink device to show.
|
|
If this argument is omitted all devices are listed.
|
|
<P>
|
|
|
|
Format is:
|
|
|
|
BUS_NAME/BUS_ADDRESS
|
|
<P>
|
|
<A NAME="lbAF"> </A>
|
|
<H3>devlink dev eswitch show - display devlink device eswitch attributes</H3>
|
|
|
|
<A NAME="lbAG"> </A>
|
|
<H3>devlink dev eswitch set - sets devlink device eswitch attributes</H3>
|
|
|
|
<P>
|
|
<DL COMPACT>
|
|
<DT id="1"><B>mode</B> { <B>legacy</B> | <B>switchdev</B> }
|
|
|
|
<DD>
|
|
Set eswitch mode
|
|
<P>
|
|
<I>legacy</I>
|
|
|
|
- Legacy SRIOV
|
|
<P>
|
|
<I>switchdev</I>
|
|
|
|
- SRIOV switchdev offloads
|
|
<P>
|
|
<DT id="2"><B>inline-mode</B> { <B>none</B> | <B>link</B> | <B>network</B> | <B>transport</B> }
|
|
|
|
<DD>
|
|
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.
|
|
<P>
|
|
<I>none</I>
|
|
|
|
- None
|
|
<P>
|
|
<I>link</I>
|
|
|
|
- L2 mode
|
|
<P>
|
|
<I>network</I>
|
|
|
|
- L3 mode
|
|
<P>
|
|
<I>transport</I>
|
|
|
|
- L4 mode
|
|
<P>
|
|
<DT id="3"><B>encap</B> { <B>disable</B> | <B>enable</B> }
|
|
|
|
<DD>
|
|
Set eswitch encapsulation support
|
|
<P>
|
|
<I>disable</I>
|
|
|
|
- Disable encapsulation support
|
|
<P>
|
|
<I>enable</I>
|
|
|
|
- Enable encapsulation support
|
|
<P>
|
|
</DL>
|
|
<A NAME="lbAH"> </A>
|
|
<H3>devlink dev param set - set new value to devlink device configuration parameter</H3>
|
|
|
|
<P>
|
|
<DL COMPACT>
|
|
<DT id="4"><B>name</B><I> PARAMETER</I>
|
|
|
|
<DD>
|
|
Specify parameter name to set.
|
|
<P>
|
|
<DT id="5"><B>value</B><I> VALUE</I>
|
|
|
|
<DD>
|
|
New value to set.
|
|
<P>
|
|
<DT id="6"><B>cmode</B> { <B>runtime</B> | <B>driverinit</B> | <B>permanent</B> }
|
|
|
|
<DD>
|
|
Configuration mode in which the new value is set.
|
|
<P>
|
|
<I>runtime</I>
|
|
|
|
- Set new value while driver is running. This configuration mode doesn't require any reset to apply the new value.
|
|
<P>
|
|
<I>driverinit</I>
|
|
|
|
- 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.
|
|
<P>
|
|
<I>permanent</I>
|
|
|
|
- New value is written to device's non-volatile memory. This configuration mode requires hard reset to apply the new value.
|
|
<P>
|
|
</DL>
|
|
<A NAME="lbAI"> </A>
|
|
<H3>devlink dev param show - display devlink device supported configuration parameters attributes</H3>
|
|
|
|
<P>
|
|
<B>name</B>
|
|
|
|
<I>PARAMETER</I>
|
|
|
|
Specify parameter name to show.
|
|
If this argument is omitted all parameters supported by devlink devices are listed.
|
|
<P>
|
|
<A NAME="lbAJ"> </A>
|
|
<H3>devlink dev reload - perform hot reload of the driver.</H3>
|
|
|
|
<P>
|
|
<P>
|
|
|
|
<I>DEV</I>
|
|
|
|
- Specifies the devlink device to reload.
|
|
<P>
|
|
<B>netns</B>
|
|
|
|
<B>{</B><I> PID </I><B>|</B><I> NAME </I><B>|</B><I> ID </I><B>}</B>
|
|
|
|
- Specifies the network namespace to reload into, either by pid, name or id.
|
|
<P>
|
|
<A NAME="lbAK"> </A>
|
|
<H3>devlink dev info - display device information.</H3>
|
|
|
|
Display device information provided by the driver. This command can be used
|
|
to query versions of the hardware components or device components which
|
|
can't be updated (
|
|
<I>fixed</I>
|
|
|
|
) as well as device firmware which can be updated. For firmware components
|
|
<I>running</I>
|
|
|
|
displays the versions of firmware currently loaded into the device, while
|
|
<I>stored</I>
|
|
|
|
reports the versions in device's flash.
|
|
<I>Running</I>
|
|
|
|
and
|
|
<I>stored</I>
|
|
|
|
versions may differ after flash has been updated, but before reboot.
|
|
<P>
|
|
<P>
|
|
|
|
<I>DEV</I>
|
|
|
|
- specifies the devlink device to show.
|
|
If this argument is omitted all devices are listed.
|
|
<P>
|
|
<A NAME="lbAL"> </A>
|
|
<H3>devlink dev flash - write device's non-volatile memory.</H3>
|
|
|
|
<P>
|
|
<P>
|
|
|
|
<I>DEV</I>
|
|
|
|
- specifies the devlink device to write to.
|
|
<P>
|
|
<B>file</B>
|
|
|
|
<I>PATH</I>
|
|
|
|
- Path to the file which will be written into device's flash. The path needs
|
|
to be relative to one of the directories searched by the kernel firmware loaded,
|
|
such as /lib/firmware.
|
|
<P>
|
|
<B>component</B>
|
|
|
|
<I>NAME</I>
|
|
|
|
- If device stores multiple firmware images in non-volatile memory, this
|
|
parameter may be used to indicate which firmware image should be written.
|
|
The value of
|
|
<I>NAME</I>
|
|
|
|
should match the component names from
|
|
<B>devlink dev info</B>
|
|
|
|
and may be driver-dependent.
|
|
<P>
|
|
<A NAME="lbAM"> </A>
|
|
<H2>EXAMPLES</H2>
|
|
|
|
<P>
|
|
|
|
devlink dev show
|
|
<DL COMPACT><DT id="7"><DD>
|
|
Shows the state of all devlink devices on the system.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
devlink dev show pci/0000:01:00.0
|
|
<DL COMPACT><DT id="8"><DD>
|
|
Shows the state of specified devlink device.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
devlink dev eswitch show pci/0000:01:00.0
|
|
<DL COMPACT><DT id="9"><DD>
|
|
Shows the eswitch mode of specified devlink device.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
devlink dev eswitch set pci/0000:01:00.0 mode switchdev
|
|
<DL COMPACT><DT id="10"><DD>
|
|
Sets the eswitch mode of specified devlink device to switchdev.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
devlink dev param show pci/0000:01:00.0 name max_macs
|
|
<DL COMPACT><DT id="11"><DD>
|
|
Shows the parameter max_macs attributes.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
devlink dev param set pci/0000:01:00.0 name internal_error_reset value true cmode runtime
|
|
<DL COMPACT><DT id="12"><DD>
|
|
Sets the parameter internal_error_reset of specified devlink device to true.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
devlink dev reload pci/0000:01:00.0
|
|
<DL COMPACT><DT id="13"><DD>
|
|
Performs hot reload of specified devlink device.
|
|
</DL>
|
|
|
|
<P>
|
|
|
|
devlink dev flash pci/0000:01:00.0 file firmware.bin
|
|
<DL COMPACT><DT id="14"><DD>
|
|
Flashes the specified devlink device with provided firmware file name. If the driver supports it, user gets updates about the flash status. For example:
|
|
<BR>
|
|
|
|
Preparing to flash
|
|
<BR>
|
|
|
|
Flashing 100%
|
|
<BR>
|
|
|
|
Flashing done
|
|
</DL>
|
|
|
|
<P>
|
|
<A NAME="lbAN"> </A>
|
|
<H2>SEE ALSO</H2>
|
|
|
|
<B><A HREF="/cgi-bin/man/man2html?8+devlink">devlink</A></B>(8),
|
|
|
|
<B><A HREF="/cgi-bin/man/man2html?8+devlink-port">devlink-port</A></B>(8),
|
|
|
|
<B><A HREF="/cgi-bin/man/man2html?8+devlink-sb">devlink-sb</A></B>(8),
|
|
|
|
<B><A HREF="/cgi-bin/man/man2html?8+devlink-monitor">devlink-monitor</A></B>(8),
|
|
|
|
<BR>
|
|
|
|
<P>
|
|
<A NAME="lbAO"> </A>
|
|
<H2>AUTHOR</H2>
|
|
|
|
Jiri Pirko <<A HREF="mailto:jiri@mellanox.com">jiri@mellanox.com</A>>
|
|
<P>
|
|
|
|
<HR>
|
|
<A NAME="index"> </A><H2>Index</H2>
|
|
<DL>
|
|
<DT id="15"><A HREF="#lbAB">NAME</A><DD>
|
|
<DT id="16"><A HREF="#lbAC">SYNOPSIS</A><DD>
|
|
<DT id="17"><A HREF="#lbAD">DESCRIPTION</A><DD>
|
|
<DL>
|
|
<DT id="18"><A HREF="#lbAE">devlink dev show - display devlink device attributes</A><DD>
|
|
<DT id="19"><A HREF="#lbAF">devlink dev eswitch show - display devlink device eswitch attributes</A><DD>
|
|
<DT id="20"><A HREF="#lbAG">devlink dev eswitch set - sets devlink device eswitch attributes</A><DD>
|
|
<DT id="21"><A HREF="#lbAH">devlink dev param set - set new value to devlink device configuration parameter</A><DD>
|
|
<DT id="22"><A HREF="#lbAI">devlink dev param show - display devlink device supported configuration parameters attributes</A><DD>
|
|
<DT id="23"><A HREF="#lbAJ">devlink dev reload - perform hot reload of the driver.</A><DD>
|
|
<DT id="24"><A HREF="#lbAK">devlink dev info - display device information.</A><DD>
|
|
<DT id="25"><A HREF="#lbAL">devlink dev flash - write device's non-volatile memory.</A><DD>
|
|
</DL>
|
|
<DT id="26"><A HREF="#lbAM">EXAMPLES</A><DD>
|
|
<DT id="27"><A HREF="#lbAN">SEE ALSO</A><DD>
|
|
<DT id="28"><A HREF="#lbAO">AUTHOR</A><DD>
|
|
</DL>
|
|
<HR>
|
|
This document was created by
|
|
<A HREF="/cgi-bin/man/man2html">man2html</A>,
|
|
using the manual pages.<BR>
|
|
Time: 00:06:11 GMT, March 31, 2021
|
|
</BODY>
|
|
</HTML>
|