Received: by 2002:a05:6358:4e97:b0:b3:742d:4702 with SMTP id ce23csp3091375rwb; Mon, 15 Aug 2022 17:55:06 -0700 (PDT) X-Google-Smtp-Source: AA6agR7XfB3dt0kbGs4aiRxbaN00E3av7FZ9IkJtsahC91WtRvUBYkNdKKavUM/RZAFc/65SabF+ X-Received: by 2002:a17:907:3e93:b0:730:a92b:e7e1 with SMTP id hs19-20020a1709073e9300b00730a92be7e1mr12212644ejc.621.1660611305980; Mon, 15 Aug 2022 17:55:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1660611305; cv=none; d=google.com; s=arc-20160816; b=XOiQaKllNeTQzgackBaNd50fKUZ8llCazwGp03zpA5w/G7ONmuj07mjDHYauOrF2MI JNfcEn0r1Ex4Bv0ZpJ1b7hh3TXWKFiGZPaLdpBSGSg9WiUPOgfr+wMUmCIIMmBcjSOtP d4wDugYkk2hPtv+OsAGzuuIUdc2i7Q8vhgYhrQRjuejBU/cX+gSS0J4ukRe5XEOW71BF kx64FTSaLGyxadEEQzMymVVAnJ+kfKb7gkjSAGBuHG6ZWav6H8pOjafd+hTz7BCojtE9 4D+FNbyLruZDharXlyCJbbJDqypuVmga3ckAu7Q7RJeYmckWZq1L+DTBw8ne4UqiPQBv xJ5Q== 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=r2UL97194TBLfGJpL5OCotmRioOrVM8QvS/cC/8t8nk=; b=Yum59XONWUJI8UEnq01Woq6lQPFbjV+q13uxMy8L4ODhyaDf7amLOmMSSVQl58fJfX PMiQq0Eg/uopDlVFev4oEUxfthIeHU5Rg/6eNGNBAOg75WKVLSlOFHHyiN6bBaszI6aH Ee9zprr8Lkex7Kk8daJvQVUjRLK4k+u5DujpjdLpM/DRWb6Xu1+jyumiaCon8vJBj9o9 +CLDBWcHS7v4mhpCc+P8Sl41fwg5mTq1W1nYjLnRgd65Svh4eiMFvsxaFaTWRrsveRwE F04Dx3AajMS/078KV15co2tcIQkxXumnDJwZ4GkCQT6pGnHQh3ePjpUiwoemJOxglvc4 dVUQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=mZJZAyzQ; 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 nd38-20020a17090762a600b0073159d67b74si9221975ejc.46.2022.08.15.17.54.39; Mon, 15 Aug 2022 17:55:05 -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=mZJZAyzQ; 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 S1352563AbiHPAPO (ORCPT + 99 others); Mon, 15 Aug 2022 20:15:14 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46794 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1351140AbiHPAE2 (ORCPT ); Mon, 15 Aug 2022 20:04:28 -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 A8F751705DF; Mon, 15 Aug 2022 13:28:21 -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 A4840B8119A; Mon, 15 Aug 2022 20:28:19 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 00608C433C1; Mon, 15 Aug 2022 20:28:17 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1660595298; bh=YXN664tHlqpao73ub4aCiZFPrlz/XdG5wd1w5nCQIKI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=mZJZAyzQytWkWK7P53IocHSw0Rvaih3GlqfoeeHhuo9rOji898qfE4SEgIWMXKlre 5M9adG1upUQXyjimPG6fxm4bhrEjEWKuu5WOLtOnTRYwBXQ/x2cDE+wYV1Vyc2rOZG Gpv+mLSWGvqUAYz63I4qcwQNwjLeUnyyshCbw6Fg= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Jonathan Cameron , Matt Ranostay , =?UTF-8?q?Nuno=20S=C3=A1?= , Sasha Levin Subject: [PATCH 5.19 0719/1157] iio: temp: maxim_thermocouple: Fix alignment for DMA safety Date: Mon, 15 Aug 2022 20:01:15 +0200 Message-Id: <20220815180508.253279329@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 10897f34309b3c7bc14698407436c82d11c07f47 ] ____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: 1f25ca11d84a ("iio: temperature: add support for Maxim thermocouple chips") Signed-off-by: Jonathan Cameron Cc: Matt Ranostay Acked-by: Nuno Sá Link: https://lore.kernel.org/r/20220508175712.647246-93-jic23@kernel.org Signed-off-by: Sasha Levin --- drivers/iio/temperature/maxim_thermocouple.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/iio/temperature/maxim_thermocouple.c b/drivers/iio/temperature/maxim_thermocouple.c index 98c41cddc6f0..c28a7a6dea5f 100644 --- a/drivers/iio/temperature/maxim_thermocouple.c +++ b/drivers/iio/temperature/maxim_thermocouple.c @@ -122,7 +122,7 @@ struct maxim_thermocouple_data { struct spi_device *spi; const struct maxim_thermocouple_chip *chip; - u8 buffer[16] ____cacheline_aligned; + u8 buffer[16] __aligned(IIO_DMA_MINALIGN); char tc_type; }; -- 2.35.1