opensm/osm_mesh.c: fixing a bug in compare_switches()
PATCH 1/1 opensm/osm_mesh.c: fixing a bug in compare_switches()
I'm pretty sure that ";" at the end of "if" statement is not supposed to be there (not sure how it worked till now though).
Also, making this condition a bit more readable.
--- opensm/opensm/osm_mesh.c | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-)
opensm/opensm/osm_mesh.c +2 -1
@@ -1385,7 +1385,8 @@ static int compare_switches(const void *p1, const void *p2)for (i =0 ; i < ctx->mesh->dimension; i++) { j = ctx->mesh->dim_order[i]; -if ((ret = s1->node->coord[j] - s2->node->coord[j])); + ret = s1->node->coord[j] - s2->node->coord[j]; +if (ret)return ret; }
Signature · 6 lines
1.6.2.4 -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): 4C86538E.3080206-VPRAkNaXOzVS1MOuV/[email protected]
Sasha Khapyorsky
AppliedQuoted 6 lines · Yevgeny Kliteynik
I'm pretty sure that ";" at the end of "if" statement is not supposed to be there (not sure how it worked till now though).
Also, making this condition a bit more readable.Signed-off-by Yevgeny Kliteynik <[email protected]>
Applied. Thanks.
Sasha
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
Thanks Sasha,
I'm not sure where that came from. This was a little optimization that improved the results in some cases. But wouldn't break the rest of the code. Seems to have gotten broken somewhere along the way.
Bob Pearson
Quoted 9 lines · Sasha Khapyorsky
Quoted 7 lines · Yevgeny Kliteynik
I'm pretty sure that ";" at the end of "if" statement is not supposed to be there (not sure how it worked till now though).
Also, making this condition a bit more readable.Signed-off-by Yevgeny Kliteynik<[email protected]>
Quoted 9 lines
Applied. Thanks.
Sasha
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html