From patchwork Sun Oct 13 09:05:42 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonathan Cameron X-Patchwork-Id: 11187317 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 5521014DB for ; Sun, 13 Oct 2019 09:07:53 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 2AA5F20679 for ; Sun, 13 Oct 2019 09:07:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1570957673; bh=GnAbmRqSltmFgVAtWkr1ppMMBXyYUykDifDjgp/IOns=; h=From:To:Cc:Subject:Date:List-ID:From; b=ytUrKdCYcbffh3rHZWWcIe+drPQAro7mkis+jeYFNjFHna0wLAxSi46NUoAQrJZbe xClIhJ4nMub4ZJqcESD3xMAOGftNVJrK09hCyO5dmz5z0YbjkFI9hyHAQ/9an05zGG RvicN9ft6xlxiUp9iaomwI/iL34YfbGg7BBqyBB8= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728579AbfJMJHw (ORCPT ); Sun, 13 Oct 2019 05:07:52 -0400 Received: from mail.kernel.org ([198.145.29.99]:44542 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728496AbfJMJHw (ORCPT ); Sun, 13 Oct 2019 05:07:52 -0400 Received: from localhost.localdomain (cpc149474-cmbg20-2-0-cust94.5-4.cable.virginm.net [82.4.196.95]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 45FE620673; Sun, 13 Oct 2019 09:07:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1570957672; bh=GnAbmRqSltmFgVAtWkr1ppMMBXyYUykDifDjgp/IOns=; h=From:To:Cc:Subject:Date:From; b=UHqztY9rxZK8c44qCWisY2COK3m3GkngqaAfv5vpBM3rSzWFhYwVntY6CCAjbAVYW +Y+reDoy6/7hRI78yblXHE2W5xUL8Y3lMlGyFklxJkT9lZsxmtVqde1gG4KdvK6Dwx ucElB2Uvv/5Ce2Ccklfol3ENtd/3PL545ZHn6yvI= From: jic23@kernel.org To: linux-iio@vger.kernel.org Cc: Jonathan Cameron , Lukas Wunner Subject: [PATCH] iio:adc:mcp320x: Tidy up endian types in type cast. Date: Sun, 13 Oct 2019 10:05:42 +0100 Message-Id: <20191013090542.1375572-1-jic23@kernel.org> X-Mailer: git-send-email 2.23.0 MIME-Version: 1.0 Sender: linux-iio-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-iio@vger.kernel.org From: Jonathan Cameron Fixes the sparse warning: drivers/iio/adc/mcp320x.c:167:41: warning: incorrect type in argument 1 (different base types) drivers/iio/adc/mcp320x.c:167:41: expected restricted __be32 const [usertype] *p drivers/iio/adc/mcp320x.c:167:41: got unsigned int [usertype] * Signed-off-by: Jonathan Cameron Cc: Lukas Wunner Reviewed-by: Lukas Wunner --- drivers/iio/adc/mcp320x.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/iio/adc/mcp320x.c b/drivers/iio/adc/mcp320x.c index 38bf10085696..465c7625a55a 100644 --- a/drivers/iio/adc/mcp320x.c +++ b/drivers/iio/adc/mcp320x.c @@ -164,7 +164,7 @@ static int mcp320x_adc_conversion(struct mcp320x *adc, u8 channel, case mcp3550_60: case mcp3551: case mcp3553: { - u32 raw = be32_to_cpup((u32 *)adc->rx_buf); + u32 raw = be32_to_cpup((__be32 *)adc->rx_buf); if (!(adc->spi->mode & SPI_CPOL)) raw <<= 1; /* strip Data Ready bit in SPI mode 0,0 */