|
@@ -1172,7 +1172,7 @@ int journal_dirty_metadata(handle_t *handle, struct buffer_head *bh)
|
|
}
|
|
}
|
|
|
|
|
|
/* That test should have eliminated the following case: */
|
|
/* That test should have eliminated the following case: */
|
|
- J_ASSERT_JH(jh, jh->b_frozen_data == 0);
|
|
|
|
|
|
+ J_ASSERT_JH(jh, jh->b_frozen_data == NULL);
|
|
|
|
|
|
JBUFFER_TRACE(jh, "file as BJ_Metadata");
|
|
JBUFFER_TRACE(jh, "file as BJ_Metadata");
|
|
spin_lock(&journal->j_list_lock);
|
|
spin_lock(&journal->j_list_lock);
|
|
@@ -1522,7 +1522,7 @@ static void __journal_temp_unlink_buffer(struct journal_head *jh)
|
|
|
|
|
|
J_ASSERT_JH(jh, jh->b_jlist < BJ_Types);
|
|
J_ASSERT_JH(jh, jh->b_jlist < BJ_Types);
|
|
if (jh->b_jlist != BJ_None)
|
|
if (jh->b_jlist != BJ_None)
|
|
- J_ASSERT_JH(jh, transaction != 0);
|
|
|
|
|
|
+ J_ASSERT_JH(jh, transaction != NULL);
|
|
|
|
|
|
switch (jh->b_jlist) {
|
|
switch (jh->b_jlist) {
|
|
case BJ_None:
|
|
case BJ_None:
|
|
@@ -1591,11 +1591,11 @@ __journal_try_to_free_buffer(journal_t *journal, struct buffer_head *bh)
|
|
if (buffer_locked(bh) || buffer_dirty(bh))
|
|
if (buffer_locked(bh) || buffer_dirty(bh))
|
|
goto out;
|
|
goto out;
|
|
|
|
|
|
- if (jh->b_next_transaction != 0)
|
|
|
|
|
|
+ if (jh->b_next_transaction != NULL)
|
|
goto out;
|
|
goto out;
|
|
|
|
|
|
spin_lock(&journal->j_list_lock);
|
|
spin_lock(&journal->j_list_lock);
|
|
- if (jh->b_transaction != 0 && jh->b_cp_transaction == 0) {
|
|
|
|
|
|
+ if (jh->b_transaction != NULL && jh->b_cp_transaction == NULL) {
|
|
if (jh->b_jlist == BJ_SyncData || jh->b_jlist == BJ_Locked) {
|
|
if (jh->b_jlist == BJ_SyncData || jh->b_jlist == BJ_Locked) {
|
|
/* A written-back ordered data buffer */
|
|
/* A written-back ordered data buffer */
|
|
JBUFFER_TRACE(jh, "release data");
|
|
JBUFFER_TRACE(jh, "release data");
|
|
@@ -1603,7 +1603,7 @@ __journal_try_to_free_buffer(journal_t *journal, struct buffer_head *bh)
|
|
journal_remove_journal_head(bh);
|
|
journal_remove_journal_head(bh);
|
|
__brelse(bh);
|
|
__brelse(bh);
|
|
}
|
|
}
|
|
- } else if (jh->b_cp_transaction != 0 && jh->b_transaction == 0) {
|
|
|
|
|
|
+ } else if (jh->b_cp_transaction != NULL && jh->b_transaction == NULL) {
|
|
/* written-back checkpointed metadata buffer */
|
|
/* written-back checkpointed metadata buffer */
|
|
if (jh->b_jlist == BJ_None) {
|
|
if (jh->b_jlist == BJ_None) {
|
|
JBUFFER_TRACE(jh, "remove from checkpoint list");
|
|
JBUFFER_TRACE(jh, "remove from checkpoint list");
|
|
@@ -1963,7 +1963,7 @@ void __journal_file_buffer(struct journal_head *jh,
|
|
|
|
|
|
J_ASSERT_JH(jh, jh->b_jlist < BJ_Types);
|
|
J_ASSERT_JH(jh, jh->b_jlist < BJ_Types);
|
|
J_ASSERT_JH(jh, jh->b_transaction == transaction ||
|
|
J_ASSERT_JH(jh, jh->b_transaction == transaction ||
|
|
- jh->b_transaction == 0);
|
|
|
|
|
|
+ jh->b_transaction == NULL);
|
|
|
|
|
|
if (jh->b_transaction && jh->b_jlist == jlist)
|
|
if (jh->b_transaction && jh->b_jlist == jlist)
|
|
return;
|
|
return;
|