Re: [PATCH kernel 05/15] powerpc/iommu: Stop using @current in mm_iommu_xxx

2016-08-15 Thread David Gibson
On Fri, Aug 12, 2016 at 02:56:59PM +1000, Alexey Kardashevskiy wrote: > On 12/08/16 12:57, David Gibson wrote: > > On Wed, Aug 03, 2016 at 06:40:46PM +1000, Alexey Kardashevskiy wrote: > >> In some situations the userspace memory context may live longer than > >> the userspace process itself so if

Re: [PATCH kernel 05/15] powerpc/iommu: Stop using @current in mm_iommu_xxx

2016-08-11 Thread Alexey Kardashevskiy
On 12/08/16 12:57, David Gibson wrote: > On Wed, Aug 03, 2016 at 06:40:46PM +1000, Alexey Kardashevskiy wrote: >> In some situations the userspace memory context may live longer than >> the userspace process itself so if we need to do proper memory context >> cleanup, we better cache @mm and use it

Re: [PATCH kernel 05/15] powerpc/iommu: Stop using @current in mm_iommu_xxx

2016-08-11 Thread David Gibson
On Wed, Aug 03, 2016 at 06:40:46PM +1000, Alexey Kardashevskiy wrote: > In some situations the userspace memory context may live longer than > the userspace process itself so if we need to do proper memory context > cleanup, we better cache @mm and use it later when the process is gone > (@current

Re: [PATCH kernel 05/15] powerpc/iommu: Stop using @current in mm_iommu_xxx

2016-08-08 Thread Balbir Singh
On 09/08/16 16:04, Nicholas Piggin wrote: > On Tue, 9 Aug 2016 14:43:00 +1000 > Balbir Singh wrote: > >> On 03/08/16 18:40, Alexey Kardashevskiy wrote: > >>> -long mm_iommu_get(unsigned long ua, unsigned long entries, >>> +long mm_iommu_get(struct mm_struct *mm, unsigned long ua, unsigned long

Re: [PATCH kernel 05/15] powerpc/iommu: Stop using @current in mm_iommu_xxx

2016-08-08 Thread Nicholas Piggin
On Tue, 9 Aug 2016 14:43:00 +1000 Balbir Singh wrote: > On 03/08/16 18:40, Alexey Kardashevskiy wrote: > > -long mm_iommu_get(unsigned long ua, unsigned long entries, > > +long mm_iommu_get(struct mm_struct *mm, unsigned long ua, unsigned long > > entries, > > struct mm_iommu_table_

Re: [PATCH kernel 05/15] powerpc/iommu: Stop using @current in mm_iommu_xxx

2016-08-08 Thread Alexey Kardashevskiy
On 05/08/16 17:00, Michael Ellerman wrote: > Alexey Kardashevskiy writes: > >> In some situations the userspace memory context may live longer than >> the userspace process itself so if we need to do proper memory context >> cleanup, we better cache @mm and use it later when the process is gone >

Re: [PATCH kernel 05/15] powerpc/iommu: Stop using @current in mm_iommu_xxx

2016-08-08 Thread Balbir Singh
On 03/08/16 18:40, Alexey Kardashevskiy wrote: > In some situations the userspace memory context may live longer than > the userspace process itself so if we need to do proper memory context > cleanup, we better cache @mm and use it later when the process is gone > (@current or @current->mm are N

Re: [PATCH kernel 05/15] powerpc/iommu: Stop using @current in mm_iommu_xxx

2016-08-05 Thread Michael Ellerman
Alexey Kardashevskiy writes: > In some situations the userspace memory context may live longer than > the userspace process itself so if we need to do proper memory context > cleanup, we better cache @mm and use it later when the process is gone > (@current or @current->mm are NULL). > > This cha

Re: [PATCH kernel 05/15] powerpc/iommu: Stop using @current in mm_iommu_xxx

2016-08-03 Thread Nicholas Piggin
On Wed, 3 Aug 2016 18:40:46 +1000 Alexey Kardashevskiy wrote: > In some situations the userspace memory context may live longer than > the userspace process itself so if we need to do proper memory context > cleanup, we better cache @mm and use it later when the process is gone > (@current or @c

[PATCH kernel 05/15] powerpc/iommu: Stop using @current in mm_iommu_xxx

2016-08-03 Thread Alexey Kardashevskiy
In some situations the userspace memory context may live longer than the userspace process itself so if we need to do proper memory context cleanup, we better cache @mm and use it later when the process is gone (@current or @current->mm are NULL). This changes mm_iommu_xxx API to receive mm_struct