pci: fix check of mknod
authorWei Dai <wei.dai@intel.com>
Thu, 17 Nov 2016 06:47:15 +0000 (14:47 +0800)
committerThomas Monjalon <thomas.monjalon@6wind.com>
Tue, 6 Dec 2016 10:59:39 +0000 (11:59 +0100)
commitf1d54e6dfb1624d9c2d0a1b8a96eb4a84070b639
tree7bd709f1be2f3c26f9fc360cf911b558199d57d0
parent5d8f0baf69ea1462c8cc32729c789f7278bf3dc2
pci: fix check of mknod

In function pci_mknod_uio_dev() in lib/librte_eal/eal/eal_pci_uio.c,
The return value of mknod() is ret, not f got by fopen().
So the value of ret should be checked for mknod().

Fixes: f7f97c16048e ("pci: add option --create-uio-dev to run without hotplug")

Signed-off-by: Wei Dai <wei.dai@intel.com>
Acked-by: Olivier Matz <olivier.matz@6wind.com>
lib/librte_eal/linuxapp/eal/eal_pci_uio.c