This source file includes following definitions.
- component_open
- component_query
- component_close
- assign_module
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29 #include <src/include/pmix_config.h>
30 #include "pmix_common.h"
31
32 #include "src/mca/base/pmix_mca_base_var.h"
33 #include "src/mca/psec/psec.h"
34 #include "psec_none.h"
35
36 static pmix_status_t component_open(void);
37 static pmix_status_t component_close(void);
38 static pmix_status_t component_query(pmix_mca_base_module_t **module, int *priority);
39 static pmix_psec_module_t* assign_module(void);
40
41
42
43
44
45 pmix_psec_base_component_t mca_psec_none_component = {
46 .base = {
47 PMIX_PSEC_BASE_VERSION_1_0_0,
48
49
50 .pmix_mca_component_name = "none",
51 PMIX_MCA_BASE_MAKE_VERSION(component,
52 PMIX_MAJOR_VERSION,
53 PMIX_MINOR_VERSION,
54 PMIX_RELEASE_VERSION),
55
56
57 .pmix_mca_open_component = component_open,
58 .pmix_mca_close_component = component_close,
59 .pmix_mca_query_component = component_query,
60 },
61 .data = {
62
63 PMIX_MCA_BASE_METADATA_PARAM_CHECKPOINT
64 },
65 .assign_module = assign_module
66 };
67
68
69 static int component_open(void)
70 {
71 int index;
72 const pmix_mca_base_var_storage_t *value=NULL;
73
74
75
76 if (0 > (index = pmix_mca_base_var_find("pmix", "psec", NULL, NULL))) {
77 return PMIX_ERROR;
78 }
79 pmix_mca_base_var_get_value (index, &value, NULL, NULL);
80 if (NULL != value && NULL != value->stringval && '\0' != value->stringval[0]) {
81 if (NULL != strstr(value->stringval, "none")) {
82 return PMIX_SUCCESS;
83 }
84 }
85 return PMIX_ERROR;
86 }
87
88
89 static int component_query(pmix_mca_base_module_t **module, int *priority)
90 {
91 *priority = 0;
92 *module = (pmix_mca_base_module_t *)&pmix_none_module;
93 return PMIX_SUCCESS;
94 }
95
96
97 static int component_close(void)
98 {
99 return PMIX_SUCCESS;
100 }
101
102 static pmix_psec_module_t* assign_module(void)
103 {
104 return &pmix_none_module;
105 }