From: Eric Dumazet <eric.dumazet@gmail.com>
To: David Miller <davem@davemloft.net>
Cc: netdev@vger.kernel.org, Tom Herbert <therbert@google.com>
Subject: [PATCH net-next-2.6] xps: NUMA allocations for per cpu data
Date: Sun, 28 Nov 2010 16:43:24 +0100 [thread overview]
Message-ID: <1290959004.29196.13.camel@edumazet-laptop> (raw)
In-Reply-To: <1290791866.2855.263.camel@edumazet-laptop>
store_xps_map() allocates maps that are used by single cpu, it makes
sense to use NUMA allocations.
Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Cc: Tom Herbert <therbert@google.com>
---
net/core/net-sysfs.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/net/core/net-sysfs.c b/net/core/net-sysfs.c
index 68dbbfd..35f28b1 100644
--- a/net/core/net-sysfs.c
+++ b/net/core/net-sysfs.c
@@ -950,8 +950,9 @@ static ssize_t store_xps_map(struct netdev_queue *queue,
if (map_len >= alloc_len) {
alloc_len = alloc_len ?
2 * alloc_len : XPS_MIN_MAP_ALLOC;
- new_map = kzalloc(XPS_MAP_SIZE(alloc_len),
- GFP_KERNEL);
+ new_map = kzalloc_node(XPS_MAP_SIZE(alloc_len),
+ GFP_KERNEL,
+ cpu_to_node(cpu));
if (!new_map)
goto error;
new_map->alloc_len = alloc_len;
next prev parent reply other threads:[~2010-11-28 15:43 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-11-21 23:17 [PATCH 2/2 v7] xps: Transmit Packet Steering Tom Herbert
2010-11-22 11:42 ` Changli Gao
2010-11-22 13:33 ` Eric Dumazet
2010-11-24 19:45 ` David Miller
2010-11-26 17:13 ` Tom Herbert
2010-11-26 17:17 ` Eric Dumazet
2010-11-28 15:43 ` Eric Dumazet [this message]
2010-11-29 17:43 ` [PATCH net-next-2.6] xps: NUMA allocations for per cpu data David Miller
2010-11-25 17:12 ` [PATCH 2/2 v7] xps: Transmit Packet Steering Ben Hutchings
2010-11-29 18:14 ` [PATCH net-next-2.6] sched: use xps information for qdisc NUMA affinity Eric Dumazet
2010-11-30 18:31 ` Tom Herbert
2010-11-30 18:39 ` Eric Dumazet
2010-11-30 18:46 ` Ben Hutchings
2010-11-30 18:52 ` Eric Dumazet
2010-11-30 18:48 ` David Miller
2010-11-30 19:07 ` Eric Dumazet
2010-11-30 19:19 ` Ben Hutchings
2010-11-30 19:21 ` David Miller
2010-11-30 20:01 ` Brandeburg, Jesse
2010-12-01 20:49 ` David Miller
2010-12-01 20:55 ` Eric Dumazet
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=1290959004.29196.13.camel@edumazet-laptop \
--to=eric.dumazet@gmail.com \
--cc=davem@davemloft.net \
--cc=netdev@vger.kernel.org \
--cc=therbert@google.com \
/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