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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id C0FBAC61DA4 for ; Thu, 16 Feb 2023 18:51:32 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:Content-Type: List-Subscribe:List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id: In-Reply-To:MIME-Version:References:Message-ID:Subject:Cc:To:From:Date: Reply-To:Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date :Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=3nGszIX1GSnDVRG7L4gMRrdRDWjrWaS5TXkO3xXKux4=; b=Vow/C4LzDnoZ+xfw6dZWRZ4WCu l9YW2bShsS5i1DiM3Ih10S6zyJzqLSHWI+MaF5sK+TcuGxtUI2htJ9f/+6mY98MQrLi5+w7090Rrr tAc8kTTkqZWdCHgjej83vsnIKHjASE9/S9CPDSB19NyXU7l/CVJo3m61q3Onn6MHjsYRwAWfV7wRY Lkfi8d8jyGhpmqOPPy/T/KdM72ex5vBiBrqF7X6C8FEKYuoDTWggPmxYtR8L5/g1zAfvSTs6laxPT /XHdgFFdMqvALFnOT+/XH1rAc+eDHadsSF0MECbirancnx0ofOmImMrGjD26S/2BLX3SS0a4rPgx2 jskc5MnQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pSjL2-00Ba0T-3E; Thu, 16 Feb 2023 18:50:36 +0000 Received: from ams.source.kernel.org ([2604:1380:4601:e00::1]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1pSjKz-00BZzm-Az; Thu, 16 Feb 2023 18:50:34 +0000 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 ACE43B82951; Thu, 16 Feb 2023 18:50:31 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0DCEAC433D2; Thu, 16 Feb 2023 18:50:24 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1676573430; bh=AImnf+2dqdDiUhTA+4XLQG6ccdNzGaAOj2rHAnNmR9s=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=cwn2YrfskMK7b8K/KimZBAxY/yyMR/7dHYwkZ62/Ai0XU+LFgqyfNyyeGPdpBVD/z L5tR6ut4sU5d0mPmnlz4O3RGW1dEEEeJyiVGZcmuEcDFtLfUYmMsbc7TzqPoodANtP hlNgL9cbxXz3nPmhgZoJsHw8Cy5xVuoVntsQFQ6gUp4p8vv50rlYukm/+dJLWsXO4+ +BG8W2lJu5PqVhOQHPmkCR52mXRI0bIV8ckrCigczowbjO0Q2bcMVpdbKMbf+/eUYw MWuW3ALreFOeCyBrbqK6ki6aic8OAe4gScHw7OhlSTUzSD/6Vqo+dHijYTR0D/n+rN 58PVJwgvIXBGA== Date: Thu, 16 Feb 2023 18:50:22 +0000 From: Conor Dooley To: Cristian Ciocaltea Cc: Lee Jones , Rob Herring , Krzysztof Kozlowski , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Emil Renner Berthing , Palmer Dabbelt , Paul Walmsley , Albert Ou , Giuseppe Cavallaro , Alexandre Torgue , Jose Abreu , Maxime Coquelin , Richard Cochran , Sagar Kadam , Yanhong Wang , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, netdev@vger.kernel.org, linux-riscv@lists.infradead.org, linux-stm32@st-md-mailman.stormreply.com, linux-arm-kernel@lists.infradead.org, kernel@collabora.com, daire.mcnamara@microchip.com Subject: Re: [PATCH 04/12] soc: sifive: ccache: Add non-coherent DMA handling Message-ID: References: <20230211031821.976408-1-cristian.ciocaltea@collabora.com> <20230211031821.976408-5-cristian.ciocaltea@collabora.com> MIME-Version: 1.0 In-Reply-To: <20230211031821.976408-5-cristian.ciocaltea@collabora.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230216_105033_542506_37E54DA0 X-CRM114-Status: GOOD ( 15.22 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: multipart/mixed; boundary="===============4378715531216979555==" Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org --===============4378715531216979555== Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="dCe6axd58RjANF5F" Content-Disposition: inline --dCe6axd58RjANF5F Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Emil, +CC Daire On Sat, Feb 11, 2023 at 05:18:13AM +0200, Cristian Ciocaltea wrote: > From: Emil Renner Berthing >=20 > Add functions to flush the caches and handle non-coherent DMA. >=20 > Signed-off-by: Emil Renner Berthing > [replace with ] > Signed-off-by: Cristian Ciocaltea > --- > +void *sifive_ccache_set_uncached(void *addr, size_t size) > +{ > + phys_addr_t phys_addr =3D __pa(addr) + uncached_offset; > + void *mem_base; > + > + mem_base =3D memremap(phys_addr, size, MEMREMAP_WT); > + if (!mem_base) { > + pr_err("%s memremap failed for addr %p\n", __func__, addr); > + return ERR_PTR(-EINVAL); > + } > + > + return mem_base; > +} The rest of this I either get b/c we did it, or will become moot so I amn't worried about it, but can you please explain this, in particular the memremap that you're doing here? Cheers, Conor. --dCe6axd58RjANF5F Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYIAB0WIQRh246EGq/8RLhDjO14tDGHoIJi0gUCY+567gAKCRB4tDGHoIJi 0isoAQCgGCQCl64HiPsxg1E4/GDsGMTIJGdrEEQIXQCaEdTjeAD9Hv8l410SaOFy q5SvBa8IxUyuUjr2p8ixdFb2JfHoEAk= =7P7u -----END PGP SIGNATURE----- --dCe6axd58RjANF5F-- --===============4378715531216979555== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel --===============4378715531216979555==--