From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 8BE14A04B8; Tue, 5 May 2020 11:08:42 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 1A74D1D508; Tue, 5 May 2020 11:08:42 +0200 (CEST) Received: from EUR05-VI1-obe.outbound.protection.outlook.com (mail-vi1eur05on2043.outbound.protection.outlook.com [40.107.21.43]) by dpdk.org (Postfix) with ESMTP id CB5701D42B for ; Tue, 5 May 2020 11:08:40 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=PRkDGCZB67c7/9cnii2JbOlHVqYIjvwdLbT2GBD2v/Ucu/51aGl4+9MHrXydxVeqh1Ac0/rJeWdgt9ld2lQY7N7SucGF7ZvxU8sqNppoPgvYGBGrZJURX08BR8x5eoYI0PUPMezHfviGWPs2rcw2jzrl80PG3iVgCxCKS7kCJtD7oVqtfmXnvc0XUKDxUP8BetWg8drr+vdPzv9pS7mebZTzCViNNjCzpYMorF6Dx8vuKTIOYCUV/kZF6eCCTplBJlnuk/g3E2t6rM2AAPOBjmcWYgcwqNp7ata3CcKKCTuZhUx7OsJaUXQKEa70pCA225PJludGM+1O9HVIy2YNCA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=IRRW2P/F3fOULYckYlj26EjjtgBWLWR6DlYxfjxemM4=; b=hDkg5kSEHcGElnuCfyByMUGfZppY7NEkCqIWPHpc+SQ2I61G49SwlotCbvXfieGgSteNQQl0dGkmYCORkTnTGQS5jW3ejk5LBa8zwk6bebOl1MWJjZ6zrSF5NZkSoCqiBl3OJP7CIHWQFIHoLsY/02/3amHDECI1TYxRci9KmAz+ljFWQsvd0ePkoVgJTLE3e42UrfvBxguSQUt7qMdleq1xHQV6zWl+5TYDQCEib/bkqpbKZfZXBhZ+XQ3DBWoccX3cGAPithchNA0MppipU80/i2c4YQu6FvEFhEcu/k6Jgw0yr+OXlMEzReMhMOkqZyXMIMU9KOYHCAsjA4LUWQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=mellanox.com; dmarc=pass action=none header.from=mellanox.com; dkim=pass header.d=mellanox.com; arc=none 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=IRRW2P/F3fOULYckYlj26EjjtgBWLWR6DlYxfjxemM4=; b=mmro9uhly7OIMv0g/mrhIyrSetaCidhnt6W+aa1lWPBuFaiDdbsXzSgvKouRpLlAgDCmD5O3iZsRpigk+xf3W9lX2xbP2y9YvaOnont/2FFkPb6rREBHHcnUIUrvW+OtEm8tCHTtBCNfIfRTvsK3WAobcKPylQAYZAwtLHBGzXo= Received: from AM0PR0502MB4019.eurprd05.prod.outlook.com (2603:10a6:208:f::11) by AM0PR0502MB3922.eurprd05.prod.outlook.com (2603:10a6:208:1a::33) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2958.29; Tue, 5 May 2020 09:08:39 +0000 Received: from AM0PR0502MB4019.eurprd05.prod.outlook.com ([fe80::a564:a117:9022:1fee]) by AM0PR0502MB4019.eurprd05.prod.outlook.com ([fe80::a564:a117:9022:1fee%7]) with mapi id 15.20.2958.030; Tue, 5 May 2020 09:08:38 +0000 From: Matan Azrad To: Ophir Munk , "dev@dpdk.org" CC: Ophir Munk , Raslan Darawsheh Thread-Topic: [PATCH v2] net/mlx5: fix resetting verbs hash fields Thread-Index: AQHWIqTOWJiQE7AI5kyUN/VNTyaHHqiZNChA Date: Tue, 5 May 2020 09:08:38 +0000 Message-ID: References: <20200504063851.25030-1-ophirmu@mellanox.com> <20200505061607.15978-1-ophirmu@mellanox.com> In-Reply-To: <20200505061607.15978-1-ophirmu@mellanox.com> Accept-Language: en-US, he-IL Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: mellanox.com; dkim=none (message not signed) header.d=none;mellanox.com; dmarc=none action=none header.from=mellanox.com; x-originating-ip: [77.126.88.104] x-ms-publictraffictype: Email x-ms-office365-filtering-ht: Tenant x-ms-office365-filtering-correlation-id: 6748fc36-882c-401f-ed64-08d7f0d3e657 x-ms-traffictypediagnostic: AM0PR0502MB3922:|AM0PR0502MB3922: x-ld-processed: a652971c-7d2e-4d9b-a6a4-d149256f461b,ExtFwd x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:390; x-forefront-prvs: 0394259C80 x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: jZcTNe3ChVlJywxb26jTmSEynbkXyAuFjtdwbzW2oFyXI+Tw9R3JAZPk+x1hL40EzLqYMAJuuqLeKUuMe/qpTUSl9egJxBrahrQpuggDXoTeSJzPjnwWz70fl2ubmn6A89QYSdhdUZ2njo0SIrZZhjmzozJHOC2q48/CM8xT1wjgGEVylExmuD/KS1ksf5PbWB8ommswrol9lksilWI0c1YmE9pGpINJDymzzFxtd8JXgWTqbSGWaPHkYbakzv5OJQS0Huuxy/fn8PJYoEDKWTunbKKuNbupXTIzLYyqhE0FS44JaovlF3uMQ78LWMNNAt+gASxL3iiLd8+hEhg3PIXfj7bkLkDBR/pZmxv3nkEBHgXVdZcH3NZ1x2HTvGSIZOyVCDzUGNxlTfJeAI3QiqIxGIPwDydmlXcO1e7oTDga1ut70ufVQNynqbY+yQ8Oik2JTy1zLtuFY29Pirceaq9uO52xBoTYOqpMrCn+ULvxas5ABWCxVMKmIyiSFmITZ/RVrryFGL6Ma3uU9ydQgA== x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AM0PR0502MB4019.eurprd05.prod.outlook.com; PTR:; CAT:NONE; SFTY:; SFS:(4636009)(39860400002)(136003)(346002)(376002)(396003)(366004)(33430700001)(33656002)(64756008)(107886003)(66556008)(76116006)(110136005)(66476007)(66446008)(33440700001)(54906003)(316002)(8676002)(186003)(26005)(7696005)(53546011)(8936002)(6506007)(66946007)(52536014)(86362001)(9686003)(55016002)(478600001)(5660300002)(71200400001)(4326008)(2906002); DIR:OUT; SFP:1101; x-ms-exchange-antispam-messagedata: Xxj8bqLXJ0EdvQIa0IpP5n1I1IM/IayKH9Xxz7zrYy1lvBGhrP5mU9YKeI+/LHTAT+VKrrWf4EVGz2nS+wSsDCGusoofNiHoqMW+YNYG4m9lS9QqL1YG3slVv1CkNcy2G4V1AfbwWXmmwqVcPzehJXvlKWg9hZhG8pVeI/eVuQj1ts2ls6mDJ339lbYEeADArrQdudVMObYSSlpMDRgUfEMFpc+wPnfiJGkw3XKnluH3DtCQPCiMZuyXIIMqY11M54uN/V/BsoK74Ri9fIwfJXxOiGL9UCnsXxhZNe4tXWbMd0nb3GZr340/eYxZvUIHeif/5UPsCdjM5GVK0h89xb7GPbWg3csG+DoilloCeixD5qw/csFck0AE9tuc5Hf5v/4q8NGGX5Q49GrPilf2gqOQl3neLVvnlN0pEiHko3KYIfgob95EsSja2imYJnWigSIKaawXYV4zMl3BLnSOBFheTenHmaAcyzxEdabcMmnWIpxtYvK3UnoRPM3aCk7uTlsizUu11Q19+4jV181VjnTCDuKNIhS772qLRmG3i2uS/Ukn/2FjYo34L0YwwBxu86vNwbnZ/TInUEg5v0VukK0JhNpMZz6pQUXq10Hj94ru181pxVevJT34qv+vvTHuOZddFSIWKmcOkQohXBmNhuIBGCOYVXgwIzxHWBhK7biH+eH0YqO0mYEtHV21uY8HKRZs4ZOk14e2plU31e53w0rWOnKfnEcYWp5XL/ej8pLzsRzqA4/GbzywUu9e8irCZRYkeFWzBapJPUgfNdwbpH+H4h8o+Bu7V2rHbfJ2PIU= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: Mellanox.com X-MS-Exchange-CrossTenant-Network-Message-Id: 6748fc36-882c-401f-ed64-08d7f0d3e657 X-MS-Exchange-CrossTenant-originalarrivaltime: 05 May 2020 09:08:38.8828 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: a652971c-7d2e-4d9b-a6a4-d149256f461b X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: guzjcwCut/cmWTApGC5/4o2/O/e9tTvhMS14LI7n7r97wO4PWHVXiSu43dbj54XzDioVDYDxRRua100zqhA/DA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR0502MB3922 Subject: Re: [dpdk-dev] [PATCH v2] net/mlx5: fix resetting verbs hash fields 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" > -----Original Message----- > From: Ophir Munk > Sent: Tuesday, May 5, 2020 9:16 AM > To: dev@dpdk.org > Cc: Ophir Munk ; Raslan Darawsheh > ; Matan Azrad > Subject: [PATCH v2] net/mlx5: fix resetting verbs hash fields >=20 > The flow_verbs_translate() function accumulates hash fields while iterati= ng > through the flow items (SRC_IPV4, DST_IPV4, SRC_IPV6, DST_IPV6, > SRC_PORT_TCP, DST_PORT_TCP, SRC_PORT_UDP, DST_PORT_UDP). > Before this commit the dev_flow handle structure was reused in each new > flow_verbs_translate() call, however the dev_flow->hash_fields variable > was not reset before each call. As a result hash_fields from previous cal= ls > remained present in the current flow which lead to invalid combinations (= e.g. > simultaneous IPv4 and IPv6 specs). This scenario happens for example in t= he > next flows sequence, when running in verbs mode (dv_flow_en=3D0). >=20 > flow create 0 ingress group 0 pattern eth / ipv4 / end flow > create 0 ingress group 0 pattern eth / ipv6 / end >=20 > The fix is to reset dev_flow->hash_fields in flow_verbs_prepare(). >=20 > Fixes: e7bfa3596a0a ("net/mlx5: separate the flow handle resource") >=20 > Signed-off-by: Ophir Munk Acked-by: Matan Azrad