Subject: Re: Limiting disk I/O?
To: Matthias Scheler <tron@zhadum.org.uk>
From: Jukka Marin <jmarin@embedtronics.fi>
List: tech-kern
Date: 12/04/2007 16:11:42
On Tue, Dec 04, 2007 at 02:06:40PM +0000, Matthias Scheler wrote:
> Can the flush be stopped and resume later? If I understood correctly the
> problem is that when the system flushes it flushes everything. So the
> loop should look like this perhaps:
> 
> void
> Flush()
> {
> 	while (something_to_be_flushed()) {
> 		flush_a_bit();
> 		if (more_io_waiting() and have_some_free_buffer_space())
> 			return;
> 	}
> }

Sounds better again :)

  -jm