Re: Should implementations of ->direct_access be allowed to sleep?

2015-03-29 Thread Boaz Harrosh
On 03/29/2015 11:02 AM, Boaz Harrosh wrote: > On 03/26/2015 09:32 PM, Dave Chinner wrote: <> > I think that ->direct_access should not be any different then > any other block-device access, ie allow to sleep. > BTW: Matthew you yourself have said that after a page-load of memcpy a user should

Re: Should implementations of ->direct_access be allowed to sleep?

2015-03-29 Thread Boaz Harrosh
On 03/26/2015 09:32 PM, Dave Chinner wrote: <> >> I'm leaning towards the latter. But I'm not sure what GFP flags to >> recommend that brd use ... GFP_NOWAIT | __GFP_ZERO, perhaps? > > What, so we get random IO failures under memory pressure? > > I really think we should allow .direct_access to

Re: Should implementations of -direct_access be allowed to sleep?

2015-03-29 Thread Boaz Harrosh
On 03/29/2015 11:02 AM, Boaz Harrosh wrote: On 03/26/2015 09:32 PM, Dave Chinner wrote: I think that -direct_access should not be any different then any other block-device access, ie allow to sleep. BTW: Matthew you yourself have said that after a page-load of memcpy a user should call

Re: Should implementations of -direct_access be allowed to sleep?

2015-03-29 Thread Boaz Harrosh
On 03/26/2015 09:32 PM, Dave Chinner wrote: I'm leaning towards the latter. But I'm not sure what GFP flags to recommend that brd use ... GFP_NOWAIT | __GFP_ZERO, perhaps? What, so we get random IO failures under memory pressure? I really think we should allow .direct_access to sleep. It

Re: Should implementations of ->direct_access be allowed to sleep?

2015-03-26 Thread Dave Chinner
On Thu, Mar 26, 2015 at 01:09:18PM -0400, Matthew Wilcox wrote: > On Tue, Mar 24, 2015 at 11:50:47AM -0700, Matt Mullins wrote: > > We're also developing a user of direct_access, and we ended up with some > > questions about the sleeping guarantees of the direct_access API. > > That's a great

Should implementations of ->direct_access be allowed to sleep?

2015-03-26 Thread Matthew Wilcox
On Tue, Mar 24, 2015 at 11:50:47AM -0700, Matt Mullins wrote: > We're also developing a user of direct_access, and we ended up with some > questions about the sleeping guarantees of the direct_access API. That's a great question. Since DAX can always sleep when it's calling into

Should implementations of -direct_access be allowed to sleep?

2015-03-26 Thread Matthew Wilcox
On Tue, Mar 24, 2015 at 11:50:47AM -0700, Matt Mullins wrote: We're also developing a user of direct_access, and we ended up with some questions about the sleeping guarantees of the direct_access API. That's a great question. Since DAX can always sleep when it's calling into

Re: Should implementations of -direct_access be allowed to sleep?

2015-03-26 Thread Dave Chinner
On Thu, Mar 26, 2015 at 01:09:18PM -0400, Matthew Wilcox wrote: On Tue, Mar 24, 2015 at 11:50:47AM -0700, Matt Mullins wrote: We're also developing a user of direct_access, and we ended up with some questions about the sleeping guarantees of the direct_access API. That's a great question.