Re: per-bdi-throttling: synchronous writepage doesn't work correctly

2007-11-01 Thread Peter Zijlstra
On Thu, 2007-11-01 at 20:19 +0100, Miklos Szeredi wrote: > > > > > > See the file "Locking" for more details. > > > > > > > > > The "should set PG_Writeback" bit threw me off I guess. > > > > Hmm, set_page_writeback() is also the one clearing the radix tree dirty > > tag. So if that is n

Re: per-bdi-throttling: synchronous writepage doesn't work correctly

2007-11-01 Thread Miklos Szeredi
> > > > See the file "Locking" for more details. > > > > > > The "should set PG_Writeback" bit threw me off I guess. > > Hmm, set_page_writeback() is also the one clearing the radix tree dirty > tag. So if that is not called, we get in a bit of a mess, no? > > Which makes me think hostfs

Re: per-bdi-throttling: synchronous writepage doesn't work correctly

2007-11-01 Thread Peter Zijlstra
On Thu, 2007-11-01 at 18:16 +0100, Peter Zijlstra wrote: > On Thu, 2007-11-01 at 18:09 +0100, Peter Zijlstra wrote: > > On Thu, 2007-11-01 at 18:00 +0100, Miklos Szeredi wrote: > > > > > Hi, > > > > > > > > > > It looks like bdi_thresh will always be zero if filesystem does > > > > > synchronous w

Re: per-bdi-throttling: synchronous writepage doesn't work correctly

2007-11-01 Thread Peter Zijlstra
On Thu, 2007-11-01 at 18:28 +0100, Miklos Szeredi wrote: > > The page not having PG_writeback set on return is a hint, but not fool > > proof, it could be the device is just blazing fast. > > Hmm, does it actually has to be foolproof though? What will happen if > bdi_writeout_inc() is called twic

Re: per-bdi-throttling: synchronous writepage doesn't work correctly

2007-11-01 Thread Miklos Szeredi
> The page not having PG_writeback set on return is a hint, but not fool > proof, it could be the device is just blazing fast. Hmm, does it actually has to be foolproof though? What will happen if bdi_writeout_inc() is called twice for the page? The device will get twice the number of pages it d

Re: per-bdi-throttling: synchronous writepage doesn't work correctly

2007-11-01 Thread Peter Zijlstra
On Thu, 2007-11-01 at 18:09 +0100, Peter Zijlstra wrote: > On Thu, 2007-11-01 at 18:00 +0100, Miklos Szeredi wrote: > > > > Hi, > > > > > > > > It looks like bdi_thresh will always be zero if filesystem does > > > > synchronous writepage, resulting in very poor write performance. > > > > > > > >

Re: per-bdi-throttling: synchronous writepage doesn't work correctly

2007-11-01 Thread Peter Zijlstra
On Thu, 2007-11-01 at 18:00 +0100, Miklos Szeredi wrote: > > > Hi, > > > > > > It looks like bdi_thresh will always be zero if filesystem does > > > synchronous writepage, resulting in very poor write performance. > > > > > > Hostfs (UML) is one such example, but there might be others. > > > > >

Re: per-bdi-throttling: synchronous writepage doesn't work correctly

2007-11-01 Thread Miklos Szeredi
> > Hi, > > > > It looks like bdi_thresh will always be zero if filesystem does > > synchronous writepage, resulting in very poor write performance. > > > > Hostfs (UML) is one such example, but there might be others. > > > > The only solution I can think of is to add a set_page_writeback(); > >

Re: per-bdi-throttling: synchronous writepage doesn't work correctly

2007-11-01 Thread Peter Zijlstra
On Thu, 2007-11-01 at 17:49 +0100, Miklos Szeredi wrote: > Hi, > > It looks like bdi_thresh will always be zero if filesystem does > synchronous writepage, resulting in very poor write performance. > > Hostfs (UML) is one such example, but there might be others. > > The only solution I can think

per-bdi-throttling: synchronous writepage doesn't work correctly

2007-11-01 Thread Miklos Szeredi
Hi, It looks like bdi_thresh will always be zero if filesystem does synchronous writepage, resulting in very poor write performance. Hostfs (UML) is one such example, but there might be others. The only solution I can think of is to add a set_page_writeback(); end_page_writeback() pair (or some