#include <diag/diag_log.h>
int dlog_write(dlEntry *entry)
dlog_write 子例程将诊断事件写入诊断事件日志。
| 参数 |
描述 |
| ENTRY |
指向 dlEntry 类型结构的指针,其定义如下
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;
short set;
short msg;
char catName[NAME_SIZE];
}resource_t;
|
| 返回码 |
描述 |
| 重大安全事件数量 |
成功 |
| -1 |
失败 |
| 错误 FS |
指示 /var 文件系统已满 |