root/opal/mca/pmix/pmix4x/pmix/src/mca/bfrops/v12/bfrop_v12_component.c

/* [<][>][^][v][top][bottom][index][help] */

DEFINITIONS

This source file includes following definitions.
  1. component_open
  2. component_query
  3. component_close
  4. assign_module

   1 /* -*- Mode: C; c-basic-offset:4 ; indent-tabs-mode:nil -*- */
   2 /*
   3  * Copyright (c) 2004-2008 The Trustees of Indiana University and Indiana
   4  *                         University Research and Technology
   5  *                         Corporation.  All rights reserved.
   6  * Copyright (c) 2004-2005 The University of Tennbfropsee and The University
   7  *                         of Tennbfropsee Research Foundation.  All rights
   8  *                         reserved.
   9  * Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
  10  *                         University of Stuttgart.  All rights reserved.
  11  * Copyright (c) 2004-2005 The Regents of the University of California.
  12  *                         All rights reserved.
  13  * Copyright (c) 2015      Los Alamos National Security, LLC. All rights
  14  *                         reserved.
  15  * Copyright (c) 2016-2017 Intel, Inc.  All rights reserved.
  16  * $COPYRIGHT$
  17  *
  18  * Additional copyrights may follow
  19  *
  20  * $HEADER$
  21  *
  22  * These symbols are in a file by themselves to provide nice linker
  23  * semantics.  Since linkers generally pull in symbols by object
  24  * files, keeping these symbols as the only symbols in this file
  25  * prevents utility programs such as "ompi_info" from having to import
  26  * entire components just to query their version and parameters.
  27  */
  28 
  29 #include <src/include/pmix_config.h>
  30 #include <pmix_common.h>
  31 #include "src/include/types.h"
  32 #include "src/include/pmix_globals.h"
  33 
  34 #include "src/util/error.h"
  35 #include "src/server/pmix_server_ops.h"
  36 #include "src/mca/bfrops/base/base.h"
  37 #include "bfrop_v12.h"
  38 
  39 extern pmix_bfrops_module_t pmix_bfrops_pmix12_module;
  40 
  41 static pmix_status_t component_open(void);
  42 static pmix_status_t component_query(pmix_mca_base_module_t **module, int *priority);
  43 static pmix_status_t component_close(void);
  44 static pmix_bfrops_module_t* assign_module(void);
  45 /*
  46  * Instantiate the public struct with all of our public information
  47  * and pointers to our public functions in it
  48  */
  49 pmix_bfrops_base_component_t mca_bfrops_v12_component = {
  50     .base = {
  51         PMIX_BFROPS_BASE_VERSION_1_0_0,
  52 
  53         /* Component name and version */
  54         .pmix_mca_component_name = "v12",
  55         PMIX_MCA_BASE_MAKE_VERSION(component, PMIX_MAJOR_VERSION, PMIX_MINOR_VERSION,
  56                                    PMIX_RELEASE_VERSION),
  57 
  58         /* Component open and close functions */
  59         .pmix_mca_open_component = component_open,
  60         .pmix_mca_close_component = component_close,
  61         .pmix_mca_query_component = component_query,
  62     },
  63     .priority = 5,
  64     .assign_module = assign_module
  65 };
  66 
  67 
  68 pmix_status_t component_open(void)
  69 {
  70     /* setup the types array */
  71     PMIX_CONSTRUCT(&mca_bfrops_v12_component.types, pmix_pointer_array_t);
  72 
  73     return PMIX_SUCCESS;
  74 }
  75 
  76 
  77 pmix_status_t component_query(pmix_mca_base_module_t **module, int *priority)
  78 {
  79 
  80     *priority = mca_bfrops_v12_component.priority;
  81     *module = (pmix_mca_base_module_t *)&pmix_bfrops_pmix12_module;
  82     return PMIX_SUCCESS;
  83 }
  84 
  85 
  86 pmix_status_t component_close(void)
  87 {
  88     PMIX_DESTRUCT(&mca_bfrops_v12_component.types);
  89     return PMIX_SUCCESS;
  90 }
  91 
  92 static pmix_bfrops_module_t* assign_module(void)
  93 {
  94     return &pmix_bfrops_pmix12_module;
  95 }

/* [<][>][^][v][top][bottom][index][help] */