tools: Fix some strings and functions regarding VFIO support
PATCH 1/1 tools: Fix some strings and functions regarding VFIO support
This patch fixes several minor issues in setup.sh:
- show_nics() would not display the current Ethernet settings if the user only loads the vfio-pci module, b/c it only checks for presence of igb_uio. Fix this by adding a check for vfio-pci.
- unbind_nics(): Fix option naming and string inside function.
- Exchange a forgotten "igb_uio" with "vfio-pci" in a comment.
--- tools/setup.sh | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-)
tools/setup.sh +6 -6
@@ -427,16 +427,16 @@ grep_meminfo() # show_nics() { - if /sbin/lsmod | grep -q igb_uio ; then + if /sbin/lsmod | grep -q -e igb_uio -e vfio_pci; then ${RTE_SDK}/tools/dpdk_nic_bind.py --status else - echo "# Please load the 'igb_uio' kernel module before querying or " - echo "# adjusting NIC device bindings" + echo "# Please load the 'igb_uio' or 'vfio-pci' kernel module before " + echo "# querying or adjusting NIC device bindings" fi } # -# Uses dpdk_nic_bind.py to move devices to work with igb_uio +# Uses dpdk_nic_bind.py to move devices to work with vfio-pci # bind_nics_to_vfio() {
@@ -477,7 +477,7 @@ unbind_nics() { ${RTE_SDK}/tools/dpdk_nic_bind.py --status echo "" - echo -n "Enter PCI address of device to bind to IGB UIO driver: " + echo -n "Enter PCI address of device to unbind: " read PCI_PATH echo "" echo -n "Enter name of kernel driver to bind the device to: "
@@ -574,7 +574,7 @@ step5_func() TEXT[1]="Uninstall all targets" FUNC[1]="uninstall_targets" - TEXT[2]="Unbind NICs from IGB UIO driver" + TEXT[2]="Unbind NICs from IGB UIO or VFIO driver" FUNC[2]="unbind_nics" TEXT[3]="Remove IGB UIO module"
Signature · 1 line
1.9.1
A message that is not in the archive (sent off-list or not yet received): 1427112386-2657-1-git-send-email-andre.o.richter-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org
Thomas Monjalon
AppliedQuoted 11 lines
This patch fixes several minor issues in
setup.sh:-
show_nics()would not display the current Ethernet settings if the user only loads the vfio-pci module, b/c it only checks for presence ofigb_uio. Fix this by adding a check for vfio-pci.-
unbind_nics(): Fix option naming and string inside function.- Exchange a forgotten "
igb_uio" with "vfio-pci" in a comment.Signed-off-by Andre Richter <[email protected]>
Applied, thanks