From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f43.google.com (mail-wm0-f43.google.com [74.125.82.43]) by dpdk.org (Postfix) with ESMTP id 58B18379E for ; Mon, 11 Jul 2016 16:41:07 +0200 (CEST) Received: by mail-wm0-f43.google.com with SMTP id o80so54029907wme.1 for ; Mon, 11 Jul 2016 07:41:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=wRUwzc7lYic8ssOR0oanaHzU5j26u2101ajL12cczF8=; b=AQV+pWOTzzsBd4G/91NBLdvErANMK5EtdTkylPqYrj+aWyQ63VIZWxO/tutmqEO26r MCzJo2QKAz1w3Q/Isomt7bfJPmB0q4GS1nTD9px06/vm56HTfqNLV/dkpoCM8KauqtzP gVaXtBMcF0u7lSJb93KzjpMLFjLYIE29lagInXeWj4uvymVbM7qLCoHqOo+5nfvX6c0x 0B7LcTrYHQvnAQHZ3J0cfhH53yEVznLxGd1jgFY1op8NsBrpxABWcVJkUcQFb4/yMuwQ L6i+Rg1B0gUmVwbPbcrJJkOGDQFVIX8btOPmskLU9Jf+3RvpGW91Eld11N2+6ZbU1T5U 8sRw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=wRUwzc7lYic8ssOR0oanaHzU5j26u2101ajL12cczF8=; b=fmVFQLbhrrsJCVTqpp5d/v790PWkat5O1CLG7m/H88NozgFIbHpAhRM6uWrNVuk7/+ zDS1N/PYUskmKY2/B9EHhM48ijiluVl+b9z++vyihaHUmz3UrHWQqqHZtKgydjCjdZbc YPlBlHIQQgal3tRPLu7JQoDDDWDTu+lsc0sWPNmP1CDUBzW59Yq/LOK9t+/QVPQYXwHO oADh+WWVceGcVHMZxcYQL2+cjTDPK2QFZOtO6qPFEgaKpH4IpsVvSucT9pcQwdpQEm7S LzWYYnOceCEoO4fY4rtX7w1mSGbYXINANL+HEXcUaJL5CgRwOAO/PZD6j+Icst8L4qem CIbg== X-Gm-Message-State: ALyK8tL2EoTmwsQ89WEZLIkPqMaU14+dR/QId4eW2EAeZrrk/sKvNZYqMcmEwFSboIq4DLAy X-Received: by 10.28.24.137 with SMTP id 131mr20732473wmy.77.1468248067114; Mon, 11 Jul 2016 07:41:07 -0700 (PDT) Received: from gloops.dev.6wind.com (guy78-3-82-239-227-177.fbx.proxad.net. [82.239.227.177]) by smtp.gmail.com with ESMTPSA id h7sm158371wji.47.2016.07.11.07.41.05 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 11 Jul 2016 07:41:06 -0700 (PDT) From: David Marchand To: dev@dpdk.org Cc: bruce.richardson@intel.com, thomas.monjalon@6wind.com, nhorman@tuxdriver.com, pmatilai@redhat.com, christian.ehrhardt@canonical.com, stephen@networkplumber.com, Huawei Xie , Yuanhan Liu Date: Mon, 11 Jul 2016 16:40:40 +0200 Message-Id: <1468248045-3495-6-git-send-email-david.marchand@6wind.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1468248045-3495-1-git-send-email-david.marchand@6wind.com> References: <1461156236-25349-1-git-send-email-david.marchand@6wind.com> <1468248045-3495-1-git-send-email-david.marchand@6wind.com> Subject: [dpdk-dev] [PATCH v4 05/10] net/virtio: move PCI device ids to the driver X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 11 Jul 2016 14:41:07 -0000 Reused defines from the driver. Used RTE_PCI_DEVICE in place of RTE_PCI_DEV_ID_DECL* stuff. Signed-off-by: David Marchand Acked-by: Yuanhan Liu --- drivers/net/virtio/virtio_ethdev.c | 7 ++----- lib/librte_eal/common/include/rte_pci_dev_ids.h | 16 ---------------- 2 files changed, 2 insertions(+), 21 deletions(-) diff --git a/drivers/net/virtio/virtio_ethdev.c b/drivers/net/virtio/virtio_ethdev.c index 8467b3c..850e3ba 100644 --- a/drivers/net/virtio/virtio_ethdev.c +++ b/drivers/net/virtio/virtio_ethdev.c @@ -103,11 +103,8 @@ static int virtio_dev_queue_stats_mapping_set( * The set of PCI devices this driver supports */ static const struct rte_pci_id pci_id_virtio_map[] = { - -#define RTE_PCI_DEV_ID_DECL_VIRTIO(vend, dev) {RTE_PCI_DEVICE(vend, dev)}, -#include "rte_pci_dev_ids.h" - -{ .vendor_id = 0, /* sentinel */ }, + { RTE_PCI_DEVICE(VIRTIO_PCI_VENDORID, VIRTIO_PCI_DEVICEID_MIN) }, + { .vendor_id = 0, /* sentinel */ }, }; struct rte_virtio_xstats_name_off { diff --git a/lib/librte_eal/common/include/rte_pci_dev_ids.h b/lib/librte_eal/common/include/rte_pci_dev_ids.h index 9e97d7c..1c66784 100644 --- a/lib/librte_eal/common/include/rte_pci_dev_ids.h +++ b/lib/librte_eal/common/include/rte_pci_dev_ids.h @@ -73,10 +73,6 @@ #define RTE_PCI_DEV_ID_DECL_IXGBEVF(vend, dev) #endif -#ifndef RTE_PCI_DEV_ID_DECL_VIRTIO -#define RTE_PCI_DEV_ID_DECL_VIRTIO(vend, dev) -#endif - #ifndef RTE_PCI_DEV_ID_DECL_VMXNET3 #define RTE_PCI_DEV_ID_DECL_VMXNET3(vend, dev) #endif @@ -102,11 +98,6 @@ #define PCI_VENDOR_ID_INTEL 0x8086 #endif -#ifndef PCI_VENDOR_ID_QUMRANET -/** Vendor ID used by virtio devices */ -#define PCI_VENDOR_ID_QUMRANET 0x1AF4 -#endif - #ifndef PCI_VENDOR_ID_VMWARE /** Vendor ID used by VMware devices */ #define PCI_VENDOR_ID_VMWARE 0x15AD @@ -361,12 +352,6 @@ RTE_PCI_DEV_ID_DECL_IXGBEVF(PCI_VENDOR_ID_INTEL, IXGBE_DEV_ID_X550EM_A_VF_HV) RTE_PCI_DEV_ID_DECL_IXGBEVF(PCI_VENDOR_ID_INTEL, IXGBE_DEV_ID_X550EM_X_VF) RTE_PCI_DEV_ID_DECL_IXGBEVF(PCI_VENDOR_ID_INTEL, IXGBE_DEV_ID_X550EM_X_VF_HV) -/****************** Virtio devices from virtio.h ******************/ - -#define QUMRANET_DEV_ID_VIRTIO 0x1000 - -RTE_PCI_DEV_ID_DECL_VIRTIO(PCI_VENDOR_ID_QUMRANET, QUMRANET_DEV_ID_VIRTIO) - /****************** VMware VMXNET3 devices ******************/ #define VMWARE_DEV_ID_VMXNET3 0x07B0 @@ -459,6 +444,5 @@ RTE_PCI_DEV_ID_DECL_BNXT(PCI_VENDOR_ID_BROADCOM, BROADCOM_DEV_ID_57314) #undef RTE_PCI_DEV_ID_DECL_IGBVF #undef RTE_PCI_DEV_ID_DECL_IXGBE #undef RTE_PCI_DEV_ID_DECL_IXGBEVF -#undef RTE_PCI_DEV_ID_DECL_VIRTIO #undef RTE_PCI_DEV_ID_DECL_VMXNET3 #undef RTE_PCI_DEV_ID_DECL_BNXT -- 1.9.1