From: Omri Mor Date: Fri, 6 Oct 2017 21:38:38 +0000 (-0500) Subject: usertools: fix device binding with python 3 X-Git-Tag: spdx-start~899 X-Git-Url: http://git.droids-corp.org/?p=dpdk.git;a=commitdiff_plain;h=8fab26f8ee80ed7dff84cd90d343e5265a6128d1 usertools: fix device binding with python 3 When using Python 3, dpdk-devbind.py fails to detect modules other than igb_uio. Fixes: bb9f408550d1 ("tools: support binding to built-in kernel modules") Signed-off-by: Omri Mor --- diff --git a/usertools/dpdk-devbind.py b/usertools/dpdk-devbind.py index da6e40cbe2..a539995cdb 100755 --- a/usertools/dpdk-devbind.py +++ b/usertools/dpdk-devbind.py @@ -204,8 +204,7 @@ def check_modules(): # special case for vfio_pci (module is named vfio-pci, # but its .ko is named vfio_pci) - sysfs_mods = map(lambda a: - a if a != 'vfio_pci' else 'vfio-pci', sysfs_mods) + sysfs_mods = [a if a != 'vfio_pci' else 'vfio-pci' for a in sysfs_mods] for mod in mods: if mod["Name"] in sysfs_mods: