1IBV_QUERY_PORT(3)       Libibverbs Programmer's Manual       IBV_QUERY_PORT(3)
2
3
4

NAME

6       ibv_query_port - query an RDMA port's attributes
7

SYNOPSIS

9       #include <infiniband/verbs.h>
10
11       int ibv_query_port(struct ibv_context *context, uint8_t port_num,
12                          struct ibv_port_attr *port_attr);
13

DESCRIPTION

15       ibv_query_port()  returns  the  attributes  of port port_num for device
16       context context through the pointer port_attr.  The argument  port_attr
17       is an ibv_port_attr struct, as defined in <infiniband/verbs.h>.
18
19       struct ibv_port_attr {
20               enum ibv_port_state     state;          /* Logical port state */
21               enum ibv_mtu            max_mtu;        /* Max MTU supported by port */
22               enum ibv_mtu            active_mtu;     /* Actual MTU */
23               int                     gid_tbl_len;    /* Length of source GID table */
24               uint32_t                port_cap_flags; /* Port capabilities */
25               uint32_t                max_msg_sz;     /* Maximum message size */
26               uint32_t                bad_pkey_cntr;  /* Bad P_Key counter */
27               uint32_t                qkey_viol_cntr; /* Q_Key violation counter */
28               uint16_t                pkey_tbl_len;   /* Length of partition table */
29               uint16_t                lid;            /* Base port LID */
30               uint16_t                sm_lid;         /* SM LID */
31               uint8_t                 lmc;            /* LMC of LID */
32               uint8_t                 max_vl_num;     /* Maximum number of VLs */
33               uint8_t                 sm_sl;          /* SM service level */
34               uint8_t                 subnet_timeout; /* Subnet propagation delay */
35               uint8_t                 init_type_reply;/* Type of initialization performed by SM */
36               uint8_t                 active_width;   /* Currently active link width */
37               uint8_t                 active_speed;   /* Currently active link speed */
38               uint8_t                 phys_state;     /* Physical port state */
39               uint8_t                 link_layer;     /* link layer protocol of the port */
40               uint8_t                 flags;          /* Port flags */
41               uint16_t                port_cap_flags2;/* Port capabilities */
42       };
43
44       possible values for the link layer field are IBV_LINK_LAYER_INFINIBAND,
45       IBV_LINK_LAYER_ETHERNET, or IBV_LINK_LAYER_UNSPECIFIED.
46
47       supported port flags:
48       IBV_QPF_GRH_REQUIRED - When this flag is set, the applications must create all AH with GRH configured.
49
50

RETURN VALUE

52       ibv_query_port() returns 0 on success, or the value of errno on failure
53       (which indicates the failure reason).
54

SEE ALSO

56       ibv_create_qp(3), ibv_destroy_qp(3), ibv_query_qp(3), ibv_create_ah(3)
57

AUTHORS

59       Dotan Barak <dotanba@gmail.com>
60
61
62
63libibverbs                        2006-10-31                 IBV_QUERY_PORT(3)
Impressum