summaryrefslogtreecommitdiff
path: root/drivers/infiniband/sw/rxe/rxe.h
diff options
context:
space:
mode:
authorAndrew Boyer <andrew.boyer@dell.com>2018-11-01 16:18:45 +0300
committerJason Gunthorpe <jgg@mellanox.com>2018-11-09 00:22:53 +0300
commit5736c7c499f142bceec06a2ab3113997d0175f80 (patch)
treef9f612e4953208fae58155fd74946ce0876b82c6 /drivers/infiniband/sw/rxe/rxe.h
parent759ace7832802eaefbca821b2b43a44ab896b449 (diff)
downloadlinux-5736c7c499f142bceec06a2ab3113997d0175f80.tar.xz
RDMA/rxe: Distinguish between down links and disabled links
In ib_query_port(), use the netdev's IFF_UP flag to determine phys_state (flag set = down = POLLING, flag clear = disabled = DISABLED). Callers can then use the phys_state field to distinguish between links which have a dead partner, cable missing, etc., from links which are turned off on the local node. This is useful for HA and supportability. Signed-off-by: Andrew Boyer <andrew.boyer@dell.com> Signed-off-by: Doug Ledford <dledford@redhat.com>
Diffstat (limited to 'drivers/infiniband/sw/rxe/rxe.h')
-rw-r--r--drivers/infiniband/sw/rxe/rxe.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/infiniband/sw/rxe/rxe.h b/drivers/infiniband/sw/rxe/rxe.h
index d9ec2de68738..8f79bd86d033 100644
--- a/drivers/infiniband/sw/rxe/rxe.h
+++ b/drivers/infiniband/sw/rxe/rxe.h
@@ -65,8 +65,9 @@
*/
#define RXE_UVERBS_ABI_VERSION 2
-#define IB_PHYS_STATE_LINK_UP (5)
-#define IB_PHYS_STATE_LINK_DOWN (3)
+#define RDMA_LINK_PHYS_STATE_LINK_UP (5)
+#define RDMA_LINK_PHYS_STATE_DISABLED (3)
+#define RDMA_LINK_PHYS_STATE_POLLING (2)
#define RXE_ROCE_V2_SPORT (0xc000)