Package Details: linux-bfq-mq-docs 4.16.3-1

Git Clone URL: https://aur.archlinux.org/linux-bfq-mq.git (read-only)
Package Base: linux-bfq-mq
Description: Kernel hackers manual - HTML documentation that comes with the Linux-bfq-mq kernel
Upstream URL: https://github.com/Algodev-github/bfq-mq/
Licenses: GPL2
Provides: linux-bfq-mq-docs=4.16.3, linux-docs=4.16.3
Submitter: monotykamary
Maintainer: monotykamary (sir_lucjan)
Last Packager: sir_lucjan
Votes: 5
Popularity: 0.074035
First Submitted: 2017-05-11 19:00
Last Updated: 2018-04-19 11:27

Pinned Comments

monotykamary commented on 2017-05-14 16:02

IO scheduler will default to "mq-deadline" given that DEFAULT_MQ_IOSCHED is currently not implemented in mainline. For now, you can use `sudo tee /sys/block/sda/queue/scheduler <<< bfq-mq` to enable "bfq-mq".

You can also add this to your udev rules:
```
# Non-rotational disks
ACTION=="add|change", KERNEL=="sd[a-z]", ATTR{queue/rotational}=="0", ATTR{queue/scheduler}="bfq-mq"
# Rotational disks
ACTION=="add|change", KERNEL=="sd[a-z]", ATTR{queue/rotational}=="1", ATTR{queue/scheduler}="bfq-mq"
```

`sudo udevadm control --reload && sudo udevadm trigger`

Configs are left at Arch default and v4.12 defaults except for the following definitions:

CONFIG_IOSCHED_BFQ=y
CONFIG_BFQ_GROUP_IOSCHED=y
CONFIG_DEFAULT_BFQ=y
CONFIG_DEFAULT_IOSCHED="bfq-sq"
CONFIG_MQ_IOSCHED_BFQ=y
CONFIG_MQ_BFQ_GROUP_IOSCHED=y

`config.i686` was made in deselecting x64 in `make xconfig`, but has not been tested.

The patch (4.12-bfq-mq-*.patch) is formatted from `git format-patch 87b2c3fc6317` straight from a local clone of https://github.com/Algodev-github/bfq-mq. Makefile commits are now kept in newer patches for use of sir_lucjan's Makefile stream edits.

Latest Comments

sir_lucjan commented on 2018-01-29 21:56

@Mthw

not out of date until 4.15.x hits to [core]

test0 commented on 2017-11-26 10:59

@monotykamary:

Now everything is clear, thank you very much for the explanation.

monotykamary commented on 2017-11-26 09:30

@test0

That should be correct. [noop, deadline, cfq] are single-queue IO schedulers and [mq-deadline, kyber, bfq, none] are multi-queue IO schedulers. In terms of how the patch is applied, there are no problems as to where bfq-sq and bfq-mq are applied.

As to why this is happening is because in this this pkgbase, we use config options `CONFIG_DM_MQ_DEFAULT=y` and `CONFIG_SCSI_MQ_DEFAULT=y` which enables multi-queue IO scheduling by default. If you would like to revert to single-queue IO scheduling without recompiling the package, you can use the kernel bootline options `scsi_mod.use_blk_mq=n dm_mod.use_blk_mq=n`.

Probably prior to 4.14.2, these config options were probably disabled and may have been re-enabled after the package resync. EDIT: More specifically in this commit: https://aur.archlinux.org/cgit/aur.git/commit/?h=linux-bfq-mq&id=bd6e5f752a538c1783bf75ac5f5a33c5c6905dbf

test0 commented on 2017-11-26 09:16

So I have dug a bit more. I usually build linux-bfq-mq with '_localmodcfg=y', this is the only change I make to the vanilla PKGBUILD. For previous version of linux-bfq-mq 4.13.11-1, which was build with '_localmodcfg=y', after reboot I have:

$ cat /sys/block/sda/queue/scheduler
noop deadline cfq [bfq-sq]

$ zgrep IOSCHED /proc/config.gz
CONFIG_IOSCHED_NOOP=y
CONFIG_IOSCHED_DEADLINE=y
CONFIG_IOSCHED_CFQ=y
CONFIG_CFQ_GROUP_IOSCHED=y
CONFIG_IOSCHED_BFQ_SQ=y
CONFIG_BFQ_SQ_GROUP_IOSCHED=y
CONFIG_DEFAULT_IOSCHED="bfq-sq"
CONFIG_MQ_IOSCHED_BFQ=y
CONFIG_MQ_BFQ_GROUP_IOSCHED=y
CONFIG_MQ_IOSCHED_DEADLINE=y
CONFIG_MQ_IOSCHED_KYBER=y
CONFIG_IOSCHED_BFQ=y
CONFIG_BFQ_GROUP_IOSCHED=y

