Re: [PATCH v5 2/7] iommu/sva: Move PASID helpers to sva code

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Robin,

On Fri, 10 Mar 2023 20:00:52 +0000, Robin Murphy <robin.murphy@xxxxxxx>
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@xxxxxxxxxxxxxxx>
> > ---
> > 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



[Index of Archives]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux FS]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux