Whamcloud - gitweb
LU-17501 libcfs: fix CPT NUMA core exclusion handling 47/56347/4
authorFrederick Dilger <fdilger@whamcloud.com>
Thu, 12 Sep 2024 22:46:38 +0000 (16:46 -0600)
committerOleg Drokin <green@whamcloud.com>
Mon, 9 Dec 2024 06:10:05 +0000 (06:10 +0000)
commit660787c66fa80182a55c0f89895880a884fe0ba5
treede629a7042f20cadd29278132c312117706afb1f
parent170a0b204b03e314cfc69ab26477499592c0e43e
LU-17501 libcfs: fix CPT NUMA core exclusion handling

The cfs_cpt_unset_node_core() function was only setting the offset
a single time for the first node, and using the same offset for all
other nodes.

cpu_pattern='C[0]' was only removing the first core on the first
NUMA node when it should be removing a core on every NUMA node.

It produced an output like:

    cpu_partition_table=
    0       : 1
    1       : 2 3
    2       : 4 5

when it should have been:

    cpu_partition_table=
    0       : 1
    1       : 3
    2       : 5

Signed-off-by: Frederick Dilger <fdilger@whamcloud.com>
Change-Id: I22e1fe1aa73e413cf9c32562ec96f0cf4bd16fe5
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/56347
Tested-by: Maloo <maloo@whamcloud.com>
Tested-by: jenkins <devops@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Andrew Perepechko <andrew.perepechko@hpe.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lnet/lnet/lib-cpt.c