dlog_read
Purpose
Read an entry from the Diagnostic Event Log at the specified offset.
Syntax
#include <diag/diag_log.h>
dlEntry *dlog_read(dl_info *dlogInfo,int index)
Description
The dlog_read subroutine will read a Diagnostic Event Log entry at the specified offset, which is determined from the index. It will return a pointer to a structure of format:
typedef struct _logEntry {
char type; /* Log Type */
char identifier[5]; /* Diagnostic Log identifier */
unsigned int el_identifier; /* Error log identifier */
int timestamp;
unsigned int seqNum; /* order in which event is logged */
unsigned int el_seqNum; /* Error log sequence number */
unsigned int session; /* Diag Session's PID */
unsigned int testMode; /* Diagnostics test mode - hex value*/
resource_t *res_p; /* Resource information */
int resSize; /* Size of resource info */
void *errorInfo; /* Error information */
int errorSize; /* Size of error info */
} dlEntry;
typedef struct resource {
char name[NAME_SIZE];
int locSize;
char *location; /* Logical or Physical */
short set;
short msg;
char catName[NAME_SIZE];
} resource_t;
Parameters
Parameter | Description |
---|---|
dlogInfo | Pointer to structure of format:
|
index | Index into Diagnostic Event log array for specific entry |
Return Value
Upon successful completion, a pointer to dlEntry is returned. Otherwise, a value of NULL is returned.