|
@@ -382,13 +382,11 @@ repeat:
|
|
read_unlock(&journal->j_state_lock);
|
|
read_unlock(&journal->j_state_lock);
|
|
current->journal_info = handle;
|
|
current->journal_info = handle;
|
|
|
|
|
|
- lock_map_acquire(&handle->h_lockdep_map);
|
|
|
|
|
|
+ rwsem_acquire_read(&journal->j_trans_commit_map, 0, 0, _THIS_IP_);
|
|
jbd2_journal_free_transaction(new_transaction);
|
|
jbd2_journal_free_transaction(new_transaction);
|
|
return 0;
|
|
return 0;
|
|
}
|
|
}
|
|
|
|
|
|
-static struct lock_class_key jbd2_handle_key;
|
|
|
|
-
|
|
|
|
/* Allocate a new handle. This should probably be in a slab... */
|
|
/* Allocate a new handle. This should probably be in a slab... */
|
|
static handle_t *new_handle(int nblocks)
|
|
static handle_t *new_handle(int nblocks)
|
|
{
|
|
{
|
|
@@ -398,9 +396,6 @@ static handle_t *new_handle(int nblocks)
|
|
handle->h_buffer_credits = nblocks;
|
|
handle->h_buffer_credits = nblocks;
|
|
handle->h_ref = 1;
|
|
handle->h_ref = 1;
|
|
|
|
|
|
- lockdep_init_map(&handle->h_lockdep_map, "jbd2_handle",
|
|
|
|
- &jbd2_handle_key, 0);
|
|
|
|
-
|
|
|
|
return handle;
|
|
return handle;
|
|
}
|
|
}
|
|
|
|
|
|
@@ -672,7 +667,7 @@ int jbd2__journal_restart(handle_t *handle, int nblocks, gfp_t gfp_mask)
|
|
if (need_to_start)
|
|
if (need_to_start)
|
|
jbd2_log_start_commit(journal, tid);
|
|
jbd2_log_start_commit(journal, tid);
|
|
|
|
|
|
- lock_map_release(&handle->h_lockdep_map);
|
|
|
|
|
|
+ rwsem_release(&journal->j_trans_commit_map, 1, _THIS_IP_);
|
|
handle->h_buffer_credits = nblocks;
|
|
handle->h_buffer_credits = nblocks;
|
|
ret = start_this_handle(journal, handle, gfp_mask);
|
|
ret = start_this_handle(journal, handle, gfp_mask);
|
|
return ret;
|
|
return ret;
|
|
@@ -1750,7 +1745,7 @@ int jbd2_journal_stop(handle_t *handle)
|
|
wake_up(&journal->j_wait_transaction_locked);
|
|
wake_up(&journal->j_wait_transaction_locked);
|
|
}
|
|
}
|
|
|
|
|
|
- lock_map_release(&handle->h_lockdep_map);
|
|
|
|
|
|
+ rwsem_release(&journal->j_trans_commit_map, 1, _THIS_IP_);
|
|
|
|
|
|
if (wait_for_commit)
|
|
if (wait_for_commit)
|
|
err = jbd2_log_wait_commit(journal, tid);
|
|
err = jbd2_log_wait_commit(journal, tid);
|