From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mellanox.co.il (mail-il-dmz.mellanox.com [193.47.165.129]) by dpdk.org (Postfix) with ESMTP id 211941B1FE for ; Thu, 3 Jan 2019 09:14:38 +0100 (CET) Received: from Internal Mail-Server by MTLPINE1 (envelope-from yskoh@mellanox.com) with ESMTPS (AES256-SHA encrypted); 3 Jan 2019 10:14:34 +0200 Received: from scfae-sc-2.mti.labs.mlnx (scfae-sc-2.mti.labs.mlnx [10.101.0.96]) by labmailer.mlnx (8.13.8/8.13.8) with ESMTP id x038EJfb008603; Thu, 3 Jan 2019 10:14:33 +0200 From: Yongseok Koh To: Andy Green Cc: Stephen Hemminger , dpdk stable Date: Thu, 3 Jan 2019 00:13:31 -0800 Message-Id: <20190103081400.14191-8-yskoh@mellanox.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20190103081400.14191-1-yskoh@mellanox.com> References: <20190103081400.14191-1-yskoh@mellanox.com> Subject: [dpdk-stable] patch 'hash: explicit casts for truncation in CRC32c' has been queued to LTS release 17.11.5 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, 03 Jan 2019 08:14:38 -0000 Hi, FYI, your patch has been queued to LTS release 17.11.5 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 01/04/19. So please shout if anyone has objections. Also note that after the patch there's a diff of the upstream commit vs the patch applied to the branch. If the code is different (ie: not only metadata diffs), due for example to a change in context or macro names, please double check it. Thanks. Yongseok --- >>From ba05e2e6c8db651ebe72507d6a6189f473d7b554 Mon Sep 17 00:00:00 2001 From: Andy Green Date: Sat, 12 May 2018 10:00:37 +0800 Subject: [PATCH] hash: explicit casts for truncation in CRC32c [ upstream commit c981825388f81fb191f5a79c80adf0fdb074e584 ] In function 'crc32c_sse42_u64_mimic': rte_hash_crc.h:402:40: warning: conversion from 'uint64_t' {aka 'long unsigned int'} to 'uint32_t' {aka 'unsigned int'} may change value [-Wconversion] init_val = crc32c_sse42_u32(d.u32[0], init_val); Fixes: 00bf774bab0b ("hash: add assembly implementation of CRC32 intrinsics") Signed-off-by: Andy Green Reviewed-by: Stephen Hemminger --- lib/librte_hash/rte_hash_crc.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/librte_hash/rte_hash_crc.h b/lib/librte_hash/rte_hash_crc.h index 0d829175d..5a0f2d463 100644 --- a/lib/librte_hash/rte_hash_crc.h +++ b/lib/librte_hash/rte_hash_crc.h @@ -427,9 +427,9 @@ crc32c_sse42_u64_mimic(uint64_t data, uint64_t init_val) } d; d.u64 = data; - init_val = crc32c_sse42_u32(d.u32[0], init_val); - init_val = crc32c_sse42_u32(d.u32[1], init_val); - return init_val; + init_val = crc32c_sse42_u32(d.u32[0], (uint32_t)init_val); + init_val = crc32c_sse42_u32(d.u32[1], (uint32_t)init_val); + return (uint32_t)init_val; } #endif @@ -441,7 +441,7 @@ crc32c_sse42_u64(uint64_t data, uint64_t init_val) "crc32q %[data], %[init_val];" : [init_val] "+r" (init_val) : [data] "rm" (data)); - return init_val; + return (uint32_t)init_val; } #endif -- 2.11.0 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2019-01-02 23:59:12.543255014 -0800 +++ 0008-hash-explicit-casts-for-truncation-in-CRC32c.patch 2019-01-02 23:59:12.023814000 -0800 @@ -1,8 +1,10 @@ -From c981825388f81fb191f5a79c80adf0fdb074e584 Mon Sep 17 00:00:00 2001 +From ba05e2e6c8db651ebe72507d6a6189f473d7b554 Mon Sep 17 00:00:00 2001 From: Andy Green Date: Sat, 12 May 2018 10:00:37 +0800 Subject: [PATCH] hash: explicit casts for truncation in CRC32c +[ upstream commit c981825388f81fb191f5a79c80adf0fdb074e584 ] + In function 'crc32c_sse42_u64_mimic': rte_hash_crc.h:402:40: warning: conversion from 'uint64_t' {aka 'long unsigned int'} @@ -10,7 +12,6 @@ init_val = crc32c_sse42_u32(d.u32[0], init_val); Fixes: 00bf774bab0b ("hash: add assembly implementation of CRC32 intrinsics") -Cc: stable@dpdk.org Signed-off-by: Andy Green Reviewed-by: Stephen Hemminger @@ -19,10 +20,10 @@ 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/librte_hash/rte_hash_crc.h b/lib/librte_hash/rte_hash_crc.h -index 5f5fb3db1..cf28031b3 100644 +index 0d829175d..5a0f2d463 100644 --- a/lib/librte_hash/rte_hash_crc.h +++ b/lib/librte_hash/rte_hash_crc.h -@@ -398,9 +398,9 @@ crc32c_sse42_u64_mimic(uint64_t data, uint64_t init_val) +@@ -427,9 +427,9 @@ crc32c_sse42_u64_mimic(uint64_t data, uint64_t init_val) } d; d.u64 = data; @@ -35,7 +36,7 @@ } #endif -@@ -412,7 +412,7 @@ crc32c_sse42_u64(uint64_t data, uint64_t init_val) +@@ -441,7 +441,7 @@ crc32c_sse42_u64(uint64_t data, uint64_t init_val) "crc32q %[data], %[init_val];" : [init_val] "+r" (init_val) : [data] "rm" (data));