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 E80D9CD6E57 for ; Tue, 2 Jun 2026 06:10:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Transfer-Encoding: Content-Type:MIME-Version:Message-ID:Date:References:In-Reply-To:Subject:Cc: To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=tFMH5l5MTUaf6Xe98VNs76Ti6mPZN2RO0Y2Ijj9ZpVQ=; b=Uxuq7gGEak5G6EMj8D0tQtKWKO aW/seRUTPSBNkWZ2EB20rYqvcB2MoxkOsQJD+u11x01dWZU1RTcDqrvwFH45DkeGGpBa3iiy+rHiL jbQ40WX7IJXfBo3ji6L0AGNMXskPOn1/85wK12GDlHO/dR3QIGl0XVjsl8f/6t77vxPFMELnVgs2H 1hAMaaFuwB9qahhaGofFju30WgZQXK+PuOcHnYkw7l1sI+BGn5XU2tRm5aOYvTb54GPwxE39WdXvM sebCqQ34B69+X/5Sf4S2plaQtWuSvg/UI5XzYyrXk0ksdm4qL3LJ4IH86empt1AerChjdHIuckwn9 GBZtBhkw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.99.1 #2 (Red Hat Linux)) id 1wUIKP-0000000CMvC-48VY; Tue, 02 Jun 2026 06:10:17 +0000 Received: from tor.source.kernel.org ([2600:3c04:e001:324:0:1991:8:25]) by bombadil.infradead.org with esmtps (Exim 4.99.1 #2 (Red Hat Linux)) id 1wUIKN-0000000CMuu-40oO for linux-arm-kernel@lists.infradead.org; Tue, 02 Jun 2026 06:10:16 +0000 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) by tor.source.kernel.org (Postfix) with ESMTP id 1EDFC6001A; Tue, 2 Jun 2026 06:10:15 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0F4341F00893; Tue, 2 Jun 2026 06:10:04 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1780380614; bh=tFMH5l5MTUaf6Xe98VNs76Ti6mPZN2RO0Y2Ijj9ZpVQ=; h=From:To:Cc:Subject:In-Reply-To:References:Date; b=fZHJyOBoEGHiD16yVMLzAjbsRhIR7CFE9cGa8xrtaW1fYnxZpDeAP0dlt+35R/Mt6 lwiApCD3vWaU5f/ov1UftsC46EHnWWu9gVCnryDWlTRVbG8/Awo2j7YCs1kkoKzFUW CLiouOcaFGFR32sW24z1VM1bmsWZYup1WOlxsoyfafKWKAqaMUDNcPp6rSaZlrOose 2+KdIT0Et7q2lWeCijk6GKIW77oJ2/Hmw08YSLGVBKiEFhtlIH4Duf/oWZrG7NccM7 XJbsbh+yK33nHz1p9/ZqYXK8Iv1em79IHjEcPrS+wx+QrhI/G32wo36vWwfGqLIiXr rc4x3UNOXfQIA== X-Mailer: emacs 30.2 (via feedmail 11-beta-1 I) From: Aneesh Kumar K.V To: Michael Kelley , "iommu@lists.linux.dev" , "linux-arm-kernel@lists.infradead.org" , "linux-kernel@vger.kernel.org" , "linux-coco@lists.linux.dev" Cc: Robin Murphy , Marek Szyprowski , Will Deacon , Marc Zyngier , Steven Price , Suzuki K Poulose , Catalin Marinas , Jiri Pirko , Jason Gunthorpe , Mostafa Saleh , Petr Tesarik , Alexey Kardashevskiy , Dan Williams , Xu Yilun , "linuxppc-dev@lists.ozlabs.org" , "linux-s390@vger.kernel.org" , Madhavan Srinivasan , Michael Ellerman , Nicholas Piggin , "Christophe Leroy (CS GROUP)" , Alexander Gordeev , Gerald Schaefer , Heiko Carstens , Vasily Gorbik , Christian Borntraeger , Sven Schnelle , "x86@kernel.org" , Jiri Pirko Subject: RE: [PATCH v5 10/20] dma-direct: make dma_direct_map_phys() honor DMA_ATTR_CC_SHARED In-Reply-To: References: <20260522042815.370873-1-aneesh.kumar@kernel.org> <20260522042815.370873-11-aneesh.kumar@kernel.org> Date: Tue, 02 Jun 2026 11:40:00 +0530 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable 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: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Michael Kelley writes: > From: Aneesh Kumar K.V (Arm) Sent: Thursday, Ma= y 21, 2026 9:28 PM >>=20 >> Teach dma_direct_map_phys() to select the DMA address encoding based on >> DMA_ATTR_CC_SHARED. >>=20 >> Use phys_to_dma_unencrypted() for decrypted mappings and >> phys_to_dma_encrypted() otherwise. If a device requires unencrypted DMA >> but the source physical address is still encrypted, force the mapping >> through swiotlb so the DMA address and backing memory attributes remain >> consistent. >>=20 >> Update the arm64, x86, s390 and powerpc secure-guest setup to not use >> swiotlb force option >>=20 >> Tested-by: Jiri Pirko >> Signed-off-by: Aneesh Kumar K.V (Arm) ... > With this patch removing SWIOTLB_FORCE from four places in > kernel code, there are no remaining places where it is set. > The test of SWIOTLB_FORCE could be removed from > swiotlb_init_remap(), and its definition could be deleted > from include/linux/swiotlb.h. > Sure, I=E2=80=99ll add that as a separate patch in the series. -aneesh