block: cgroups, kconfig, build bits for BFQ-v7r11-4.4.0

Update Kconfig.iosched and do the related Makefile changes to include
kernel configuration options for BFQ. Also increase the number of
policies supported by the blkio controller so that BFQ can add its
own.

Signed-off-by: Paolo Valente <paolo.valente@unimore.it>
Signed-off-by: Arianna Avanzini <avanzini@google.com>
This commit is contained in:
Paolo Valente 2015-04-07 13:39:12 +02:00 committed by Timi
parent 9ffe929d8a
commit 89190bd929
3 changed files with 25 additions and 11 deletions

View file

@ -54,20 +54,22 @@ config IOSCHED_BFQ
tristate "BFQ I/O scheduler" tristate "BFQ I/O scheduler"
default n default n
---help--- ---help---
The BFQ I/O scheduler distributes bandwidth among all The BFQ I/O scheduler tries to distribute bandwidth among
processes according to their weights, regardless of the all processes according to their weights.
device parameters and with any workload. It also guarantees It aims at distributing the bandwidth as desired, independently of
a low latency to interactive and soft real-time applications. the disk parameters and with any workload. It also tries to
Details in Documentation/block/bfq-iosched.txt guarantee low latency to interactive and soft real-time
applications. If compiled built-in (saying Y here), BFQ can
be configured to support hierarchical scheduling.
config BFQ_GROUP_IOSCHED config CGROUP_BFQIO
bool "BFQ hierarchical scheduling support" bool "BFQ hierarchical scheduling support"
depends on IOSCHED_BFQ && BLK_CGROUP depends on CGROUPS && IOSCHED_BFQ=y
default n default n
---help--- ---help---
Enable hierarchical scheduling in BFQ, using the cgroups
Enable hierarchical scheduling in BFQ, using the blkio filesystem interface. The name of the subsystem will be
(cgroups-v1) or io (cgroups-v2) controller. bfqio.
choice choice
prompt "Default I/O scheduler" prompt "Default I/O scheduler"
@ -82,6 +84,16 @@ choice
config DEFAULT_CFQ config DEFAULT_CFQ
bool "CFQ" if IOSCHED_CFQ=y bool "CFQ" if IOSCHED_CFQ=y
config DEFAULT_BFQ
bool "BFQ" if IOSCHED_BFQ=y
help
Selects BFQ as the default I/O scheduler which will be
used by default for all block devices.
The BFQ I/O scheduler aims at distributing the bandwidth
as desired, independently of the disk parameters and with
any workload. It also tries to guarantee low latency to
interactive and soft real-time applications.
config DEFAULT_NOOP config DEFAULT_NOOP
bool "No-op" bool "No-op"
@ -91,6 +103,7 @@ config DEFAULT_IOSCHED
string string
default "deadline" if DEFAULT_DEADLINE default "deadline" if DEFAULT_DEADLINE
default "cfq" if DEFAULT_CFQ default "cfq" if DEFAULT_CFQ
default "bfq" if DEFAULT_BFQ
default "noop" if DEFAULT_NOOP default "noop" if DEFAULT_NOOP
endmenu endmenu

View file

@ -20,6 +20,7 @@ obj-$(CONFIG_IOSCHED_DEADLINE) += deadline-iosched.o
obj-$(CONFIG_IOSCHED_CFQ) += cfq-iosched.o obj-$(CONFIG_IOSCHED_CFQ) += cfq-iosched.o
obj-$(CONFIG_IOSCHED_BFQ) += bfq-iosched.o obj-$(CONFIG_IOSCHED_BFQ) += bfq-iosched.o
obj-$(CONFIG_IOSCHED_TEST) += test-iosched.o obj-$(CONFIG_IOSCHED_TEST) += test-iosched.o
obj-$(CONFIG_IOSCHED_BFQ) += bfq-iosched.o
obj-$(CONFIG_BLOCK_COMPAT) += compat_ioctl.o obj-$(CONFIG_BLOCK_COMPAT) += compat_ioctl.o
obj-$(CONFIG_BLK_CMDLINE_PARSER) += cmdline-parser.o obj-$(CONFIG_BLK_CMDLINE_PARSER) += cmdline-parser.o

View file

@ -44,7 +44,7 @@ struct pr_ops;
* Maximum number of blkcg policies allowed to be registered concurrently. * Maximum number of blkcg policies allowed to be registered concurrently.
* Defined here to simplify include dependency. * Defined here to simplify include dependency.
*/ */
#define BLKCG_MAX_POLS 2 #define BLKCG_MAX_POLS 3
struct request; struct request;
typedef void (rq_end_io_fn)(struct request *, int); typedef void (rq_end_io_fn)(struct request *, int);