Subject: Re: Changing the I/O scheduler on-the-fly
To: YAMAMOTO Takashi <yamt@mwd.biglobe.ne.jp>
From: Juan RP <juan@xtrarom.org>
List: tech-kern
Date: 09/08/2005 02:43:00
On Thu, 08 Sep 2005 08:34:18 +0900
YAMAMOTO Takashi <yamt@mwd.biglobe.ne.jp> wrote:

> sorry, explaining how to implement the functionality in english
> likely takes far much time for me than implementing it by myself.
> please read the code. :)
> 
> i think that the best way is refining bufq interface
> to stop embedding bufq_state in softc.

With uep's help and his comments about the problems on my
my previous implementation, I've modified the disk_set_sched()
function again... now it does:

	* Creates one additional bufq_state struct, for temporal data;
	* Copy the orig bufq data (from disk softc) to the temp data;
	* Free the orig data;
	* Copy the content of temp data to the orig data again.
	* Switch to the new strategy on the disk bufq.
	* Free the temp data;

And BTW, now I know the tsleep() call was clearly wrong.

YAMAMOTO please review it again (reload the URL).

Thanks.