implement 'unit_base' option to select between KB and Kbit et. al.

With network testing, it's often desirable to measure in terms of
kilobits/megabits rather than kilobytes/megabytes. This adds an option named
'unit_base' which can be set to either '1' or '8', where '1' means represent in
terms of bits and '8' means to represent rate in terms of bytes.

Signed-off-by: Steven Noonan <steven@uplinklabs.net>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
diff --git a/init.c b/init.c
index 92b3e5b..44c74e3 100644
--- a/init.c
+++ b/init.c
@@ -560,6 +560,13 @@
 		}
 	}
 
+	if (!o->unit_base) {
+		if (td->io_ops->flags & FIO_BIT_BASED)
+			o->unit_base = 1;
+		else
+			o->unit_base = 8;
+	}
+
 #ifndef CONFIG_FDATASYNC
 	if (o->fdatasync_blocks) {
 		log_info("fio: this platform does not support fdatasync()"