Block driver changes for 3.20
Hi Linus,
This is the pull request for block drivers for 3.20. This branch sits on top of (an earlier) for-3.20/core. It contains:
- The 4k/partition fixes for brd from Boaz/Matthew.
- A few xen front/back block fixes from David Vrabel and Roger Pau Monne.
- Floppy changes from Takashi, cleaning the device file creation.
- Switching libata to use the new blk-mq tagging policy, removing code (and a suboptimal implementation) from libata. This will throw you a merge conflict, since a bug in the original libata tagging code was fixed since this code was branched. Trivial. From Shaohua.
- Conversion of loop to blk-mq, from Ming Lei.
- Cleanup of the io_schedule() handling in bsg from Peter Zijlstra. He claims it improves on unreadable code, which will cost him a beer.
- Maintainer update or NDB, now handled by Markus Pargmann.
- NVMe:
- Optimization from me that avoids a kmalloc/kfree per IO for smaller (<= 8KB) IO. This cuts about 1% of high IOPS CPU overhead.
- Removal of (now) dead RCU code, a relic from before NVMe was converted to blk-mq.
Please pull!
git://git.kernel.dk/linux-block.git for-3.20/drivers
----------------------------------------------------------------
Boaz Harrosh (2):
brd: Fix all partitions BUGs
brd: Request from fdisk 4k alignment
David Vrabel (1):
xen-blkback: default to X86_32 ABI on x86
Jens Axboe (5):
loop: add blk-mq.h include
Merge branch 'for-3.20/core' into for-3.20/drivers
null_blk: suppress invalid partition info Merge branch 'for-3.20/core' into for-3.20/drivers
NVMe: avoid kmalloc/kfree for smaller IO
Markus Pargmann (1):
MAINTAINERS: Update NBD maintainer
Matthew Wilcox (1):
axonram: Fix bug in direct_access
Ming Lei (4):
block: loop: improve performance via blk-mq
block: loop: say goodby to bio
block: loop: introduce lo_discard() and lo_req_flush()
block: loop: don't handle REQ_FUA explicitly
Peter Zijlstra (1):
block: Simplify bsg complete all
Roger Pau Monne (2):
xen-blkback,xen-blkfront: add myself as maintainer
xen-blkfront: fix accounting of reqs when migrating
Shaohua Li (3):
libata: use blk taging
libata: move sas ata tag allocation to libata-scsi.c
libata: make sata_sil24 use fifo tag allocator
Takashi Iwai (1):
floppy: Avoid manual call of device_create_file()
kaoudis (1):
NVMe: within nvme_free_queues(), delete RCU sychro/deferred free
MAINTAINERS | 4 +- arch/powerpc/sysdev/axonram.c | 2 +- block/bsg.c | 72 +++---- drivers/ata/libata-core.c | 67 ++---- drivers/ata/libata-scsi.c | 30 ++- drivers/ata/libata.h | 4 +- drivers/ata/sata_sil24.c | 1 + drivers/block/brd.c | 109 +++++----- drivers/block/floppy.c | 17 +- drivers/block/loop.c | 416 ++++++++++++++++++------------------- drivers/block/loop.h | 18 +- drivers/block/null_blk.c | 2 +- drivers/block/nvme-core.c | 128 ++++++++---- drivers/block/xen-blkback/common.h | 9 + drivers/block/xen-blkback/xenbus.c | 4 +- drivers/block/xen-blkfront.c | 4 +- include/linux/libata.h | 5 +- include/linux/nvme.h | 3 +- include/linux/wait.h | 15 ++ 19 files changed, 473 insertions(+), 437 deletions(-)
Signature · 1 line
Jens Axboe
Quoted 5 lines · Jens Axboe
- Switching libata to use the new blk-mq tagging policy, removing code (and a suboptimal implementation) from libata. This will throw you a merge conflict, since a bug in the original libata tagging code was fixed since this code was branched. Trivial. From Shaohua.
Somebody should still check my resolution, since the code had been moved to another file. Tejun / Dan, it's your commit 72dd299d5039 ("libata: allow sata_sil24 to opt-out of tag ordered submission") that added a ATA_FLAG_LOWTAG, which conflicts with commit 98bd4be1ba95 ("libata: move sas ata tag allocation to libata-scsi.c") that moved the code.
I verified that it all looks sane, and still compiles, but somebody should verify that the tag allocation changes still *work*, particularly for that sata_sil24 case.
(I haven't pushed out quite yet, I'm waiting for the rest to compile cleanly too, and then I'll do a local compile and boot to see that it all works for me, but I'm writing this as a heads-up)
Linus
Quoted 14 lines · Linus Torvalds
Quoted 5 lines · Jens Axboe
- Switching libata to use the new blk-mq tagging policy, removing code (and a suboptimal implementation) from libata. This will throw you a merge conflict, since a bug in the original libata tagging code was fixed since this code was branched. Trivial. From Shaohua.
Somebody should still check my resolution, since the code had been moved to another file. Tejun / Dan, it's your commit
72dd299d5039("libata: allowsata_sil24to opt-out of tag ordered submission") that added aATA_FLAG_LOWTAG, which conflicts with commit98bd4be1ba95("libata: move sas ata tag allocation tolibata-scsi.c") that moved the code.
Quoted 7 lines
I verified that it all looks sane, and still compiles, but somebody should verify that the tag allocation changes still *work*, particularly for that
sata_sil24case.(I haven't pushed out quite yet, I'm waiting for the rest to compile cleanly too, and then I'll do a local compile and boot to see that it all works for me, but I'm writing this as a heads-up)
When the code was moved, it also morphed into the sas specific tag allocation. And the LOWTAG part was for sil24, which doesn't call that code anymore. So either resolution is fine:
1) Drop the LOWTAG part of ata_sas_allocate_tag(), which is the easy resolve. Or,
2) Add the two LOWTAG lines in ata_sas_allocate_tag().
So don't worry too much about it, if it compiles, it's good...
Signature · 1 line
Jens Axboe
Quoted 4 lines · Jens Axboe
When the code was moved, it also morphed into the sas specific tag allocation. And the LOWTAG part was for sil24, which doesn't call that code anymore.
Hmm. So where does the sil24 get its tag allocation from then? Because then *that* code presumably needs the LOWTAG hackery..
Linus
Quoted 8 lines · Linus Torvalds
Quoted 4 lines · Jens Axboe
When the code was moved, it also morphed into the sas specific tag allocation. And the LOWTAG part was for sil24, which doesn't call that code anymore.
Hmm. So where does the sil24 get its tag allocation from then? Because then *that* code presumably needs the LOWTAG hackery..
commit 9269e23496ddd83b974536019cf420520df0ee7f
Author: Shaohua Li <[email protected]> Date: Fri Jan 23 20:17:59 2015 -0800
libata: make sata_sil24 use fifo tag allocator
libata starts using block tag now, we can use BLK_TAG_ALLOC_FIFO to solve the sata_sil24 tag bug.
https://bugzilla.kernel.org/show_bug.cgi?id=87101
Signature · 1 line
Jens Axboe
Quoted 9 lines · Jens Axboe
commit
9269e23496ddd83b974536019cf420520df0ee7fAuthor: Shaohua Li <[email protected]> Date: Fri Jan 23 20:17:59 2015 -0800libata: make
sata_sil24use fifo tag allocatorlibata starts using block tag now, we can use
BLK_TAG_ALLOC_FIFOto solve thesata_sil24tag bug.
Ahh, ok. So we should probably just remove the now unused/useless ATA_FLAG_LOWTAG entirely.
I'll leave my resolution alone, and leave that for Tejun if he cares.
Thanks,
Linus
Quoted 6 lines · Linus Torvalds
Quoted 5 lines · Jens Axboe
commit
9269e23496ddd83b974536019cf420520df0ee7fAuthor: Shaohua Li <[email protected]> Date: Fri Jan 23 20:17:59 2015 -0800
Quoted 7 lines
Quoted 4 lines
libata: make
sata_sil24use fifo tag allocatorlibata starts using block tag now, we can use
BLK_TAG_ALLOC_FIFOto solve thesata_sil24tag bug.Ahh, ok. So we should probably just remove the now unused/useless
ATA_FLAG_LOWTAGentirely.
Yeah, we can kill that after the fact. I probably should have pulled in that commit from Dan and fixed this up... But in any case, it'll be fine as is right now.
Signature · 1 line
Jens Axboe
Hello,
Quoted 3 lines · Jens Axboe
Yeah, we can kill that after the fact. I probably should have pulled in that commit from Dan and fixed this up... But in any case, it'll be fine as is right now.
Yeap, the current code should be fine. I'll remove the LOWTAG flag from libata side in the coming devel window.
Thanks.
Signature · 1 line
tejun
Hi Linus,
Quoted 3 lines · On Thu, 12 Feb 2015 13:57:52 -0700 Jens Axboe <[email protected]> wrote:
Shaohua Li (3):
libata: move sas ata tag allocation tolibata-scsi.c
So, I assume you figured out the attached semantic conflict ...
Signature · 2 lines
Cheers, Stephen Rothwell [email protected]
Hi Jens,
Today's linux-next merge of the block tree got a conflict in drivers/ata/libata-core.c between commit 72dd299d5039 ("libata: allow sata_sil24 to opt-out of tag ordered submission") from Linus' tree and commit 98bd4be1ba95 ("libata: move sas ata tag allocation to libata-scsi.c") from the block tree.
I fixed it up (I used the version from the block tree and then added the following patch) and can carry the fix as necessary (no action is required).
From: Stephen Rothwell <[email protected]>
Date: Tue, 27 Jan 2015 14:59:51 +1100
Subject: [PATCH] libata: fix for move of sas tag allocation code
--- drivers/ata/libata-scsi.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
drivers/ata/libata-scsi.c +4 -1
@@ -4240,7 +4240,10 @@ int ata_sas_allocate_tag(struct ata_port *ap)unsigned int i, tag;for (i =0 , tag = ap->sas_last_tag +1 ; i < max_queue; i++, tag++) { - tag = tag < max_queue ? tag :0 ; +if (ap->flags &ATA_FLAG_LOWTAG ) + tag = i; +else + tag = tag < max_queue ? tag :0 ;/* the last tag is reserved for internal command. */ if (tag ==ATA_TAG_INTERNAL )
Signature · 5 lines
2.1.4 -- Cheers, Stephen Rothwell [email protected]