diff --git a/ompi/mca/common/ompio/common_ompio_file_open.c b/ompi/mca/common/ompio/common_ompio_file_open.c index ba75f551ed..d21863a26e 100644 --- a/ompi/mca/common/ompio/common_ompio_file_open.c +++ b/ompi/mca/common/ompio/common_ompio_file_open.c @@ -129,11 +129,6 @@ int mca_common_ompio_file_open (ompi_communicator_t *comm, goto fn_fail; } - if (OMPI_SUCCESS != (ret = mca_fcoll_base_file_select (ompio_fh, - NULL))) { - opal_output(1, "mca_fcoll_base_file_select() failed\n"); - goto fn_fail; - } ompio_fh->f_sharedfp_component = NULL; /*component*/ ompio_fh->f_sharedfp = NULL; /*module*/ @@ -165,6 +160,12 @@ int mca_common_ompio_file_open (ompi_communicator_t *comm, goto fn_fail; } + if (OMPI_SUCCESS != (ret = mca_fcoll_base_file_select (ompio_fh, + NULL))) { + opal_output(1, "mca_fcoll_base_file_select() failed\n"); + goto fn_fail; + } + if ( true == use_sharedfp ) { /* open the file once more for the shared file pointer if required. @@ -420,7 +421,7 @@ int mca_common_ompio_set_file_defaults (mca_io_ompio_file_t *fh) /* Default file View */ fh->f_iov_type = MPI_DATATYPE_NULL; - fh->f_stripe_size = mca_io_ompio_bytes_per_agg; + fh->f_stripe_size = 0; /*Decoded iovec of the file-view*/ fh->f_decoded_iov = NULL; fh->f_etype = NULL; diff --git a/ompi/mca/io/ompio/io_ompio_aggregators.c b/ompi/mca/io/ompio/io_ompio_aggregators.c index 7f20faba8c..9bf568235c 100644 --- a/ompi/mca/io/ompio/io_ompio_aggregators.c +++ b/ompi/mca/io/ompio/io_ompio_aggregators.c @@ -63,7 +63,7 @@ int mca_io_ompio_simple_grouping(mca_io_ompio_file_t *fh, int k=0, p=0, g=0; int total_procs = 0; - if ( 0 < fh->f_stripe_size ) { + if ( 0 >= fh->f_stripe_size ) { stripe_size = OMPIO_DEFAULT_STRIPE_SIZE; }