IB/core: Add subnet prefix to port info
authorEli Cohen <eli@mellanox.com>
Fri, 11 Mar 2016 20:58:36 +0000 (22:58 +0200)
committerDoug Ledford <dledford@redhat.com>
Mon, 21 Mar 2016 20:34:06 +0000 (16:34 -0400)
commitfad61ad4e755f5dd13c7702a87cd907207392534
treea8f2df35c806be02cc3353abab8b6df956e83654
parentd603c809ef91fa2d211bde5e95be417847410379
IB/core: Add subnet prefix to port info

The subnet prefix is a part of the port_info MAD returned and should be
available at the ib_port_attr struct. We define it here and provide a
default implementation in case the hardware driver does not provide one.
The subnet prefix is required when creating the address vector to access
the SA in networks where GRH must be used.

Signed-off-by: Eli Cohen <eli@mellanox.com>
Reviewed-by: Or Gerlitz <ogerlitz@mellanox.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/infiniband/core/device.c
include/rdma/ib_verbs.h