From patchwork Tue May 3 08:58:26 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonathan Cameron X-Patchwork-Id: 12835323 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 996FDC4332F for ; Tue, 3 May 2022 08:55:49 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233060AbiECI7T (ORCPT ); Tue, 3 May 2022 04:59:19 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37330 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233071AbiECI64 (ORCPT ); Tue, 3 May 2022 04:58:56 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E368A18B3E for ; Tue, 3 May 2022 01:55:23 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 7FA1C61266 for ; Tue, 3 May 2022 08:55:23 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 310F9C385B3; Tue, 3 May 2022 08:55:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1651568122; bh=YYjIlAMbZFXS5TJCoxi+sB+JWOWMX+6tZaFa1o0muw0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=a2l3ZWkhep32CTNWg4Z6WmHyDQXr2A68VXngqTwkYCGU3VscUFUkplmYzntWKB0N1 PmhJvqL3zOC+Qp0HpPRGtT74bjqSj3IQSiQBtKLSzRsoZPeoyuhwcu3S6JH11xceQ9 dUC4JsRpfdXeV+hcHb9pDUtiz59cXz84Gz0HazBNNMmqvofb9U8cxfEKENP8RSnL3Z o7xmrd5D36RgSLr2rZiAgLYiUcEQ/pRTRQFMG9z5+a91ea6JfLcNXO+biRSykH+7Zk Djrn/wYP4/ToYKuDwX4RBuvEJU7HB5kxF7HOhmrwQp2OX6STaFmYqMGfsWHZLgW4r1 Oqgserkhc9wJw== From: Jonathan Cameron To: linux-iio@vger.kernel.org Cc: Akinobu Mita , Alexandru Lazar , Alexandru Tachici , Antoniu Miclaus , Charles-Antoine Couret , Cosmin Tanislav , Cristian Pop , David Lechner , Ivan Mikhaylov , Jacopo Mondi , Jean-Baptiste Maneyrol , Lars-Peter Clausen , Marcelo Schmitt , =?utf-8?q?M=C3=A5rten_Lindahl?= , Matt Ranostay , Michael Hennerich , Michael Welling , Mugilraj Dhavachelvan , Navin Sankar Velliangiri , =?utf-8?q?Nuno_S=C3=A1?= , Paul Cercueil , Phil Reid , Puranjay Mohan , Ricardo Ribalda , Robert Jones , Rui Miguel Silva , Sean Nyekjaer , Tomas Melin , Tomislav Denis , =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= , Jonathan Cameron Subject: [PATCH 23/92] iio: adc: max1027: Fix alignment for DMA safety Date: Tue, 3 May 2022 09:58:26 +0100 Message-Id: <20220503085935.1533814-24-jic23@kernel.org> X-Mailer: git-send-email 2.36.0 In-Reply-To: <20220503085935.1533814-1-jic23@kernel.org> References: <20220503085935.1533814-1-jic23@kernel.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-iio@vger.kernel.org From: Jonathan Cameron ____cacheline_aligned is an insufficient guarantee for non-coherent DMA on platforms with 128 byte cachelines above L1. Switch to the updated IIO_ALIGN definition. Fixes: fc167f624833 ("iio: add support of the max1027") Signed-off-by: Jonathan Cameron --- drivers/iio/adc/max1027.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/iio/adc/max1027.c b/drivers/iio/adc/max1027.c index 4daf1d576c4e..f79fe49d69b7 100644 --- a/drivers/iio/adc/max1027.c +++ b/drivers/iio/adc/max1027.c @@ -272,7 +272,7 @@ struct max1027_state { struct mutex lock; struct completion complete; - u8 reg ____cacheline_aligned; + u8 reg __aligned(IIO_ALIGN); }; static int max1027_wait_eoc(struct iio_dev *indio_dev)