opensm/osm_sa.{c,h}: osm_sa_db_file_dump() return values
PATCH 1/1 opensm/osm_sa.{c,h}: osm_sa_db_file_dump() return values
Since osm_sa_db_file_dump() doesn't have to actually dump SA DB, reflecting this in the function return values.
Function returns 0 if the SA DB was actually dumped,
Quoted 1 line
0 if there was no need to dump the SA DB and <0 if
some error occurred.
--- opensm/include/opensm/osm_sa.h | 4 +++- opensm/opensm/osm_sa.c | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-)
opensm/include/opensm/osm_sa.h +3 -1
@@ -436,7 +436,9 @@ int osm_sa_db_file_dump(struct osm_opensm *p_osm);* [in] Pointer to an osm_opensm_t object. * * RETURN VALUES -* None +* 0 if the SA DB was actually dumped +* >0 if there was no need to dump the SA DB +* <0 if some error occurred. * *********/
opensm/opensm/osm_sa.c +1 -1
@@ -704,7 +704,7 @@ static void sa_dump_all_sa(osm_opensm_t * p_osm, FILE * file)int osm_sa_db_file_dump (osm_opensm_t * p_osm) { -int res =0 ; +int res =1 ;if (p_osm->sa.dirty) { res =opensm_dump_to_file ( p_osm,"opensm-sa.dump" , sa_dump_all_sa);
Signature · 6 lines
1.5.1.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): 4B5878A5.1080800-LDSdmyG8hGV8YrgS2mwiifqBs+8SCbDb@public.gmane.org
Sasha Khapyorsky
AppliedQuoted 8 lines · Yevgeny Kliteynik
Since
osm_sa_db_file_dump()doesn't have to actually dump SA DB, reflecting this in the function return values.Function returns 0 if the SA DB was actually dumped,
Quoted 1 line
0 if there was no need to dump the SA DB and <0 if
some error occurred.
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