From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from EUR04-HE1-obe.outbound.protection.outlook.com (mail-eopbgr70042.outbound.protection.outlook.com [40.107.7.42]) by dpdk.org (Postfix) with ESMTP id 2B6501E20 for ; Sun, 7 Oct 2018 17:38:08 +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=F1mSqgfcyoNlaGzF9qZ2wWBKe1so5FvL6WxfmP+6uMo=; b=uqE7dxPjdjoIUvj0DDN1VQxl0l4fEM2R30u9wDYJDYRnQmnxIAQmcrkLSTIctDvcWxyDPZy7nMciHNNJbPRT8HMRBhAiyYlIbj2cP4jBBmQGdmG86Pn8d62bh1XF1O3xrM+cIfADVnfNX9mno2fI0L6IfviS3ycta2h/SHdVbwc= Received: from AM0PR05MB4435.eurprd05.prod.outlook.com (52.134.92.20) by AM0PR05MB4481.eurprd05.prod.outlook.com (52.134.92.30) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1207.23; Sun, 7 Oct 2018 15:38:06 +0000 Received: from AM0PR05MB4435.eurprd05.prod.outlook.com ([fe80::2549:a872:4864:b84e]) by AM0PR05MB4435.eurprd05.prod.outlook.com ([fe80::2549:a872:4864:b84e%6]) with mapi id 15.20.1207.024; Sun, 7 Oct 2018 15:38:06 +0000 From: Mordechay Haimovsky To: Adrien Mazarguil , Shahaf Shuler , "orika@contextream.com" CC: "dev@dpdk.org" , Mordechay Haimovsky Thread-Topic: [PATCH] ethdev: fix flow API item/action name conversion Thread-Index: AQHUXlO9RtCMayM8HkejXrqNTu8aRw== Date: Sun, 7 Oct 2018 15:38:06 +0000 Message-ID: <1538926667-23009-1-git-send-email-motih@mellanox.com> Accept-Language: he-IL, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: DB6P193CA0021.EURP193.PROD.OUTLOOK.COM (2603:10a6:6:29::31) To AM0PR05MB4435.eurprd05.prod.outlook.com (2603:10a6:208:5a::20) authentication-results: spf=none (sender IP is ) smtp.mailfrom=motih@mellanox.com; x-ms-exchange-messagesentrepresentingtype: 1 x-originating-ip: [37.142.13.130] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1; AM0PR05MB4481; 6:k1M/xyl5QimErveigkkOzhYrmpBT8a1yRupY/usLLNjld4sa9aNcNklZ5vUyIOVw4vLXgyrvRUtDtGUBvRg+UFEX20ArnMG4c83Unp7aZnVH7jYk9ARqStqVCi8OPyEcG6Vu7z2b1AACnjOijFwF5la/FtDM0NwCW/n/JE8mGqoem1L0e4qghvzPQtf8Ny9HfAKn9o0QVngWWMrIQkXyfQg2EFYGj/5AJycGfY6N91FNIG+2pJ/lg3oto7PGBeOPvi+zPe0szrgsUAbgNR7+y2NAsmuSu9xFE+RrmzlJkARK/phYpAnd9VJECIAmyeJqT5YiUipvY9BxRSmHZok693MoOk8IrWmaAJZvEMiNK2yYdQwlYP5vZEn3l2vqbvfwCanXHBzNtduR3RbCy7CICUIXv2j197e5G+fAu5AC4BAO8bxzbMBYWxDS0kSLBA7kCcwQtER1KDZ9L8G0eT5H1Q==; 5:KHS35FsrSKF4ac7P9bVNrwmK2Sy60o7tN0jLxDsBVPUmLW4ffaGpLN3Vdqr/ltJw+qMRjs2gM0wSIrNIf/bGZA0P36DBxZXxHeqZgVAUnBPDxoL13AXyDwEhoRQdLkzBdJra9/6+QB2oE8/QCBIxYJjrD7eoB5MNEAiHORKXcjg=; 7:UWNiCcf5nyrLJcJ2q2tLmhLxoJyI2Ol/f2QXjKnKE7440PRw7RYwSnTmdlhAHSjiiNSdwmzIKSOLvGqXG/bBG2ddAcqpJ6sncGI7h1rIctIdui/8DEpmAnJ/LNkhUctVD5AOzCy5C59mvcHDb7pS5YmRyatqasSwF6CId4ZitYuywqvxSjvO2LRCCp0rAsFYrI/cQ16WhNDE79s96l2JwwgegyPQ8wWOkgviFfvwJKEI8KcFq01uYBqwDF4DAmgz x-ms-office365-filtering-correlation-id: cff04e04-34c6-4fd0-8b21-08d62c6ae01a x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: BCL:0; PCL:0; RULEID:(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600074)(711020)(4618075)(2017052603328)(7153060)(7193020); SRVR:AM0PR05MB4481; x-ms-traffictypediagnostic: AM0PR05MB4481: x-ld-processed: a652971c-7d2e-4d9b-a6a4-d149256f461b,ExtAddr 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)(93006095)(93001095)(3231355)(944501410)(52105095)(3002001)(10201501046)(6055026)(149066)(150057)(6041310)(20161123564045)(20161123562045)(20161123560045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123558120)(201708071742011)(7699051); SRVR:AM0PR05MB4481; BCL:0; PCL:0; RULEID:; SRVR:AM0PR05MB4481; x-forefront-prvs: 0818724663 x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(366004)(376002)(396003)(39860400002)(346002)(136003)(199004)(189003)(7736002)(68736007)(2501003)(2900100001)(8676002)(81166006)(6512007)(25786009)(53936002)(81156014)(256004)(14444005)(8936002)(52116002)(2906002)(478600001)(36756003)(5250100002)(6506007)(305945005)(316002)(3846002)(6116002)(107886003)(386003)(4326008)(66066001)(2616005)(110136005)(1857600001)(97736004)(106356001)(5660300001)(186003)(102836004)(26005)(99286004)(14454004)(476003)(486006)(86362001)(6486002)(105586002)(71190400001)(71200400001)(6436002)(54906003)(42262002); DIR:OUT; SFP:1101; SCL:1; SRVR:AM0PR05MB4481; H:AM0PR05MB4435.eurprd05.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; A:1; MX:1; received-spf: None (protection.outlook.com: mellanox.com does not designate permitted sender hosts) x-microsoft-antispam-message-info: famWDjIfLyRoN7mwXrbl/91RmwOd07je9SVMqg8z6GVsdXhyO0cZlhfqNYxblQJpIqL3HWyZTQp+M1yVlkglxd7dcziBsxJGFE1AH6XYB5YWNHDN2fXtNH2xvVFmFRyuzqAsiqY8A+qmKjpIgMxriqQRqGARTHsRbg87TcnYoIQP2nCpb5Qi+J0xNCbiK0d+tkc665U71RV2diXBQ0fkCJ1jX5BjXhJCei5O8Ba22DqSNRiI5wh4WKv2/PMJ8eGoxchf0FFoQpyGCumbOs5jalnY0VAf3KXNdrLxIwSfk8adRWhhetsVSIVswlboeagLM03BneOk9M0T4RUcniyM32ji1BITj08y4ZA4HprG3HE= spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: Mellanox.com X-MS-Exchange-CrossTenant-Network-Message-Id: cff04e04-34c6-4fd0-8b21-08d62c6ae01a X-MS-Exchange-CrossTenant-originalarrivaltime: 07 Oct 2018 15:38:06.5090 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: a652971c-7d2e-4d9b-a6a4-d149256f461b X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR05MB4481 Subject: [dpdk-dev] [PATCH] ethdev: fix flow API item/action name conversion 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: Sun, 07 Oct 2018 15:38:08 -0000 This patch fixes a typecast bug found in rte_flow_conv_name routine used in rte_flow item/action name conversion. Fixes: ae6b2cf49505 ("ethdev: add flow API item/action name conversion") Signed-off-by: Moti Haimovsky --- lib/librte_ethdev/rte_flow.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/librte_ethdev/rte_flow.c b/lib/librte_ethdev/rte_flow.c index 9c56a97..21a4286 100644 --- a/lib/librte_ethdev/rte_flow.c +++ b/lib/librte_ethdev/rte_flow.c @@ -767,7 +767,7 @@ enum rte_flow_conv_item_spec_type { { rte_flow_desc_action, RTE_DIM(rte_flow_desc_action), }, }; const struct desc_info *const info =3D &info_rep[!!is_action]; - unsigned int type =3D (uintptr_t)src; + unsigned int type =3D *(const unsigned int *)src; =20 if (type >=3D info->num) return rte_flow_error_set --=20 1.8.3.1