Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753738AbdGNJcp (ORCPT ); Fri, 14 Jul 2017 05:32:45 -0400 Received: from mout.kundenserver.de ([217.72.192.73]:52310 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753574AbdGNJcm (ORCPT ); Fri, 14 Jul 2017 05:32:42 -0400 From: Arnd Bergmann To: linux-kernel@vger.kernel.org, Lars-Peter Clausen , Michael Hennerich , Jonathan Cameron , Greg Kroah-Hartman Cc: Linus Torvalds , Tejun Heo , Guenter Roeck , linux-ide@vger.kernel.org, linux-media@vger.kernel.org, akpm@linux-foundation.org, dri-devel@lists.freedesktop.org, Arnd Bergmann , stable@vger.kernel.org, Hartmut Knaack , Peter Meerwald-Stadler , linux-iio@vger.kernel.org, devel@driverdev.osuosl.org Subject: [PATCH 10/14] staging:iio:resolver:ad2s1210 fix negative IIO_ANGL_VEL read Date: Fri, 14 Jul 2017 11:31:03 +0200 Message-Id: <20170714093129.1366900-1-arnd@arndb.de> X-Mailer: git-send-email 2.9.0 In-Reply-To: <20170714092540.1217397-1-arnd@arndb.de> References: <20170714092540.1217397-1-arnd@arndb.de> X-Provags-ID: V03:K0:7kUZJ7IPymt25S8JQd8PtHIZcXHdXNXETpAme/TzfjsnvVhbWSg 9rc+vbvWJSliTiAs45fkeWbTvpV0c4eJxrM3SSNEpuS0cp1jtnJ4hNKPTnXw8FRejQD4Vam ebs+Xp4m2YdRHThH8Wnua+aQcjiGPrRHqhdkSm7ac3ZgecAIySFTWYif8n3peng7CLmrU53 lpA0Dkf09z6iqvQcfRxXg== X-UI-Out-Filterresults: notjunk:1;V01:K0:UmAmo0eEBxM=:5kaNQ1dp2U2OK1jgvtzYAk fpwNa5Qn641OVBY3rNpKqReuSPoQvgmkeNnyrE6Z2p1BMLJf3Dy7x6LwSM8kLpugMFvP8CAiE 5ohfkRoAyB/ElRcRq345G4rgjSJGGr+DgcedABxYoJsnSuSAmGEWlz76Q0CYC6DF9kDRTbkXj IxVI6mRTOVsouGiUdcpQknFe01A/bwh1ptebS6+7kz+nt1yuOAlMgAr23cWWe6U8gEEAa76g9 x/kO6P2N8Vbw3gwf/JpxHYXsVK13ulFfiiDiZVQYEzoXY7sKK619Xl3IjHOSUi3efRs095P2Y EYAvGO5pHwfhtB50IKczGt2qZdmiM3/j7Tcy8zwjL5f/dw0w/UXlApmD92JihKDR2p8hBUrrZ MQ9Z4Qdtjr6PynyTuQj8nVrBoT8FAqDN6Nk1AInnLarAOixOtMatQbwm+pTKs5QTtFnWdcdZy exYdDlAEa3X9knGAyg5hnOvaAnySicnaTziyep9d1R0DR3vaeNHfYPLHS0xRMTH7JxIj0GRRN lW3w33ZBWEaCV8GHU0+ymbGLW6ZdflIC7P0VB2j8wrY/sMRarHe4/g33AROmtTi/fzYtkO7tE hqLW3qB8EC8bi7DUYSkF6UlI8EkbDg15t6DIgTjZEvmTuB+OjuZptZ2vxOpV8fmngjKjXxJfM /4g8dbu2I7GRB6vPQksQC/UfqA0FkHfwS6SvwBz6Zn0PysnI4Pd/5TE0AWk+kTEDDVTHe75fH oucMjrFAF3gi2gXjlNya0Jccew5ZXAX50dW0rw== Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1100 Lines: 31 gcc-7 points out an older regression: drivers/staging/iio/resolver/ad2s1210.c: In function 'ad2s1210_read_raw': drivers/staging/iio/resolver/ad2s1210.c:515:42: error: '<<' in boolean context, did you mean '<' ? [-Werror=int-in-bool-context] The original code had 'unsigned short' here, but incorrectly got converted to 'bool'. This reverts the regression and uses a normal type instead. Fixes: 29148543c521 ("staging:iio:resolver:ad2s1210 minimal chan spec conversion.") Cc: stable@vger.kernel.org Signed-off-by: Arnd Bergmann --- drivers/staging/iio/resolver/ad2s1210.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/iio/resolver/ad2s1210.c b/drivers/staging/iio/resolver/ad2s1210.c index a6a8393d6664..3e00df74b18c 100644 --- a/drivers/staging/iio/resolver/ad2s1210.c +++ b/drivers/staging/iio/resolver/ad2s1210.c @@ -472,7 +472,7 @@ static int ad2s1210_read_raw(struct iio_dev *indio_dev, long m) { struct ad2s1210_state *st = iio_priv(indio_dev); - bool negative; + u16 negative; int ret = 0; u16 pos; s16 vel; -- 2.9.0