From: Jens Axboe <axboe@kernel.dk>
To: Jeff Moyer <jmoyer@redhat.com>
Cc: linux-kernel@vger.kernel.org
Subject: Re: blk_mq_update_queue_map makes an (invalid?) assumption about cpu ordering
Date: Tue, 15 Oct 2013 12:14:03 -0600 [thread overview]
Message-ID: <20131015181403.GY541@kernel.dk> (raw)
In-Reply-To: <x49fvs2pgjx.fsf@segfault.boston.devel.redhat.com>
On Tue, Oct 15 2013, Jeff Moyer wrote:
> Hi, Jens,
>
> blk_mq_update_queue_map does this:
>
> for_each_possible_cpu(i) {
> if (!cpu_online(i)) {
> map[i] = 0;
> continue;
> }
>
> ...
> first_sibling = get_first_sibling(i);
> if (first_sibling == i) {
> map[i] = cpu_to_queue_index(nr_uniq_cpus, nr_queues,
> queue);
> queue++;
> } else
> map[i] = map[first_sibling];
>
> This assumes that the first_sibling is listed before any other siblings,
> which I don't believe is true. I don't think you get any guaranteed
> ordering in that cpu_possible_mask.
>
> ... or did I miss something?
That's correct, it's assuming the first sibling is the lowest numbered
one. Are there cases where that would not be correct? I was sort of
assuming that was what "first" meant here.
--
Jens Axboe
next prev parent reply other threads:[~2013-10-15 18:14 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-10-15 17:52 blk_mq_update_queue_map makes an (invalid?) assumption about cpu ordering Jeff Moyer
2013-10-15 18:14 ` Jens Axboe [this message]
2013-10-15 18:25 ` Jeff Moyer
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=20131015181403.GY541@kernel.dk \
--to=axboe@kernel.dk \
--cc=jmoyer@redhat.com \
--cc=linux-kernel@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.