Lines Matching full:transaction
163 transaction_t *transaction; in kjournald2() local
180 * transaction commit and any fs involvement might get stuck waiting for in kjournald2()
226 transaction = journal->j_running_transaction; in kjournald2()
227 if (transaction == NULL || in kjournald2()
228 time_before(jiffies, transaction->t_expires)) { in kjournald2()
241 transaction = journal->j_running_transaction; in kjournald2()
242 if (transaction && time_after_eq(jiffies, transaction->t_expires)) { in kjournald2()
243 journal->j_commit_request = transaction->t_tid; in kjournald2()
311 * If the source buffer has already been modified by a new transaction
325 int jbd2_journal_write_metadata_buffer(transaction_t *transaction, in jbd2_journal_write_metadata_buffer() argument
335 journal_t *journal = transaction->t_journal; in jbd2_journal_write_metadata_buffer()
339 * transaction is allowed to write it, so nobody else is allowed in jbd2_journal_write_metadata_buffer()
355 * If a new transaction has already done a buffer copy-out, then in jbd2_journal_write_metadata_buffer()
424 * copying is moved to the transaction's shadow queue. in jbd2_journal_write_metadata_buffer()
428 __jbd2_journal_file_buffer(jh_in, transaction, BJ_Shadow); in jbd2_journal_write_metadata_buffer()
443 * Returns true if a transaction commit was started.
452 * The only transaction we can possibly wait upon is the in __jbd2_log_start_commit()
453 * currently running transaction (if it exists). Otherwise, in __jbd2_log_start_commit()
494 * transaction if we don't have an active handle, otherwise, we will deadlock.
497 * 1 if transaction was successfully committed.
501 transaction_t *transaction = NULL; in __jbd2_journal_force_commit() local
507 transaction = journal->j_running_transaction; in __jbd2_journal_force_commit()
508 if (!tid_geq(journal->j_commit_request, transaction->t_tid)) in __jbd2_journal_force_commit()
511 transaction = journal->j_committing_transaction; in __jbd2_journal_force_commit()
513 if (!transaction) { in __jbd2_journal_force_commit()
518 tid = transaction->t_tid; in __jbd2_journal_force_commit()
531 * calling process is not within transaction.
551 * Caller want unconditional commit. We can only force the running transaction
566 * Start a commit of the current running transaction (if any). Returns true
567 * if a transaction is going to be committed (or is currently already
579 /* There's a running transaction and we've just made sure in jbd2_journal_start_commit()
587 * completion of that transaction. in jbd2_journal_start_commit()
598 * Return 1 if a given transaction has not yet sent barrier request
599 * connected with a transaction commit. If 0 is returned, transaction
611 /* Transaction already committed? */ in jbd2_trans_will_send_data_barrier()
618 * The query transaction hasn't started committing, in jbd2_trans_will_send_data_barrier()
630 * Transaction is being committed and we already proceeded to in jbd2_trans_will_send_data_barrier()
659 * Some callers make sure transaction is already committing and in that in jbd2_log_wait_commit()
775 /* Return 1 when transaction with given tid has already committed. */
783 * When this function returns the transaction corresponding to tid
784 * will be completed. If the transaction has currently running, start
785 * committing that transaction before waiting for it to complete. If
786 * the transaction id is stale, it is by definition already completed,
797 /* transaction not yet started, so request it */ in jbd2_complete_transaction()
965 jbd2_journal_get_descriptor_buffer(transaction_t *transaction, int type) in jbd2_journal_get_descriptor_buffer() argument
967 journal_t *journal = transaction->t_journal; in jbd2_journal_get_descriptor_buffer()
981 atomic_dec(&transaction->t_outstanding_credits); in jbd2_journal_get_descriptor_buffer()
987 header->h_sequence = cpu_to_be32(transaction->t_tid); in jbd2_journal_get_descriptor_buffer()
1010 * Return tid of the oldest transaction in the journal and block in the journal
1011 * where the transaction starts.
1013 * If the journal is now empty, return which will be the next transaction ID
1014 * we will write and where will that transaction start.
1022 transaction_t *transaction; in jbd2_journal_get_log_tail() local
1027 transaction = journal->j_checkpoint_transactions; in jbd2_journal_get_log_tail()
1028 if (transaction) { in jbd2_journal_get_log_tail()
1029 *tid = transaction->t_tid; in jbd2_journal_get_log_tail()
1030 *block = transaction->t_log_start; in jbd2_journal_get_log_tail()
1031 } else if ((transaction = journal->j_committing_transaction) != NULL) { in jbd2_journal_get_log_tail()
1032 *tid = transaction->t_tid; in jbd2_journal_get_log_tail()
1033 *block = transaction->t_log_start; in jbd2_journal_get_log_tail()
1034 } else if ((transaction = journal->j_running_transaction) != NULL) { in jbd2_journal_get_log_tail()
1035 *tid = transaction->t_tid; in jbd2_journal_get_log_tail()
1067 * soon as we update j_tail, next transaction can start reusing journal in __jbd2_update_log_tail()
1069 * old transaction with possibly newly overwritten data. in __jbd2_update_log_tail()
1138 seq_printf(seq, "average: \n %ums waiting for transaction\n", in jbd2_seq_info_show()
1144 seq_printf(seq, " %ums running transaction\n", in jbd2_seq_info_show()
1146 seq_printf(seq, " %ums transaction was being locked\n", in jbd2_seq_info_show()
1150 seq_printf(seq, " %ums logging transaction\n", in jbd2_seq_info_show()
1152 seq_printf(seq, " %lluus average transaction commit time\n", in jbd2_seq_info_show()
1154 seq_printf(seq, " %lu handles per transaction\n", in jbd2_seq_info_show()
1156 seq_printf(seq, " %lu blocks per transaction\n", in jbd2_seq_info_show()
1158 seq_printf(seq, " %lu logged blocks per transaction\n", in jbd2_seq_info_show()
1420 * Base amount of descriptor blocks we reserve for each transaction.
1435 * space for commit block and normal transaction descriptor blocks. in jbd2_descriptor_blocks_per_trans()
1442 * Initialize number of blocks each transaction reserves for its bookkeeping
1443 * and maximum number of blocks a transaction can use. This needs to be called
1497 /* After journal features are set, we can compute transaction limits */ in journal_load_superblock()
1770 * transaction will start reusing journal space and so we in journal_reset()
1847 * @tail_tid: TID of the new transaction at the tail of the log
1848 * @tail_block: The first block of the transaction at the tail of the log
2086 printk(KERN_ERR "JBD2: journal transaction %u on %s " in jbd2_journal_load()
2407 transaction_t *transaction = NULL; in jbd2_journal_flush() local
2413 transaction = journal->j_running_transaction; in jbd2_journal_flush()
2414 __jbd2_log_start_commit(journal, transaction->t_tid); in jbd2_journal_flush()
2416 transaction = journal->j_committing_transaction; in jbd2_journal_flush()
2419 if (transaction) { in jbd2_journal_flush()
2420 tid_t tid = transaction->t_tid; in jbd2_journal_flush()
2517 * journal (not of a single transaction). This operation cannot be
2527 * immediately and no further transaction commits will be honoured.
2534 * Any attempt to get a new transaction handle on a journal which is in
2545 * transaction without having to complete the transaction to record the
2553 transaction_t *transaction; in jbd2_journal_abort() local
2581 * Mark the abort as occurred and start current running transaction in jbd2_journal_abort()
2588 transaction = journal->j_running_transaction; in jbd2_journal_abort()
2589 if (transaction) in jbd2_journal_abort()
2590 __jbd2_log_start_commit(journal, transaction->t_tid); in jbd2_journal_abort()
2862 * b_jcount reaches zero. Running transaction (b_transaction) and checkpoint
2863 * transaction (b_cp_transaction) hold their references to b_jcount.
2866 * _before_ attaching the journal_head to a transaction. To protect the
2876 * (Get another reference for transaction)
3013 * transaction's lists.