sioplus: relax sync_read_expire, tighten sync_write_expire

Signed-off-by: Dan Trifan <jimsth@gmail.com>
sioplus iosched: change fifo batching logic to a sane one

Before this commit, there was always one more request
batched than set via the fifo_batch sysfs variable.
E.g., a setting of 1 would suggest that 1 request would
be handled as a batch, but instead 2 requests were batched.
This is not very logical.

Now, the pre-set setting of fifo_batch = 1 ensures that each
request is handled on its own, which is what we want for
flash memory devices.

Signed-off-by: Dan Trifan <jimsth@gmail.com>
sioplus iosched: change write starvation logic to a sane one

Before this commit, there was always one more dispatched
read request necessary than set via the writes_starved
sysfs variable. This is not logical. Fix this.

Signed-off-by: Dan Trifan <jimsth@gmail.com>
sioplus iosched: fix wrong batch counting logic

Before this commit, the batch counter was increased
with any dispatched request. This does not make sense:
Every time an expired request was picked due to the
batch counter reaching its barrier, the batch counter
was increased, effectively reducing (=crippling)the
following non-expired batch. Fix this.

Signed-off-by: Dan Trifan <jimsth@gmail.com>
sioplus iosched: update description text

Signed-off-by: Dan Trifan <jimsth@gmail.com>
sioplus iosched: tweaks (adjusting the iosched to recent changes)

Signed-off-by: Dan Trifan <jimsth@gmail.com>
sioplus iosched: tweaks based on extensive testing by pkgnex

"I've probably spent way too much time on this, but I have settled on a complete tuning set for Sioplus that seems to consistently offer modest storage benchmark improvement over the r56 settings along with great subjective feel:

async_read_expire = 500
async_write_expire = 2000
fifo_batch = 3
sync_read_expire = 250
sync_write_expire = 1250
writes_starved = 1

This set-up keeps the same read/write ratios you have in r56 (and prior), and keeps some separation between the expiration times, but shortens the expiration significantly for asynchronous operations and slightly for synchronous ones. It also groups the two different types of read operations as the first to expire, rather than the synchronous operations being first to expire. This seems to speed everything up a little in the objective testing - especially reads which are more frequent than writes, and so far feels really good subjectively on my device."

Signed-off-by: Dan Trifan <jimsth@gmail.com>