@@ -2134,21 +2134,21 @@
* case it is in the committing transaction so that we stand to ordered
* mode consistency guarantees.
*/
-int jbd2_journal_begin_ordered_truncate(struct jbd2_inode *inode,
+int jbd2_journal_begin_ordered_truncate(struct jbd2_inode *jinode,
loff_t new_size)
{
journal_t *journal;
transaction_t *commit_trans;
int ret = 0;
- if (!inode->i_transaction && !inode->i_next_transaction)
+ if (!jinode->i_transaction || !jinode->i_next_transaction)
goto out;
- journal = inode->i_transaction->t_journal;
+ journal = jinode->i_transaction->t_journal;
spin_lock(&journal->j_state_lock);
commit_trans = journal->j_committing_transaction;
spin_unlock(&journal->j_state_lock);
- if (inode->i_transaction == commit_trans) {
- ret = filemap_fdatawrite_range(inode->i_vfs_inode->i_mapping,
+ if (jinode->i_transaction == commit_trans) {
+ ret = filemap_fdatawrite_range(jinode->i_vfs_inode->i_mapping,
new_size, LLONG_MAX);
if (ret)
jbd2_journal_abort(journal, ret);