.TH "hwlocality_openfabrics" 3 "Version 2.14.0" "Hardware Locality (hwloc)" \" -*- nroff -*- .ad l .nh .SH NAME hwlocality_openfabrics \- Interoperability with OpenFabrics .SH SYNOPSIS .br .PP .SS "Functions" .in +1c .ti -1c .RI "int \fBhwloc_ibv_get_device_cpuset\fP (\fBhwloc_topology_t\fP topology, struct ibv_device *ibdev, \fBhwloc_cpuset_t\fP set)" .br .ti -1c .RI "\fBhwloc_obj_t\fP \fBhwloc_ibv_get_device_osdev_by_name\fP (\fBhwloc_topology_t\fP topology, const char *ibname)" .br .ti -1c .RI "\fBhwloc_obj_t\fP \fBhwloc_ibv_get_device_osdev\fP (\fBhwloc_topology_t\fP topology, struct ibv_device *ibdev)" .br .in -1c .SH "Detailed Description" .PP This interface offers ways to retrieve topology information about OpenFabrics devices (InfiniBand, Omni-Path, usNIC, etc)\&. .SH "Function Documentation" .PP .SS "int hwloc_ibv_get_device_cpuset (\fBhwloc_topology_t\fP topology, struct ibv_device * ibdev, \fBhwloc_cpuset_t\fP set)\fR [inline]\fP" .PP Get the CPU set of processors that are physically close to device \fRibdev\fP\&. Store in \fRset\fP the CPU-set describing the locality of the OpenFabrics device \fRibdev\fP (InfiniBand, etc)\&. .PP Topology \fRtopology\fP and device \fRibdev\fP must match the local machine\&. I/O devices detection is not needed in the topology\&. .PP The function only returns the locality of the device\&. If more information about the device is needed, OS objects should be used instead, see \fBhwloc_ibv_get_device_osdev()\fP and \fBhwloc_ibv_get_device_osdev_by_name()\fP\&. .PP This function is currently only implemented in a meaningful way for Linux; other systems will simply get the cpuset of the entire topology\&. .PP \fBReturns\fP .RS 4 0 on success\&. .PP -1 on error, for instance if device information could not be found\&. .RE .PP .SS "\fBhwloc_obj_t\fP hwloc_ibv_get_device_osdev (\fBhwloc_topology_t\fP topology, struct ibv_device * ibdev)\fR [inline]\fP" .PP Get the hwloc OS device object corresponding to the OpenFabrics device \fRibdev\fP\&. .PP \fBReturns\fP .RS 4 The hwloc OS device object describing the OpenFabrics device \fRibdev\fP (InfiniBand, etc)\&. .PP \fRNULL\fP if none could be found\&. .RE .PP Topology \fRtopology\fP and device \fRibdev\fP must match the local machine\&. I/O devices detection must be enabled in the topology\&. If not, the locality of the object may still be found using \fBhwloc_ibv_get_device_cpuset()\fP\&. .PP \fBNote\fP .RS 4 The corresponding PCI device object can be obtained by looking at the OS device parent object\&. .RE .PP .SS "\fBhwloc_obj_t\fP hwloc_ibv_get_device_osdev_by_name (\fBhwloc_topology_t\fP topology, const char * ibname)\fR [inline]\fP" .PP Get the hwloc OS device object corresponding to the OpenFabrics device named \fRibname\fP\&. .PP \fBReturns\fP .RS 4 The hwloc OS device object describing the OpenFabrics device (InfiniBand, Omni-Path, usNIC, etc) whose name is \fRibname\fP (mlx5_0, hfi1_0, usnic_0, qib0, etc)\&. .PP \fRNULL\fP if none could be found\&. .RE .PP The name \fRibname\fP is usually obtained from ibv_get_device_name()\&. .PP The topology \fRtopology\fP does not necessarily have to match the current machine\&. For instance the topology may be an XML import of a remote host\&. I/O devices detection must be enabled in the topology\&. .PP \fBNote\fP .RS 4 The corresponding PCI device object can be obtained by looking at the OS device parent object\&. .RE .PP .SH "Author" .PP Generated automatically by Doxygen for Hardware Locality (hwloc) from the source code\&.