aboutsummaryrefslogtreecommitdiffstats
path: root/src/vppinfra/unix.h
diff options
context:
space:
mode:
authorhsandid <halsandi@cisco.com>2024-03-25 17:51:31 +0100
committerDamjan Marion <dmarion@0xa5.net>2024-03-29 16:29:44 +0000
commit71c32a898941e32b5d4f865b50fbe775560c582d (patch)
treeebddae6023dcdb8912fde7a32febfc19ee294f98 /src/vppinfra/unix.h
parent3e147f08efc82c1c9d131bd03ee2efd493775570 (diff)
vlib: improve automatic core pinning
Type: feature Auto core pinning now fetches vpp cpu affinity list using pthread api. This enables us to do core-pinning in environments where the host cpu list does not necessarily align with cpus available to vpp Change-Id: Ife8c2a2351c08c5c6c4fdf7c729eeff2697bc39a Signed-off-by: hsandid <halsandi@cisco.com>
Diffstat (limited to 'src/vppinfra/unix.h')
-rw-r--r--src/vppinfra/unix.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/vppinfra/unix.h b/src/vppinfra/unix.h
index 651f9bb99e0..3ad57b05e72 100644
--- a/src/vppinfra/unix.h
+++ b/src/vppinfra/unix.h
@@ -56,6 +56,9 @@ clib_error_t *unix_proc_file_contents (char *file, u8 ** result);
/* Retrieve bitmap of online cpu cures */
clib_bitmap_t *os_get_online_cpu_core_bitmap ();
+/* Retrieve bitmap of cpus vpp has affinity to */
+clib_bitmap_t *os_get_cpu_affinity_bitmap (int pid);
+
/* Retrieve bitmap of online cpu nodes (sockets) */
clib_bitmap_t *os_get_online_cpu_node_bitmap ();