summaryrefslogtreecommitdiff
path: root/usertools
diff options
context:
space:
mode:
authorTimothy Redaelli <tredaelli@redhat.com>2019-05-31 13:11:26 +0200
committerThomas Monjalon <thomas@monjalon.net>2019-07-04 23:08:58 +0200
commit93b93beb123d96e5acbbb24491c491bec47da60d (patch)
tree8ca19c574a396d9ea80ae80b702cec68610578a7 /usertools
parenta70ed3884104df68d28105c8ebc1fb86ae1a6248 (diff)
downloaddpdk-93b93beb123d96e5acbbb24491c491bec47da60d.zip
dpdk-93b93beb123d96e5acbbb24491c491bec47da60d.tar.gz
dpdk-93b93beb123d96e5acbbb24491c491bec47da60d.tar.xz
usertools: fix refresh binding infos
Currently clear_data (dpdk-devbind.py) doesn't work as expected since "global devices" is missing and so "devices" is considered a local variable. This commit changes "clear_data" function in order to really clear devices by adding "global devices". Fixes: ea9f00f7289a ("usertools: refactor NIC and crypto binding details") Cc: stable@dpdk.org Signed-off-by: Timothy Redaelli <tredaelli@redhat.com> Acked-by: Luca Boccassi <bluca@debian.org> Reviewed-by: David Marchand <david.marchand@redhat.com>
Diffstat (limited to 'usertools')
-rwxr-xr-xusertools/dpdk-devbind.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/usertools/dpdk-devbind.py b/usertools/dpdk-devbind.py
index 5c1cd35..4791e5f 100755
--- a/usertools/dpdk-devbind.py
+++ b/usertools/dpdk-devbind.py
@@ -216,6 +216,7 @@ def get_pci_device_details(dev_id, probe_lspci):
def clear_data():
'''This function clears any old data'''
+ global devices
devices = {}
def get_device_details(devices_type):