However with linux-bfq-mq 4.14.2-3 with or without '_localmodcfg=y' after reboot I have:

$ cat /sys/block/sda/queue/scheduler
[mq-deadline] kyber bfq bfq-mq none

$ zgrep IOSCHED /proc/config.gz
CONFIG_IOSCHED_NOOP=y
CONFIG_IOSCHED_DEADLINE=y
CONFIG_IOSCHED_CFQ=y
CONFIG_CFQ_GROUP_IOSCHED=y
CONFIG_IOSCHED_BFQ_SQ=y
CONFIG_BFQ_SQ_GROUP_IOSCHED=y
CONFIG_DEFAULT_IOSCHED="bfq-sq"
CONFIG_MQ_IOSCHED_BFQ=y
CONFIG_MQ_BFQ_GROUP_IOSCHED=y
CONFIG_MQ_IOSCHED_DEADLINE=y
CONFIG_MQ_IOSCHED_KYBER=y
CONFIG_IOSCHED_BFQ=y
CONFIG_BFQ_GROUP_IOSCHED=y

Maybe I something messed up, but I'm not aware what this can be. I have always built every version of linux-bfq-mq package in the same way, but starting from 4.14.2 version there is something wrong with elevator's names (in fact I should assume starting from 4.14 version, because it's very improbable that minor version change has any impact on this issue).

sir_lucjan commented on 2017-11-25 12:00

@test0 - sorry, that was my bad.

But...

@@ -63,6 +93,7 @@ config DEFAULT_IOSCHED
string
default "deadline" if DEFAULT_DEADLINE
default "cfq" if DEFAULT_CFQ
+ default "bfq-sq" if DEFAULT_BFQ_SQ
default "noop" if DEFAULT_NOOP

You're wrong.

sir_lucjan commented on 2017-11-25 12:00

@test0 - sorry, that was my bad.

But...

@@ -63,6 +93,7 @@ config DEFAULT_IOSCHED
string
default "deadline" if DEFAULT_DEADLINE
default "cfq" if DEFAULT_CFQ
+ default "bfq-sq" if DEFAULT_BFQ_SQ
default "noop" if DEFAULT_NOOP

You're wrong.

monotykamary commented on 2017-11-25 10:32

@test0

I have added back the _srcpatch variable to SUBLEVEL which will point to the correct patch version to fix the apply error.

As for CONFIG_DEFAULT_IOSCHED, there doesn't seem to be any change from upstream bfq-mq[1][2] that shows bfq-sq or its conditionals were removed. However, bfq-sq was removed from blk-mq[3] some time ago.

--
[1] https://github.com/Algodev-github/bfq-mq/blob/bb4162667e471c0a63fdc9c4ee1b7899331f1f18/block/bfq-sq-iosched.c
[2] https://github.com/Algodev-github/bfq-mq/blob/abdfb33a3325df55ec0261fd824ca61ddac13575/block/Kconfig.iosched
[3] https://github.com/Algodev-github/bfq-mq/commit/cf794d80a7f88faff3a4ca37d3cda1a2391ccab1#diff-0e55bac8567a89d2861df16ed50bbd34L5325

test0 commented on 2017-11-25 09:46

@sir_lucjan:

Please adjust 'SUBLEVEL' in the PKGBUILD, otherwise bfq patch is applying incorrectly. There should be line:
"s|SUBLEVEL = 0|SUBLEVEL = 2|g"

Also please adjust 'CONFIG_DEFAULT_IOSCHED' in the config, because with the newer bfq patch there is no "bfq-sq" elevator name anymore. Available elevator names are 'bfq' or 'bfq-mq', otherwise by default 'mq-deadline' is selected.

Best regards.

monotykamary commented on 2017-08-14 23:23

I have added mailing list patches (currently includes Ming Lei's patches for SCSI-MQ) thanks to and reference from sir_lucjan.

They are disabled by default to be faithful to the original bfq-mq repository, but feel free to enable them in the PKGBUILD.

monotykamary commented on 2017-08-12 04:12

Well, that didn't last long. Patches have been reverted to the old diff and hand delete method, but at least I kept the path convention.

Since upstream patches are just cherry-picked commits from the rc tags, cherry-picking on top of that becomes very unreliable.

All comments