From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM01-BN3-obe.outbound.protection.outlook.com (mail-bn3nam01on0080.outbound.protection.outlook.com [104.47.33.80]) by dpdk.org (Postfix) with ESMTP id 7A4A97CAB for ; Tue, 18 Jul 2017 08:00:59 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=CAVIUMNETWORKS.onmicrosoft.com; s=selector1-cavium-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=obCPEwICB8E8cEyOAQbv06RMXqee5+7yRbrJ9E70XJE=; b=Wlvc3130pFjuHzZ/SUufHpqZTy/V2WnFF5y734i3b26zYaXC0buXrXy+4ZCFgJDZJM0Z+AQI9a72N00qf/TYJfJbAk77PfOwuXHMpVPi5CsiUOEQ1qWDXloMtzW788yRFuQBDLVySTao3x+Fwy3fQmB98uDp8/dO2LGPJgGy2rI= Authentication-Results: monjalon.net; dkim=none (message not signed) header.d=none;monjalon.net; dmarc=none action=none header.from=caviumnetworks.com; Received: from localhost.localdomain (14.140.2.178) by CY4PR07MB3096.namprd07.prod.outlook.com (10.172.115.10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1261.13; Tue, 18 Jul 2017 06:00:52 +0000 From: Santosh Shukla To: thomas@monjalon.net, dev@dpdk.org Cc: bruce.richardson@intel.com, jerin.jacob@caviumnetworks.com, hemant.agrawal@nxp.com, shreyansh.jain@nxp.com, gaetan.rivet@6wind.com, sergio.gonzalez.monroy@intel.com, anatoly.burakov@intel.com, stephen@networkplumber.org, maxime.coquelin@redhat.com, olivier.matz@6wind.com, Santosh Shukla Date: Tue, 18 Jul 2017 11:29:43 +0530 Message-Id: <20170718055950.10208-6-santosh.shukla@caviumnetworks.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20170718055950.10208-1-santosh.shukla@caviumnetworks.com> References: <20170711061631.5018-1-santosh.shukla@caviumnetworks.com> <20170718055950.10208-1-santosh.shukla@caviumnetworks.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [14.140.2.178] X-ClientProxiedBy: SG2PR01CA0029.apcprd01.prod.exchangelabs.com (10.165.9.167) To CY4PR07MB3096.namprd07.prod.outlook.com (10.172.115.10) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 3182e26d-f0bc-4b94-ec78-08d4cda25b8f X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(300000500095)(300135000095)(300000501095)(300135300095)(22001)(300000502095)(300135100095)(300000503095)(300135400095)(201703131423075)(201703031133081)(300000504095)(300135200095)(300000505095)(300135600095)(300000506095)(300135500095); SRVR:CY4PR07MB3096; X-Microsoft-Exchange-Diagnostics: 1; CY4PR07MB3096; 3:cZfemWIMJ8MMzmoKx1IanwDdpFUQjx8IueboULiK1RnrmXnn+NAUbHajPa1lK4G4sYaPK8F25zL6k+EhWylSa2U8HPNK/sQYLCFFOMxQiJ1buPM1sY2y/rN+kQ4qjM91Htl0OFdHjyXBDK1+4aDXrql+BekguFGmwIHI58/kPxRiilQ+mhoXUDmMn3WV6WWIBdpZTBaYsNwrgNrbhXcQQYo6gGiHwGzEGFOpNMYxNFSpJzmN2YqroM+YYXNsbWl8IIDsb/E3PVp1pQVYHuXeu99pDytPWsZwl7smJi0/p11E/8JUDlWhMsPOJ79+VCeN3IWxFM5+ePAGonktUfoYadOXpSPjV+dz36p/MMpmgzg3vq00Wtta87ugDWTuNxIpId6Kb+H+la0dHn0+AmEWtXi+nMy+ka33V9QvWeSaZ0t1eCzr2y0+HIlQKRF4SZueVJ+u6hgA4uJwq4Rn35G30gVhLwkTh9nqSsUUGT/01pCY1ED8JvAHkXdZ3nMox7yefDqS84eNMhjAh26IbH6gQDeDKqzLcvhUIDyTGCHKTNcrPWapp/hRW/LCYGvkh6wqMzZeKwZfGU73Lgt9rWtsncC7sTXBn+upCuLCjP/4ArrI02uajSKvyubbkUNDzcpY8p2PIib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ESoazBNOtHcys0kPeOoOozDCrw+VUwOIvAm+EHXRxnFyjM6KJ6dleGmTjbk8gO+CX/5mWxlDmA07dCsYUNXDcNZfEHEpU5jDUoVe2SbTTYCNh2yLVotuQ4H38YlTgYCokaKg9tLm/laKSd9ZZbMN6xzuPX2Yd2kLbPb3K+MIZGaU1OfWAkJJxBxrTSadSP/ZsEzggdExE4io36qLB9kyli0Bya+hJuJ/uaqHQUixHh0MTkV5a0z/ZK/T/hNBxeb+sDsf1YAJG4P7/f27ARViHZ9YIiQ+9rBNC7rdTaQ9EOFz+V9RHIXoBD9IS+cY= X-Exchange-Antispam-Report-Test: UriScan:(236129657087228)(278021516957215)(247924648384137); X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(601004)(2401047)(5005006)(8121501046)(2017060910075)(93006095)(100000703101)(100105400095)(10201501046)(3002001)(6041248)(20161123558100)(20161123564025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123562025)(20161123555025)(20161123560025)(6072148)(100000704101)(100105200095)(100000705101)(100105500095); SRVR:CY4PR07MB3096; BCL:0; PCL:0; RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095); SRVR:CY4PR07MB3096; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; CY4PR07MB3096; 4:yysRVVi9G+blSjmfftYIUlmxzWvEgyMtVymWGcsGQ3?= =?us-ascii?Q?Y4H2G3ZQBMmwhErRYQ9ClzEqCnhoLnxXfRdScj0VPcmZwOnrEK2wHo5ygKga?= =?us-ascii?Q?R5/opnb43QNZMFSUXpjcYJwBIm7RSgcjsYrveT9ZMpJ9hVDEy61Em8aFVgw9?= =?us-ascii?Q?40iLHZ1qQ7EIcUxfTYZGQKSPjA6YKEIALOuMrjVwdtdVPbnyIGHX57e7vK1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1iOxUUNY2jib9k8+KGZMBbrDgjwQRjJu7oQfLhpD?= =?us-ascii?Q?X/nzL8tXuuUBgvq//tMh5hA3+0CEMscCEvI3CIN4Ez5MzU0O7HLZacowo8bB?= =?us-ascii?Q?JdOLfCxNeVtZFkJTIUcpY6jhyEya7TQibOe1tchbXi1tmUbx40QWYvkYhceu?= =?us-ascii?Q?SvYpCNqqLqZ3LshboJBHbcdr38ZN9OozokTkQq?= X-Forefront-PRVS: 037291602B X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(4630300001)(7370300001)(6069001)(6009001)(39410400002)(39850400002)(39400400002)(39450400003)(39840400002)(39860400002)(48376002)(25786009)(66066001)(42186005)(50226002)(81166006)(6666003)(189998001)(8676002)(6486002)(110136004)(2906002)(107886003)(38730400002)(7416002)(966005)(36756003)(5660300001)(7736002)(47776003)(1076002)(76176999)(50986999)(5003940100001)(305945005)(6512007)(478600001)(4326008)(72206003)(53936002)(5890100001)(7350300001)(3846002)(6506006)(33646002)(2950100002)(5009440100003)(50466002)(6116002)(6306002)(8656003)(42882006)(110426004); DIR:OUT; SFP:1101; SCL:1; SRVR:CY4PR07MB3096; H:localhost.localdomain; FPR:; SPF:None; MLV:sfv; LANG:en; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; CY4PR07MB3096; 23:HPAjumsYHdVdStQGPTrUeIJDxXXZ4yDcDUawW7lEK?= =?us-ascii?Q?kop/Rmblt8Ezkd92NDv3w9+o+VymL4wvSaliqunZaPQxqGoJFZ3788S1s1bk?= =?us-ascii?Q?XBKzxsjJyWPbeyYTln1wz4SzSlKYORwq6BxRB0SiO2lTUoxufVCJoktVvPG9?= =?us-ascii?Q?AEF9apPigwJ1lMsdaSuRkA9KlEtX/bHTsMmaTEQgjkksdJAn+MkQ22cHZzgN?= =?us-ascii?Q?Xo1sUXG6+Jqw5N8y82lbZjw/xRiqzcbDoiMknJ8zOzfYxRg0bBk9STrJaUIz?= =?us-ascii?Q?ZcW7J3Yr8qr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iagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; CY4PR07MB3096; 7:0lxXamq8oXc2srhbnGSWvxVdGUwwsKYDpHTE6BwaCZ9fKbCwXv4gqKVjGkYZUrmPn8/pTx7iVtX3KcHoyHelNKxmq17m+qmYy4rFll243Socmsp4YBPWpSzXSg4tpgT3XkumP4d9WzJfUGdE1iVwpfb78HerK+PrYMAbNS87tBegLsB1QrzAQunE0dKE6GS30XTYdFfWIMCnflnbE4oFaB/v9xcJGqDP0CqCwjj0yqTRFz1ci4U1Wq529MMDjvrcwC0O2wmqMvvth1F+BAv3FPDON4mfN1PomHsJm0nk/5TKjvc1olIpSfUR5NogsPa2lSkDj8HnXrN4aSCQ7iUdCNR/ruEAqRJSZORuRSL0GUoIzz/wEDcR+FjWndZX0d/0+ap6spLvGrAQja4U1buo2ZPNMKgPiI1vwMUyVPgcUEH6B1/3cHPKWvkp5rtvftsfzkzm2b90LykxAzzH5xZ+F9pYUiYS0AwiE8YxSRzjGQ2iPgKC0VgiAzyfjMWOlhCT6BSDX5eDRN1mevpOMHCNaMxgPme/+1sEG4yosGbjJkHTAVlMAoZVEM7Vxbt6jBUwgij/6wu5zQ4GNmnKe4qBSH6aGdP16em/PpWi95upRIWZ24TDB84pF9p3zlNj0Y6FTfK5N5hMnI50MIVEalG0plvoPbrPe1hmqljL7/j3kYNbHUCyWLK0AaKhUfDXUbEuW+kKaFkS1tZIOnfTVIQuzcr2owxvCc/R1zQR8AywTminBFlAMX9NHGGZniuQzBaGUreYbcJfxdRvWXL3OJgowYgnfOb5lIYUslk6/EW14uk= X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 18 Jul 2017 06:00:52.6105 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY4PR07MB3096 Subject: [dpdk-dev] [PATCH v4 05/12] linuxapp/eal_pci: get iommu class X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Jul 2017 06:01:00 -0000 Get iommu class of PCI device on the bus and returns preferred iova mapping mode for that bus. Algorithm for iova scheme selection for PCI bus: 0. If no device bound then return with RTE_IOVA_DC mapping mode, else goto 1). 1. Look for device attached to vfio kdrv and has .drv_flag set to RTE_PCI_DRV_IOVA_AS_VA. 2. Look for any device attached to UIO class of driver. 3. Check for vfio-noiommu mode enabled. If 2) & 3) is false and 1) is true then select mapping scheme as RTE_IOVA_VA. Otherwise use default mapping scheme (RTE_IOVA_PA). Signed-off-by: Santosh Shukla Signed-off-by: Jerin Jacob --- v3 --> v4 : - Reworded WARNING message (suggested by Maxime) - Added pci_device_is_bound func to check for no device case (suggested by Hemant). - Added ifdef vfio_present. v1 --> v2: - Removed Linux version check in vfio_noiommu func. Refer [1]. - Extending autodetction logic for _iommu_class. Refer [2]. [1] https://www.mail-archive.com/dev@dpdk.org/msg70108.html [2] https://www.mail-archive.com/dev@dpdk.org/msg70279.html lib/librte_eal/linuxapp/eal/eal_pci.c | 95 +++++++++++++++++++++++++ lib/librte_eal/linuxapp/eal/eal_vfio.c | 19 +++++ lib/librte_eal/linuxapp/eal/eal_vfio.h | 4 ++ lib/librte_eal/linuxapp/eal/rte_eal_version.map | 1 + 4 files changed, 119 insertions(+) diff --git a/lib/librte_eal/linuxapp/eal/eal_pci.c b/lib/librte_eal/linuxapp/eal/eal_pci.c index 7d9e1a99b..ecd946250 100644 --- a/lib/librte_eal/linuxapp/eal/eal_pci.c +++ b/lib/librte_eal/linuxapp/eal/eal_pci.c @@ -45,6 +45,7 @@ #include "eal_filesystem.h" #include "eal_private.h" #include "eal_pci_init.h" +#include "eal_vfio.h" /** * @file @@ -488,6 +489,100 @@ rte_pci_scan(void) return -1; } +/* + * Is pci device bound to any kdrv + */ +static inline int +pci_device_is_bound(void) +{ + struct rte_pci_device *dev = NULL; + int ret = 0; + + FOREACH_DEVICE_ON_PCIBUS(dev) { + if (dev->kdrv == RTE_KDRV_UNKNOWN || + dev->kdrv == RTE_KDRV_NONE) { + continue; + } else { + ret = 1; + break; + } + } + return ret; +} + +/* + * Any one of the device bound to uio + */ +static inline int +pci_device_bound_uio(void) +{ + struct rte_pci_device *dev = NULL; + + FOREACH_DEVICE_ON_PCIBUS(dev) { + if (dev->kdrv == RTE_KDRV_IGB_UIO || + dev->kdrv == RTE_KDRV_UIO_GENERIC) { + return 1; + } + } + return 0; +} + +/* + * Any one of the device has iova as va + */ +static inline int +pci_device_has_iova_va(void) +{ + struct rte_pci_device *dev = NULL; + struct rte_pci_driver *drv = NULL; + + FOREACH_DRIVER_ON_PCIBUS(drv) { + if (drv && drv->drv_flags & RTE_PCI_DRV_IOVA_AS_VA) { + FOREACH_DEVICE_ON_PCIBUS(dev) { + if (dev->kdrv == RTE_KDRV_VFIO && + rte_pci_match(drv, dev)) + return 1; + } + } + } + return 0; +} + +/* + * Get iommu class of PCI devices on the bus. + */ +enum rte_iova_mode +rte_pci_get_iommu_class(void) +{ + bool is_bound; + bool is_vfio_noiommu_enabled = true; + bool has_iova_va; + bool is_bound_uio; + + is_bound = pci_device_is_bound(); + if (!is_bound) + return RTE_IOVA_DC; + + has_iova_va = pci_device_has_iova_va(); + is_bound_uio = pci_device_bound_uio(); +#ifdef VFIO_PRESENT + is_vfio_noiommu_enabled = vfio_noiommu_is_enabled() == 1 ? 1 : 0; +#endif + + if (has_iova_va && !is_bound_uio && !is_vfio_noiommu_enabled) + return RTE_IOVA_VA; + + if (has_iova_va) { + RTE_LOG(WARNING, EAL, "Some devices want iova as va but pa will be used because.. "); + if (is_vfio_noiommu_enabled) + RTE_LOG(WARNING, EAL, "vfio-noiommu mode configured\n"); + if (is_bound_uio) + RTE_LOG(WARNING, EAL, "few device bound to UIO\n"); + } + + return RTE_IOVA_PA; +} + /* Read PCI config space. */ int rte_pci_read_config(const struct rte_pci_device *device, void *buf, size_t len, off_t offset) diff --git a/lib/librte_eal/linuxapp/eal/eal_vfio.c b/lib/librte_eal/linuxapp/eal/eal_vfio.c index 946df7e31..c8a97b7e7 100644 --- a/lib/librte_eal/linuxapp/eal/eal_vfio.c +++ b/lib/librte_eal/linuxapp/eal/eal_vfio.c @@ -816,4 +816,23 @@ vfio_noiommu_dma_map(int __rte_unused vfio_container_fd) return 0; } +int +vfio_noiommu_is_enabled(void) +{ + int fd, ret, cnt __rte_unused; + char c; + + ret = -1; + fd = open(VFIO_NOIOMMU_MODE, O_RDONLY); + if (fd < 0) + return -1; + + cnt = read(fd, &c, 1); + if (c == 'Y') + ret = 1; + + close(fd); + return ret; +} + #endif diff --git a/lib/librte_eal/linuxapp/eal/eal_vfio.h b/lib/librte_eal/linuxapp/eal/eal_vfio.h index 5ff63e5d7..26ea8e119 100644 --- a/lib/librte_eal/linuxapp/eal/eal_vfio.h +++ b/lib/librte_eal/linuxapp/eal/eal_vfio.h @@ -150,6 +150,8 @@ struct vfio_config { #define VFIO_NOIOMMU_GROUP_FMT "/dev/vfio/noiommu-%u" #define VFIO_GET_REGION_ADDR(x) ((uint64_t) x << 40ULL) #define VFIO_GET_REGION_IDX(x) (x >> 40) +#define VFIO_NOIOMMU_MODE \ + "/sys/module/vfio/parameters/enable_unsafe_noiommu_mode" /* DMA mapping function prototype. * Takes VFIO container fd as a parameter. @@ -210,6 +212,8 @@ int pci_vfio_is_enabled(void); int vfio_mp_sync_setup(void); +int vfio_noiommu_is_enabled(void); + #define SOCKET_REQ_CONTAINER 0x100 #define SOCKET_REQ_GROUP 0x200 #define SOCKET_CLR_GROUP 0x300 diff --git a/lib/librte_eal/linuxapp/eal/rte_eal_version.map b/lib/librte_eal/linuxapp/eal/rte_eal_version.map index a69bbb599..5dd40f948 100644 --- a/lib/librte_eal/linuxapp/eal/rte_eal_version.map +++ b/lib/librte_eal/linuxapp/eal/rte_eal_version.map @@ -206,6 +206,7 @@ DPDK_17.08 { rte_bus_find_by_device; rte_bus_find_by_name; rte_pci_match; + rte_pci_get_iommu_class; } DPDK_17.05; -- 2.11.0