19 #ifndef HWLOC_OPENFABRICS_VERBS_H
20 #define HWLOC_OPENFABRICS_VERBS_H
23 #include <hwloc/autogen/config.h>
26 #include <infiniband/verbs.h>
46 static __hwloc_inline
int
50 #ifdef HWLOC_LINUX_SYS
53 #define HWLOC_OPENFABRICS_VERBS_SYSFS_PATH_MAX 128
54 char path[HWLOC_OPENFABRICS_VERBS_SYSFS_PATH_MAX];
57 sprintf(path,
"/sys/class/infiniband/%s/device/local_cpus",
58 ibv_get_device_name(ibdev));
59 sysfile = fopen(path,
"r");
HWLOC_DECLSPEC void hwloc_bitmap_copy(hwloc_bitmap_t dst, hwloc_const_bitmap_t src)
Copy the contents of bitmap src into the already allocated bitmap dst.
static __hwloc_inline hwloc_const_cpuset_t __hwloc_attribute_pure hwloc_topology_get_complete_cpuset(hwloc_topology_t topology)
Get complete CPU set.
Definition: helper.h:729
Macros to help interaction between hwloc and Linux.
HWLOC_DECLSPEC int hwloc_linux_parse_cpumap_file(FILE *file, hwloc_cpuset_t set)
Convert a linux kernel cpumap file file into hwloc CPU set.
Definition: topology-linux.c:1332
static __hwloc_inline int hwloc_ibv_get_device_cpuset(hwloc_topology_t topology __hwloc_attribute_unused, struct ibv_device *ibdev, hwloc_cpuset_t set)
Get the CPU set of logical processors that are physically close to device ibdev.
Definition: openfabrics-verbs.h:47