bioqdisksort - fixes to avoid starvation
authorMatthew Dillon <dillon@apollo.backplane.com>
Sat, 8 Aug 2009 22:07:40 +0000 (15:07 -0700)
committerMatthew Dillon <dillon@apollo.backplane.com>
Sat, 8 Aug 2009 22:07:40 +0000 (15:07 -0700)
commit539f339ee934d4f0a53b0071fb42acc78b49269b
tree71d7bc90c3ac44f49fbc38fdaba96046a7a4728a
parent440a040b9f9f331115835cebc4322d22ed35436b
bioqdisksort - fixes to avoid starvation

Long chains of pipelined write I/O were being sorted in front of other
requests.  Due to the pipelining these other requests would wind up
getting starved virtually permanently.

Prevent starvation by forcing one out of every 16 BIOs to be ordered.

This fixes issues with HAMMER which tends to have more of an absolute
ordering of meta data verses data then UFS.
sys/kern/subr_disk.c
sys/sys/buf.h
sys/sys/buf2.h