Lines Matching refs:errstate
1227 struct bofi_errstate *errstate, in add_edef() argument
1247 errdef->log.logsize = errstate->log.logsize = in add_edef()
1250 errdef->log.logsize = errstate->log.logsize = 0; in add_edef()
1252 errdef->log.logbase = errstate->log.logbase = in add_edef()
1275 errstate->errdef_handle = errdef->errdef_handle; in add_edef()
1280 collect_state(int fd, int cmd, struct bofi_errstate *errstate, in collect_state() argument
1284 size_t ls = errstate->log.logsize; in collect_state()
1290 errstate->log.logsize = 0; /* only copy the driver log once */ in collect_state()
1293 errstate->log.logsize); in collect_state()
1296 if (ioctl(fd, cmd, errstate) == -1 && errno != EINTR) { in collect_state()
1304 errstate->log.entries, ls, in collect_state()
1306 errdef->access_type, errstate->log.wrapcnt); in collect_state()
1309 errstate->access_count, errstate->fail_count, in collect_state()
1310 errstate->log.flags, errstate->log.wrapcnt); in collect_state()
1313 if ((errstate->log.flags & BOFI_LOG_WRAP) && in collect_state()
1314 errstate->access_count > 0) in collect_state()
1316 if (errstate->access_count <= 1 && in collect_state()
1317 errstate->fail_count == 0 && in collect_state()
1318 errstate->acc_chk == 0) { in collect_state()
1320 errstate->log.entries); in collect_state()
1325 errstate->access_count, errstate->fail_count, in collect_state()
1326 errstate->acc_chk); in collect_state()
1329 errstate->log.logsize, errstate->log.entries, in collect_state()
1330 errdef->offset, errdef->len, errstate->access_count); in collect_state()
1332 } while (rval == 0 && errstate->log.entries < ls); in collect_state()
1335 errstate->log.logsize = ls; in collect_state()
1336 if (errstate->log.entries != 0) { in collect_state()
1337 if (ioctl(fd, BOFI_CHK_STATE, errstate) == -1) { in collect_state()
1340 Progname, errstate->log.entries, strerror(errno)); in collect_state()
1345 errstate->log.entries, errstate->access_count, in collect_state()
1346 errstate->log.start_time, errstate->log.stop_time); in collect_state()
1348 log2errdefs(fd, errdef, &(errstate->log), devpath); in collect_state()