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 X-Spam-Level: X-Spam-Status: No, score=-5.3 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 18DC0C4320A for ; Fri, 23 Jul 2021 05:41:14 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id E375360F02 for ; Fri, 23 Jul 2021 05:41:13 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233723AbhGWFAi (ORCPT ); Fri, 23 Jul 2021 01:00:38 -0400 Received: from verein.lst.de ([213.95.11.211]:36999 "EHLO verein.lst.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230131AbhGWFAg (ORCPT ); Fri, 23 Jul 2021 01:00:36 -0400 Received: by verein.lst.de (Postfix, from userid 2407) id E180A67373; Fri, 23 Jul 2021 07:41:06 +0200 (CEST) Date: Fri, 23 Jul 2021 07:41:06 +0200 From: Christoph Hellwig To: "Tian, Kevin" Cc: Christoph Hellwig , Joerg Roedel , Jason Gunthorpe , Alex Williamson , David Woodhouse , Lu Baolu , Will Deacon , Kirti Wankhede , "linux-arm-kernel@lists.infradead.org" , "iommu@lists.linux-foundation.org" , "kvm@vger.kernel.org" , Robin Murphy Subject: Re: [PATCH 3/6] vfio: remove the unused mdev iommu hook Message-ID: <20210723054106.GA31771@lst.de> References: <20210514133143.GK1096940@ziepe.ca> <20210517123010.GO1096940@ziepe.ca> <20210517133500.GP1096940@ziepe.ca> <20210722133450.GA29155@lst.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.17 (2007-11-01) Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org On Fri, Jul 23, 2021 at 05:36:17AM +0000, Tian, Kevin wrote: > > > And a new set of IOMMU-API: > > > > > > - iommu_{un}bind_pgtable(domain, dev, addr); > > > - iommu_{un}bind_pgtable_pasid(domain, dev, addr, pasid); > > > - iommu_cache_invalidate(domain, dev, invalid_info); > > > > What caches is this supposed to "invalidate"? > > pasid cache, iotlb or dev_iotlb entries that are related to the bound > pgtable. the actual affected cache type and granularity (device-wide, > pasid-wide, selected addr-range) are specified by the caller. Maybe call it pgtable_invalidate or similar? To avoid confusing it with the CPUs dcache.