All of lore.kernel.org
 help / color / mirror / Atom feed
From: Omar Sandoval <osandov@osandov.com>
To: Jens Axboe <axboe@fb.com>, linux-block@vger.kernel.org
Cc: linux-kernel@vger.kernel.org, kernel-team@fb.com
Subject: [PATCH v2 2/5] scale_bitmap: allocate wait queues on a specific node
Date: Wed,  7 Sep 2016 16:46:03 -0700	[thread overview]
Message-ID: <e961019b6ad33891fe70ffdd9ee6b78ffa84c396.1473291702.git.osandov@fb.com> (raw)
In-Reply-To: <cover.1473291702.git.osandov@fb.com>
In-Reply-To: <cover.1473291702.git.osandov@fb.com>

From: Omar Sandoval <osandov@fb.com>

The original `bt_alloc()` we converted from was using `kzalloc()`, not
`kzalloc_node()`, to allocate the wait queues. This was probably an
oversight, so fix it for `scale_bitmap_queue_init_node()`.

Signed-off-by: Omar Sandoval <osandov@fb.com>
---
 lib/scale_bitmap.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/scale_bitmap.c b/lib/scale_bitmap.c
index 4d47c19..237170c 100644
--- a/lib/scale_bitmap.c
+++ b/lib/scale_bitmap.c
@@ -212,7 +212,7 @@ int scale_bitmap_queue_init_node(struct scale_bitmap_queue *sbq,
 
 	atomic_set(&sbq->wake_index, 0);
 
-	sbq->ws = kzalloc(SBQ_WAIT_QUEUES * sizeof(*sbq->ws), flags);
+	sbq->ws = kzalloc_node(SBQ_WAIT_QUEUES * sizeof(*sbq->ws), flags, node);
 	if (!sbq->ws) {
 		scale_bitmap_free(&sbq->map);
 		return -ENOMEM;
-- 
2.9.3


  parent reply	other threads:[~2016-09-07 23:46 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-09-07 23:46 [PATCH v2 0/5] blk-mq: abstract tag allocation out into scale_bitmap library Omar Sandoval
2016-09-07 23:46 ` [PATCH v2 1/5] " Omar Sandoval
2016-09-08  0:01   ` Alexei Starovoitov
2016-09-08  0:38     ` Omar Sandoval
2016-09-08  1:12       ` Alexei Starovoitov
2016-09-08 16:11         ` Jens Axboe
2016-09-08 18:16           ` Omar Sandoval
2016-09-07 23:46 ` Omar Sandoval [this message]
2016-09-07 23:46 ` [PATCH v2 3/5] scale_bitmap: push per-cpu last_tag into scale_bitmap_queue Omar Sandoval
2016-09-07 23:46 ` [PATCH v2 4/5] scale_bitmap: push alloc policy " Omar Sandoval
2016-09-07 23:46 ` [PATCH v2 5/5] scale_bitmap: randomize initial last_cache values Omar Sandoval

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=e961019b6ad33891fe70ffdd9ee6b78ffa84c396.1473291702.git.osandov@fb.com \
    --to=osandov@osandov.com \
    --cc=axboe@fb.com \
    --cc=kernel-team@fb.com \
    --cc=linux-block@vger.kernel.org \
    --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.