DPDK patches and discussions
 help / color / mirror / Atom feed
From: Andre Richter <andre.o.richter@gmail.com>
To: dev@dpdk.org
Subject: [dpdk-dev] [PATCH] tools: Fix some strings and functions regarding VFIO support
Date: Wed, 18 Mar 2015 16:05:07 +0100	[thread overview]
Message-ID: <1426691107-7399-1-git-send-email-andre.o.richter@gmail.com> (raw)

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(-)

diff --git a/tools/setup.sh b/tools/setup.sh
index ac438c2..5a8b2f3 100755
--- a/tools/setup.sh
+++ b/tools/setup.sh
@@ -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"
-- 
1.9.1

             reply	other threads:[~2015-03-18 15:05 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-18 15:05 Andre Richter [this message]
2015-03-23 11:09 ` Thomas Monjalon
2015-03-23 11:52   ` Andre Richter

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1426691107-7399-1-git-send-email-andre.o.richter@gmail.com \
    --to=andre.o.richter@gmail.com \
    --cc=dev@dpdk.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).