@@ -1048,8 +1048,7 @@ ds_pool_put(struct ds_pool *pool)
10481048void
10491049pool_fetch_hdls_ult (void * data )
10501050{
1051- struct ds_pool * pool = data ;
1052- int rc = 0 ;
1051+ struct ds_pool * pool = data ;
10531052
10541053 D_INFO (DF_UUID ": begin: fetch_hdls=%u stopping=%u\n" , DP_UUID (pool -> sp_uuid ),
10551054 pool -> sp_fetch_hdls , pool -> sp_stopping );
@@ -1065,19 +1064,18 @@ pool_fetch_hdls_ult(void *data)
10651064 }
10661065 ABT_mutex_unlock (pool -> sp_mutex );
10671066
1068- if ( pool -> sp_stopping ) {
1069- D_DEBUG ( DB_MD , DF_UUID ": skip fetching hdl due to stop\n" ,
1070- DP_UUID ( pool -> sp_uuid ));
1071- D_GOTO ( out , rc );
1072- }
1073- D_INFO ( DF_UUID ": fetching handles\n" , DP_UUID ( pool -> sp_uuid ));
1074- rc = ds_pool_iv_conn_hdl_fetch (pool );
1075- if (rc ) {
1076- D_INFO ( DF_UUID " iv conn fetch %d\n" , DP_UUID ( pool -> sp_uuid ), rc ) ;
1077- D_GOTO ( out , rc );
1067+ while (! pool -> sp_stopping ) {
1068+ int rc ;
1069+
1070+ D_DEBUG ( DB_MD , DF_UUID ": fetching handles: begin\n" , DP_UUID ( pool -> sp_uuid ) );
1071+ rc = ds_pool_iv_conn_hdl_fetch ( pool );
1072+ D_DEBUG ( DB_MD , DF_UUID ": fetching handles: end: " DF_RC " \n" ,
1073+ DP_UUID (pool -> sp_uuid ), DP_RC ( rc ) );
1074+ if (rc == 0 )
1075+ break ;
1076+ dss_sleep ( 1000 /* ms */ );
10781077 }
10791078
1080- out :
10811079 D_INFO (DF_UUID ": signaling done\n" , DP_UUID (pool -> sp_uuid ));
10821080 ABT_mutex_lock (pool -> sp_mutex );
10831081 ABT_cond_signal (pool -> sp_fetch_hdls_done_cond );
0 commit comments