Struct ibverbs::Device [] [src]

pub struct Device<'a>(_);

An RDMA device.

Methods

impl<'a> Device<'a>
[src]

Opens an RMDA device and creates a context for further use.

This context will later be used to query its resources or for creating resources.

Unlike what the verb name suggests, it doesn't actually open the device. This device was opened by the kernel low-level driver and may be used by other user/kernel level code. This verb only opens a context to allow user level applications to use it.

Errors

  • EINVAL: PORT_NUM is invalid (from ibv_query_port_attr).
  • ENOMEM: Out of memory (from ibv_query_port_attr).
  • EMFILE: Too many files are opened by this process (from ibv_query_gid).
  • Other: the device is not in ACTIVE or ARMED state.

Returns a string of the name, which is associated with this RDMA device.

This name is unique within a specific machine (the same name cannot be assigned to more than one device). However, this name isn't unique across an InfiniBand fabric (this name can be found in different machines).

When there are more than one RDMA devices in a computer, changing the device location in the computer (i.e. in the PCI bus) may result a change in the names associated with the devices. In order to distinguish between the device, it is recommended using the device GUID, returned by Device::guid.

The name is composed from:

  • a prefix which describes the RDMA device vendor and model
    • cxgb3 - Chelsio Communications, T3 RDMA family
    • cxgb4 - Chelsio Communications, T4 RDMA family
    • ehca - IBM, eHCA family
    • ipathverbs - QLogic
    • mlx4 - Mellanox Technologies, ConnectX family
    • mthca - Mellanox Technologies, InfiniHost family
    • nes - Intel, Intel-NE family
  • an index that helps to differentiate between several devices from the same vendor and family in the same computer

Returns the Global Unique IDentifier (GUID) of this RDMA device.

This GUID, that was assigned to this device by its vendor during the manufacturing, is unique and can be used as an identifier to an RDMA device.

From the prefix of the RDMA device GUID, one can know who is the vendor of that device using the IEEE OUI.

Errors

  • EMFILE: Too many files are opened by this process.

Trait Implementations

impl<'a> Sync for Device<'a>
[src]

impl<'a> Send for Device<'a>
[src]

impl<'a> From<&'a *mut ibv_device> for Device<'a>
[src]

Performs the conversion.