From patchwork Mon Jun 13 13:01:57 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jan Viktorin X-Patchwork-Id: 13537 Return-Path: X-Original-To: patchwork@dpdk.org Delivered-To: patchwork@dpdk.org Received: from [92.243.14.124] (localhost [IPv6:::1]) by dpdk.org (Postfix) with ESMTP id 92C0F5902; Mon, 13 Jun 2016 15:07:39 +0200 (CEST) Received: from wes1-so1.wedos.net (wes1-so1.wedos.net [46.28.106.15]) by dpdk.org (Postfix) with ESMTP id 30B1B567B for ; Mon, 13 Jun 2016 15:07:32 +0200 (CEST) Received: from pcviktorin.fit.vutbr.cz (pcviktorin.fit.vutbr.cz [147.229.13.147]) by wes1-so1.wedos.net (Postfix) with ESMTPSA id 3rStNg701WzC5w; Mon, 13 Jun 2016 15:07:31 +0200 (CEST) From: Jan Viktorin To: dev@dpdk.org Cc: Jan Viktorin , Anatoly Burakov , David Marchand , Keith Wiles , Santosh Shukla , Stephen Hemminger , Shreyansh Jain Date: Mon, 13 Jun 2016 15:01:57 +0200 Message-Id: <1465822926-23742-8-git-send-email-viktorin@rehivetech.com> X-Mailer: git-send-email 2.8.0 In-Reply-To: <1465822926-23742-1-git-send-email-viktorin@rehivetech.com> References: <1465822926-23742-1-git-send-email-viktorin@rehivetech.com> In-Reply-To: <1461937456-22943-1-git-send-email-viktorin@rehivetech.com> References: <1461937456-22943-1-git-send-email-viktorin@rehivetech.com> Subject: [dpdk-dev] [PATCH v2 07/16] vfio: move vfio-specific SOCKET_* constants 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: , Errors-To: dev-bounces@dpdk.org Sender: "dev" The constants are not PCI-specific. Move them into the eal_vfio.h. Signed-off-by: Jan Viktorin --- lib/librte_eal/linuxapp/eal/eal_pci_init.h | 7 ------- lib/librte_eal/linuxapp/eal/eal_vfio.h | 6 ++++++ 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/lib/librte_eal/linuxapp/eal/eal_pci_init.h b/lib/librte_eal/linuxapp/eal/eal_pci_init.h index b4d7628..fd81f4d 100644 --- a/lib/librte_eal/linuxapp/eal/eal_pci_init.h +++ b/lib/librte_eal/linuxapp/eal/eal_pci_init.h @@ -87,13 +87,6 @@ int pci_vfio_map_resource(struct rte_pci_device *dev); int pci_vfio_get_group_fd(int iommu_group_fd); int pci_vfio_get_container_fd(void); -/* socket comm protocol definitions */ -#define SOCKET_REQ_CONTAINER 0x100 -#define SOCKET_REQ_GROUP 0x200 -#define SOCKET_OK 0x0 -#define SOCKET_NO_FD 0x1 -#define SOCKET_ERR 0xFF - #endif #endif /* EAL_PCI_INIT_H_ */ diff --git a/lib/librte_eal/linuxapp/eal/eal_vfio.h b/lib/librte_eal/linuxapp/eal/eal_vfio.h index 8cb0d1d..121df0a 100644 --- a/lib/librte_eal/linuxapp/eal/eal_vfio.h +++ b/lib/librte_eal/linuxapp/eal/eal_vfio.h @@ -115,6 +115,12 @@ vfio_set_iommu_type(int vfio_container_fd); int vfio_has_supported_extensions(int vfio_container_fd); +#define SOCKET_REQ_CONTAINER 0x100 +#define SOCKET_REQ_GROUP 0x200 +#define SOCKET_OK 0x0 +#define SOCKET_NO_FD 0x1 +#define SOCKET_ERR 0xFF + int vfio_type1_dma_map(int); int vfio_noiommu_dma_map(int);