staging: lustre: libcfs: Fix NUMA emulated mode

Kernel commit c1c3443c9c
assigns all allowed cpus to emulated node.

End cpt initialization loop when all CPUs are assigned.

Signed-off-by: Andriy Skulysh <Andriy_Skulysh@xyratex.com>
Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3992
Reviewed-on: http://review.whamcloud.com/7724
Reviewed-by: Liang Zhen <liang.zhen@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Signed-off-by: James Simmons <jsimmons@infradead.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Andriy Skulysh 2016-04-27 21:37:16 -04:00 committed by Greg Kroah-Hartman
parent 98f2ec6120
commit 9ebd489658
1 changed files with 7 additions and 2 deletions

View File

@ -755,8 +755,13 @@ cfs_cpt_table_create(int ncpt)
struct cfs_cpu_partition *part;
int n;
if (cpt >= ncpt)
goto failed;
/*
* Each emulated NUMA node has all allowed CPUs in
* the mask.
* End loop when all partitions have assigned CPUs.
*/
if (cpt == ncpt)
break;
part = &cptab->ctb_parts[cpt];