@@ -374,6 +374,9 @@ void dapls_ib_reinit_ep(IN DAPL_EP * ep_ptr)
#endif // _WIN32 || _WIN64
#if DAPL_USE_IBACM
+#ifndef RAI_NOROUTE
+#define RAI_NOROUTE 0
+#endif
uint8_t dapls_get_sl(DAPL_HCA *hca_ptr, uint16_t dlid)
{
struct rdma_addrinfo hint, *res;
@@ -387,6 +390,7 @@ uint8_t dapls_get_sl(DAPL_HCA *hca_ptr, uint16_t dlid)
path.dlid = dlid;
memset(&hint, 0, sizeof hint);
+ hint.ai_flags = RAI_NOROUTE;
hint.ai_route = &path;
hint.ai_route_len = sizeof(path);
@@ -397,6 +401,10 @@ uint8_t dapls_get_sl(DAPL_HCA *hca_ptr, uint16_t dlid)
if (res->ai_route_len)
sl = ntohs(((struct ibv_path_record *) res->ai_route)->
qosclass_sl) & 0xF;
+ else
+ dapl_log(DAPL_DBG_TYPE_CM_WARNING,
+ " dapls_get_sl: Warning, route miss 0x%x -> 0x%x\n",
+ slid, dlid);
rdma_freeaddrinfo(res);
out: