From patchwork Wed Mar 1 09:27:49 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Petri Savolainen X-Patchwork-Id: 94686 Delivered-To: patch@linaro.org Received: by 10.140.20.113 with SMTP id 104csp1701032qgi; Wed, 1 Mar 2017 01:28:42 -0800 (PST) X-Received: by 10.55.158.84 with SMTP id h81mr7870483qke.85.1488360522702; Wed, 01 Mar 2017 01:28:42 -0800 (PST) Return-Path: Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id q131si3803851qke.144.2017.03.01.01.28.42; Wed, 01 Mar 2017 01:28:42 -0800 (PST) Received-SPF: pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) client-ip=54.225.227.206; Authentication-Results: mx.google.com; spf=pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) smtp.mailfrom=lng-odp-bounces@lists.linaro.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 425A9637B4; Wed, 1 Mar 2017 09:28:42 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on ip-10-142-244-252 X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAD_ENC_HEADER,BAYES_00, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,URIBL_BLOCKED autolearn=disabled version=3.4.0 Received: from [127.0.0.1] (localhost [127.0.0.1]) by lists.linaro.org (Postfix) with ESMTP id 20825637B8; Wed, 1 Mar 2017 09:28:38 +0000 (UTC) X-Original-To: lng-odp@lists.linaro.org Delivered-To: lng-odp@lists.linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id C521C63C93; Wed, 1 Mar 2017 09:28:34 +0000 (UTC) Received: from EUR02-AM5-obe.outbound.protection.outlook.com (mail-eopbgr00137.outbound.protection.outlook.com [40.107.0.137]) by lists.linaro.org (Postfix) with ESMTPS id 18835637B7 for ; Wed, 1 Mar 2017 09:28:11 +0000 (UTC) Received: from AM5PR0701CA0062.eurprd07.prod.outlook.com (10.169.145.152) by HE1PR0701MB1737.eurprd07.prod.outlook.com (10.167.246.135) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.947.2; Wed, 1 Mar 2017 09:28:07 +0000 Received: from DB5EUR03FT051.eop-EUR03.prod.protection.outlook.com (2a01:111:f400:7e0a::208) by AM5PR0701CA0062.outlook.office365.com (2603:10a6:203:2::24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.947.2 via Frontend Transport; Wed, 1 Mar 2017 09:28:07 +0000 Received-SPF: SoftFail (protection.outlook.com: domain of transitioning linaro.org discourages use of 131.228.2.37 as permitted sender) Received: from hybrid2.ext.net.nokia.com (131.228.2.37) by DB5EUR03FT051.mail.protection.outlook.com (10.152.21.19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.933.11 via Frontend Transport; Wed, 1 Mar 2017 09:28:07 +0000 Received: from fihe3nok1349.nsn-intra.net (10.158.36.137) by fihe3nok1348.nsn-intra.net (10.158.36.136) with Microsoft SMTP Server (TLS) id 15.1.466.34; Wed, 1 Mar 2017 11:27:58 +0200 Received: from mailrelay.int.nokia.com (10.130.128.21) by fihe3nok1349.nsn-intra.net (10.158.36.137) with Microsoft SMTP Server (TLS) id 15.1.466.34 via Frontend Transport; Wed, 1 Mar 2017 11:27:58 +0200 Received: from fihe3nok0734.emea.nsn-net.net (localhost [127.0.0.1]) by fihe3nok0734.emea.nsn-net.net (8.14.9/8.14.5) with ESMTP id v219RnsW001347 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Wed, 1 Mar 2017 11:27:49 +0200 Received: from 10.144.19.15 ([10.144.104.219]) by fihe3nok0734.emea.nsn-net.net (8.14.9/8.14.5) with ESMTP id v219Rno8001338 (version=TLSv1/SSLv3 cipher=AES128-SHA256 bits=128 verify=NOT) for ; Wed, 1 Mar 2017 11:27:49 +0200 X-HPESVCS-Source-Ip: 10.144.104.219 From: Petri Savolainen To: Date: Wed, 1 Mar 2017 11:27:49 +0200 Message-ID: <1488360469-25958-2-git-send-email-petri.savolainen@linaro.org> X-Mailer: git-send-email 2.8.1 In-Reply-To: <1488360469-25958-1-git-send-email-petri.savolainen@linaro.org> References: <1488360469-25958-1-git-send-email-petri.savolainen@linaro.org> MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-HT: Tenant X-Forefront-Antispam-Report: CIP:131.228.2.37; IPV:NLI; CTRY:FI; EFV:NLI; SFV:NSPM; SFS:(10019020)(6009001)(7916002)(39450400003)(39840400002)(39410400002)(39860400002)(39850400002)(2980300002)(199003)(189002)(9170700003)(356003)(2351001)(50466002)(105596002)(92566002)(2906002)(106466001)(47776003)(305945005)(110136004)(38730400002)(53936002)(22756006)(5660300001)(33646002)(6916009)(450100001)(2950100002)(50226002)(77096006)(189998001)(81166006)(5003940100001)(8936002)(8676002)(36756003)(86362001)(626004)(76176999)(50986999); DIR:OUT; SFP:1102; SCL:1; SRVR:HE1PR0701MB1737; H:hybrid2.ext.net.nokia.com; FPR:; SPF:SoftFail; MLV:sfv; A:1; MX:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; DB5EUR03FT051; 1:VzAnKvZ46ftmKeLLCzYI3hLsbNtvNRQsxIGHvVzRikLMpylpWlmIDIvcGae6Wk9+5QjMf9z3cnkji6FO6/vzKvO1doyJWrtAT8tcdEwDRv/VbvAljql55nwYi2K9CEEjPR37tHkX2NWs1AHngZvkmK6FKLfF4Tuo+VsTwYGqVpX5inGsrHuNMP6OwDLqNxLA7CTlRCqEbIEeBnB2ByGr7IVwS7UluXBh+VXPrr2+haAv5sk00Q34QCtr3zYIA+Kd6RAvgaUnTXh66mRnyr3smqxMwmvn4ACed2vRs/az3/lWOnF+YWXyagRCKxbnbf3oRHm6L6anQzxA6Vne/FM5UkgT7k5UOlmGPnNt56tJ2ivxIDNy7hLmRiJfRlRGzDaReG66FVBjkHfs1OdKWLNY8MDZ/UKiEwQ/znt2CuiMgWiUBDu3p4nERqbyMjK6LTymsSEleKJnG8C/pPYUW49kzw== X-MS-Office365-Filtering-Correlation-Id: c43bc902-ea92-4cda-0dc4-08d460854530 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001); SRVR:HE1PR0701MB1737; X-Microsoft-Exchange-Diagnostics: 1; HE1PR0701MB1737; 3:ugX3lWI4Ixzs8ycsQzWiyzvVYMxumRqMPTBmrnUseWgiQZws/e6ca/LfYzgUdyf2gITsOnutEX+y2yBQdIGRnAUJqk+3aHcB8zENPiUdXhpfNxDzw+I1+cbl7+fqJpQBQ6CjCFBAxYE6TIIWzvWfSPcUCB01CCaUDMhGaISztBDsOkbhB4f3ZNfUWXZVxzilCvI2bNwt4KUCjh2P7tQ67WiAXIgr5BtUCOx/Ehyh5wk2bS1qCRIYioJ8Mp8EC9wi8qicmq0749zVjCWKeGq8r5YTEJ+OSrkbcQnOJ3Ky90as8sXAhuSAqkU9LPxO89T6D/Ub0RljLxTVwHeG1srKjrLqKUngL4/ME1O5pgW6M+XK2AhJcR7vOfAIiDDRUw4s; 25:9VnSHifq7XW1EMh31FdUWMga85jJ/nCqirb1soVmtL4EtJBH/8X2oqf7WSXFdgeKRzFUi7mg+FJL75CLGPqlAZvZv7et7BT+8x6LS5dkEuKP+BtF6GCKAJy+sBmZoUf8zbV1Pj3ZV506xuTlN+ASvZOnlodZtLVKZIuOF0KJRJ3KKsLGDK59qEjfNDfIxMatDl+GXmhWiayPsyoU7ymr6kNpSq1/QzwaHqHUJI7jFztr9RcHcVhKp2R4pXyNNf8qTOQb57lnSBg6R8BeNGHlTzn4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2Y0eVCfsQXR806Cs9qEDbI4OqRIIBkzoecaW7HFdSiiRwJ7caIVVFI81IIbpqg= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040375)(601004)(2401047)(13016025)(13018025)(8121501046)(5005006)(3002001)(10201501046)(6055026)(6041248)(20161123555025)(20161123562025)(20161123564025)(20161123558025)(20161123560025)(6072148); SRVR:HE1PR0701MB1737; BCL:0; PCL:0; RULEID:; SRVR:HE1PR0701MB1737; X-Microsoft-Exchange-Diagnostics: 1; HE1PR0701MB1737; 4:hr8i2fwltteOYAFlWJN2oBKkCa6N+vLQyjQe/YT9w1hEKmplIS12xn9rpWmBo34p7JDEFJRmVSN1HS147+Khdz0biNmIM45Vj2HsU1pjD4VapsGgkAnyZvwDC7LXh+UG6EL/XKEJMXLTXCKbqv78Gj5yRpgVen4U4qhwpSxGLpiXRjifqqiQdJ09qWuuZn3PED4gLStUbjA5aCffZ5mgQjMokQkcr6PYVuE3e20CC+6JimpQ6lqYmDH7+G5PGiokKX8glR8sXnw9EiL8HgwI+yR8/vga07TCW4/5f87uvQ41Js/jMxI+bArSzA8Y0ZX7kRlbvw5h5DKUw7rU3puMLQwSJoUk2IL/a6YQ+Kpa+4fEISaxkg7Z7lsljqR1Y8pCQ9e0B8kF0JVxusfQPDmjpkD1vGOBcg1Mg/6BC0DWXYio0wtawNkyKTT/+A8/Jhb1PU7QliAZ+i2gEM58agNgofoLrhCJCT00GkwpMs0Ttwd/2Ahh6pZtC2qilL9t9+rrVsNGY3BRgjK52yDL/PMRfxJ1TcKQfJjo6y/YV7hB7dWgbMbdCCDMwRHRitLIP4+2rivzkTzb4qjq4LUYhjo8TYMTg2luRdB5olj0Xjcg4OuyPPJWxGxIB5WRTVbeoHx0O3IJkyZ+DW4hz0u8gOALc/A4NXcBMGhGRz8lnbMuXCE= X-Forefront-PRVS: 0233768B38 X-Microsoft-Exchange-Diagn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hgrBmX/IYZ9xgx9c4puimlu0n+3l5V1TXZ7R8KKIbF+9+vQNLyWvB+/VQHYqIidstJadLrTidORP/ga7EgZ+EOx1IHEYPd+L9g== X-OriginatorOrg: nokia.onmicrosoft.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 01 Mar 2017 09:28:07.2682 (UTC) X-MS-Exchange-CrossTenant-Id: 5d471751-9675-428d-917b-70f44f9630b0 X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=5d471751-9675-428d-917b-70f44f9630b0; Ip=[131.228.2.37]; Helo=[hybrid2.ext.net.nokia.com] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: HE1PR0701MB1737 Subject: [lng-odp] [PATCH v2 2/2] linux-gen: tm: use handle conversion function X-BeenThere: lng-odp@lists.linaro.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: "The OpenDataPlane \(ODP\) List" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: lng-odp-bounces@lists.linaro.org Sender: "lng-odp" Use (from buffer to packet handle) conversion function instead of casting. Signed-off-by: Petri Savolainen --- platform/linux-generic/odp_traffic_mngr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 2.8.1 diff --git a/platform/linux-generic/odp_traffic_mngr.c b/platform/linux-generic/odp_traffic_mngr.c index 309f237..4e9358b 100644 --- a/platform/linux-generic/odp_traffic_mngr.c +++ b/platform/linux-generic/odp_traffic_mngr.c @@ -107,7 +107,7 @@ static int queue_tm_reenq(queue_entry_t *queue, odp_buffer_hdr_t *buf_hdr) odp_tm_queue_t tm_queue = MAKE_ODP_TM_QUEUE((uint8_t *)queue - offsetof(tm_queue_obj_t, tm_qentry)); - odp_packet_t pkt = (odp_packet_t)buf_hdr->handle.handle; + odp_packet_t pkt = _odp_packet_from_buffer(buf_hdr->handle.handle); return odp_tm_enq(tm_queue, pkt); }