(I don't think this made it to the mailng list, so re-posting.)
I don't disagree with the concept here, but can you explain the problem that you're seeing? Is it that the path is assumed to be routed based on the hop_limit (set in ib_init_ah_from_path)? Are any changes needed for active side processing? Btw, I'd prefer something more like: if (cm_req_get_primary_subnet_local. ) primary_path->hop_limit = 1; else primary_path->hop_limit = req_msg->primary_hop_limit; (or '? :' equivalent), versus setting hop_limit, then overriding it in the common case. And I'm fine if we don't keep the comment. - Sean _____ From: Jim Hall [mailto:[EMAIL PROTECTED] Sent: Monday, September 17, 2007 7:38 AM To: [EMAIL PROTECTED] Cc: Hefty, Sean Subject: [PATCH] core/cm: improve request message interpertation of subnet local fields When parsing a CMA connect request message, if the subnet local is 1 (both nodes on same subnet), then explicitly set the hop limit in the corresponding path record to 1. This avoids a Global/Local mis-configuration problem with Solaris infinband CMA sessions. Signed-off-by: Jim L Hall < <mailto:[EMAIL PROTECTED]> [EMAIL PROTECTED]> --- drivers/infiniband/core/cm.c | 16 ++++++++++++++++ 1 files changed, 16 insertions(+), 0 deletions(-) diff --git a/drivers/infiniband/core/cm.c b/drivers/infiniband/core/cm.c index d446998..3d8740c 100644 --- a/drivers/infiniband/core/cm.c +++ b/drivers/infiniband/core/cm.c @@ -1109,6 +1109,14 @@ static void cm_format_paths_from_req(struct cm_req_msg *req_msg, cm_req_get_primary_local_ack_timeout(req_msg); primary_path->packet_life_time -= (primary_path->packet_life_time > 0); + if (cm_req_get_primary_subnet_local(req_msg) == 1) { + + /* At this point we know that both sides are on the same + * subnet, any hop limits above 1 don't make much sense + */ + primary_path->hop_limit = 1; + } + if (req_msg->alt_local_lid) { memset(alt_path, 0, sizeof *alt_path); alt_path->dgid = req_msg->alt_local_gid; @@ -1129,6 +1137,14 @@ static void cm_format_paths_from_req(struct cm_req_msg *req_msg, alt_path->packet_life_time = cm_req_get_alt_local_ack_timeout(req_msg); alt_path->packet_life_time -= (alt_path->packet_life_time > 0); + + if (cm_req_get_alt_subnet_local(req_msg) == 1) { + + /* At this point we know that both sides are on the same + * subnet, any hop limits above 1 don't make much sense + */ + alt_path->hop_limit = 1; + } } }
_______________________________________________ general mailing list general@lists.openfabrics.org http://lists.openfabrics.org/cgi-bin/mailman/listinfo/general To unsubscribe, please visit http://openib.org/mailman/listinfo/openib-general