From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wr0-f193.google.com (mail-wr0-f193.google.com [209.85.128.193]) by dpdk.org (Postfix) with ESMTP id 4C7B71B885 for ; Tue, 15 May 2018 15:47:58 +0200 (CEST) Received: by mail-wr0-f193.google.com with SMTP id v5-v6so207055wrf.9 for ; Tue, 15 May 2018 06:47:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=We0gHM41t9x+sz84b9pOIbhi1ngUaAmcBH1lrhO5Kiw=; b=QeAYBV+d+2T9Doudsr3RO1koNYTYJu4UBmgiCXjPk0aOoYXXnaxJs5BKCi8WxQ06Y5 ceNxkLX5U1nDPaqESkcuURb85iIyEynyhIOPqwG5T5kO7G3p4J+0P11we6MM7AwVLUpA URIRbA03FTKmVmXHARFVVAbZklLMETeGx+kfM39EVZ3/VoPNAy9iT4x3sZBNu+MtyLws ZJtjTs1IpxjpK2CFd32G0Ik4kbeAy1sxqwrBdN83Nl/ysqC+XxvkIVhM34ilGnE67bQG z2OIhpYcxsUratUH9tLpRIAMGiO9qr3ur4ymQ4bljvnDYwufoeUh7XdBDHXW5LsQx4GY H4VQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=We0gHM41t9x+sz84b9pOIbhi1ngUaAmcBH1lrhO5Kiw=; b=kjtIK19M212bhoMDrAywHzwUGHDq/vMdWQEWHY5nQfWKtoP4Af7f4LZHfNRuRuNhZp uUXkjMiCImBEqJQvVhhQrpM5U14ad+eYdwtCiFHikOvNhP22nyRrpQYXCkSDY2WNKwzI 7MHwa14Z9HoTPHxYNSMBz7eGw9JxBpU9QfCf/66+ieiWvwLOR/4oOQ4PaIV3Tfyt9ZWK iWpNw92634Gzg1TuvTFCPp/da7DkcDBMCReO4huGZ9tBPaVgfdYoZqv1Aw3o6MhnhTSK HTDDuA4RW0MzH0EENT29qck4vsnBtmlrwEQWsuISzoETbKNA+zEAjV27gEW8I34ckiei qaEw== X-Gm-Message-State: ALKqPwf7xM4x0kMxJlU+T7AW1PpY5ugO4ZV8Z7GMguWEvT45YfBSEf6c CTdnrbgZFXKmujYMuHGENSiyRq10 X-Google-Smtp-Source: AB8JxZrVguGflHSiGkWG/ujQ95gl+cWvklCDfxpm1vCFc8G1Sr7jioSqH0WQwzurTVVSCgVI3cTqqw== X-Received: by 2002:adf:c4c3:: with SMTP id o3-v6mr10527101wrf.108.1526392078020; Tue, 15 May 2018 06:47:58 -0700 (PDT) Received: from localhost (slip139-92-244-193.lon.uk.prserv.net. [139.92.244.193]) by smtp.gmail.com with ESMTPSA id g28-v6sm637188wmc.38.2018.05.15.06.47.56 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 15 May 2018 06:47:57 -0700 (PDT) From: luca.boccassi@gmail.com To: Andy Green Cc: Stephen Hemminger , dpdk stable Date: Tue, 15 May 2018 14:46:21 +0100 Message-Id: <20180515134731.9337-10-luca.boccassi@gmail.com> X-Mailer: git-send-email 2.14.2 In-Reply-To: <20180515134731.9337-1-luca.boccassi@gmail.com> References: <20180503110612.12146-2-luca.boccassi@gmail.com> <20180515134731.9337-1-luca.boccassi@gmail.com> Subject: [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to stable release 18.02.2 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: Tue, 15 May 2018 13:47:58 -0000 Hi, FYI, your patch has been queued to stable release 18.02.2 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 05/16/18. So please shout if anyone has objections. Thanks. Luca Boccassi --- >>From 3cc1184a1fbf1759137afa35a3422c23ab48ad5d Mon Sep 17 00:00:00 2001 From: Andy Green Date: Sat, 12 May 2018 09:58:57 +0800 Subject: [PATCH] eal: explicit cast of builtin for bsf32 [ upstream commit 54a93341ccaaf3665352ddad0807cf3ed40c36f9 ] rte_common.h:416:9: warning: conversion to 'uint32_t' {aka 'unsigned int'} from 'int' may change the sign of the result [-Wsign-conversion] return __builtin_ctz(v); ^~~~~~~~~~~~~~~~ The builtin is defined to return int, but we want to return it as uint32_t. Its only defined valid return values are positive integers or zero, which is OK for uint32_t. So just add an explicit cast. Fixes: 03f6bced5bba ("eal: use intrinsic function") Signed-off-by: Andy Green Reviewed-by: Stephen Hemminger --- lib/librte_eal/common/include/rte_common.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/librte_eal/common/include/rte_common.h b/lib/librte_eal/common/include/rte_common.h index c7803e41c..00478007e 100644 --- a/lib/librte_eal/common/include/rte_common.h +++ b/lib/librte_eal/common/include/rte_common.h @@ -320,7 +320,7 @@ rte_align64pow2(uint64_t v) static inline uint32_t rte_bsf32(uint32_t v) { - return __builtin_ctz(v); + return (uint32_t)__builtin_ctz(v); } /** -- 2.14.2