Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 5ee0524b authored by Bart Van Assche's avatar Bart Van Assche Committed by Jens Axboe
Browse files

block: Add 'lock' as third argument to blk_alloc_queue_node()



This patch does not change any functionality.

Signed-off-by: default avatarBart Van Assche <bart.vanassche@wdc.com>
Reviewed-by: default avatarJoseph Qi <joseph.qi@linux.alibaba.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: Philipp Reisner <philipp.reisner@linbit.com>
Cc: Ulf Hansson <ulf.hansson@linaro.org>
Cc: Kees Cook <keescook@chromium.org>
Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
parent 392db380
Loading
Loading
Loading
Loading
+4 −3
Original line number Diff line number Diff line
@@ -810,7 +810,7 @@ void blk_exit_rl(struct request_queue *q, struct request_list *rl)

struct request_queue *blk_alloc_queue(gfp_t gfp_mask)
{
	return blk_alloc_queue_node(gfp_mask, NUMA_NO_NODE);
	return blk_alloc_queue_node(gfp_mask, NUMA_NO_NODE, NULL);
}
EXPORT_SYMBOL(blk_alloc_queue);

@@ -888,7 +888,8 @@ static void blk_rq_timed_out_timer(struct timer_list *t)
	kblockd_schedule_work(&q->timeout_work);
}

struct request_queue *blk_alloc_queue_node(gfp_t gfp_mask, int node_id)
struct request_queue *blk_alloc_queue_node(gfp_t gfp_mask, int node_id,
					   spinlock_t *lock)
{
	struct request_queue *q;

@@ -1030,7 +1031,7 @@ blk_init_queue_node(request_fn_proc *rfn, spinlock_t *lock, int node_id)
{
	struct request_queue *q;

	q = blk_alloc_queue_node(GFP_KERNEL, node_id);
	q = blk_alloc_queue_node(GFP_KERNEL, node_id, NULL);
	if (!q)
		return NULL;

+1 −1
Original line number Diff line number Diff line
@@ -2556,7 +2556,7 @@ struct request_queue *blk_mq_init_queue(struct blk_mq_tag_set *set)
{
	struct request_queue *uninit_q, *q;

	uninit_q = blk_alloc_queue_node(GFP_KERNEL, set->numa_node);
	uninit_q = blk_alloc_queue_node(GFP_KERNEL, set->numa_node, NULL);
	if (!uninit_q)
		return ERR_PTR(-ENOMEM);

+2 −1
Original line number Diff line number Diff line
@@ -1760,7 +1760,8 @@ static int null_add_dev(struct nullb_device *dev)
		}
		null_init_queues(nullb);
	} else if (dev->queue_mode == NULL_Q_BIO) {
		nullb->q = blk_alloc_queue_node(GFP_KERNEL, dev->home_node);
		nullb->q = blk_alloc_queue_node(GFP_KERNEL, dev->home_node,
						NULL);
		if (!nullb->q) {
			rv = -ENOMEM;
			goto out_cleanup_queues;
+1 −1
Original line number Diff line number Diff line
@@ -766,7 +766,7 @@ static int ide_init_queue(ide_drive_t *drive)
	 *	limits and LBA48 we could raise it but as yet
	 *	do not.
	 */
	q = blk_alloc_queue_node(GFP_KERNEL, hwif_to_node(hwif));
	q = blk_alloc_queue_node(GFP_KERNEL, hwif_to_node(hwif), NULL);
	if (!q)
		return 1;

+1 −1
Original line number Diff line number Diff line
@@ -384,7 +384,7 @@ static int nvm_create_tgt(struct nvm_dev *dev, struct nvm_ioctl_create *create)
		goto err_dev;
	}

	tqueue = blk_alloc_queue_node(GFP_KERNEL, dev->q->node);
	tqueue = blk_alloc_queue_node(GFP_KERNEL, dev->q->node, NULL);
	if (!tqueue) {
		ret = -ENOMEM;
		goto err_disk;
Loading