Received: by 2002:a05:6a10:9e8c:0:0:0:0 with SMTP id y12csp1059667pxx; Tue, 27 Oct 2020 07:22:04 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy08CeoCUNKyy77oAoe3K+1qZt5iIx3xbojkefDVg70TyVkNx/ieYj+5YQLqy+tpV1+NLI1 X-Received: by 2002:aa7:c84b:: with SMTP id g11mr2404251edt.86.1603808524451; Tue, 27 Oct 2020 07:22:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1603808524; cv=none; d=google.com; s=arc-20160816; b=yxGpMQ0Lj343n74IxeB5I6Dq0+1fskCfGDGopC7nVLMD11k+RxgiE9SWfiI7YNlu0f HxlCotp0XJA2nPchx3jbA94/txaFGdleix/OjxVcXTlkqg84D/nC7qgPGV9kIOL3kMSY SZINjXGJBdhpDJet1eWrycD72Iow/5T3cwWFI4vBu5cVIv+fsSal1r0xhqPJpklal6ew 32TVEYlg/le1qvY1nlL2xNCAqn5ootAMB4Rpt0+1D11Wxf4UD7h1MGERUxSb9tlNFQRH GdyPlvPJPco0bAZcF1Lz9db0X/+uznJ8eD9dVRfDeUTLtyPNoXGO22bh1sc/BvvGT70K suhw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=jmNJLBRCFdFXQCPDsbgJxCeg7OTT63Ved9ZS239LUkg=; b=uNRS7l0nqxfAewZ7cRqjWS+jpbIvqM4X0Jjwc136bEdNHybvK/bqU9Jy30pF+w71o4 iihFjjtyfH7Cc4UzgjnS1eStTobANC+eGTpd5swiOUAf5FJKmIegb2i53Wd9jt7YuT3P DT/UlPaes53Rq2RMK2ZYIT7evScafkUxiZFASNGc/0cmfEgsrAuO76EmC1QDE4N9ezUs TiUGckJPk20xtUBQjqd4hRLe2Fn268cM38YCAxlQGvU96tfpN/8iNhhxdcjhYcVqflPU Jb2Qe6NEnd2YtsUq+CvaGPWYqRBq24FyUC8Qbm2KbveahzkiT+NhbtSP5K+jlI0/hj0N DACw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b=uwVkm9dZ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id u15si923644edx.510.2020.10.27.07.21.42; Tue, 27 Oct 2020 07:22:04 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b=uwVkm9dZ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2444579AbgJ0IoY (ORCPT + 99 others); Tue, 27 Oct 2020 04:44:24 -0400 Received: from casper.infradead.org ([90.155.50.34]:34702 "EHLO casper.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2443713AbgJ0IoX (ORCPT ); Tue, 27 Oct 2020 04:44:23 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=jmNJLBRCFdFXQCPDsbgJxCeg7OTT63Ved9ZS239LUkg=; b=uwVkm9dZG6qemWi1SUFtrghO8y U61seC3CjXBZ7FVApPCnMiEXJCSFrO9lQKMTHYIfUr9Y15LQGLCcbwOtZCWWC+SkmG8RD3nregZlH kiitudLOmiKoSMDkcfFvPQb6jgNt7RT75k+oQZNyu0kdR4f2Y5/Vde5PI0ld2a3pmmW/WyqruPh2z T8hXR7Pv6ajnvlYC45xSGFziuYv/skTWwThqP5D7d4RiekvuZst5EbXOyMB9/C6jF5mLzW6eym5ay +pvcFFcjgZ3QmJBlfJk+JydPksRC3QWLCdZGY6t3YUAhA1biP76jRuDxsqf5e10JjDNtZKhKTEWJw sXCX+sHg==; Received: from hch by casper.infradead.org with local (Exim 4.92.3 #3 (Red Hat Linux)) id 1kXKaD-0002zC-6S; Tue, 27 Oct 2020 08:43:57 +0000 Date: Tue, 27 Oct 2020 08:43:57 +0000 From: Christoph Hellwig To: Jason Gunthorpe Cc: Tom Lendacky , x86@kernel.org, linux-kernel@vger.kernel.org, linux-arch@vger.kernel.org, linux-mm@kvack.org, kvm@vger.kernel.org, Radim Kr??m???? , Arnd Bergmann , Matt Fleming , Konrad Rzeszutek Wilk , Andrey Ryabinin , Ingo Molnar , Borislav Petkov , Andy Lutomirski , "H. Peter Anvin" , Paolo Bonzini , Alexander Potapenko , Thomas Gleixner , Dmitry Vyukov , Rik van Riel , Larry Woodman , Dave Young , Toshimitsu Kani , "Michael S. Tsirkin" , Brijesh Singh Subject: Re: AMD SME encrpytion and PCI BAR pages to user space Message-ID: <20201027084357.GA10053@infradead.org> References: <20201019152556.GA560082@nvidia.com> <4b9f13bf-3f82-1aed-c7be-0eaecebc5d82@amd.com> <20201021115933.GS6219@nvidia.com> <20201021160322.GT6219@nvidia.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20201021160322.GT6219@nvidia.com> X-SRS-Rewrite: SMTP reverse-path rewritten from by casper.infradead.org. See http://www.infradead.org/rpr.html Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Oct 21, 2020 at 01:03:22PM -0300, Jason Gunthorpe wrote: > Oh, interesting.. Yes the issue is no userspace DMA stuff uses the DMA > API correctly (because it is in userspace) > > So SWIOTLB tricks don't work, I wish the dma_map could fail for these > situations Userspace DMA by definition also does not use dma_map..