From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM01-SN1-obe.outbound.protection.outlook.com (mail-sn1nam01on0046.outbound.protection.outlook.com [104.47.32.46]) by dpdk.org (Postfix) with ESMTP id C813C2B92 for ; Thu, 30 Aug 2018 14:59:30 +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:X-MS-Exchange-SenderADCheck; bh=aizjhbHGOevu2bsybKl8IgQnM51OIy/v9IbuJA9M9e4=; b=DRzg/QrBJgvJ8TSRc7mrbdgNDyJ1ghnZodIAlpSOM/VevMbx8ogEskhX6qX/hznacRLqBApuq0yovjUd02l/bmKXwlcuyGB/nLg6gY0fIf/BV/R/6iwde9VDNOPxwX1T3g1ZBqQCykbG36HK7gRq8FfKhurhR4UITHlHe6WWQs0= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Santosh.Shukla@cavium.com; Received: from [192.168.0.106] (45.117.223.90) by BYAPR07MB4328.namprd07.prod.outlook.com (2603:10b6:a02:bf::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1080.18; Thu, 30 Aug 2018 12:59:25 +0000 To: hemant.agrawal@nxp.com, =?UTF-8?Q?Ga=c3=abtan_Rivet?= , "Burakov, Anatoly" Cc: eric zhang , bruce.richardson@intel.com, dev@dpdk.org, Allain.Legacy@windriver.com, Matt.Peters@windriver.com References: <1535558289-10336-1-git-send-email-eric.zhang@windriver.com> <20180830094323.37xkgud4fz3mflbg@bidouze.vm.6wind.com> <0f19de06-fccd-eff2-b33e-71d49a005dbb@nxp.com> From: santosh Message-ID: Date: Thu, 30 Aug 2018 18:29:10 +0530 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: <0f19de06-fccd-eff2-b33e-71d49a005dbb@nxp.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Content-Language: en-US X-Originating-IP: [45.117.223.90] X-ClientProxiedBy: PN1PR0101CA0066.INDPRD01.PROD.OUTLOOK.COM (2603:1096:c00:d::28) To BYAPR07MB4328.namprd07.prod.outlook.com (2603:10b6:a02:bf::22) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 0119e96b-f51e-48a2-8bd1-08d60e786b8a X-Microsoft-Antispam: BCL:0; PCL:0; RULEID:(7020095)(4652040)(8989137)(4534165)(4627221)(201703031133081)(201702281549075)(8990107)(5600074)(711020)(2017052603328)(7153060)(7193020); SRVR:BYAPR07MB4328; X-Microsoft-Exchange-Diagnostics: 1; BYAPR07MB4328; 3:tw8U/O7NImfHzz3yxuNd2/hwI7iTBaVtU5nt3k2BCBRpBOogUPr7mAC3CmQBubW1foZQ2GYl78hOY9gHjHOaEna/qDyF2zgjPKhfiWq+M/GSAEPNLvJZHCqB3UjNZ8GybnNlY3McI0zQwce1x1BwZKHGLtRIfHhymKV4m/UvrdFSyWPaigr6f1g0rRqEMfCYOziXcWi9Va0biB57OX7bKwGdzCAILVyUVo/Q58KQcSM2CkBphz9eDyziXXjXEykC; 25:xdXJCakAgxVaiQIFqwZ+KusmG9SKtKcN5/GzMC4A59vtRXYz4Wvyqf2nhRVCjGW2dtgahREOpPUAJOAf1kylscAYN3TucodqG75YUsXbWlAiCUCBVkd5kQA/lMcaRsNgjHtJ7ifdeliqIF1TtrMY1/r2UY54dJzf8Po0tlhInjxlFHkpdE6tHHJemxi6MVs67CtpwP0y+9b4b/11T2aU1ctZUKujgkMLAqHgJXJZKC+YWApPQh6IdFKxOMJ+DkOLYsBl4JqjX/N0z69SQunT14zcGjXN7yEMfiDoQgyDuvffplfjSJUe/DqTHq82m4vSWGHgn/ODLeCDtQfOuNbbqg==; 31:PJpS2OQAttRAdViyfnCcqZsRb4EEc5MB0OVutjPGq5fV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NUw/OaFgzU7/+Lag+tcUtmNga1ZFZgFmbuU0vDUyKZXa2Y12jPuPKfy0e7jRHxNKC+mwvIUI6erA92j2NWMg== X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-MS-Exchange-SenderADCheck: 1 X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(2401047)(8121501046)(5005006)(10201501046)(93006095)(3231311)(944501410)(52105095)(3002001)(149027)(150027)(6041310)(20161123558120)(20161123562045)(20161123564045)(20161123560045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(201708071742011)(7699016); SRVR:BYAPR07MB4328; BCL:0; PCL:0; RULEID:; SRVR:BYAPR07MB4328; X-Forefront-PRVS: 07807C55DC X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(6049001)(136003)(366004)(39850400004)(376002)(396003)(346002)(189003)(199004)(36756003)(23676004)(2486003)(8936002)(52146003)(5024004)(76176011)(68736007)(26005)(2906002)(386003)(16576012)(6666003)(52116002)(58126008)(53546011)(6306002)(86152003)(486006)(446003)(11346002)(229853002)(16526019)(6486002)(42882007)(50466002)(476003)(956004)(2616005)(2870700001)(97736004)(77096007)(110136005)(186003)(6246003)(31696002)(6116002)(8676002)(106356001)(3846002)(31686004)(117156002)(478600001)(5660300001)(305945005)(7736002)(25786009)(66066001)(65956001)(65806001)(93886005)(65826007)(316002)(966005)(47776003)(81166006)(53936002)(64126003)(105586002)(81156014)(72206003)(4326008); DIR:OUT; SFP:1101; SCL:1; SRVR:BYAPR07MB4328; H:[192.168.0.106]; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; Received-SPF: None (protection.outlook.com: cavium.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?utf-8?B?MTtCWUFQUjA3TUI0MzI4OzIzOndMRzVINVdqSkh4Tmtjb3RBb2Fsbk9mdmtT?= =?utf-8?B?ajFJUTNuTFZtRGlhZ0J3c1gy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UV4YiznsX4Cn7mDgHbgpcO5BGnH9tyTfE4/pFoCkBIK+yQ5Y8OMuEXXnTY4lqS1PZ1eImKp7eBFDqhY6gcmLIOATtEr18SvFlrQ432XJ5OBceA+VELtpv+P5nrZB5jA==; 5:D9Gj8G5RnVD9qVtSBfln59DP+TSFXy930dZqQrJnUSuRRPSdrVIb29FwiUo59oPv+3IoL1onIdFQofqx0CI8lmRqRoPPcXCuGrTGswU0AcqJXy5ivs9U2+eEiB/8SJXDqLipsekzklwL929cUHQ/MIcYe/akNvpNfPlA9o/h8BY=; 7:5vOoXp+tdMEzmSPIfEQHnRZQd3mHi7MnBqL0lWEhAnOh1OjpuiaQst/1wOl+228kzoeSZNJ7ZAa9w90buwqtMrGNYpxuqFekrm3TbpYFxn7PDJxA5rxpA0603jzCNo5LvJYaYtKymHvV9DRrFEgSHZhp0AVye4nV+syC9AgdfLcePKR6CecQiVCM1USm9T3XyXpzN2I8i6vCc8Fthklmx/viZKTw1f0rc9dZeO2vfSrLbbWPT2T0LtC7d0IndjBC SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Aug 2018 12:59:25.7592 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 0119e96b-f51e-48a2-8bd1-08d60e786b8a X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 711e4ccf-2e9b-4bcf-a551-4094005b6194 X-MS-Exchange-Transport-CrossTenantHeadersStamped: BYAPR07MB4328 Subject: Re: [dpdk-dev] [PATCH] eal: force IOVA mode to physical 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: Thu, 30 Aug 2018 12:59:31 -0000 On Thursday 30 August 2018 05:43 PM, Hemant wrote: > External Email > > Hi, > > On 8/30/2018 3:13 PM, Gaƫtan Rivet wrote: >> Hi, >> >> On Thu, Aug 30, 2018 at 10:09:04AM +0100, Burakov, Anatoly wrote: >>> On 29-Aug-18 4:58 PM, eric zhang wrote: >>>> This patch adds a configuration option to force the IOVA mode to >>>> physical address (PA). There exists virtual devices that are not >>>> directly attached to the PCI bus, and therefore the auto detection >>>> of the IOVA mode based on probing the PCI bus and IOMMU configuration >>>> may not report the required addressing mode. Having the configuration >>>> option permits the mode to be explicitly configured in this scenario. >>>> >>>> Signed-off-by: eric zhang >>>> --- >>> Defining this at compile-time seems like an overkill. Wouldn't it be better >>> to just add an EAL command-line option to force IOVA mode to a particular >>> value? > That is a good suggestion. >>> -- >>> Thanks, >>> Anatoly >> What is the bus of these devices and why not implement get_iommu_class >> in it? > There are cases, where you are using dpdk libraries with external > libraries and you need to change the default behavior DPDK lib to use > physical address instead of virtual address. > Providing an option to user will help. > > More appropriate solution could be: * Either fix it at bus layer .. i.e.. get_iommu_class().. * Or introduce something like [1] --iova-mode= param. Former is better solution than latter if autodetection is a key criteria. Thanks. [1] http://patchwork.dpdk.org/patch/25192/