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 008D7C6FA82 for ; Thu, 8 Sep 2022 13:03:24 +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-Transfer-Encoding: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-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=T7jV2iijAb7gWtMyRmxFGuGbsMlW9GDAxSgiFBV0reg=; b=3TplEQ9r8Joeae rpbd0cqFpZyLFt10nzWYsM+LhoVwXJ8vxAB7siUirTbnmNaFF9cvJqa6oOuxoEnCtWOYUd3oQXoBg t+XMOdRRs/N34mZk+padWZByLmaeCfEGfFyEV0t3JS0BtEjjcySx0gy5Mv9I+udjsX0cbuZkPo5qF 0goidTP1dv9IVtHJRtqZpRG9A/naLlQXJKnnYZivfmsOVBCT8hW51n5jjBlCp1O8RLnAc94UYxjMa hvTppGGJhp3inJ717Aft31dxXXfaWLu/vO8Sx70+3IALo1ZVjY/GvqfEbRZfmTOnGpG/UshhSB6Jn ltlVVoA4UnLu5/z65/UA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1oWHAk-003XWl-Bv; Thu, 08 Sep 2022 13:02:22 +0000 Received: from dfw.source.kernel.org ([139.178.84.217]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1oWHAh-003XW5-87 for linux-arm-kernel@lists.infradead.org; Thu, 08 Sep 2022 13:02:20 +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 dfw.source.kernel.org (Postfix) with ESMTPS id C9DE261CEA; Thu, 8 Sep 2022 13:02:18 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 1296EC433D6; Thu, 8 Sep 2022 13:02:16 +0000 (UTC) Date: Thu, 8 Sep 2022 14:02:13 +0100 From: Catalin Marinas To: Robin Murphy Cc: Will Deacon , Christoph Hellwig , linux-arm-kernel@lists.infradead.org, Mark Rutland , Ard Biesheuvel Subject: Re: [PATCH] arm64: dma: Drop cache invalidation from arch_dma_prep_coherent() Message-ID: References: <20220823122111.17439-1-will@kernel.org> <20220907090305.GA30704@lst.de> <5d856574-4cd7-70d0-adcb-3e284fef315f@arm.com> <20220907162543.GA30558@willie-the-truck> <6dfd53a1-ce24-086d-1ce6-093d48b033da@arm.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <6dfd53a1-ce24-086d-1ce6-093d48b033da@arm.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220908_060219_356839_B2A935D5 X-CRM114-Status: GOOD ( 17.51 ) 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: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Thu, Sep 08, 2022 at 12:32:42PM +0100, Robin Murphy wrote: > On 2022-09-08 11:32, Catalin Marinas wrote: > > The architecture requires invalidate or clean while also stating that > > clean+invalidate can be used instead, so I don't think there's much to > > justify. From the mismatched attributes section: > > > > 1. If the mismatched attributes for a memory location all assign the > > same shareability attribute to a Location that has a cacheable > > attribute, > > This is not describing our case, though. We do have a cacheable attribute in > at least one alias, but the shareability is *not* the same across all > aliases, therefore at face value it clearly does not apply. >From the CPU perspective, both the cacheable and non-cacheable aliases have the same inner shareable attribute. The device accessing the buffer presumably should use the same shareability attributes. In the worst case it's outer shareable but on most implementations the inner and outer shareability domains are the same. -- Catalin _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel