Skip to contentSkip to conversation

When exiting, update SADB only in MASTER state

PATCH New Hal Rosenstock 1 participant 1 message Nov 4, 2013 InfiniBand

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 When exiting, update SADB only in MASTER state

From: Vladimir Koushnir <vladimirk-VPRAkNaXOzVWk0Htik3J/[email protected]>

---
 opensm/osm_opensm.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
opensm/osm_opensm.c +2 -1
index b3c487f..f2e04f6 100644
@@ -132,7 +132,8 @@ void osm_opensm_destroy(IN osm_opensm_t * p_osm)
 	cl_disp_shutdown(&p_osm->sminfo_get_disp);
 
 	/* dump SA DB */
-	if (p_osm->subn.opt.sa_db_dump)
+	if ((p_osm->sm.p_subn->sm_state == IB_SMINFO_STATE_MASTER) &&
+	     p_osm->subn.opt.sa_db_dump)
 		osm_sa_db_file_dump(p_osm);
 
 	/* do the destruction in reverse order as init */
Signature · 6 lines
1.7.8.2

--
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