Go to the source code of this file.
|
| static int | insert_in_list (char *name, char *units, char *description, char *filename) |
| |
| static int | generateEventList (char *base_dir) |
| |
| static long long | getEventValue (int index) |
| |
| static int | _coretemp_init_thread (hwd_context_t *ctx) |
| |
| static int | _coretemp_init_component (int cidx) |
| |
| static int | _coretemp_init_control_state (hwd_control_state_t *ctl) |
| |
| static int | _coretemp_start (hwd_context_t *ctx, hwd_control_state_t *ctl) |
| |
| static int | _coretemp_read (hwd_context_t *ctx, hwd_control_state_t *ctl, long long **events, int flags) |
| |
| static int | _coretemp_stop (hwd_context_t *ctx, hwd_control_state_t *ctl) |
| |
| static int | _coretemp_shutdown_thread (hwd_context_t *ctx) |
| |
| static int | _coretemp_shutdown_component () |
| |
| static int | _coretemp_ctl (hwd_context_t *ctx, int code, _papi_int_option_t *option) |
| |
| static int | _coretemp_update_control_state (hwd_control_state_t *ptr, NativeInfo_t *native, int count, hwd_context_t *ctx) |
| |
| static int | _coretemp_set_domain (hwd_control_state_t *cntl, int domain) |
| |
| static int | _coretemp_reset (hwd_context_t *ctx, hwd_control_state_t *ctl) |
| |
| static int | _coretemp_ntv_enum_events (unsigned int *EventCode, int modifier) |
| |
| static int | _coretemp_ntv_code_to_name (unsigned int EventCode, char *name, int len) |
| |
| static int | _coretemp_ntv_code_to_descr (unsigned int EventCode, char *name, int len) |
| |
| static int | _coretemp_ntv_code_to_info (unsigned int EventCode, PAPI_event_info_t *info) |
| |
◆ INVALID_RESULT
| #define INVALID_RESULT -1000000L |
◆ NUM_PATHS
◆ REFRESH_LAT
◆ _coretemp_ctl()
◆ _coretemp_init_component()
| static int _coretemp_init_component |
( |
int |
cidx | ) |
|
|
static |
Definition at line 359 of file linux-coretemp.c.
char description[PAPI_MAX_STR_LEN]
char disabled_reason[PAPI_MAX_STR_LEN]
static struct temp_event * root
static CORETEMP_native_event_entry_t * _coretemp_native_events
char units[MAX_EVENTS][BUFSIZ]
PAPI_component_info_t cmp_info
char name[PAPI_MAX_STR_LEN]
char units[PAPI_MIN_STR_LEN]
CORETEMP_register_t resources
char units[PAPI_MIN_STR_LEN]
char description[PAPI_MAX_STR_LEN]
static struct temp_event * last
static int is_initialized
static int generateEventList(char *base_dir)
papi_vector_t _coretemp_vector
#define papi_calloc(a, b)
char name[PAPI_MAX_STR_LEN]
◆ _coretemp_init_control_state()
Definition at line 426 of file linux-coretemp.c.
int coretemp_ctl(hwd_context_t *ctx, int code, _papi_int_option_t *option)
long long PAPI_get_real_usec(void)
static long long getEventValue(int index)
◆ _coretemp_init_thread()
◆ _coretemp_ntv_code_to_descr()
| static int _coretemp_ntv_code_to_descr |
( |
unsigned int |
EventCode, |
|
|
char * |
name, |
|
|
int |
len |
|
) |
| |
|
static |
Definition at line 638 of file linux-coretemp.c.
640 int index = EventCode;
static CORETEMP_native_event_entry_t * _coretemp_native_events
char description[PAPI_MAX_STR_LEN]
◆ _coretemp_ntv_code_to_info()
| static int _coretemp_ntv_code_to_info |
( |
unsigned int |
EventCode, |
|
|
PAPI_event_info_t * |
info |
|
) |
| |
|
static |
Definition at line 650 of file linux-coretemp.c.
653 int index = EventCode;
char description[PAPI_MAX_STR_LEN]
char units[PAPI_MIN_STR_LEN]
char long_descr[PAPI_HUGE_STR_LEN]
static CORETEMP_native_event_entry_t * _coretemp_native_events
char units[PAPI_MIN_STR_LEN]
char symbol[PAPI_HUGE_STR_LEN]
char name[PAPI_MAX_STR_LEN]
◆ _coretemp_ntv_code_to_name()
| static int _coretemp_ntv_code_to_name |
( |
unsigned int |
EventCode, |
|
|
char * |
name, |
|
|
int |
len |
|
) |
| |
|
static |
Definition at line 623 of file linux-coretemp.c.
625 int index = EventCode;
static CORETEMP_native_event_entry_t * _coretemp_native_events
◆ _coretemp_ntv_enum_events()
| static int _coretemp_ntv_enum_events |
( |
unsigned int * |
EventCode, |
|
|
int |
modifier |
|
) |
| |
|
static |
Definition at line 584 of file linux-coretemp.c.
589 switch ( modifier ) {
606 *EventCode = *EventCode + 1;
◆ _coretemp_read()
Definition at line 452 of file linux-coretemp.c.
char events[MAX_EVENTS][BUFSIZ]
long long counts[CORETEMP_MAX_COUNTERS]
long long PAPI_get_real_usec(void)
static long long getEventValue(int index)
◆ _coretemp_reset()
◆ _coretemp_set_domain()
◆ _coretemp_shutdown_component()
| static int _coretemp_shutdown_component |
( |
| ) |
|
|
static |
Definition at line 506 of file linux-coretemp.c.
static CORETEMP_native_event_entry_t * _coretemp_native_events
static int is_initialized
◆ _coretemp_shutdown_thread()
◆ _coretemp_start()
◆ _coretemp_stop()
Definition at line 479 of file linux-coretemp.c.
long long counts[CORETEMP_MAX_COUNTERS]
static long long getEventValue(int index)
◆ _coretemp_update_control_state()
Definition at line 533 of file linux-coretemp.c.
static CORETEMP_native_event_entry_t * _coretemp_native_events
CORETEMP_register_t resources
◆ generateEventList()
| static int generateEventList |
( |
char * |
base_dir | ) |
|
|
static |
Definition at line 91 of file linux-coretemp.c.
102 struct dirent *hwmonx;
112 dir = opendir(base_dir);
114 SUBDBG(
"Can't find %s, are you sure the coretemp module is loaded?\n",
120 while( (hwmonx = readdir(dir) ) ) {
121 if ( !strncmp(
"hwmon", hwmonx->d_name, 5) ) {
126 for(pathnum=0;pathnum<
NUM_PATHS;pathnum++) {
128 snprintf(path,
PATH_MAX,
"%s/%s/%s",
129 base_dir, hwmonx->d_name,paths[pathnum]);
131 SUBDBG(
"Trying to open %s\n",path);
145 modulename[strlen(modulename)-1]=
'\0';
150 SUBDBG(
"Found module %s\n",modulename);
172 location[strlen(location)-1]=
'\0';
181 if (
fff==NULL)
continue;
186 SUBDBG(
"Unable to generate name %s:in%i_input\n", hwmonx->d_name,
i);
218 location[strlen(location)-1]=
'\0';
227 if (
fff==NULL)
continue;
232 SUBDBG(
"Unable to generate name %s:temp%i_input\n", hwmonx->d_name,
i);
263 location[strlen(location)-1]=
'\0';
271 SUBDBG(
"Unable to generate filename %s/fan%d_input\n", path,
i);
276 if (
fff==NULL)
continue;
281 SUBDBG(
"Unable to generate name %s:fan%i_input\n", hwmonx->d_name,
i);
char filename[MAXNAMESIZE]
char units[MAX_EVENTS][BUFSIZ]
char description[PAPI_MAX_STR_LEN]
#define SUBDBG(format, args...)
char location[PAPI_MAX_STR_LEN]
static int insert_in_list(char *name, char *units, char *description, char *filename)
◆ getEventValue()
| static long long getEventValue |
( |
int |
index | ) |
|
|
static |
Definition at line 312 of file linux-coretemp.c.
331 result=strtoll(
buf, NULL, 10);
static CORETEMP_native_event_entry_t * _coretemp_native_events
volatile int buf[CACHE_FLUSH_BUFFER_SIZE_INTS]
◆ insert_in_list()
| static int insert_in_list |
( |
char * |
name, |
|
|
char * |
units, |
|
|
char * |
description, |
|
|
char * |
filename |
|
) |
| |
|
static |
Definition at line 44 of file linux-coretemp.c.
72 PAPIERROR(
"This shouldn't be possible\n");
static struct temp_event * root
char filename[MAXNAMESIZE]
char units[MAX_EVENTS][BUFSIZ]
char name[PAPI_MAX_STR_LEN]
char units[PAPI_MIN_STR_LEN]
char description[PAPI_MAX_STR_LEN]
void PAPIERROR(char *format,...)
static struct temp_event * last
#define papi_calloc(a, b)
◆ _coretemp_native_events
◆ _coretemp_vector
◆ is_initialized
◆ last
◆ num_events
◆ root