Lines Matching defs:coargs

714 	callout_data_t *coargs = (callout_data_t *)priv;
719 if ((coargs == NULL) || (co == NULL)) {
723 if ((coargs->flags & COF_FREE) && !(co->c_xid & CALLOUT_ID_FREE)) {
730 if (!(coargs->flags & COF_FREE) && (co->c_xid & CALLOUT_ID_FREE)) {
737 if ((coargs->flags & COF_FUNC) &&
738 (coargs->funcaddr != (uintptr_t)co->c_func)) {
741 if ((coargs->flags & COF_PARAM) &&
742 (coargs->param != (uintptr_t)co->c_arg)) {
745 if (!(coargs->flags & COF_LONG) && (co->c_xid & CALLOUT_LONGTERM)) {
748 if (!(coargs->flags & COF_SHORT) && !(co->c_xid & CALLOUT_LONGTERM)) {
751 if ((coargs->flags & COF_EXEC) && !(co->c_xid & CALLOUT_EXECUTING)) {
755 if (coargs->flags & COF_BYIDH) {
756 if (!(coargs->flags & COF_FREE)) {
758 if (mdb_vread(&coargs->exp, sizeof (hrtime_t),
763 coargs->exp = 0;
766 if (mdb_vread(&coargs->list_flags, sizeof (int),
771 coargs->list_flags = 0;
775 coargs->exp = 0;
776 coargs->list_flags = 0;
778 if (coargs->exp != 0) {
779 if ((coargs->flags & COF_TIME) &&
780 (coargs->exp != coargs->time)) {
783 if ((coargs->flags & COF_BEFORE) &&
784 (coargs->exp > coargs->btime)) {
787 if ((coargs->flags & COF_AFTER) &&
788 (coargs->exp < coargs->atime)) {
793 list_flags = coargs->list_flags;
794 if ((coargs->flags & COF_HIRES) && (coargs->flags & COF_ABS)) {
801 if ((coargs->flags & COF_HIRES) &&
805 if ((coargs->flags & COF_ABS) &&
816 if ((coargs->flags & COF_HEAP) &&
821 if ((coargs->flags & COF_QUEUE) &&
827 #define callout_table_mask ((1 << coargs->ctbits) - 1)
832 if ((coargs->flags & COF_CHDR) && !(coargs->flags & COF_ADDR)) {
838 if (!(coargs->flags & COF_VERBOSE)) {
841 } else if (coargs->flags & COF_BYIDH) {
846 if (coargs->flags & COF_LONGLIST) {
853 coargs->flags &= ~COF_CHDR;
854 coargs->flags |= (COF_THDR | COF_LHDR);
857 if (!(coargs->flags & COF_ADDR)) {
858 if (!(coargs->flags & COF_VERBOSE)) {
862 (coargs->flags & COF_EXPREL) ?
863 coargs->exp - coargs->now : coargs->exp);
864 } else if (coargs->flags & COF_BYIDH) {
866 (coargs->flags & COF_EXPREL) ?
867 coargs->exp - coargs->now : coargs->exp);
869 list_flags = coargs->list_flags;
876 if (coargs->flags & COF_LONGLIST) {
896 callout_data_t *coargs = (callout_data_t *)priv;
901 if ((coargs == NULL) || (cl == NULL)) {
905 coargs->exp = cl->cl_expiration;
906 coargs->list_flags = cl->cl_flags;
907 if ((coargs->flags & COF_FREE) &&
915 if (!(coargs->flags & COF_FREE) &&
923 if ((coargs->flags & COF_TIME) &&
924 (cl->cl_expiration != coargs->time)) {
927 if ((coargs->flags & COF_BEFORE) &&
928 (cl->cl_expiration > coargs->btime)) {
931 if ((coargs->flags & COF_AFTER) &&
932 (cl->cl_expiration < coargs->atime)) {
935 if (!(coargs->flags & COF_EMPTY) &&
940 if ((coargs->flags & COF_HIRES) && (coargs->flags & COF_ABS)) {
946 if ((coargs->flags & COF_HIRES) &&
950 if ((coargs->flags & COF_ABS) &&
956 if ((coargs->flags & COF_HEAP) &&
957 !(coargs->list_flags & CALLOUT_LIST_FLAG_HEAPED)) {
961 if ((coargs->flags & COF_QUEUE) &&
962 !(coargs->list_flags & CALLOUT_LIST_FLAG_QUEUED)) {
966 if ((coargs->flags & COF_LHDR) && !(coargs->flags & COF_ADDR) &&
967 (coargs->flags & (COF_LIST | COF_VERBOSE))) {
968 if (!(coargs->flags & COF_VERBOSE)) {
975 if (coargs->flags & COF_LONGLIST) {
980 coargs->flags &= ~COF_LHDR;
981 coargs->flags |= (COF_THDR | COF_CHDR);
983 if (coargs->flags & (COF_LIST | COF_VERBOSE)) {
984 if (!(coargs->flags & COF_ADDR)) {
985 if (!(coargs->flags & COF_VERBOSE)) {
987 TABLE_TO_SEQID(coargs->ndx),
988 co_typenames[coargs->ndx &
992 list_flags = coargs->list_flags;
994 (coargs->flags & COF_EXPREL) ?
995 coargs->exp - coargs->now : coargs->exp,
1000 coargs->bucket, cl->cl_callouts.ch_head);
1002 if (coargs->flags & COF_LONGLIST) {
1011 if (coargs->flags & COF_LIST) {
1020 if (coargs->flags & COF_FREE) {
1025 if (coargs->flags & COF_VERBOSE) {
1033 if (mdb_pwalk("callouts_bytime", callouts_cb, coargs,
1038 if (coargs->flags & COF_VERBOSE) {
1049 callout_data_t *coargs = (callout_data_t *)priv;
1057 if ((coargs == NULL) || (ct == NULL) || (coargs->co_table == NULL)) {
1061 index = ((char *)addr - (char *)coargs->co_table) /
1066 if ((coargs->flags & COF_SEQID) && (coargs->seqid != seqid)) {
1070 if (!(coargs->flags & COF_REAL) && (cotype == CALLOUT_REALTIME)) {
1074 if (!(coargs->flags & COF_NORM) && (cotype == CALLOUT_NORMAL)) {
1078 if (!(coargs->flags & COF_EMPTY) && (
1083 if ((coargs->flags & COF_THDR) && !(coargs->flags & COF_ADDR) &&
1084 (coargs->flags & (COF_TABLE | COF_VERBOSE))) {
1088 coargs->flags &= ~COF_THDR;
1089 coargs->flags |= (COF_LHDR | COF_CHDR);
1090 if (coargs->flags & COF_LONGLIST) {
1099 if (coargs->flags & (COF_TABLE | COF_VERBOSE)) {
1100 if (!(coargs->flags & COF_ADDR)) {
1105 if (coargs->flags & COF_LONGLIST) {
1122 if (coargs->flags & COF_TABLE) {
1127 coargs->ndx = index;
1128 if (coargs->flags & COF_VERBOSE) {
1132 if (!(coargs->flags & COF_BYIDH)) {
1134 if (coargs->flags & COF_FREE) {
1136 coargs->bucket = 0;
1140 if (mdb_pwalk("callout_list", callout_list_cb, coargs,
1150 coargs->bucket = -1;
1152 coargs, (uintptr_t)clptr) == -1) {
1161 coargs->bucket = -1;
1163 coargs, (uintptr_t)clptr) == -1) {
1179 coargs->bucket = i;
1182 coargs, (uintptr_t)clptr) == -1) {
1191 if (coargs->flags & COF_FREE) {
1193 coargs->bucket = 0;
1197 if (mdb_pwalk("callouts_byid", callouts_cb, coargs,
1213 coargs->bucket = i;
1221 coargs, (uintptr_t)coptr) == -1) {
1229 if (coargs->flags & COF_VERBOSE) {
1239 callout_common_init(callout_data_t *coargs)
1242 if (mdb_readvar(&(coargs->co_table), "callout_table") == -1) {
1247 if (mdb_readsym(&(coargs->now), sizeof (hrtime_t), "hrtime_last") !=
1249 if (mdb_readsym(&(coargs->now), sizeof (hrtime_t),
1256 if (mdb_readvar(&(coargs->ctbits), "callout_table_bits") == -1) {
1260 if (mdb_readvar(&(coargs->nsec_per_tick), "nsec_per_tick") == -1) {
1276 callout_data_t coargs;
1284 coargs.flags = COF_DEFAULT;
1286 coargs.seqid = -1;
1289 'r', MDB_OPT_CLRBITS, COF_NORM, &coargs.flags,
1290 'n', MDB_OPT_CLRBITS, COF_REAL, &coargs.flags,
1291 'l', MDB_OPT_CLRBITS, COF_SHORT, &coargs.flags,
1292 's', MDB_OPT_CLRBITS, COF_LONG, &coargs.flags,
1293 'x', MDB_OPT_SETBITS, COF_EXEC, &coargs.flags,
1294 'h', MDB_OPT_SETBITS, COF_HIRES, &coargs.flags,
1295 'B', MDB_OPT_SETBITS, COF_ABS, &coargs.flags,
1296 'E', MDB_OPT_SETBITS, COF_EMPTY, &coargs.flags,
1300 't', MDB_OPT_UINTPTR_SET, &tflag, (uintptr_t *)&coargs.time,
1301 'a', MDB_OPT_UINTPTR_SET, &aflag, (uintptr_t *)&coargs.atime,
1302 'b', MDB_OPT_UINTPTR_SET, &bflag, (uintptr_t *)&coargs.btime,
1306 'T', MDB_OPT_SETBITS, COF_TABLE, &coargs.flags,
1307 'D', MDB_OPT_SETBITS, COF_EXPREL, &coargs.flags,
1308 'L', MDB_OPT_SETBITS, COF_LIST, &coargs.flags,
1309 'V', MDB_OPT_SETBITS, COF_VERBOSE, &coargs.flags,
1310 'v', MDB_OPT_SETBITS, COF_LONGLIST, &coargs.flags,
1311 'i', MDB_OPT_SETBITS, COF_BYIDH, &coargs.flags,
1312 'F', MDB_OPT_SETBITS, COF_FREE, &coargs.flags,
1313 'H', MDB_OPT_SETBITS, COF_HEAP, &coargs.flags,
1314 'Q', MDB_OPT_SETBITS, COF_QUEUE, &coargs.flags,
1315 'A', MDB_OPT_SETBITS, COF_ADDR, &coargs.flags,
1321 if ((retval = callout_common_init(&coargs)) != DCMD_OK) {
1327 coargs.time *= coargs.nsec_per_tick;
1328 coargs.atime *= coargs.nsec_per_tick;
1329 coargs.btime *= coargs.nsec_per_tick;
1333 coargs.time += coargs.now;
1334 coargs.atime += coargs.now;
1335 coargs.btime += coargs.now;
1343 coargs.flags |= COF_SEQID;
1344 coargs.seqid = (int)Stmp;
1352 if (coargs.flags & COF_SEQID) {
1356 coargs.cpu = (cpu_t *)Ctmp;
1357 if (mdb_vread(&coargs.seqid, sizeof (processorid_t),
1358 (uintptr_t)&(coargs.cpu->cpu_seqid)) == -1) {
1362 coargs.flags |= COF_SEQID;
1365 if (!(coargs.flags & (COF_REAL | COF_NORM))) {
1366 coargs.flags |= COF_REAL | COF_NORM;
1368 if (!(coargs.flags & (COF_LONG | COF_SHORT))) {
1369 coargs.flags |= COF_LONG | COF_SHORT;
1376 coargs.flags |= COF_TIME;
1379 coargs.flags |= COF_AFTER;
1382 coargs.flags |= COF_BEFORE;
1384 if ((aflag && bflag) && (coargs.btime <= coargs.atime)) {
1390 if ((coargs.flags & COF_HEAP) && (coargs.flags & COF_QUEUE)) {
1399 coargs.funcaddr = mdb_strtoull(funcname);
1401 coargs.funcaddr = sym.st_value;
1403 coargs.flags |= COF_FUNC;
1410 coargs.param = mdb_strtoull(paramstr);
1412 coargs.param = sym.st_value;
1414 coargs.flags |= COF_PARAM;
1426 coargs.flags |= (COF_REAL | COF_NORM);
1429 if (DCMD_HDRSPEC(flags) || (coargs.flags & COF_VERBOSE)) {
1430 coargs.flags |= COF_THDR | COF_LHDR | COF_CHDR;
1432 if (coargs.flags & COF_FREE) {
1433 coargs.flags |= COF_EMPTY;
1435 if (!(coargs.flags & COF_LIST)) {
1436 coargs.flags |= COF_BYIDH;
1441 if (mdb_pwalk("callout_table", callout_t_cb, &coargs, addr) == -1) {
1456 callout_data_t coargs;
1469 coargs.flags = COF_DEFAULT | COF_BYIDH;
1471 'd', MDB_OPT_SETBITS, COF_DECODE, &coargs.flags,
1472 'v', MDB_OPT_SETBITS, COF_LONGLIST, &coargs.flags,
1489 coargs.flags |= COF_CHDR;
1494 if ((retval = callout_common_init(&coargs)) != DCMD_OK) {
1499 #define callout_table_mask ((1 << coargs.ctbits) - 1)
1500 #define callout_table_bits coargs.ctbits
1501 #define nsec_per_tick coargs.nsec_per_tick
1514 if (coargs.flags & COF_DECODE) {
1529 ctptr = coargs.co_table + tableid;
1555 coargs.ndx = tableid;
1556 coargs.bucket = idhash;
1559 if (mdb_pwalk("callouts_byid", callouts_cb, &coargs,