Received: by 2002:a05:6358:4e97:b0:b3:742d:4702 with SMTP id ce23csp3022532rwb; Mon, 15 Aug 2022 16:20:02 -0700 (PDT) X-Google-Smtp-Source: AA6agR6qafhCjv3IOaUnShPvCbJ+4wKvfrKBvVlaFeLdJO9rj1QMarIwxgRZ7aZfHBfs1TbnDbUt X-Received: by 2002:a05:6402:e94:b0:443:e3fe:7c87 with SMTP id h20-20020a0564020e9400b00443e3fe7c87mr3840778eda.144.1660605601744; Mon, 15 Aug 2022 16:20:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1660605601; cv=none; d=google.com; s=arc-20160816; b=EJcS0RryoLbKDw2JwtIZIj6eROWhBzyISKF2V3eWzT/0UbJ7GjeYX+gmbwGdGiJ3dx v0w3iZsXZPqpe4+sMO4yCb5b1pNFZc/Fp/j9z2zscIB6OswqgQYTNa49lvNahOSsouVI uW2SO8TTdiuOrGefHiRe0Z2gE1OVC2pCcFxV+5spuTsJttPz4i8sNrbT7S9vp61i5T9Z vnS+Tn5ZdUKI8u6c5lII8Yc6Jmn1rDdPjsNK+J2UYukY0cxlociSVnXQSzuRh4XXuesz UjpndGHtivRD3Y3xvCD8J12VCDMNDO6X5BUUJkyRn00/QZqmmDPq45VorO7hTEDfpDcj XgFA== 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=inZm41rUbBeVPTYd/AKoLTWzWU1so6It7+e+RnteDRYYg0ycZTenENZCSF3gd9uxb4 /Ld9mHG/XYGpoGoDDqWP0ZFGH0Cac/E8+VU4IedV1F4mrLS62vTaj3Ibj0hc/Bo50UWo hP5jWD0+WQHFj5YRC88XqyGoTkz3v9UVqaBGdbD+oWRrmKzrzXo6vZZZqczd7Ru8HIyT GCZORxQYaye1j3K/Ss/BpulVnyfW+QAhiantdyF9uILv53qE5eXTeUvyX2sYr2QKZB7F EHziYiCVCc6vOhdHyJWJdA1Ro5xleanKo0KL1UCwKeuN0M+AqTGPMx76Wzk2kZcl1dmx D0Ug== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=gZ6nuqlw; 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 dn14-20020a17090794ce00b00730a0ca675asi7215011ejc.380.2022.08.15.16.19.37; Mon, 15 Aug 2022 16:20:01 -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=gZ6nuqlw; 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 S1348974AbiHOViU (ORCPT + 99 others); Mon, 15 Aug 2022 17:38:20 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43388 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1348981AbiHOVgR (ORCPT ); Mon, 15 Aug 2022 17:36:17 -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 06DB6DD758; Mon, 15 Aug 2022 12:25:38 -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 A200BB81125; Mon, 15 Aug 2022 19:25:37 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 07409C433C1; Mon, 15 Aug 2022 19:25:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1660591536; bh=fkS7l4Mv2LRZIz6RMO+Qh8fV/b9u3krpLRZn04lzIRY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=gZ6nuqlwws6y/45uLVJkEfVcQ1smW6bnrqUSbQlJlt2KV0Fb4TX2U4M3f3mbAdqUd V4gybGg8hPHU/45jtsxqBHeogoP/iMXTO9O8zt+TK5Oulg14sYLn1By1oXinKhNfXM MGFjC6wT3yUuEpO/ZA9assezAH+5Ps2pTdMpZTYA= 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.18 0610/1095] iio: adc: max1241: Fix alignment for DMA safety Date: Mon, 15 Aug 2022 20:00:09 +0200 Message-Id: <20220815180454.743090611@linuxfoundation.org> X-Mailer: git-send-email 2.37.2 In-Reply-To: <20220815180429.240518113@linuxfoundation.org> References: <20220815180429.240518113@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