2004-01-31 21:43:26 +00:00
|
|
|
/*
|
2005-11-05 19:57:48 +00:00
|
|
|
* Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
|
|
|
|
* University Research and Technology
|
|
|
|
* Corporation. All rights reserved.
|
|
|
|
* Copyright (c) 2004-2005 The University of Tennessee and The University
|
|
|
|
* of Tennessee Research Foundation. All rights
|
|
|
|
* reserved.
|
2004-11-28 20:09:25 +00:00
|
|
|
* Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
|
|
|
|
* University of Stuttgart. All rights reserved.
|
2005-03-24 12:43:37 +00:00
|
|
|
* Copyright (c) 2004-2005 The Regents of the University of California.
|
|
|
|
* All rights reserved.
|
2004-11-22 01:38:40 +00:00
|
|
|
* $COPYRIGHT$
|
|
|
|
*
|
|
|
|
* Additional copyrights may follow
|
|
|
|
*
|
2004-01-31 21:43:26 +00:00
|
|
|
* $HEADER$
|
|
|
|
*/
|
|
|
|
|
2006-02-12 01:33:29 +00:00
|
|
|
#include "orte_config.h"
|
2004-01-31 21:43:26 +00:00
|
|
|
|
|
|
|
#include <stdio.h>
|
|
|
|
|
2006-02-12 01:33:29 +00:00
|
|
|
#include "orte/orte_constants.h"
|
|
|
|
#include "opal/mca/mca.h"
|
|
|
|
#include "opal/mca/base/base.h"
|
|
|
|
#include "orte/mca/oob/oob.h"
|
|
|
|
#include "orte/mca/oob/base/base.h"
|
2004-01-31 21:43:26 +00:00
|
|
|
|
|
|
|
|
|
|
|
int mca_oob_base_close(void)
|
|
|
|
{
|
2005-07-03 16:22:16 +00:00
|
|
|
opal_list_item_t* item;
|
2004-08-10 21:02:36 +00:00
|
|
|
|
|
|
|
/* Finalize all the oob modules and free their list items */
|
2005-07-03 16:22:16 +00:00
|
|
|
for (item = opal_list_remove_first(&mca_oob_base_modules);
|
2004-08-10 21:02:36 +00:00
|
|
|
item != NULL;
|
2005-07-03 16:22:16 +00:00
|
|
|
item = opal_list_remove_first(&mca_oob_base_modules)) {
|
2004-08-10 21:02:36 +00:00
|
|
|
mca_oob_base_info_t* base = (mca_oob_base_info_t *) item;
|
2004-08-19 19:34:37 +00:00
|
|
|
base->oob_module->oob_fini();
|
2005-08-29 21:35:01 +00:00
|
|
|
OBJ_RELEASE(base);
|
2004-08-06 17:23:37 +00:00
|
|
|
}
|
|
|
|
|
2004-01-31 21:43:26 +00:00
|
|
|
/* Close all remaining available modules (may be one if this is a
|
2004-06-07 15:33:53 +00:00
|
|
|
OMPI RTE program, or [possibly] multiple if this is ompi_info) */
|
2004-01-31 21:43:26 +00:00
|
|
|
|
2004-08-10 21:02:36 +00:00
|
|
|
mca_base_components_close(mca_oob_base_output, &mca_oob_base_components, NULL);
|
2004-08-06 17:23:37 +00:00
|
|
|
|
2004-07-01 14:49:54 +00:00
|
|
|
OBJ_DESTRUCT(&mca_oob_base_modules);
|
2004-08-02 00:24:22 +00:00
|
|
|
OBJ_DESTRUCT(&mca_oob_base_components);
|
2005-10-06 19:39:20 +00:00
|
|
|
OBJ_DESTRUCT(&mca_oob_base_exception_handlers);
|
2004-08-02 00:24:22 +00:00
|
|
|
|
2004-08-18 15:51:40 +00:00
|
|
|
if( NULL != mca_oob_base_include )
|
|
|
|
free(mca_oob_base_include);
|
|
|
|
if( NULL != mca_oob_base_exclude )
|
|
|
|
free(mca_oob_base_exclude);
|
2004-01-31 21:43:26 +00:00
|
|
|
|
2004-08-18 15:51:40 +00:00
|
|
|
/* All done */
|
2006-02-12 01:33:29 +00:00
|
|
|
return ORTE_SUCCESS;
|
2004-01-31 21:43:26 +00:00
|
|
|
}
|
2004-08-18 15:51:40 +00:00
|
|
|
|