lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20230310133628.290c0efa@jacob-builder>
Date:   Fri, 10 Mar 2023 13:36:28 -0800
From:   Jacob Pan <jacob.jun.pan@...ux.intel.com>
To:     Robin Murphy <robin.murphy@....com>
Cc:     LKML <linux-kernel@...r.kernel.org>, iommu@...ts.linux.dev,
        Jason Gunthorpe <jgg@...dia.com>,
        Lu Baolu <baolu.lu@...ux.intel.com>,
        Joerg Roedel <joro@...tes.org>,
        Jean-Philippe Brucker <jean-philippe@...aro.com>,
        Dave Hansen <dave.hansen@...el.com>,
        Thomas Gleixner <tglx@...utronix.de>,
        X86 Kernel <x86@...nel.org>, bp@...en8.de,
        "H. Peter Anvin" <hpa@...or.com>,
        Peter Zijlstra <peterz@...radead.org>, corbet@....net,
        vkoul@...nel.org, dmaengine@...r.kernel.org,
        linux-doc@...r.kernel.org, Will Deacon <will@...nel.org>,
        David Woodhouse <dwmw2@...radead.org>,
        Raj Ashok <ashok.raj@...el.com>,
        "Tian, Kevin" <kevin.tian@...el.com>, Yi Liu <yi.l.liu@...el.com>,
        "Yu, Fenghua" <fenghua.yu@...el.com>,
        Dave Jiang <dave.jiang@...el.com>,
        Kirill Shutemov <kirill.shutemov@...ux.intel.com>,
        Tony Luck <tony.luck@...el.com>, jacob.jun.pan@...ux.intel.com
Subject: Re: [PATCH v5 2/7] iommu/sva: Move PASID helpers to sva code

Hi Robin,

On Fri, 10 Mar 2023 20:00:52 +0000, Robin Murphy <robin.murphy@....com>
wrote:

> On 2023-03-09 22:21, Jacob Pan wrote:
> > Preparing to remove IOASID infrastructure, PASID management will be
> > under SVA code. Decouple mm code from IOASID. Use iommu-help.h instead
> > of iommu.h to prevent circular inclusion.
> > 
> > Signed-off-by: Jacob Pan <jacob.jun.pan@...ux.intel.com>
> > ---
> > v5:
> > 	- move definition of helpers to iommu code to be consistent with
> > 	  declarations. (Kevin)
> > 	- fix patch partitioning bug (Baolu)
> > v4:
> > 	- delete and open code mm_set_pasid
> > 	- keep mm_init_pasid() as inline for fork performance
> > ---
> >   drivers/iommu/iommu-sva.c    | 10 +++++++++-
> >   include/linux/ioasid.h       |  2 +-
> >   include/linux/iommu-helper.h | 12 ++++++++++++  
> 
> Eww, can we not? iommu-helper is very much just parts of a specific type 
> of bitmap-based IOVA allocator used by some crusty old arch-specific 
> IOMMU code and SWIOTLB. It is unrelated to the iommu.h IOMMU API, and 
> dragging that stuff into modern SVA-related matters seems bizarrely 
> inappropriate. Could we just move the mm_pasid stuff into ioasid.h here, 
> then maybe rename it to iommu-sva.h at the end if eradicating the old 
> name really matters?
thanks for explaining the history behind iommu-helper.h, having a new
include/linux/iommu-sva.h would probably be cleaner.

my original intent for using iommu-helper.h was to avoid problems by mm.h
#include iommu.h. So I just needed a separate small header. let me do
without iommu-helper.h.

Thanks,

Jacob

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