From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.6 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, USER_AGENT_GIT autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5A787CA9EAE for ; Tue, 29 Oct 2019 18:51:03 +0000 (UTC) Received: from dpdk.org (dpdk.org [92.243.14.124]) by mail.kernel.org (Postfix) with ESMTP id DB0CB20830 for ; Tue, 29 Oct 2019 18:51:02 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (1024-bit key) header.d=monjalon.net header.i=@monjalon.net header.b="FBnCaKgX"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=messagingengine.com header.i=@messagingengine.com header.b="crmw7iUo" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org DB0CB20830 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=monjalon.net Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=dev-bounces@dpdk.org Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 410F71BF71; Tue, 29 Oct 2019 19:51:01 +0100 (CET) Received: from out4-smtp.messagingengine.com (out4-smtp.messagingengine.com [66.111.4.28]) by dpdk.org (Postfix) with ESMTP id 61AB71BF45 for ; Tue, 29 Oct 2019 19:50:59 +0100 (CET) Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id D776421C39; Tue, 29 Oct 2019 14:50:58 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute1.internal (MEProxy); Tue, 29 Oct 2019 14:50:58 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; s=mesmtp; bh=EG5G5wz3MT OVtOG2bZzizdMJuHJBcPoe3ye4FLFl2Ys=; b=FBnCaKgXYzRllmmPIcVoOdxnAf nGfUiFVmrP1ssOjrF/ft4SnI9yep1ExVg+6TFKegUQcH4c2LwIvPEX3N71j27rna bgQkLPV6Cwnu6HQWiKAFuPVAXbHEIIHn+KHQi6RBEPKXWR6zTjRDQW3ODDcXrNwe b14+ds8XpHEzE6lwY= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:date:from :in-reply-to:message-id:mime-version:references:subject:to :x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s= fm1; bh=EG5G5wz3MTOVtOG2bZzizdMJuHJBcPoe3ye4FLFl2Ys=; b=crmw7iUo yPuNZibr1hF2uQ+ylizb04PNIzrGUmQCjp+AaYr4w2vA2vLE7SrvtSCu57XMf5f1 YbQBNwu8BSyIJrAFqLe2VW99Py/Nonmf696HfM2hcTOE1m/NFMtw9feisHxQbE8c xlKqk+Eocbfhm6pPtYsTGk/ETzgmLrjnHAY1kg3fI9dKC+1CUi/3vsEB7rJNNQQb r9akDW9fvS29+SVJxz7ah0k1SRNMeJwYG1SQTUe3Q+4rHZx2hQDMGW6KK8RLOhfY XxVMaDAWh4BkvIK+aZ/pDd7pF+ZO07IOTGcQ5fmwlleo+lPGKd7FUM4rW3ZblqEG Q4610+99nvhGLg== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedufedruddtuddgudduiecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfgh necuuegrihhlohhuthemuceftddtnecumhhishhsihhnghcuvffquchfihgvlhguucdlfe dtmdenucfjughrpefhvffufffkofgjfhgggfestdekredtredttdenucfhrhhomhepvfhh ohhmrghsucfoohhnjhgrlhhonhcuoehthhhomhgrshesmhhonhhjrghlohhnrdhnvghtqe enucfkphepjeejrddufeegrddvtdefrddukeegnecurfgrrhgrmhepmhgrihhlfhhrohhm pehthhhomhgrshesmhhonhhjrghlohhnrdhnvghtnecuvehluhhsthgvrhfuihiivgeptd X-ME-Proxy: Received: from xps.monjalon.net (184.203.134.77.rev.sfr.net [77.134.203.184]) by mail.messagingengine.com (Postfix) with ESMTPA id 3EA99D6006A for ; Tue, 29 Oct 2019 14:50:58 -0400 (EDT) From: Thomas Monjalon To: Cc: dev@dpdk.org Date: Tue, 29 Oct 2019 19:50:48 +0100 Message-Id: <20191029185051.32203-1-thomas@monjalon.net> X-Mailer: git-send-email 2.23.0 In-Reply-To: <4165509.5enYigmRGf@xps> References: <4165509.5enYigmRGf@xps> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-dev] [PATCH v2 0/3] ethdev: configure SR-IOV VF from host 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: , Errors-To: dev-bounces@dpdk.org Sender: "dev" In a virtual environment, the network controller may have to configure some SR-IOV VF parameters for security reasons. When the PF (host port) is driven by DPDK (OVS-DPDK case), we face two different cases: - driver is bifurcated (Mellanox case), so the VF can be configured via the kernel. - driver is on top of UIO or VFIO, so DPDK API is required, and PMD-specific APIs were used. This new generic API will avoid vendors fragmentation. Some PMD-specific API could migrate to this generic model. As an example, the default MAC address configuration is demonstrated for a VF mapped to mlx5 representor port. As it breaks the ABI, I propose to merge this API in DPDK 19.11-rc2. I am sorry I had not send a patch since proposing a RFC in August. (I gave priority to the summit and the -rc1 release) Thomas Monjalon (3): ethdev: identify SR-IOV VF from host ethdev: set VF MAC address from host net/mlx5: set VF MAC address from host drivers/net/mlx5/mlx5.c | 6 +++ drivers/net/mlx5/mlx5.h | 1 + drivers/net/mlx5/mlx5_mac.c | 19 ++++++++ lib/librte_ethdev/rte_ethdev.c | 55 +++++++++++++++++++++--- lib/librte_ethdev/rte_ethdev.h | 38 ++++++++++++++++ lib/librte_ethdev/rte_ethdev_core.h | 1 + lib/librte_ethdev/rte_ethdev_version.map | 1 + 7 files changed, 114 insertions(+), 7 deletions(-) -- 2.23.0