From: Thomas Monjalon Date: Tue, 3 Mar 2015 15:04:59 +0000 (+0100) Subject: virtio: fix build with debug enabled X-Git-Tag: spdx-start~9505 X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=80edfef4a83664ed0c96b13a8c1917a2575d768d;p=dpdk.git virtio: fix build with debug enabled With CONFIG_RTE_LIBRTE_VIRTIO_DEBUG_INIT=y: error: ‘devname’ undeclared (first use in this function) Fixes: da978dfdc43b ("virtio: use port IO to get PCI resource") Signed-off-by: Thomas Monjalon Acked-by: Changchun Ouyang --- diff --git a/lib/librte_pmd_virtio/virtio_ethdev.c b/lib/librte_pmd_virtio/virtio_ethdev.c index 4bad1e4474..d239083266 100644 --- a/lib/librte_pmd_virtio/virtio_ethdev.c +++ b/lib/librte_pmd_virtio/virtio_ethdev.c @@ -971,7 +971,7 @@ static int virtio_resource_init_by_uio(struct rte_pci_device *pci_dev) pci_dev->intr_handle.fd = open(dirname, O_RDWR); if (pci_dev->intr_handle.fd < 0) { PMD_INIT_LOG(ERR, "Cannot open %s: %s\n", - devname, strerror(errno)); + dirname, strerror(errno)); return -1; }