From: Eric Dumazet Date: Fri, 20 Jan 2017 16:08:56 +0000 (-0800) Subject: ipv6: add NUMA awareness to seg6_hmac_init_algo() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=9ca677b1bd8979f9a7702db5ed4028e4b8b232e8;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git ipv6: add NUMA awareness to seg6_hmac_init_algo() Since we allocate per cpu storage, let's also use NUMA hints. Signed-off-by: Eric Dumazet Acked-by: David Lebrun Signed-off-by: David S. Miller --- diff --git a/net/ipv6/seg6_hmac.c b/net/ipv6/seg6_hmac.c index 5215e1eba010..b274f1d95e03 100644 --- a/net/ipv6/seg6_hmac.c +++ b/net/ipv6/seg6_hmac.c @@ -389,7 +389,8 @@ static int seg6_hmac_init_algo(void) return -ENOMEM; for_each_possible_cpu(cpu) { - shash = kzalloc(shsize, GFP_KERNEL); + shash = kzalloc_node(shsize, GFP_KERNEL, + cpu_to_node(cpu)); if (!shash) return -ENOMEM; *per_cpu_ptr(algo->shashs, cpu) = shash;