Received: by 2002:a05:6358:4e97:b0:b3:742d:4702 with SMTP id ce23csp3084684rwb; Mon, 15 Aug 2022 17:45:14 -0700 (PDT) X-Google-Smtp-Source: AA6agR7aaebuWnPNFvteKiqdUDAEjJ5CkRvGbuV06htTyxYn8UNvN07wCzF3CraTg1XASQOZlVS6 X-Received: by 2002:a63:2c6:0:b0:41d:9a04:c227 with SMTP id 189-20020a6302c6000000b0041d9a04c227mr15607243pgc.167.1660610714435; Mon, 15 Aug 2022 17:45:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1660610714; cv=none; d=google.com; s=arc-20160816; b=SpDrAt2GDUidOj7N7uxKjDqLBf4ZN1mBLXaY4nEW+KK/lcZtB/hD05A/ZLGpCHynqf AYRaeuXuw8FX9Rk4kU+WMqkT6EyZ+iKVmRQ84rqlcBRXhJ826IBEvbMX93OApXoxa04S AT+cdcGBhE2XOSi4LbJdgAjli3EQ0JZCV7mOljvpWgSAzKC2wLL0oLBhQGN782lvIYhH eyRAWrMDxY3klIW1awGI/md+NT6ojXoFWQAirMRqcFyzMI0M6FNrZtsEGWhsAe+zjocX KMDXuJudq+ffBfzk6tlWS8Y2Jw7Rc8gWv/L/tCuytsZHo9jvWIeidNmJfbrfdXQWij4L us8Q== 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=2Tu+gahRRcx0VLDI+mcjJ3XrfUTQ2S0LYVHjMdk/5Ak=; b=MfgVrcihoizhhyRfnFXIo6WPP5c2++ainsbADlPg+HsY7IijcxI1w8wMMrfs5MyRLc CrlAexFNileNGMwcgNmxVwORfFt++39UvVixkyJtYPxr11MY+zZYMKF/O9+9YeTeDF5w Kh2SOgqu+agSBkhScqAS/re0oCSbnpUz8RmoaFJsX5NtMeCj2yTf1poFKr1hSpqJmJMO jDyh0FCbDh0HlXzIx1zHlla3YERPi5XOuZzWG8xivkGyfA/WxHI02iPaGy+a2tVMo8Wp jdIIIAkgrwjWVdDViw+ra5r2bvrrh8Urc4+InKhMLbVc4dd61xh9y6T8Rt117o4z2NWj BnZQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=dTrL2BBN; 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 bd33-20020a056a0027a100b00534b6674cb4si7064315pfb.301.2022.08.15.17.45.03; Mon, 15 Aug 2022 17:45:14 -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=dTrL2BBN; 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 S1349035AbiHOVkX (ORCPT + 99 others); Mon, 15 Aug 2022 17:40:23 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40322 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1348642AbiHOVg5 (ORCPT ); Mon, 15 Aug 2022 17:36:57 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3CC0AAD; Mon, 15 Aug 2022 12:26: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 dfw.source.kernel.org (Postfix) with ESMTPS id CC3C4610A3; Mon, 15 Aug 2022 19:26:37 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id BDA80C433C1; Mon, 15 Aug 2022 19:26:36 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1660591597; bh=K1mckkucQ53SKXsVQAHvieVbLZoUpM1bXDgk3yp9K1w=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=dTrL2BBN3uJOj5JieFAzFoIAn6byj9kAOQVubirjAJmnZk5YQdeRDqfXB0CqVE6OY 7h/2JyIZuGGmXho8W/1nuw/0yWQx/KWODCRQwK1QkG38mYh5hbJrnaFg86N+Z5spDE bVKkCSTjxzV00ZxTEJrXLb5T8VFncUphfjO5yJ2Q= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Jonathan Cameron , Paul Cercueil , =?UTF-8?q?Nuno=20S=C3=A1?= , Sasha Levin Subject: [PATCH 5.18 0632/1095] iio: dac: ad5592r: Fix alignment for DMA safety Date: Mon, 15 Aug 2022 20:00:31 +0200 Message-Id: <20220815180455.589344187@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 4a4a79c06caeec47003bcbee1cf3094479f26e24 ] ____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: 56ca9db862bf ("iio: dac: Add support for the AD5592R/AD5593R ADCs/DACs") Signed-off-by: Jonathan Cameron Cc: Paul Cercueil Acked-by: Nuno Sá Link: https://lore.kernel.org/r/20220508175712.647246-49-jic23@kernel.org Signed-off-by: Sasha Levin --- drivers/iio/dac/ad5592r-base.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/iio/dac/ad5592r-base.h b/drivers/iio/dac/ad5592r-base.h index 2a22ef691996..cc7be426cbc8 100644 --- a/drivers/iio/dac/ad5592r-base.h +++ b/drivers/iio/dac/ad5592r-base.h @@ -14,6 +14,8 @@ #include #include +#include + struct device; struct ad5592r_state; @@ -65,7 +67,7 @@ struct ad5592r_state { u8 gpio_in; u8 gpio_val; - __be16 spi_msg ____cacheline_aligned; + __be16 spi_msg __aligned(IIO_DMA_MINALIGN); __be16 spi_msg_nop; }; -- 2.35.1