Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge branch 'for-linus' of git://git.kernel.dk/linux-block

Pull block fixes from Jens Axboe:
"Three fixes, two regressions and one that poses a problem in blk-mq
with the new nvmef code"

* 'for-linus' of git://git.kernel.dk/linux-block:
blk-mq: skip unmapped queues in blk_mq_alloc_request_hctx
nvme-rdma: only clear queue flags after successful connect
blk-throttle: Extend slice if throttle group is not empty

+19 -5
+14 -2
block/blk-mq.c
··· 296 296 if (ret) 297 297 return ERR_PTR(ret); 298 298 299 + /* 300 + * Check if the hardware context is actually mapped to anything. 301 + * If not tell the caller that it should skip this queue. 302 + */ 299 303 hctx = q->queue_hw_ctx[hctx_idx]; 304 + if (!blk_mq_hw_queue_mapped(hctx)) { 305 + ret = -EXDEV; 306 + goto out_queue_exit; 307 + } 300 308 ctx = __blk_mq_get_ctx(q, cpumask_first(hctx->cpumask)); 301 309 302 310 blk_mq_set_alloc_data(&alloc_data, q, flags, ctx, hctx); 303 311 rq = __blk_mq_alloc_request(&alloc_data, rw, 0); 304 312 if (!rq) { 305 - blk_queue_exit(q); 306 - return ERR_PTR(-EWOULDBLOCK); 313 + ret = -EWOULDBLOCK; 314 + goto out_queue_exit; 307 315 } 308 316 309 317 return rq; 318 + 319 + out_queue_exit: 320 + blk_queue_exit(q); 321 + return ERR_PTR(ret); 310 322 } 311 323 EXPORT_SYMBOL_GPL(blk_mq_alloc_request_hctx); 312 324
+4 -2
block/blk-throttle.c
··· 780 780 /* 781 781 * If previous slice expired, start a new one otherwise renew/extend 782 782 * existing slice to make sure it is at least throtl_slice interval 783 - * long since now. 783 + * long since now. New slice is started only for empty throttle group. 784 + * If there is queued bio, that means there should be an active 785 + * slice and it should be extended instead. 784 786 */ 785 - if (throtl_slice_used(tg, rw)) 787 + if (throtl_slice_used(tg, rw) && !(tg->service_queue.nr_queued[rw])) 786 788 throtl_start_new_slice(tg, rw); 787 789 else { 788 790 if (time_before(tg->slice_end[rw], jiffies + throtl_slice))
+1 -1
drivers/nvme/host/rdma.c
··· 561 561 562 562 queue = &ctrl->queues[idx]; 563 563 queue->ctrl = ctrl; 564 - queue->flags = 0; 565 564 init_completion(&queue->cm_done); 566 565 567 566 if (idx > 0) ··· 594 595 goto out_destroy_cm_id; 595 596 } 596 597 598 + clear_bit(NVME_RDMA_Q_DELETING, &queue->flags); 597 599 set_bit(NVME_RDMA_Q_CONNECTED, &queue->flags); 598 600 599 601 return 0;