From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f65.google.com (mail-wm0-f65.google.com [74.125.82.65]) by dpdk.org (Postfix) with ESMTP id C793D2BFA for ; Fri, 13 Jul 2018 11:40:52 +0200 (CEST) Received: by mail-wm0-f65.google.com with SMTP id s9-v6so869555wmh.3 for ; Fri, 13 Jul 2018 02:40:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=ZCrDcYYHpVXorjSoNz1WGWRX4qGYVF1LAOHCur08Wb4=; b=DjfaRDVbTAcjft9huMMhG1lOzcANDWkWX1ifMf3xop0tH9A3ed6KGy8r8g89tlV9+r HpuuS4Yp1+iHVTsXdPzmusKChRACZ0OnEdYyrTIi8UjRwfhy2NVeLiAyOemHmkdXQxI7 L9G18AdIsBPzV2SNEuE32mbbnhL0+xjdMrV6MFThIhiYaUOZ/ylchHE0uzYTdbN2ue4J HF4p48AGZ1k7XZ2kyDdQjmdV9prHoJsUTJ/rnh8saWefciTmfIQSm3/CVuhN7YEC7Wap rRP+piUf/6lwmTsq9qKgCboEi0+DH9ogyeJGmWaiMl4uIuYjPLl/+3bw0BbvKqNddexv fKBw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=ZCrDcYYHpVXorjSoNz1WGWRX4qGYVF1LAOHCur08Wb4=; b=OLKHzlAZQI/+0blzulO7tAk4XDbWk6IGZq5hkBmXakq8+R+56EpO8flJaNkU/H6KBq Jg8erWkG9QO+vGYo8hviz+CQdvuq74N0Tqh8AmxW1xmyXgSl9gmIpJbfAyXLCPpTRXIN gRnRo5dt3kf/TQ8SrCfVFKIAYJ4xrBAs+6CzaKdFm70F5vb9+fqwzHogZY6gbCuq9teN N9NanTGV0rXvkzcHKpKAJPB7s+q0yNDsbglaY8kMKu0wzBgXeCc4DnPZCMsLov/iUiqS WLPXPPWyIsG75i3SDik3LbkftC3mU4jXYP7DA2oDo6uonftEWOQzmz1KhmRZrZJcTD6R RBoA== X-Gm-Message-State: AOUpUlGYdPhJ7DIhylZlKvCXNaFUxrjItiLqtFYUajMhNYioOxylhckx z5rCGrm35W7549gnu0Gu5/FuuA== X-Google-Smtp-Source: AAOMgpfsDZeYYmEY0Y2LMFHPScDMHaOprIwVmF5dJC/F6dcbBocfph9zJkAauJHi8ns0M9eL63Funw== X-Received: by 2002:a1c:180e:: with SMTP id 14-v6mr3570131wmy.120.1531474852566; Fri, 13 Jul 2018 02:40:52 -0700 (PDT) Received: from 6wind.com (host.78.145.23.62.rev.coltfrance.com. [62.23.145.78]) by smtp.gmail.com with ESMTPSA id i125-v6sm3188340wmd.11.2018.07.13.02.40.51 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 13 Jul 2018 02:40:51 -0700 (PDT) Date: Fri, 13 Jul 2018 11:40:35 +0200 From: Adrien Mazarguil To: Shahaf Shuler Cc: Nelio Laranjeiro , Yongseok Koh , dev@dpdk.org Message-ID: <20180713092910.26276-1-adrien.mazarguil@6wind.com> References: <20180627173355.4718-1-adrien.mazarguil@6wind.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180627173355.4718-1-adrien.mazarguil@6wind.com> X-Mailer: git-send-email 2.11.0 Subject: [dpdk-dev] [PATCH v2 0/6] net/mlx5: add support for switch flow rules 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: Fri, 13 Jul 2018 09:40:52 -0000 This series adds support for switch flow rules, that is, rte_flow rules applied to mlx5 devices at the switch level. It allows applications to offload traffic redirection between DPDK ports in hardware, while optionally modifying it (e.g. performing encap/decap). For this to work, involved DPDK ports must be part of the same switch domain, as is the case with port representors, and the transfer attribute must be requested on flow rules. Also since the mlx5 switch is controlled through Netlink instead of Verbs, and given how tedious formatting Netlink messages is, a new dependency is added to mlx5: libmnl. See relevant patch. v2 changes: - Mostly compilation fixes for missing Netlink definitions on older systems. - Reduced stack consumption. - Adapted series to rely on mlx5_dev_to_port_id() instead of mlx5_dev_to_domain_id(). - See relevant patches for more information. Adrien Mazarguil (6): net/mlx5: lay groundwork for switch offloads net/mlx5: add framework for switch flow rules net/mlx5: add fate actions to switch flow rules net/mlx5: add L2-L4 pattern items to switch flow rules net/mlx5: add VLAN item and actions to switch flow rules net/mlx5: add port ID pattern item to switch flow rules drivers/net/mlx5/Makefile | 142 ++++ drivers/net/mlx5/mlx5.c | 32 + drivers/net/mlx5/mlx5.h | 28 + drivers/net/mlx5/mlx5_flow.c | 111 +++ drivers/net/mlx5/mlx5_nl_flow.c | 1247 ++++++++++++++++++++++++++++++++++ mk/rte.app.mk | 2 +- 6 files changed, 1561 insertions(+), 1 deletion(-) create mode 100644 drivers/net/mlx5/mlx5_nl_flow.c -- 2.11.0