@@ -137,43 +137,47 @@ static int init(void)
137137 if (OPAL_SUCCESS != (rc = enough_space (shmemfile , shmemsize ,
138138 & amount_space_avail ,
139139 & space_available ))) {
140- opal_output (0 , "%s an error occurred while determining "
141- "whether or not %s could be created." ,
142- ORTE_NAME_PRINT (ORTE_PROC_MY_NAME ), shmemfile );
140+ opal_output_verbose (2 , orte_rtc_base_framework .framework_output ,
141+ "%s an error occurred while determining "
142+ "whether or not %s could be created for topo shmem." ,
143+ ORTE_NAME_PRINT (ORTE_PROC_MY_NAME ), shmemfile );
143144 free (shmemfile );
144145 shmemfile = NULL ;
145- return rc ;
146+ return ORTE_SUCCESS ;
146147 }
147148 if (!space_available ) {
148- rc = OPAL_ERR_OUT_OF_RESOURCE ;
149- orte_show_help ("help-orte-rtc-hwloc.txt" , "target full" , true,
150- shmemfile , orte_process_info .nodename ,
151- (unsigned long )shmemsize ,
152- (unsigned long long )amount_space_avail );
149+ if (1 < opal_output_get_verbosity (orte_rtc_base_framework .framework_output )) {
150+ orte_show_help ("help-orte-rtc-hwloc.txt" , "target full" , true,
151+ shmemfile , orte_process_info .nodename ,
152+ (unsigned long )shmemsize ,
153+ (unsigned long long )amount_space_avail );
154+ }
153155 free (shmemfile );
154156 shmemfile = NULL ;
155- return rc ;
157+ return ORTE_SUCCESS ;
156158 }
157159 /* enough space is available, so create the segment */
158160 if (-1 == (shmemfd = open (shmemfile , O_CREAT | O_RDWR , 0600 ))) {
159161 int err = errno ;
160- orte_show_help ("help-orte-rtc-hwloc.txt" , "sys call fail" , true,
161- orte_process_info .nodename ,
162- "open(2)" , "" , strerror (err ), err );
163- rc = OPAL_ERROR ;
162+ if (1 < opal_output_get_verbosity (orte_rtc_base_framework .framework_output )) {
163+ orte_show_help ("help-orte-rtc-hwloc.txt" , "sys call fail" , true,
164+ orte_process_info .nodename ,
165+ "open(2)" , "" , strerror (err ), err );
166+ }
164167 free (shmemfile );
165168 shmemfile = NULL ;
166- return rc ;
169+ return ORTE_SUCCESS ;
167170 }
168171 /* populate the shmem segment with the topology */
169172 if (0 != (rc = hwloc_shmem_topology_write (opal_hwloc_topology , shmemfd , 0 ,
170173 (void * )shmemaddr , shmemsize , 0 ))) {
171- opal_output (0 , "WRITE FAILED %d" , rc );
172- ORTE_ERROR_LOG (ORTE_ERROR );
174+ opal_output_verbose (2 , orte_rtc_base_framework .framework_output ,
175+ "%s an error occurred while writing topology to %s" ,
176+ ORTE_NAME_PRINT (ORTE_PROC_MY_NAME ), shmemfile );
173177 unlink (shmemfile );
174178 free (shmemfile );
175179 shmemfile = NULL ;
176- return OPAL_ERROR ;
180+ return ORTE_SUCCESS ;
177181 }
178182#endif
179183
0 commit comments