Re: [PATCH v2 06/11] mm/hmm: improve driver API to work and wait over a range v2

2019-03-28 Thread Ira Weiny
On Thu, Mar 28, 2019 at 08:56:54PM -0400, Jerome Glisse wrote: > On Thu, Mar 28, 2019 at 09:12:21AM -0700, Ira Weiny wrote: > > On Mon, Mar 25, 2019 at 10:40:06AM -0400, Jerome Glisse wrote: > > > From: Jérôme Glisse > > > [snip] > > > +/* > > > + * HMM_RANGE_DEFAULT_TIMEOUT - default timeout (

Re: [PATCH v2 06/11] mm/hmm: improve driver API to work and wait over a range v2

2019-03-28 Thread Jerome Glisse
On Thu, Mar 28, 2019 at 09:12:21AM -0700, Ira Weiny wrote: > On Mon, Mar 25, 2019 at 10:40:06AM -0400, Jerome Glisse wrote: > > From: Jérôme Glisse > > > > A common use case for HMM mirror is user trying to mirror a range > > and before they could program the hardware it get invalidated by > > so

Re: [PATCH v2 06/11] mm/hmm: improve driver API to work and wait over a range v2

2019-03-28 Thread Ira Weiny
On Mon, Mar 25, 2019 at 10:40:06AM -0400, Jerome Glisse wrote: > From: Jérôme Glisse > > A common use case for HMM mirror is user trying to mirror a range > and before they could program the hardware it get invalidated by > some core mm event. Instead of having user re-try right away to > mirror

Re: [PATCH v2 06/11] mm/hmm: improve driver API to work and wait over a range v2

2019-03-28 Thread Jerome Glisse
On Thu, Mar 28, 2019 at 06:11:54AM -0700, Ira Weiny wrote: > On Mon, Mar 25, 2019 at 10:40:06AM -0400, Jerome Glisse wrote: > > From: Jérôme Glisse > > > > A common use case for HMM mirror is user trying to mirror a range > > and before they could program the hardware it get invalidated by > > so

Re: [PATCH v2 06/11] mm/hmm: improve driver API to work and wait over a range v2

2019-03-28 Thread Ira Weiny
On Mon, Mar 25, 2019 at 10:40:06AM -0400, Jerome Glisse wrote: > From: Jérôme Glisse > > A common use case for HMM mirror is user trying to mirror a range > and before they could program the hardware it get invalidated by > some core mm event. Instead of having user re-try right away to > mirror

[PATCH v2 06/11] mm/hmm: improve driver API to work and wait over a range v2

2019-03-25 Thread jglisse
From: Jérôme Glisse A common use case for HMM mirror is user trying to mirror a range and before they could program the hardware it get invalidated by some core mm event. Instead of having user re-try right away to mirror the range provide a completion mechanism for them to wait for any active in