Given the way LBAs are located on disk and the fact that rotational
latency is a large factor in changing locations of a drive head, any
attempts to do a C-SCAN pass are pretty much useless. Further
complicating this is any volume management that sits between the fs and
the actual storage.
A nice feature to have longer term is to have the write_inodes paths for
background flushing understand storage congestion _through_ any volume
management. This would allow us to back off background flushing on a per
spindle basis (when using drives of course) and avoid write congestion
in both the io scheduler and in the drive's writecaches, which I
believe, but don't have hard evidence, get congested today, knocking the
drive into a fifo fashion in firmware.
A data structure that allows us to keep a dirtied_when values consistent
across back-offs and blocking allows us to further develop the
background writeout paths to get to this point (though exposing this
congestion information will require more work deeper in the stack).
--