Adaptec AHA-1520A Manual de Serviço Página 201

  • Descarregar
  • Adicionar aos meus manuais
  • Imprimir
  • Página
    / 434
  • Índice
  • MARCADORES
  • Avaliado. / 5. Com base em avaliações de clientes
Vista de página 200
SunOS 5.5 Devices log(7D)
ENXIO is returned for I_TRCLOG ioctls without any trace_ids structures, or for any
unrecognized ioctl calls. The driver silently ignores incorrectly formatted log messages
sent to the driver by a user process (no error results).
Processes that wish to write a message to the console logger may direct their output to
/dev/conslog, using either write(2) or putmsg(2).
EXAMPLES Example of I_ERRLOG registration:
struct strioctl ioc;
ioc.ic_cmd = I_ERRLOG;
ioc.ic_timout = 0; /default timeout (15 secs.) /
ioc.ic_len = 0;
ioc.ic_dp = NULL;
ioctl(log, I_STR, &ioc);
Example of I_TRCLOG registration:
struct trace_ids tid[2];
tid[0].ti_mid = 2;
tid[0].ti_sid = 0;
tid[0].ti_level = 1;
tid[1].ti_mid = 1002;
tid[1].ti_sid = 1; /any sub-id will be allowed /
tid[1].ti_level = 1; /any level will be allowed /
ioc.ic_cmd = I_TRCLOG;
ioc.ic_timout = 0;
ioc.ic_len = 2 sizeof(struct trace_ids);
ioc.ic_dp = (char )tid;
ioctl(log, I_STR, &ioc);
Example of submitting a log message (no arguments):
struct strbuf ctl, dat;
struct log_ctl lc;
char message = "Don’t forget to pick up some milk
on the way home";
ctl.len = ctl.maxlen = sizeof(lc);
ctl.buf = (char )&lc;
dat.len = dat.maxlen = strlen(message);
modified 23 Feb 1994 7D-197
Vista de página 200
1 2 ... 196 197 198 199 200 201 202 203 204 205 206 ... 433 434

Comentários a estes Manuais

Sem comentários