From 61787e1cea610ba38ba917b73db0d43589c029df Mon Sep 17 00:00:00 2001 From: Oleg Drokin Date: Mon, 2 Mar 2015 01:07:07 -0500 Subject: [PATCH] LU-6285 ptlrpc: Get rid of cpus_* calls as deprecated Use cpumask_* equivalents instead. Also we are no longer supposed to directly assign cpumasks as a method of copy, need to use cpumask_copy instead. Change-Id: I0425cd308a363e74de8d20f9a5f144fe07431f01 Signed-off-by: Oleg Drokin Reviewed-on: http://review.whamcloud.com/13925 Tested-by: Jenkins Reviewed-by: Patrick Farrell Reviewed-by: Liang Zhen Reviewed-by: James Simmons --- lustre/ptlrpc/ptlrpcd.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lustre/ptlrpc/ptlrpcd.c b/lustre/ptlrpc/ptlrpcd.c index 1471d2c..e4f89eb 100644 --- a/lustre/ptlrpc/ptlrpcd.c +++ b/lustre/ptlrpc/ptlrpcd.c @@ -518,10 +518,10 @@ static int ptlrpcd_bind(int index, int max) #if defined(CONFIG_NUMA) { int i; - mask = *cpumask_of_node(cpu_to_node(index)); + cpumask_copy(&mask, cpumask_of_node(cpu_to_node(index))); for (i = max; i < num_online_cpus(); i++) - cpu_clear(i, mask); - pc->pc_npartners = cpus_weight(mask) - 1; + cpumask_clear_cpu(i, &mask); + pc->pc_npartners = cpumask_weight(&mask) - 1; set_bit(LIOD_BIND, &pc->pc_flags); } #else @@ -561,7 +561,7 @@ static int ptlrpcd_bind(int index, int max) * that are already initialized */ for (pidx = 0, i = 0; i < index; i++) { - if (cpu_isset(i, mask)) { + if (cpumask_test_cpu(i, &mask)) { ppc = &ptlrpcds->pd_threads[i]; pc->pc_partners[pidx++] = ppc; ppc->pc_partners[ppc-> -- 1.8.3.1