Received: by 2002:a05:6358:4e97:b0:b3:742d:4702 with SMTP id ce23csp3261484rwb; Mon, 15 Aug 2022 22:36:37 -0700 (PDT) X-Google-Smtp-Source: AA6agR6ZL376CIxwWPffjfJKtO8f3XRkD+IV4QDKPmBOXoxqX+cmM33W3XA/NfUv+aBJD1VBD4wX X-Received: by 2002:a05:6402:4446:b0:43b:e1f4:8525 with SMTP id o6-20020a056402444600b0043be1f48525mr17526522edb.236.1660628197236; Mon, 15 Aug 2022 22:36:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1660628197; cv=none; d=google.com; s=arc-20160816; b=VwzrdpGwHVd0QCQ7aPGdeRGxzfbBK0aX7Ee2fwArS/tcSZwsNz6LRaOUtBh1woqf3p SKRl9F1zHGNQ/k9gq/SYnaRj34bnsZwjt0w15sgLyRmv+QrdP7XGpKgGd+hYJhfv3JyF LxSRpl39+m36RIOzBWd/cPDHImtIe6JB1ReUTNT0SxY6SqNpRu79K7TOXybOOv2sm87k BZIeRVokQgm14IX/m2Y+RoP/+X5xRh6hHvTMm8hW3GDxDJmuEgRxuCbbwITdHS7iEoU/ Yh2Qp+LeMqRU3CisEzfn4yY9Y5n+NM4nEeTUK2PiJoU+qoKg2TLSdTEs0fQtjMyO3w0Q zJsA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=UQR4xjy+6CaxLFJ3DS/if5DsbR40UGXHcWTA9EMEMvo=; b=cjwsym4kTXqn8USR96cUgN2NMsAs5ZNsR0ZDJeqgxuVSITs4topg/pOhMflqEVWfqQ s/Gc1iR/k7nszI3dUXxS5ZibpieXZFlcVqb3CXUNivT/cvPpc8ZzHz/lqtAS5uu5abFm OYkKduEcdvedaoUt2rwbFGnM36/jBWJ3m53kC7nm8KWhQpkD9jkWqp6XL8eit/wXtjZC hm+wvoKUulUIqLZPNIvxgivqLJLgDk41BpFKCFdYchGhgj6FKMJYEYXZYJUP47pI7vzv DQ5pHS/CndugHgh08DRCzNOck17xzpFc3cujQrE1k80hO5/7ys8xooh/VgyjQKh1JeFp uavQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=Xarz8mTn; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id c7-20020a05640227c700b0043be28d93adsi10349185ede.261.2022.08.15.22.36.11; Mon, 15 Aug 2022 22:36:37 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=Xarz8mTn; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230487AbiHPEhV (ORCPT + 99 others); Tue, 16 Aug 2022 00:37:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56592 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230129AbiHPEgf (ORCPT ); Tue, 16 Aug 2022 00:36:35 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AA9614D4CD; Mon, 15 Aug 2022 13:26:37 -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 ams.source.kernel.org (Postfix) with ESMTPS id 64A2FB81197; Mon, 15 Aug 2022 20:26:36 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id ACC8FC433C1; Mon, 15 Aug 2022 20:26:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1660595195; bh=fkS7l4Mv2LRZIz6RMO+Qh8fV/b9u3krpLRZn04lzIRY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Xarz8mTnVQeLOQGw/jGCM3+YkwukjbapaGvWJLyDz81fFW+oQIkNSPKe22Hrdu9nA UNc5EbUuRXhrHpqpreG8S2geptPNqBMd2tH2lppQdeUDUK8nZrRkASdR2LVGgpPA8r EL0QFN/xP+NnVAQh+uHu1O6qPvQeWskNunU2MXrM= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Jonathan Cameron , Alexandru Lazar , =?UTF-8?q?Nuno=20S=C3=A1?= , Sasha Levin Subject: [PATCH 5.19 0655/1157] iio: adc: max1241: Fix alignment for DMA safety Date: Mon, 15 Aug 2022 20:00:11 +0200 Message-Id: <20220815180505.936538683@linuxfoundation.org> X-Mailer: git-send-email 2.37.2 In-Reply-To: <20220815180439.416659447@linuxfoundation.org> References: <20220815180439.416659447@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Jonathan Cameron [ Upstream commit 9d7019e43ee67a48cef63f8f23f002233064d390 ] ____cacheline_aligned is an insufficient guarantee for non-coherent DMA on platforms with 128 byte cachelines above L1. Switch to the updated IIO_DMA_MINALIGN definition. Fixes: 8a80a71d9020 ("iio: adc: Add MAX1241 driver") Signed-off-by: Jonathan Cameron Acked-by: Alexandru Lazar Acked-by: Nuno Sá Link: https://lore.kernel.org/r/20220508175712.647246-27-jic23@kernel.org Signed-off-by: Sasha Levin --- drivers/iio/adc/max1241.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/iio/adc/max1241.c b/drivers/iio/adc/max1241.c index a5afd84af58b..a815ad1f6913 100644 --- a/drivers/iio/adc/max1241.c +++ b/drivers/iio/adc/max1241.c @@ -26,7 +26,7 @@ struct max1241 { struct regulator *vref; struct gpio_desc *shutdown; - __be16 data ____cacheline_aligned; + __be16 data __aligned(IIO_DMA_MINALIGN); }; static const struct iio_chan_spec max1241_channels[] = { -- 2.35.1