From mboxrd@z Thu Jan 1 00:00:00 1970 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 C688FC54EBC for ; Tue, 10 Jan 2023 15:12:29 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238910AbjAJPM2 (ORCPT ); Tue, 10 Jan 2023 10:12:28 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48878 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238897AbjAJPLw (ORCPT ); Tue, 10 Jan 2023 10:11:52 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1EB5F49154; Tue, 10 Jan 2023 07:11:29 -0800 (PST) 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 A2AC461779; Tue, 10 Jan 2023 15:11:28 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 383B7C433EF; Tue, 10 Jan 2023 15:11:24 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1673363488; bh=uKrtRn6CDrdTBnWrc0AschRz5jiayfkSvYCIjkppPHQ=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=pdF0lCsEFYZpu4mxGFlTO0ahbX8LHqTV7NEYRJEBBh+C2qhCkIwgCoR/x4C9avokB 3ss3e/Q1hq3fAN7hq4OS2m91Sm+jMc78d2yAv4KL73z8Ml/7zVqwg8H8K9WW0afZsE 3HvXIxNn9QVb2rAhneAxn8MTA9hnAf6KGlmvCAis/JuQ5/1OBfs7ioJecEKspWjF+n 87x8wx8RgGnqA+nJA+k5JFPxlcuuRaTm5AX+4XO3IKqkvcxC37NRn/lIOxnxn5/dsj oO/Z7sGXLoaO7w2rss9wtYhrUyVikTEslbYoeamv8Hwkb2+ZUwMXRY67UtYNU8TWOd zrMWLsyc2vMWQ== Date: Tue, 10 Jan 2023 15:11:20 +0000 From: Will Deacon To: Arnd Bergmann Cc: Christoph Hellwig , Prabhakar , "Conor.Dooley" , Geert Uytterhoeven , Heiko =?iso-8859-1?Q?St=FCbner?= , guoren , Andrew Jones , Paul Walmsley , Palmer Dabbelt , Albert Ou , "open list:RISC-V ARCHITECTURE" , open list , devicetree@vger.kernel.org, Linux-Renesas , "Lad, Prabhakar" , Philipp Tomsich , Nathan Chancellor , Atish Patra , Anup Patel , Tsukasa OI , Jisheng Zhang , Mayuresh Chitale Subject: Re: [RFC PATCH v6 1/6] riscv: mm: dma-noncoherent: Switch using function pointers for cache management Message-ID: <20230110151119.GA9436@willie-the-truck> References: <20230106185526.260163-1-prabhakar.mahadev-lad.rj@bp.renesas.com> <20230106185526.260163-2-prabhakar.mahadev-lad.rj@bp.renesas.com> <6f7d06ef-d74d-4dfc-9b77-6ae83e0d7816@app.fastmail.com> <9017adf0-acd4-4c43-8aea-3579b214b477@app.fastmail.com> <45d6eb0c-cbe3-4a83-aa12-3483638473ae@app.fastmail.com> <20230110070144.GG10289@lst.de> <02988e70-b099-46fd-b260-2d537c50543a@app.fastmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <02988e70-b099-46fd-b260-2d537c50543a@app.fastmail.com> User-Agent: Mutt/1.10.1 (2018-07-13) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jan 10, 2023 at 04:03:06PM +0100, Arnd Bergmann wrote: > On Tue, Jan 10, 2023, at 08:01, Christoph Hellwig wrote: > > On Mon, Jan 09, 2023 at 01:59:12PM +0100, Arnd Bergmann wrote: > >> I had another look at the arm64 side, which (like the zicbom > >> variant) uses 'clean' on dma_sync_single_for_device(DMA_FROM_DEVICE), > >> as that has changed not that long ago, see > >> > >> https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=c50f11c6196f45c92ca48b16a5071615d4ae0572 > > > > which IIRC has been reverted recently. > > To clarify: I was looking at arch_sync_dma_for_device(), which > changed from 'invalidate' to 'clean' last June in commit > c50f11c6196f ("arm64: mm: Don't invalidate FROM_DEVICE buffers > at start of DMA transfer"). I don't see a revert for that. > > The one that was reverted recently is arch_dma_prep_coherent, which > was changed and reverted in > > c44094eee32 Aug 23 2022 flush->clean > b7d9aae4048 Dec 6 2022 clean->flush > > I'm primarily interested in the streaming mappings (arch_sync_*) > at the moment. Just as an FYI, but we plan to revert the revert (i.e. go back to 'clean') here once Qualcomm's modem firmware loader has been updated: https://lore.kernel.org/r/20230109034843.23759-1-quic_sibis@quicinc.com Will