From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from bgl-iport-2.cisco.com (bgl-iport-2.cisco.com [72.163.197.26]) by dpdk.org (Postfix) with ESMTP id 13E824A6E for ; Fri, 7 Nov 2014 11:27:28 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=cisco.com; i=@cisco.com; l=3578; q=dns/txt; s=iport; t=1415356621; x=1416566221; h=from:to:cc:subject:date:message-id:in-reply-to: references; bh=5iH+7qVWKi0fbAidiUMVLXJYsd4H6L0lOUVXzvhkUwU=; b=gKasEGTbOKcvzauAnqJtbpvg1EKNcGD2Gpsl3uQ7jZIAmSgUG0FJnd4A hTaYV/HI00qQfDtCYtniLz2ErPf91OeIZDKw+2UO+Lxe7MhVEQnIbTYTt 55SFP4ns99UdfWq9PTLELJnVA16b/qdHRxDQDRy9SqHxVau4gWDTRz/sy E=; X-IronPort-AV: E=Sophos;i="5.07,331,1413244800"; d="scan'208";a="47245180" Received: from vla196-nat.cisco.com (HELO bgl-core-1.cisco.com) ([72.163.197.24]) by bgl-iport-2.cisco.com with ESMTP; 07 Nov 2014 10:36:59 +0000 Received: from localhost ([10.106.186.117]) (authenticated bits=0) by bgl-core-1.cisco.com (8.14.5/8.14.5) with ESMTP id sA7AajOd023698 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NO); Fri, 7 Nov 2014 10:36:59 GMT From: Sujith Sankar To: dev@dpdk.org Date: Sat, 8 Nov 2014 01:35:41 +0530 Message-Id: <1415390747-9532-2-git-send-email-ssujith@cisco.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1415390747-9532-1-git-send-email-ssujith@cisco.com> References: <1415390747-9532-1-git-send-email-ssujith@cisco.com> X-Authenticated-User: ssujith@cisco.com Subject: [dpdk-dev] [PATCH 1/7] DPDK changes for accommodating ENIC PMD 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: Fri, 07 Nov 2014 10:27:29 -0000 Signed-off-by: Sujith Sankar --- app/test-pmd/testpmd.c | 1 + config/common_linuxapp | 6 ++++++ lib/Makefile | 1 + lib/librte_eal/linuxapp/eal/eal_pci_vfio.c | 7 +++++++ lib/librte_eal/linuxapp/eal/include/eal_pci_init.h | 1 + mk/rte.app.mk | 4 ++++ 6 files changed, 20 insertions(+) diff --git a/app/test-pmd/testpmd.c b/app/test-pmd/testpmd.c index f76406f..4857d56 100644 --- a/app/test-pmd/testpmd.c +++ b/app/test-pmd/testpmd.c @@ -1874,6 +1874,7 @@ main(int argc, char** argv) "check that " "CONFIG_RTE_LIBRTE_IGB_PMD=y and that " "CONFIG_RTE_LIBRTE_EM_PMD=y and that " + "CONFIG_RTE_LIBRTE_ENIC_PMD=y and that " "CONFIG_RTE_LIBRTE_IXGBE_PMD=y in your " "configuration file\n"); diff --git a/config/common_linuxapp b/config/common_linuxapp index 57b61c9..6b5bac6 100644 --- a/config/common_linuxapp +++ b/config/common_linuxapp @@ -210,6 +210,12 @@ CONFIG_RTE_LIBRTE_I40E_QUEUE_NUM_PER_VM=4 CONFIG_RTE_LIBRTE_I40E_ITR_INTERVAL=-1 # +# Compile burst-oriented Cisco ENIC PMD driver +# +CONFIG_RTE_LIBRTE_ENIC_PMD=y +CONFIG_RTE_LIBRTE_ENIC_PMD_DEBUG_TRACE=n + +# # Compile burst-oriented VIRTIO PMD driver # CONFIG_RTE_LIBRTE_VIRTIO_PMD=y diff --git a/lib/Makefile b/lib/Makefile index e3237ff..1911790 100644 --- a/lib/Makefile +++ b/lib/Makefile @@ -43,6 +43,7 @@ DIRS-$(CONFIG_RTE_LIBRTE_CMDLINE) += librte_cmdline DIRS-$(CONFIG_RTE_LIBRTE_ETHER) += librte_ether DIRS-$(CONFIG_RTE_LIBRTE_E1000_PMD) += librte_pmd_e1000 DIRS-$(CONFIG_RTE_LIBRTE_IXGBE_PMD) += librte_pmd_ixgbe +DIRS-$(CONFIG_RTE_LIBRTE_IXGBE_PMD) += librte_pmd_enic DIRS-$(CONFIG_RTE_LIBRTE_I40E_PMD) += librte_pmd_i40e DIRS-$(CONFIG_RTE_LIBRTE_PMD_BOND) += librte_pmd_bond DIRS-$(CONFIG_RTE_LIBRTE_PMD_RING) += librte_pmd_ring diff --git a/lib/librte_eal/linuxapp/eal/eal_pci_vfio.c b/lib/librte_eal/linuxapp/eal/eal_pci_vfio.c index c776ddc..6bf8f2e 100644 --- a/lib/librte_eal/linuxapp/eal/eal_pci_vfio.c +++ b/lib/librte_eal/linuxapp/eal/eal_pci_vfio.c @@ -736,6 +736,7 @@ pci_vfio_map_resource(struct rte_pci_device *dev) maps[i].offset = reg.offset; maps[i].size = reg.size; dev->mem_resource[i].addr = bar_addr; + dev->mem_resource[i].len = reg.size; } /* if secondary process, do not set up interrupts */ @@ -791,4 +792,10 @@ pci_vfio_is_enabled(void) { return vfio_cfg.vfio_enabled; } + +int +pci_vfio_container_fd(void) +{ + return vfio_cfg.vfio_container_fd; +} #endif diff --git a/lib/librte_eal/linuxapp/eal/include/eal_pci_init.h b/lib/librte_eal/linuxapp/eal/include/eal_pci_init.h index d758bee..c9e9e40 100644 --- a/lib/librte_eal/linuxapp/eal/include/eal_pci_init.h +++ b/lib/librte_eal/linuxapp/eal/include/eal_pci_init.h @@ -71,6 +71,7 @@ int pci_uio_map_resource(struct rte_pci_device *dev); int pci_vfio_enable(void); int pci_vfio_is_enabled(void); +int pci_vfio_container_fd(void); int pci_vfio_mp_sync_setup(void); /* map VFIO resource prototype */ diff --git a/mk/rte.app.mk b/mk/rte.app.mk index 285b65c..95c652f 100644 --- a/mk/rte.app.mk +++ b/mk/rte.app.mk @@ -186,6 +186,10 @@ ifeq ($(CONFIG_RTE_LIBRTE_VMXNET3_PMD),y) LDLIBS += -lrte_pmd_vmxnet3_uio endif +ifeq ($(CONFIG_RTE_LIBRTE_ENIC_PMD),y) +LDLIBS += -lrte_pmd_enic +endif + ifeq ($(CONFIG_RTE_LIBRTE_VIRTIO_PMD),y) LDLIBS += -lrte_pmd_virtio_uio endif -- 1.9.1