From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jan Blunck Subject: [PATCH 1/2] vdev: get name from embedded device Date: Tue, 11 Jul 2017 14:56:48 -0400 Message-ID: <20170711185649.43620-2-jblunck@infradead.org> References: <20170711185649.43620-1-jblunck@infradead.org> To: dev@dpdk.org Return-path: Received: from mail-wr0-f194.google.com (mail-wr0-f194.google.com [209.85.128.194]) by dpdk.org (Postfix) with ESMTP id 150E85598 for ; Tue, 11 Jul 2017 20:57:35 +0200 (CEST) Received: by mail-wr0-f194.google.com with SMTP id z45so288726wrb.2 for ; Tue, 11 Jul 2017 11:57:35 -0700 (PDT) Received: from localhost.localdomain ([37.228.147.16]) by smtp.gmail.com with ESMTPSA id x36sm54452edb.64.2017.07.11.11.57.33 for (version=TLS1 cipher=AES128-SHA bits=128/128); Tue, 11 Jul 2017 11:57:33 -0700 (PDT) In-Reply-To: <20170711185649.43620-1-jblunck@infradead.org> List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Instead of getting the name from the devargs lets take it from the rte_device. Signed-off-by: Jan Blunck --- lib/librte_eal/common/include/rte_vdev.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/librte_eal/common/include/rte_vdev.h b/lib/librte_eal/common/include/rte_vdev.h index 3c07b76a0..fc24298f2 100644 --- a/lib/librte_eal/common/include/rte_vdev.h +++ b/lib/librte_eal/common/include/rte_vdev.h @@ -49,8 +49,8 @@ struct rte_vdev_device { static inline const char * rte_vdev_device_name(const struct rte_vdev_device *dev) { - if (dev && dev->device.devargs) - return dev->device.devargs->name; + if (dev && dev->device.name) + return dev->device.name; return NULL; } -- 2.13.2