aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2014-12-13 17:14:23 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2014-12-13 17:14:23 -0500
commitcaf292ae5bb9d57198ce001d8b762f7abae3a94d (patch)
tree5fd5d6d971503818ab2824407134cf36a80c53d0 /drivers
parent8f4385d590d4296ec38e228d17b1d002f6031dd2 (diff)
parentfcbf6a087a7e4d3f03d28333678a1010810a53c3 (diff)
Merge branch 'for-3.19/core' of git://git.kernel.dk/linux-block
Pull block driver core update from Jens Axboe: "This is the pull request for the core block IO changes for 3.19. Not a huge round this time, mostly lots of little good fixes: - Fix a bug in sysfs blktrace interface causing a NULL pointer dereference, when enabled/disabled through that API. From Arianna Avanzini. - Various updates/fixes/improvements for blk-mq: - A set of updates from Bart, mostly fixing buts in the tag handling. - Cleanup/code consolidation from Christoph. - Extend queue_rq API to be able to handle batching issues of IO requests. NVMe will utilize this shortly. From me. - A few tag and request handling updates from me. - Cleanup of the preempt handling for running queues from Paolo. - Prevent running of unmapped hardware queues from Ming Lei. - Move the kdump memory limiting check to be in the correct location, from Shaohua. - Initialize all software queues at init time from Takashi. This prevents a kobject warning when CPUs are brought online that weren't online when a queue was registered. - Single writeback fix for I_DIRTY clearing from Tejun. Queued with the core IO changes, since it's just a single fix. - Version X of the __bio_add_page() segment addition retry from Maurizio. Hope the Xth time is the charm. - Documentation fixup for IO scheduler merging from Jan. - Introduce (and use) generic IO stat accounting helpers for non-rq drivers, from Gu Zheng. - Kill off artificial limiting of max sectors in a request from Christoph" * 'for-3.19/core' of git://git.kernel.dk/linux-block: (26 commits) bio: modify __bio_add_page() to accept pages that don't start a new segment blk-mq: Fix uninitialized kobject at CPU hotplugging blktrace: don't let the sysfs interface remove trace from running list blk-mq: Use all available hardware queues blk-mq: Micro-optimize bt_get() blk-mq: Fix a race between bt_clear_tag() and bt_get() blk-mq: Avoid that __bt_get_word() wraps multiple times blk-mq: Fix a use-after-free blk-mq: prevent unmapped hw queue from being scheduled blk-mq: re-check for available tags after running the hardware queue blk-mq: fix hang in bt_get() blk-mq: move the kdump check to blk_mq_alloc_tag_set blk-mq: cleanup tag free handling blk-mq: use 'nr_cpu_ids' as highest CPU ID count for hwq <-> cpu map blk: introduce generic io stat accounting help function blk-mq: handle the single queue case in blk_mq_hctx_next_cpu genhd: check for int overflow in disk_expand_part_tbl() blk-mq: add blk_mq_free_hctx_request() blk-mq: export blk_mq_free_request() blk-mq: use get_cpu/put_cpu instead of preempt_disable/preempt_enable ...
Diffstat (limited to 'drivers')
-rw-r--r--drivers/block/aoe/aoeblk.c2
-rw-r--r--drivers/block/mtip32xx/mtip32xx.c5
-rw-r--r--drivers/block/null_blk.c10
-rw-r--r--drivers/block/virtio_blk.c7
-rw-r--r--drivers/scsi/scsi_lib.c5
5 files changed, 16 insertions, 13 deletions
diff --git a/drivers/block/aoe/aoeblk.c b/drivers/block/aoe/aoeblk.c
index dd73e1ff1759..46c282fff104 100644
--- a/drivers/block/aoe/aoeblk.c
+++ b/drivers/block/aoe/aoeblk.c
@@ -395,7 +395,7 @@ aoeblk_gdalloc(void *vp)
395 WARN_ON(d->flags & DEVFL_TKILL); 395 WARN_ON(d->flags & DEVFL_TKILL);
396 WARN_ON(d->gd); 396 WARN_ON(d->gd);
397 WARN_ON(d->flags & DEVFL_UP); 397 WARN_ON(d->flags & DEVFL_UP);
398 blk_queue_max_hw_sectors(q, BLK_DEF_MAX_SECTORS); 398 blk_queue_max_hw_sectors(q, 1024);
399 q->backing_dev_info.name = "aoe"; 399 q->backing_dev_info.name = "aoe";
400 q->backing_dev_info.ra_pages = READ_AHEAD / PAGE_CACHE_SIZE; 400 q->backing_dev_info.ra_pages = READ_AHEAD / PAGE_CACHE_SIZE;
401 d->bufpool = mp; 401 d->bufpool = mp;
diff --git a/drivers/block/mtip32xx/mtip32xx.c b/drivers/block/mtip32xx/mtip32xx.c
index 1bd5f523f8fd..3bd7ca9853a8 100644
--- a/drivers/block/mtip32xx/mtip32xx.c
+++ b/drivers/block/mtip32xx/mtip32xx.c
@@ -3775,9 +3775,10 @@ static bool mtip_check_unal_depth(struct blk_mq_hw_ctx *hctx,
3775 return false; 3775 return false;
3776} 3776}
3777 3777
3778static int mtip_queue_rq(struct blk_mq_hw_ctx *hctx, struct request *rq, 3778static int mtip_queue_rq(struct blk_mq_hw_ctx *hctx,
3779 bool last) 3779 const struct blk_mq_queue_data *bd)
3780{ 3780{
3781 struct request *rq = bd->rq;
3781 int ret; 3782 int ret;
3782 3783
3783 if (unlikely(mtip_check_unal_depth(hctx, rq))) 3784 if (unlikely(mtip_check_unal_depth(hctx, rq)))
diff --git a/drivers/block/null_blk.c b/drivers/block/null_blk.c
index 8001e812018b..caa61212fdb5 100644
--- a/drivers/block/null_blk.c
+++ b/drivers/block/null_blk.c
@@ -313,15 +313,15 @@ static void null_request_fn(struct request_queue *q)
313 } 313 }
314} 314}
315 315
316static int null_queue_rq(struct blk_mq_hw_ctx *hctx, struct request *rq, 316static int null_queue_rq(struct blk_mq_hw_ctx *hctx,
317 bool last) 317 const struct blk_mq_queue_data *bd)
318{ 318{
319 struct nullb_cmd *cmd = blk_mq_rq_to_pdu(rq); 319 struct nullb_cmd *cmd = blk_mq_rq_to_pdu(bd->rq);
320 320
321 cmd->rq = rq; 321 cmd->rq = bd->rq;
322 cmd->nq = hctx->driver_data; 322 cmd->nq = hctx->driver_data;
323 323
324 blk_mq_start_request(rq); 324 blk_mq_start_request(bd->rq);
325 325
326 null_handle_cmd(cmd); 326 null_handle_cmd(cmd);
327 return BLK_MQ_RQ_QUEUE_OK; 327 return BLK_MQ_RQ_QUEUE_OK;
diff --git a/drivers/block/virtio_blk.c b/drivers/block/virtio_blk.c
index 1fb9e09fbbc5..7ef7c098708f 100644
--- a/drivers/block/virtio_blk.c
+++ b/drivers/block/virtio_blk.c
@@ -159,10 +159,11 @@ static void virtblk_done(struct virtqueue *vq)
159 spin_unlock_irqrestore(&vblk->vqs[qid].lock, flags); 159 spin_unlock_irqrestore(&vblk->vqs[qid].lock, flags);
160} 160}
161 161
162static int virtio_queue_rq(struct blk_mq_hw_ctx *hctx, struct request *req, 162static int virtio_queue_rq(struct blk_mq_hw_ctx *hctx,
163 bool last) 163 const struct blk_mq_queue_data *bd)
164{ 164{
165 struct virtio_blk *vblk = hctx->queue->queuedata; 165 struct virtio_blk *vblk = hctx->queue->queuedata;
166 struct request *req = bd->rq;
166 struct virtblk_req *vbr = blk_mq_rq_to_pdu(req); 167 struct virtblk_req *vbr = blk_mq_rq_to_pdu(req);
167 unsigned long flags; 168 unsigned long flags;
168 unsigned int num; 169 unsigned int num;
@@ -223,7 +224,7 @@ static int virtio_queue_rq(struct blk_mq_hw_ctx *hctx, struct request *req,
223 return BLK_MQ_RQ_QUEUE_ERROR; 224 return BLK_MQ_RQ_QUEUE_ERROR;
224 } 225 }
225 226
226 if (last && virtqueue_kick_prepare(vblk->vqs[qid].vq)) 227 if (bd->last && virtqueue_kick_prepare(vblk->vqs[qid].vq))
227 notify = true; 228 notify = true;
228 spin_unlock_irqrestore(&vblk->vqs[qid].lock, flags); 229 spin_unlock_irqrestore(&vblk->vqs[qid].lock, flags);
229 230
diff --git a/drivers/scsi/scsi_lib.c b/drivers/scsi/scsi_lib.c
index 7e3d954c9cac..43318d556cbc 100644
--- a/drivers/scsi/scsi_lib.c
+++ b/drivers/scsi/scsi_lib.c
@@ -1947,9 +1947,10 @@ static void scsi_mq_done(struct scsi_cmnd *cmd)
1947 blk_mq_complete_request(cmd->request); 1947 blk_mq_complete_request(cmd->request);
1948} 1948}
1949 1949
1950static int scsi_queue_rq(struct blk_mq_hw_ctx *hctx, struct request *req, 1950static int scsi_queue_rq(struct blk_mq_hw_ctx *hctx,
1951 bool last) 1951 const struct blk_mq_queue_data *bd)
1952{ 1952{
1953 struct request *req = bd->rq;
1953 struct request_queue *q = req->q; 1954 struct request_queue *q = req->q;
1954 struct scsi_device *sdev = q->queuedata; 1955 struct scsi_device *sdev = q->queuedata;
1955 struct Scsi_Host *shost = sdev->host; 1956 struct Scsi_Host *shost = sdev->host;