Re: [PATCH 4/4] mm/hmm: change CPU page table snapshot functions to simplify drivers

2018-03-16 Thread Jerome Glisse
On Thu, Mar 15, 2018 at 10:08:21PM -0700, John Hubbard wrote: > On 03/15/2018 11:37 AM, jgli...@redhat.com wrote: > > From: Jérôme Glisse > > > > This change hmm_vma_fault() and hmm_vma_get_pfns() API to allow HMM > > to directly write entry that can match any device page

Re: [PATCH 4/4] mm/hmm: change CPU page table snapshot functions to simplify drivers

2018-03-16 Thread Jerome Glisse
On Thu, Mar 15, 2018 at 10:08:21PM -0700, John Hubbard wrote: > On 03/15/2018 11:37 AM, jgli...@redhat.com wrote: > > From: Jérôme Glisse > > > > This change hmm_vma_fault() and hmm_vma_get_pfns() API to allow HMM > > to directly write entry that can match any device page table entry > > format.

Re: [PATCH 4/4] mm/hmm: change CPU page table snapshot functions to simplify drivers

2018-03-15 Thread John Hubbard
On 03/15/2018 11:37 AM, jgli...@redhat.com wrote: > From: Jérôme Glisse > > This change hmm_vma_fault() and hmm_vma_get_pfns() API to allow HMM > to directly write entry that can match any device page table entry > format. Device driver now provide an array of flags value and

Re: [PATCH 4/4] mm/hmm: change CPU page table snapshot functions to simplify drivers

2018-03-15 Thread John Hubbard
On 03/15/2018 11:37 AM, jgli...@redhat.com wrote: > From: Jérôme Glisse > > This change hmm_vma_fault() and hmm_vma_get_pfns() API to allow HMM > to directly write entry that can match any device page table entry > format. Device driver now provide an array of flags value and we use > enum to

[PATCH 4/4] mm/hmm: change CPU page table snapshot functions to simplify drivers

2018-03-15 Thread jglisse
From: Jérôme Glisse This change hmm_vma_fault() and hmm_vma_get_pfns() API to allow HMM to directly write entry that can match any device page table entry format. Device driver now provide an array of flags value and we use enum to index this array for each flag. This also

[PATCH 4/4] mm/hmm: change CPU page table snapshot functions to simplify drivers

2018-03-15 Thread jglisse
From: Jérôme Glisse This change hmm_vma_fault() and hmm_vma_get_pfns() API to allow HMM to directly write entry that can match any device page table entry format. Device driver now provide an array of flags value and we use enum to index this array for each flag. This also allow the device