Lines Matching refs:tf

312 nfslog_close_trans_file(struct nfslog_trans_file *tf)  in nfslog_close_trans_file()  argument
314 assert(tf != NULL); in nfslog_close_trans_file()
315 assert(tf->refcnt > 0); in nfslog_close_trans_file()
316 if (tf->refcnt > 1) { in nfslog_close_trans_file()
317 (tf->refcnt)--; in nfslog_close_trans_file()
321 if (tf->fp != NULL) { in nfslog_close_trans_file()
322 (void) fsync(fileno(tf->fp)); in nfslog_close_trans_file()
323 (void) fclose(tf->fp); in nfslog_close_trans_file()
329 tf->prev->next = tf->next; in nfslog_close_trans_file()
330 if (tf->next != NULL) in nfslog_close_trans_file()
331 tf->next->prev = tf->prev; in nfslog_close_trans_file()
336 if (tf == trans_file_head) in nfslog_close_trans_file()
337 trans_file_head = tf->next; in nfslog_close_trans_file()
339 nfslog_trans_file_free(tf); in nfslog_close_trans_file()
464 struct nfslog_trans_file *tf, in nfslog_process_trans_timeout() argument
475 if (difftime(cur_time, tf->last_trans_read) > in nfslog_process_trans_timeout()
480 for (pte = tf->te_list_v3_read->next; in nfslog_process_trans_timeout()
481 pte != tf->te_list_v3_read; in nfslog_process_trans_timeout()
484 (difftime(tf->lasttrans_timestamp.tv_sec, in nfslog_process_trans_timeout()
487 nfslog_print_trans_logentry(pte, tf); in nfslog_process_trans_timeout()
493 for (pte = tf->te_list_v3_write->next; in nfslog_process_trans_timeout()
494 pte != tf->te_list_v3_write; in nfslog_process_trans_timeout()
497 (difftime(tf->lasttrans_timestamp.tv_sec, in nfslog_process_trans_timeout()
500 nfslog_print_trans_logentry(pte, tf); in nfslog_process_trans_timeout()
506 for (pte = tf->te_list_v2_read->next; in nfslog_process_trans_timeout()
507 pte != tf->te_list_v2_read; in nfslog_process_trans_timeout()
510 (difftime(tf->lasttrans_timestamp.tv_sec, in nfslog_process_trans_timeout()
513 nfslog_print_trans_logentry(pte, tf); in nfslog_process_trans_timeout()
519 for (pte = tf->te_list_v2_write->next; in nfslog_process_trans_timeout()
520 pte != tf->te_list_v2_write; in nfslog_process_trans_timeout()
523 (difftime(tf->lasttrans_timestamp.tv_sec, in nfslog_process_trans_timeout()
526 nfslog_print_trans_logentry(pte, tf); in nfslog_process_trans_timeout()
532 (void) fflush(tf->fp); in nfslog_process_trans_timeout()
552 struct nfslog_trans_file *tf, in trans_read() argument
595 if (pte = insert_te(tf->te_list_v2_read, newte)) { in trans_read()
622 struct nfslog_trans_file *tf, in trans_write() argument
662 if (pte = insert_te(tf->te_list_v2_write, newte)) { in trans_write()
670 nfslog_print_trans_logentry(pte, tf); in trans_write()
672 (void) insert_te(tf->te_list_v2_write, newte); in trans_write()
694 struct nfslog_trans_file *tf, in trans_setattr() argument
744 if (pte = insert_te(tf->te_list_v2_write, newte)) { in trans_setattr()
745 nfslog_print_trans_logentry(pte, tf); in trans_setattr()
748 if (pte = insert_te(tf->te_list_v2_read, newte)) { in trans_setattr()
749 nfslog_print_trans_logentry(pte, tf); in trans_setattr()
759 struct nfslog_trans_file *tf, in trans_create() argument
812 if (pte = insert_te(tf->te_list_v2_write, newte)) { in trans_create()
813 nfslog_print_trans_logentry(pte, tf); in trans_create()
816 if (pte = insert_te(tf->te_list_v2_read, newte)) { in trans_create()
817 nfslog_print_trans_logentry(pte, tf); in trans_create()
828 struct nfslog_trans_file *tf, in trans_remove() argument
870 if (pte = insert_te(tf->te_list_v2_write, newte)) { in trans_remove()
871 nfslog_print_trans_logentry(pte, tf); in trans_remove()
874 if (pte = insert_te(tf->te_list_v2_read, newte)) { in trans_remove()
875 nfslog_print_trans_logentry(pte, tf); in trans_remove()
878 if (pte = insert_te(tf->te_list_v3_write, newte)) { in trans_remove()
879 nfslog_print_trans_logentry(pte, tf); in trans_remove()
882 if (pte = insert_te(tf->te_list_v3_read, newte)) { in trans_remove()
883 nfslog_print_trans_logentry(pte, tf); in trans_remove()
986 struct nfslog_trans_file *tf, in trans_rename() argument
1039 if (pte = insert_te(tf->te_list_v2_write, newte)) { in trans_rename()
1043 if (pte = insert_te(tf->te_list_v2_read, newte)) { in trans_rename()
1047 if (pte = insert_te(tf->te_list_v3_write, newte)) { in trans_rename()
1051 if (pte = insert_te(tf->te_list_v3_read, newte)) { in trans_rename()
1184 struct nfslog_trans_file *tf, in trans_read3() argument
1228 if (pte = insert_te(tf->te_list_v3_read, newte)) { in trans_read3()
1254 struct nfslog_trans_file *tf, in trans_write3() argument
1295 if (pte = insert_te(tf->te_list_v3_write, newte)) { in trans_write3()
1303 nfslog_print_trans_logentry(pte, tf); in trans_write3()
1305 (void) insert_te(tf->te_list_v3_write, newte); in trans_write3()
1327 struct nfslog_trans_file *tf, in trans_setattr3() argument
1378 if (pte = insert_te(tf->te_list_v3_write, newte)) { in trans_setattr3()
1379 nfslog_print_trans_logentry(pte, tf); in trans_setattr3()
1382 if (pte = insert_te(tf->te_list_v3_read, newte)) { in trans_setattr3()
1383 nfslog_print_trans_logentry(pte, tf); in trans_setattr3()
1393 struct nfslog_trans_file *tf, in trans_create3() argument
1442 if (pte = insert_te(tf->te_list_v3_write, newte)) { in trans_create3()
1443 nfslog_print_trans_logentry(pte, tf); in trans_create3()
1446 if (pte = insert_te(tf->te_list_v3_read, newte)) { in trans_create3()
1447 nfslog_print_trans_logentry(pte, tf); in trans_create3()
1458 struct nfslog_trans_file *tf, in trans_remove3() argument
1500 if (pte = insert_te(tf->te_list_v3_write, newte)) { in trans_remove3()
1501 nfslog_print_trans_logentry(pte, tf); in trans_remove3()
1504 if (pte = insert_te(tf->te_list_v3_read, newte)) { in trans_remove3()
1505 nfslog_print_trans_logentry(pte, tf); in trans_remove3()
1508 if (pte = insert_te(tf->te_list_v2_write, newte)) { in trans_remove3()
1509 nfslog_print_trans_logentry(pte, tf); in trans_remove3()
1512 if (pte = insert_te(tf->te_list_v2_read, newte)) { in trans_remove3()
1513 nfslog_print_trans_logentry(pte, tf); in trans_remove3()
1615 struct nfslog_trans_file *tf, in trans_rename3() argument
1662 if (pte = insert_te(tf->te_list_v3_write, newte)) { in trans_rename3()
1666 if (pte = insert_te(tf->te_list_v3_read, newte)) { in trans_rename3()
1670 if (pte = insert_te(tf->te_list_v2_write, newte)) { in trans_rename3()
1674 if (pte = insert_te(tf->te_list_v2_read, newte)) { in trans_rename3()
1859 struct nfslog_trans_file *tf = (struct nfslog_trans_file *)transcookie; in nfslog_process_trans_rec() local
1866 if (tf->lasttrans_timestamp.tv_sec < in nfslog_process_trans_rec()
1868 tf->lasttrans_timestamp = in nfslog_process_trans_rec()
1872 tf->last_trans_read = time(0); in nfslog_process_trans_rec()
1879 if (tf->trans_to_log & TRANSTOLOG_OPER_READ) in nfslog_process_trans_rec()
1880 pte = trans_read(logrec, tf, fhpath, path1); in nfslog_process_trans_rec()
1883 if (tf->trans_to_log & TRANSTOLOG_OPER_WRITE) in nfslog_process_trans_rec()
1884 pte = trans_write(logrec, tf, fhpath, path1); in nfslog_process_trans_rec()
1887 if (tf->trans_to_log & TRANSTOLOG_OPER_SETATTR) in nfslog_process_trans_rec()
1888 pte = trans_setattr(logrec, tf, in nfslog_process_trans_rec()
1892 if (tf->trans_to_log & TRANSTOLOG_OPER_REMOVE) in nfslog_process_trans_rec()
1893 pte = trans_remove(logrec, tf, fhpath, path1); in nfslog_process_trans_rec()
1896 if (tf->trans_to_log & TRANSTOLOG_OPER_MKDIR) in nfslog_process_trans_rec()
1900 if (tf->trans_to_log & TRANSTOLOG_OPER_RMDIR) in nfslog_process_trans_rec()
1904 if (tf->trans_to_log & TRANSTOLOG_OPER_CREATE) in nfslog_process_trans_rec()
1905 pte = trans_create(logrec, tf, fhpath, path1); in nfslog_process_trans_rec()
1908 if (tf->trans_to_log & TRANSTOLOG_OPER_RENAME) in nfslog_process_trans_rec()
1909 pte = trans_rename(logrec, tf, in nfslog_process_trans_rec()
1913 if (tf->trans_to_log & TRANSTOLOG_OPER_LINK) in nfslog_process_trans_rec()
1917 if (tf->trans_to_log & TRANSTOLOG_OPER_SYMLINK) in nfslog_process_trans_rec()
1927 if (tf->trans_to_log & TRANSTOLOG_OPER_READ) in nfslog_process_trans_rec()
1928 pte = trans_read3(logrec, tf, fhpath, path1); in nfslog_process_trans_rec()
1931 if (tf->trans_to_log & TRANSTOLOG_OPER_WRITE) in nfslog_process_trans_rec()
1932 pte = trans_write3(logrec, tf, fhpath, path1); in nfslog_process_trans_rec()
1935 if (tf->trans_to_log & TRANSTOLOG_OPER_SETATTR) in nfslog_process_trans_rec()
1936 pte = trans_setattr3(logrec, tf, in nfslog_process_trans_rec()
1940 if (tf->trans_to_log & TRANSTOLOG_OPER_REMOVE) in nfslog_process_trans_rec()
1941 pte = trans_remove3(logrec, tf, in nfslog_process_trans_rec()
1945 if (tf->trans_to_log & TRANSTOLOG_OPER_MKDIR) in nfslog_process_trans_rec()
1949 if (tf->trans_to_log & TRANSTOLOG_OPER_RMDIR) in nfslog_process_trans_rec()
1953 if (tf->trans_to_log & TRANSTOLOG_OPER_CREATE) in nfslog_process_trans_rec()
1954 pte = trans_create3(logrec, tf, in nfslog_process_trans_rec()
1958 if (tf->trans_to_log & TRANSTOLOG_OPER_RENAME) in nfslog_process_trans_rec()
1959 pte = trans_rename3(logrec, tf, in nfslog_process_trans_rec()
1963 if (tf->trans_to_log & TRANSTOLOG_OPER_MKNOD) in nfslog_process_trans_rec()
1967 if (tf->trans_to_log & TRANSTOLOG_OPER_LINK) in nfslog_process_trans_rec()
1972 if (tf->trans_to_log & TRANSTOLOG_OPER_SYMLINK) in nfslog_process_trans_rec()
1984 nfslog_print_trans_logentry(pte, tf); in nfslog_process_trans_rec()
1993 struct nfslog_trans_file *tf) in nfslog_print_trans_logentry() argument
2008 if (tf->trans_output_type == TRANSLOG_BASIC) { in nfslog_print_trans_logentry()
2018 optype = (tf->trans_output_type == TRANSLOG_EXTENDED ? in nfslog_print_trans_logentry()
2022 optype = (tf->trans_output_type == TRANSLOG_EXTENDED ? in nfslog_print_trans_logentry()
2026 optype = (tf->trans_output_type == TRANSLOG_EXTENDED ? in nfslog_print_trans_logentry()
2030 optype = (tf->trans_output_type == TRANSLOG_EXTENDED ? in nfslog_print_trans_logentry()
2034 optype = (tf->trans_output_type == TRANSLOG_EXTENDED ? in nfslog_print_trans_logentry()
2038 optype = (tf->trans_output_type == TRANSLOG_EXTENDED ? in nfslog_print_trans_logentry()
2042 optype = (tf->trans_output_type == TRANSLOG_EXTENDED ? in nfslog_print_trans_logentry()
2046 optype = (tf->trans_output_type == TRANSLOG_EXTENDED ? in nfslog_print_trans_logentry()
2050 optype = (tf->trans_output_type == TRANSLOG_EXTENDED ? in nfslog_print_trans_logentry()
2054 optype = (tf->trans_output_type == TRANSLOG_EXTENDED ? in nfslog_print_trans_logentry()
2058 optype = (tf->trans_output_type == TRANSLOG_EXTENDED ? in nfslog_print_trans_logentry()
2072 (void) fprintf(tf->fp, in nfslog_print_trans_logentry()