From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757350AbdJKLzI convert rfc822-to-8bit (ORCPT ); Wed, 11 Oct 2017 07:55:08 -0400 Received: from mga06.intel.com ([134.134.136.31]:1801 "EHLO mga06.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751948AbdJKLzD (ORCPT ); Wed, 11 Oct 2017 07:55:03 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.43,361,1503385200"; d="scan'208";a="161420560" From: "Liu, Yi L" To: Joerg Roedel CC: Jacob Pan , "iommu@lists.linux-foundation.org" , LKML , David Woodhouse , "Greg Kroah-Hartman" , "Wysocki, Rafael J" , Jean-Philippe Brucker , "Lan, Tianyu" , "Tian, Kevin" , "Raj, Ashok" , Alex Williamson , "Liu, Yi L" Subject: RE: [PATCH v2 03/16] iommu: introduce iommu invalidate API function Thread-Topic: [PATCH v2 03/16] iommu: introduce iommu invalidate API function Thread-Index: AQHTPi3heG1vc8SMMUewp9Xdviow+KLclt0AgACPqYCAASBMoP//o7cAgACl5bA= Date: Wed, 11 Oct 2017 11:54:52 +0000 Message-ID: References: <1507244624-39189-1-git-send-email-jacob.jun.pan@linux.intel.com> <1507244624-39189-4-git-send-email-jacob.jun.pan@linux.intel.com> <20171010133542.juag7cwbivlb56sl@8bytes.org> <20171010150953.4095a045@jacob-builder> <20171011095126.GD30803@8bytes.org> In-Reply-To: <20171011095126.GD30803@8bytes.org> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-version: 11.0.0.116 dlp-reaction: no-action x-originating-ip: [10.239.127.40] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 8BIT MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > On Wed, Oct 11, 2017 at 07:54:32AM +0000, Liu, Yi L wrote: > > I agree that iommu_invalidate() is too generic. Additionally, also > > better to avoid making it svm specific. > > I also don't like to name the functions after the Intel feature, but I failed to come up > with a better alternative so far. The only one I can come up with for now would be > 'iovm', so the function name would be iommu_iovm_invalidate(). [Liu, Yi L] Actually, I'm not against 'SVM' terms. Just want to make it be compatible with future usage in non-SVM scenario. > On the other side, the ARM guys also already call the feature set 'SVM', despite it > being ambiguous and Intel specific. I don't have a strong opinion on the naming. > > > The reason we introduce this API is in vSVM case is that guest owns > > the first level page table(vtd). If we use similar mechanism for > > vIOVA, then we also need to passdown guest's vIOVA tlb flush. > > > > Since it is to expose an API for iommu tlb flushes requests from > > userspace/guest which is out of iommu. How about naming it as > > iommu_tlb_external_invalidate()? > > If you only read the function name, 'external' could mean everything. It is not clear [Liu, Yi L] Agree, 'external' is also unclear. > from the name when to use this function. So something like > iommu_iovm_invalidate() is better. > [Liu, Yi L] I didn't quite get 'iovm' mean. Can you explain a bit about the idea? Thanks, Yi L