From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from EUR01-HE1-obe.outbound.protection.outlook.com (mail-he1eur01on0044.outbound.protection.outlook.com [104.47.0.44]) by dpdk.org (Postfix) with ESMTP id BFA2DDE3; Thu, 24 May 2018 19:57:25 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Mellanox.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=KTySTrCN7FQKE2ysmhQt7lN7+T2zn8AXRMhTVQl/h4I=; b=hDhgUieyPqSh/NTH3WKQQgDjqIOgrkfkUtXbxM9GUWxz31t+SjERm6EwqfrTLZbnKmmcUx+hrLhiDeKVS9wmQXqPGjgdj6r5IcxQAxQXKjyHF52UvvDK3iZDWWoPonfTvxI7xn1dySS3fDa33LzgOkj/5WaC8cbWZPa7jrajaRY= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=yskoh@mellanox.com; Received: from mellanox.com (209.116.155.178) by AM5PR0501MB2033.eurprd05.prod.outlook.com (2603:10a6:203:1a::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.797.11; Thu, 24 May 2018 17:57:22 +0000 From: Yongseok Koh To: adrien.mazarguil@6wind.com, nelio.laranjeiro@6wind.com Cc: dev@dpdk.org, shahafs@mellanox.com, Yongseok Koh , stable@dpdk.org Date: Thu, 24 May 2018 10:56:48 -0700 Message-Id: <20180524175648.14255-1-yskoh@mellanox.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20180523015157.35716-1-yskoh@mellanox.com> References: <20180523015157.35716-1-yskoh@mellanox.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [209.116.155.178] X-ClientProxiedBy: CO2PR04CA0154.namprd04.prod.outlook.com (2603:10b6:104::32) To AM5PR0501MB2033.eurprd05.prod.outlook.com (2603:10a6:203:1a::19) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(5600026)(48565401081)(4534165)(4627221)(201703031133081)(201702281549075)(2017052603328)(7153060)(7193020); SRVR:AM5PR0501MB2033; X-Microsoft-Exchange-Diagnostics: 1; AM5PR0501MB2033; 3:+QxCB1gEA7YsAOy3yyfl7I9p5ozEWRp4AkOJF221XzlbvG5n2FmmknRKZMQOdO3MGmbnQUr9q0E2EcQg1lyuv2UNiWGXfqvXWC+wDsIaMplt+RO9pGSV/quG4X324B7FkxfBZsc5+5twpgHw/DuuhXX3KsHxJRu4fsAnTpML6sBpasEfcff+H6j4V+0WKmpU2xO/msD3ZR5XC00RvfHefsE9HnoOcKgoipLILykn8c+cZslDrRQucGRcruNl6tIl; 25:DDITaQ1kuOipkahO6XlivihshJStubRKI7jH9hd1vFm78qUdFck8XxyqIp7mSSm29Dm5AIvmfHvTaKCCLgLlpYxJRywuTh1NofKHWa5cD8uRgohIWh3l+LI778L51XMIleb8v8qX+xv5Dcw0p6OtD6CNVhXUBoU9xOG2i1j+O6x05jPq1FAakN7QIhz6fwiO1y8cdu6bOEO0WatLlWPaDUYJyiiWW2I+flutghG6AsogY2a+mXKNWQ0SS5fhzyhd3eNxmeD/nDw7vwGGGEo2nwykt3szzaIZUmnrNeWyIOZCyrTCAXwVs/RKKKKiQDxpmA/SLTbE1KfyLUtxLncQWg==; 31:P1NfKBjBjxW8vF6moHt42dClZg3kLnkoLVJMAN+puzX8440CiK+XobUzvTHIOB+D5PmKTuKzQCSvamVKtxHSm9Lz/dpVfvCV6yjYGhMVj4g753CzHFvDaJnXBTzSHaYq9GFJ9bK0azodTsDxJtHLeBYxfYzOdlsmQdWZ+uJXTnvxYCdeBdtQoiwa5Ci4PVOZsttaYJlHMOjiCDKiVtaATPkc0xcIJq+vL5wGS4uKqKs= X-MS-TrafficTypeDiagnostic: AM5PR0501MB2033: X-LD-Processed: a652971c-7d2e-4d9b-a6a4-d149256f461b,ExtAddr X-Microsoft-Exchange-Diagnostics: 1; AM5PR0501MB2033; 20:PRiN2k9CfQZuN0Ezaf7xZ1mT1TumVf2ymEhdXOBg7hGQCGEBhpha1bFc3eYHg5lpCX3+StUSiTxPTnls6pAdGI7/Gi1qhjBaVVYmP0VagDvtfLrFAYYv/emVUEwXO0jRgxnb8h/ycO27Q2gIztA2Hl7NNq+Q60bWiKYTS6F5uPlgaKW0bW/7fk9QPfbaG10ch7AHdvoIYgt8NSNRNkW8t7ryrEpUKwclHo4Q7USNRjHCRwyPVpu1aCFDorg4bDtNCony2iEdTWqg+8nMIXB6z93AMIxWu9M2dlAqVKpECKyrOmhMBNFmVLEhmIMtA9J14vi0PF4gSMLgqBAPKcYs9+14c9tPONJl37Elg8UtJqrVodhpTjD8Iec7LyV3gzDJmb/JCY6hzVxZN09B+Rds44JINQnDb0YJgEw0pUWMax2Fl2FjFdhKeQkZa04cJrZxSBkRKKuSoMhKu4oe36eK/s9cxj0TeV44r40Lj2zkke2C/pJ3v60y7xmxiMWMehOi; 4:IZJbS/tcFcsgedFzZX5kBDGjbzCezNuHu9jvXkddPbVaOa0lEoHg9ePhqg40jGViEWKyQBaBXfhRvLbV3mSnC+mr1zZMckgmEokFH4BDNw5Wq0S31wRFGv4wvcZKKMEEeFeC73X69gYzfcWfgRgb5GWotvp1skvK4OFjpHynzxMvI2BaR2NH0KwzkM/NYlne75hjKWtZSycOR5eqgRTteFYqQOnwtg0OphhaGg48QBXrWQ7RZ3SgyZpkc9iJgCfxwuIIkpM+n2+6RsdOxJT0xg== 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)(5005006)(8121501046)(3231254)(944501410)(52105095)(3002001)(10201501046)(93006095)(93001095)(6055026)(149027)(150027)(6041310)(20161123562045)(20161123564045)(20161123560045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123558120)(6072148)(201708071742011)(7699016); SRVR:AM5PR0501MB2033; BCL:0; PCL:0; RULEID:; SRVR:AM5PR0501MB2033; X-Forefront-PRVS: 0682FC00E8 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(39380400002)(366004)(346002)(39860400002)(376002)(396003)(189003)(199004)(575784001)(86362001)(386003)(6666003)(16526019)(5660300001)(316002)(486006)(36756003)(76176011)(26005)(478600001)(68736007)(21086003)(8936002)(186003)(16586007)(50226002)(69596002)(25786009)(6116002)(55016002)(52116002)(48376002)(7696005)(51416003)(446003)(3846002)(11346002)(105586002)(81156014)(97736004)(305945005)(106356001)(81166006)(476003)(4326008)(1076002)(7736002)(66066001)(2906002)(8676002)(2616005)(53936002)(50466002)(47776003)(956004); DIR:OUT; SFP:1101; SCL:1; SRVR:AM5PR0501MB2033; H:mellanox.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; Received-SPF: None (protection.outlook.com: mellanox.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; AM5PR0501MB2033; 23:gmUIZzdKr6IeXRahJ93y8sfjnIvJ2Az66CgVzKr?= =?us-ascii?Q?9JkQimm4tFn1prf+nMJqSG5kBlIYys4S1WmvgIBH35Cr/x6JI5Aex6GVuKo3?= =?us-ascii?Q?N+mbshGT2KTWbsSr/0ysU6vBmG/0AfQmBVjnR0Q0G88lbUp/XhPQp89iiebD?= =?us-ascii?Q?60TIZj3e6YJByMNmHZovYI7XmcHG36yeVFt8GP/u88cZPcY3Wn5Kex4w+GWn?= =?us-ascii?Q?wiQDVXjYXpYjcT34idaQTKPkfDA8mr4Mu5pMJusEhEE2yBlm9J96sFN+b2Qy?= =?us-ascii?Q?Cqm3DFlFxj+pl8RRMKRkNkglymKHc0rKguU9tB3CSy29uHIWU917p3nfBZey?= =?us-ascii?Q?oAu8Mo0sdFUjc+7kbiLa8sU9tveETvSTMJm7YmoH7ig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soft-Antispam-Message-Info: 7xWNh0fXnVXZp2tO3ahve58/E7QfVjigGNhLSWPwqcwrnOhrOPl3I0n36wDf0stu1/B596jVFS5n6MDVLIxiDLLTeSokzWpWnkv+K9hLqMTRBFp8wxSsjRuD+yrE9cuhKftUSKu5FMebnLo/Xnq5px6QzKlwH2myrOs/RzOMdJfhdNxQApSlGK1it2ZUz6J6 X-Microsoft-Exchange-Diagnostics: 1; AM5PR0501MB2033; 6:VGNQZIeUU2Soj5oeBThlgD09kS3DvsFRMqq5zNQ35eUBZjxOnvK0XooMMv5dID1iEn4emW7Vpb9TzLfK/XOr2qyc1om77+Vc5DRLT9g4UIPDA4tm+gqPemqdR7C1A9tzGzI6pbrX0AxCz2LQ2ulHXgMsHlm9B5UofCLtFYFXoRE4mFp52HoXA4miXQkxE7M1xrxtLrywFiOPP3KtRqdPdOOSsJAQ1Qn2h+HMOeehBbuQDYeInXkJHNe5OEl75Z3xoPYkgpBvh6CV6NIs4r8KSvyuSltQfW1XPt0IXLFoEHSHIr9kM4HDTe6hC2cRPXupy9JKBXluW4Ppzy9OJSPBwZudjQh+5R8h6r5UoKwW61tbI4PshqEGiv50qTDdjbfVZIe7BNfvjksa4Bcm2Utmg5lhvXzBqfltngbzHYfo72pIv+tcJpYfiDd5R1WWQn/okPcFwSXu8gzqwCmD/toRGQ==; 5:+xoHO0gjuE+zdCMegs/1S4U47Rqz5B7bWSudcRM+2tbDYfj/dgQnTFVEUt5ONPvOoieOlNU5vPkeowJoikJT7LhrPZJLKKxYGtsm23RIJN1yV8lmO4Ypx0vp5oVB7gt/2S+ccy5ToZ3L3fYOshww+ah4sg80aa5+dtNWU1ZnlKo=; 24:IL/yd73w7Xb4TxKXEIJxwLe9mAyQMmEhbm2fEHodadOJiRCoU3aemzfKbLsTJ2pgY+zpii5xjl7nPKnljCDqhEvkFT5WU9Xj5qzBkIifNMo= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; AM5PR0501MB2033; 7:2gQXNhyMxIFxatgf6iYJ5nJrpzOFkGQESez6c9XAKFsgzFyG090sxtq7r9fifOpR8cXC0UhmE1ydAVwMpt91Lz5y8Yy04XloM7YoVsZFD8/MbrukZhmZKF+ONP47synIjLZaFOdGwntkomMe042p78Zfsmx865SGY1aGfMl0Dnic9M+/5L4afCfuR18U4Ivze+wZCub/JCRJWxz4vvGDXEwCYD4N61y0v11A+MNNFLzlilQObq4iu8n8Rw8Kdc0p X-MS-Office365-Filtering-Correlation-Id: 1f5293e8-77b1-41f9-7b86-08d5c19fcd8f X-OriginatorOrg: Mellanox.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 24 May 2018 17:57:22.1545 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 1f5293e8-77b1-41f9-7b86-08d5c19fcd8f X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: a652971c-7d2e-4d9b-a6a4-d149256f461b X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM5PR0501MB2033 Subject: [dpdk-stable] [PATCH v2] net/mlx5: fix GRE flow rule X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 May 2018 17:57:26 -0000 Creating a flow having pattern from the middle of a packet is allowed. For example, testpmd> flow create 0 ingress pattern vxlan vni is 20 / end actions ... Device can parse GRE protocol number in outer IP header but specifying from GRE header can't differentiate it from VxLAN tunnel. As a result, the following rule will be interpreted as a wildcard rule, which always matches any packet. testpmd> flow create 0 ingress pattern gre / end actions ... Fixes: 96c6c65a10d2 ("net/mlx5: support GRE tunnel flow") Fixes: 1f106da2bf7b ("net/mlx5: support MPLS-in-GRE and MPLS-in-UDP") Cc: stable@dpdk.org Signed-off-by: Yongseok Koh --- v2: * amend commit message. * remove GRE entry from the head item regardless of HW support. drivers/net/mlx5/mlx5_flow.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/net/mlx5/mlx5_flow.c b/drivers/net/mlx5/mlx5_flow.c index 994be05be..adb995f0d 100644 --- a/drivers/net/mlx5/mlx5_flow.c +++ b/drivers/net/mlx5/mlx5_flow.c @@ -331,8 +331,7 @@ static const struct mlx5_flow_items mlx5_flow_items[] = { [RTE_FLOW_ITEM_TYPE_END] = { .items = ITEMS(RTE_FLOW_ITEM_TYPE_ETH, RTE_FLOW_ITEM_TYPE_VXLAN, - RTE_FLOW_ITEM_TYPE_VXLAN_GPE, - RTE_FLOW_ITEM_TYPE_GRE), + RTE_FLOW_ITEM_TYPE_VXLAN_GPE), }, [RTE_FLOW_ITEM_TYPE_ETH] = { .items = ITEMS(RTE_FLOW_ITEM_TYPE_VLAN, -- 2.11.0