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 Tennessee and The University 7 * of Tennessee 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) 2007-2008 Cisco Systems, Inc. All rights reserved. 14 * Copyright (c) 2015 Los Alamos National Security, LLC. All rights 15 * 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 "opal_config.h" 30 31 #include "opal/constants.h" 32 #include "opal/mca/pstat/pstat.h" 33 #include "pstat_linux.h" 34 35 /* 36 * Public string showing the pstat ompi_linux component version number 37 */ 38 const char *opal_pstat_linux_component_version_string = 39 "OPAL linux pstat MCA component version " OPAL_VERSION; 40 41 /* 42 * Local function 43 */ 44 static int pstat_linux_component_query(mca_base_module_t **module, int *priority); 45 46 /* 47 * Instantiate the public struct with all of our public information 48 * and pointers to our public functions in it 49 */ 50 51 const opal_pstat_base_component_t mca_pstat_linux_component = { 52 53 /* First, the mca_component_t struct containing meta information 54 about the component itself */ 55 56 .base_version = { 57 OPAL_PSTAT_BASE_VERSION_2_0_0, 58 59 /* Component name and version */ 60 .mca_component_name = "linux", 61 MCA_BASE_MAKE_VERSION(component, OPAL_MAJOR_VERSION, OPAL_MINOR_VERSION, 62 OPAL_RELEASE_VERSION), 63 64 .mca_query_component = pstat_linux_component_query, 65 }, 66 .base_data = { 67 /* The component is checkpoint ready */ 68 MCA_BASE_METADATA_PARAM_CHECKPOINT 69 }, 70 }; 71 72 73 static int pstat_linux_component_query(mca_base_module_t **module, int *priority) 74 { 75 *priority = 20; 76 *module = (mca_base_module_t *)&opal_pstat_linux_module; 77 78 return OPAL_SUCCESS; 79 } 80