root/opal/mca/event/event.h

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

INCLUDED FROM


   1 /* -*- Mode: C; c-basic-offset:4 ; indent-tabs-mode:nil -*- */
   2 /*
   3  * Copyright (c) 2010      Cisco Systems, Inc.  All rights reserved.
   4  * Copyright (c) 2010      Oracle and/or its affiliates.  All rights reserved.
   5  * Copyright (c) 2014-2015 Intel, Inc. All rights reserved.
   6  * Copyright (c) 2015      Los Alamos National Security, LLC. All rights
   7  *                         reserved.
   8  *
   9  * $COPYRIGHT$
  10  *
  11  * Additional copyrights may follow
  12  */
  13 
  14 #ifndef OPAL_MCA_EVENT_H
  15 #define OPAL_MCA_EVENT_H
  16 
  17 #include "opal_config.h"
  18 
  19 #ifdef HAVE_SYS_TYPES_H
  20 #include <sys/types.h>
  21 #endif
  22 #ifdef HAVE_SYS_TIME_H
  23 #include <sys/time.h>
  24 #endif
  25 #include <stdint.h>
  26 #include <stdarg.h>
  27 
  28 #include "opal/class/opal_pointer_array.h"
  29 
  30 #include "opal/mca/mca.h"
  31 #include "opal/mca/base/base.h"
  32 
  33 BEGIN_C_DECLS
  34 
  35 /* set the number of event priority levels */
  36 #define OPAL_EVENT_NUM_PRI   8
  37 
  38 #define OPAL_EV_ERROR_PRI         0
  39 #define OPAL_EV_MSG_HI_PRI        1
  40 #define OPAL_EV_SYS_HI_PRI        2
  41 #define OPAL_EV_MSG_LO_PRI        3
  42 #define OPAL_EV_SYS_LO_PRI        4
  43 #define OPAL_EV_INFO_HI_PRI       5
  44 #define OPAL_EV_INFO_LO_PRI       6
  45 #define OPAL_EV_LOWEST_PRI        7
  46 
  47 #define OPAL_EVENT_SIGNAL(ev)   opal_event_get_signal(ev)
  48 
  49 #define OPAL_TIMEOUT_DEFAULT    {1, 0}
  50 
  51 /**
  52  * Structure for event components.
  53  */
  54 struct opal_event_base_component_2_0_0_t {
  55     /** MCA base component */
  56     mca_base_component_t base_version;
  57     /** MCA base data */
  58     mca_base_component_data_t base_data;
  59 };
  60 
  61 /**
  62  * Convenience typedef
  63  */
  64 typedef struct opal_event_base_component_2_0_0_t opal_event_base_component_2_0_0_t;
  65 typedef struct opal_event_base_component_2_0_0_t opal_event_component_t;
  66 
  67 /**
  68  * Macro for use in components that are of type event
  69  */
  70 #define OPAL_EVENT_BASE_VERSION_2_0_0 \
  71     OPAL_MCA_BASE_VERSION_2_1_0("event", 2, 0, 0)
  72 
  73 END_C_DECLS
  74 
  75 /* include implementation to call */
  76 #include MCA_event_IMPLEMENTATION_HEADER
  77 
  78 #endif /* OPAL_EVENT_H_ */

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