From: Ming Lei <ming.lei@redhat.com>
To: Jens Axboe <axboe@kernel.dk>
Cc: linux-block@vger.kernel.org, Ming Lei <ming.lei@redhat.com>,
Christoph Hellwig <hch@lst.de>
Subject: [PATCH V3 1/3] blk-mq: fix allocation for queue mapping table
Date: Mon, 17 Dec 2018 20:08:42 +0800 [thread overview]
Message-ID: <20181217120844.8131-2-ming.lei@redhat.com> (raw)
In-Reply-To: <20181217120844.8131-1-ming.lei@redhat.com>
Type of each element in queue mapping table is 'unsigned int,
intead of 'struct blk_mq_queue_map)', so fix it.
Cc: Christoph Hellwig <hch@lst.de>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Ming Lei <ming.lei@redhat.com>
---
block/blk-mq.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/block/blk-mq.c b/block/blk-mq.c
index 2d3a29eb58ca..313f28b2d079 100644
--- a/block/blk-mq.c
+++ b/block/blk-mq.c
@@ -3019,7 +3019,7 @@ int blk_mq_alloc_tag_set(struct blk_mq_tag_set *set)
ret = -ENOMEM;
for (i = 0; i < set->nr_maps; i++) {
set->map[i].mq_map = kcalloc_node(nr_cpu_ids,
- sizeof(struct blk_mq_queue_map),
+ sizeof(set->map[i].mq_map[0]),
GFP_KERNEL, set->numa_node);
if (!set->map[i].mq_map)
goto out_free_mq_map;
--
2.9.5
next prev parent reply other threads:[~2018-12-17 12:09 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-12-17 12:08 [PATCH V3 0/4] blk-mq: queue mapping fix & improvement Ming Lei
2018-12-17 12:08 ` Ming Lei [this message]
2018-12-17 12:08 ` [PATCH V3 2/3] blk-mq: export hctx->type in debugfs instead of sysfs Ming Lei
2018-12-17 12:08 ` [PATCH V3 3/3] blk-mq: fix dispatch from sw queue Ming Lei
2018-12-17 12:55 ` Jens Axboe
2018-12-17 13:29 ` Jens Axboe
2018-12-17 15:43 ` Jens Axboe
2018-12-17 12:56 ` [PATCH V3 0/4] blk-mq: queue mapping fix & improvement Jens Axboe
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20181217120844.8131-2-ming.lei@redhat.com \
--to=ming.lei@redhat.com \
--cc=axboe@kernel.dk \
--cc=hch@lst.de \
--cc=linux-block@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).