26 #include <librtasevent.h> 27 #include <servicelog-1/servicelog.h> 40 extern char *scenario_file;
41 extern int testing_finished;
47 #define RTAS_ERRD_ARGS "c:de:f:hl:m:p:Rs:" 53 #define RTAS_ERRD_ARGS "dh" 60 extern struct servicelog *
slog;
62 #define RTAS_ERROR_LOG_MAX 4096 63 #define ADDL_TEXT_MAX 256 66 #define MAX(x,y) ((x) > (y) ? (x) : (y)) 113 #define RE_SCANLOG_AVAIL 0x00000001 114 #define RE_SERVICEABLE 0x00000002 115 #define RE_PLATDUMP_AVAIL 0x00000004 116 #define RE_PREDICTIVE 0x00000008 118 #define RE_HMC_TAGGED 0x40000000 119 #define RE_ALREADY_REPORTED 0x20000000 120 #define RE_RECOVERED_ERROR 0x10000000 125 #define dbg(_f, _a...) _dbg("%s(): "_f, __FUNCTION__, ##_a) 130 void _dbg(
const char *, ...);
175 char *loc,
char *pn,
char *sn,
char *ccin);
void free_diag_vpd(struct event *)
Definition: diag_support.c:39
void log_event(struct event *)
log the event in the servicelog DB
Definition: servicelog.c:216
char * rtas_errd_log0
Saved ("rolled over") messages log for rtas_errd daemon.
Definition: files.c:73
int process_v6(struct event *)
Definition: v6ela.c:526
int platform_log_fd
Definition: files.c:38
int debug
Debug level to run at for rtas_errd daemon.
Definition: rtas_errd.c:41
void check_scanlog_dump(void)
Check for new scanlog dumps.
Definition: dump.c:163
#define RTAS_ERROR_LOG_MAX
Definition: rtas_errd.h:62
Header for ppc64-diag config file.
struct to track and handle RTAS events in rtas_errd.
Definition: rtas_errd.h:97
void handle_hotplug_event(struct event *)
Definition: hotplug.c:34
int process_pre_v6(struct event *)
Handle older (pre-v6) style events.
Definition: ela.c:541
time_t get_event_date(struct event *event)
Retrieve the timestamp from an event.
Definition: servicelog.c:48
int servicelog_sev(int rtas_sev)
convert RTAS severity to servicelog severity
Definition: servicelog.c:102
void close_files(void)
Close all the files used by rtas_errd.
Definition: files.c:320
struct servicelog * slog
servicelog struct for libservicelog use
Definition: rtas_errd.c:62
char * proc_error_log2
Alternate file to read RTAS events from.
Definition: files.c:53
unsigned sequence
Definition: rtas_errd.h:74
void handle_resource_dealloc(struct event *)
Parse RTAS event for CPU guard information.
Definition: guard.c:548
char * tm
Definition: rtas_errd.h:85
void cfg_log(char *,...)
dummy interface for calls to diag_cfg
Definition: files.c:688
struct rtas_event * rtas_event
Definition: rtas_errd.h:108
#define ADDL_TEXT_MAX
Definition: rtas_errd.h:63
char * scanlog
buffer to hold scanlog dump path
Definition: files.c:94
int get_error_fmt(struct event *)
Extract the error log format indicator from the chrp error log.
Definition: ela.c:1196
char * platform_log
Definition: files.c:37
void check_eeh(struct event *)
Check a RTAS event for EEH event notification.
Definition: eeh.c:61
char * ds
Definition: rtas_errd.h:80
unsigned time_stamp
Definition: rtas_errd.h:75
char * diag_get_fru_pn(struct event *, char *)
Definition: diag_support.c:484
char * proc_error_log1
File to read RTAS events from.
Definition: files.c:52
Definition: rtas_errd.h:73
char * get_dt_status(char *)
Definition: diag_support.c:243
unsigned int flags
Definition: rtas_errd.h:103
int check_epow(struct event *)
Check an RTAS event for EPOW data.
Definition: epow.c:396
Definition: rtas_errd.h:79
int init_files(void)
Initialize files used by rtas_errd.
Definition: files.c:264
void setup_sigchld_handler(void)
setup child signal handler
Definition: signal.c:99
char * fn
Definition: rtas_errd.h:82
int length
Definition: rtas_errd.h:100
int platform_log_write(char *,...)
Write messages to the platform log.
Definition: files.c:860
int menugoal(struct event *, char *)
void log_msg(struct event *, char *,...)
Log messages to rtas_errd_log.
Definition: files.c:706
unsigned err_id
Definition: rtas_errd.h:76
struct sl_event * sl_entry
Definition: rtas_errd.h:109
void update_epow_status_file(int)
Update the epow status file.
Definition: files.c:887
int read_proc_error_log(char *, int)
Read data from proc_error_log.
Definition: files.c:351
void epow_timer_handler(int, siginfo_t, void *)
Routine to handle SIGALRM timer interrupts.
Definition: epow.c:63
void check_platform_dump(struct event *)
Check RTAS event for a platform dump.
Definition: dump.c:274
struct rtas_event_hdr * rtas_hdr
Definition: rtas_errd.h:101
char * messages_log
Definition: update.c:68
void restore_sigchld_default(void)
restore child signal handler
Definition: signal.c:73
char * epow_status_file
Definition: files.c:83
int print_rtas_event(struct event *)
Print an RTAS event to the platform log.
Definition: files.c:758
void update_rtas_msgs(void)
Update RTAS messages in the platform log.
Definition: update.c:207
int handle_rtas_event(struct event *)
Main routine for processing RTAS events.
Definition: rtas_errd.c:126
void sighup_handler(int, siginfo_t, void *)
signal handler for SIGHUP
Definition: signal.c:41
char * se
Definition: rtas_errd.h:84
char * loc_codes
Definition: rtas_errd.h:104
void add_callout(struct event *event, char pri, int type, char *proc, char *loc, char *pn, char *sn, char *ccin)
Add a new FRU callout to the list for this event.
Definition: servicelog.c:138
char * rtas_errd_log
Message log for the rtas_errd daemon.
Definition: files.c:72
void _dbg(const char *,...)
Write debug messages to stdout.
Definition: files.c:726
void handle_prrn_event(struct event *)
Definition: prrn.c:621
int seq_num
Definition: rtas_errd.h:98
char * yl
Definition: rtas_errd.h:81
char * sn
Definition: rtas_errd.h:83