reiserfs: Use lowercase names of quota functions

Use lowercase names of quota functions instead of old uppercase ones.

Signed-off-by: Jan Kara <jack@suse.cz>
CC: reiserfs-devel@vger.kernel.org
This commit is contained in:
Jan Kara 2009-01-26 17:14:18 +01:00
parent a269eb1829
commit 77db4f25bc
5 changed files with 24 additions and 22 deletions

View File

@ -430,7 +430,7 @@ static void _reiserfs_free_block(struct reiserfs_transaction_handle *th,
journal_mark_dirty(th, s, sbh); journal_mark_dirty(th, s, sbh);
if (for_unformatted) if (for_unformatted)
DQUOT_FREE_BLOCK_NODIRTY(inode, 1); vfs_dq_free_block_nodirty(inode, 1);
} }
void reiserfs_free_block(struct reiserfs_transaction_handle *th, void reiserfs_free_block(struct reiserfs_transaction_handle *th,
@ -1055,7 +1055,7 @@ static inline int blocknrs_and_prealloc_arrays_from_search_start
amount_needed, hint->inode->i_uid); amount_needed, hint->inode->i_uid);
#endif #endif
quota_ret = quota_ret =
DQUOT_ALLOC_BLOCK_NODIRTY(hint->inode, amount_needed); vfs_dq_alloc_block_nodirty(hint->inode, amount_needed);
if (quota_ret) /* Quota exceeded? */ if (quota_ret) /* Quota exceeded? */
return QUOTA_EXCEEDED; return QUOTA_EXCEEDED;
if (hint->preallocate && hint->prealloc_size) { if (hint->preallocate && hint->prealloc_size) {
@ -1064,8 +1064,7 @@ static inline int blocknrs_and_prealloc_arrays_from_search_start
"reiserquota: allocating (prealloc) %d blocks id=%u", "reiserquota: allocating (prealloc) %d blocks id=%u",
hint->prealloc_size, hint->inode->i_uid); hint->prealloc_size, hint->inode->i_uid);
#endif #endif
quota_ret = quota_ret = vfs_dq_prealloc_block_nodirty(hint->inode,
DQUOT_PREALLOC_BLOCK_NODIRTY(hint->inode,
hint->prealloc_size); hint->prealloc_size);
if (quota_ret) if (quota_ret)
hint->preallocate = hint->prealloc_size = 0; hint->preallocate = hint->prealloc_size = 0;
@ -1098,7 +1097,10 @@ static inline int blocknrs_and_prealloc_arrays_from_search_start
nr_allocated, nr_allocated,
hint->inode->i_uid); hint->inode->i_uid);
#endif #endif
DQUOT_FREE_BLOCK_NODIRTY(hint->inode, amount_needed + hint->prealloc_size - nr_allocated); /* Free not allocated blocks */ /* Free not allocated blocks */
vfs_dq_free_block_nodirty(hint->inode,
amount_needed + hint->prealloc_size -
nr_allocated);
} }
while (nr_allocated--) while (nr_allocated--)
reiserfs_free_block(hint->th, hint->inode, reiserfs_free_block(hint->th, hint->inode,
@ -1129,7 +1131,7 @@ static inline int blocknrs_and_prealloc_arrays_from_search_start
REISERFS_I(hint->inode)->i_prealloc_count, REISERFS_I(hint->inode)->i_prealloc_count,
hint->inode->i_uid); hint->inode->i_uid);
#endif #endif
DQUOT_FREE_BLOCK_NODIRTY(hint->inode, amount_needed + vfs_dq_free_block_nodirty(hint->inode, amount_needed +
hint->prealloc_size - nr_allocated - hint->prealloc_size - nr_allocated -
REISERFS_I(hint->inode)-> REISERFS_I(hint->inode)->
i_prealloc_count); i_prealloc_count);

View File

@ -53,7 +53,7 @@ void reiserfs_delete_inode(struct inode *inode)
* after delete_object so that quota updates go into the same transaction as * after delete_object so that quota updates go into the same transaction as
* stat data deletion */ * stat data deletion */
if (!err) if (!err)
DQUOT_FREE_INODE(inode); vfs_dq_free_inode(inode);
if (journal_end(&th, inode->i_sb, jbegin_count)) if (journal_end(&th, inode->i_sb, jbegin_count))
goto out; goto out;
@ -1763,7 +1763,7 @@ int reiserfs_new_inode(struct reiserfs_transaction_handle *th,
BUG_ON(!th->t_trans_id); BUG_ON(!th->t_trans_id);
if (DQUOT_ALLOC_INODE(inode)) { if (vfs_dq_alloc_inode(inode)) {
err = -EDQUOT; err = -EDQUOT;
goto out_end_trans; goto out_end_trans;
} }
@ -1947,12 +1947,12 @@ int reiserfs_new_inode(struct reiserfs_transaction_handle *th,
INODE_PKEY(inode)->k_objectid = 0; INODE_PKEY(inode)->k_objectid = 0;
/* Quota change must be inside a transaction for journaling */ /* Quota change must be inside a transaction for journaling */
DQUOT_FREE_INODE(inode); vfs_dq_free_inode(inode);
out_end_trans: out_end_trans:
journal_end(th, th->t_super, th->t_blocks_allocated); journal_end(th, th->t_super, th->t_blocks_allocated);
/* Drop can be outside and it needs more credits so it's better to have it outside */ /* Drop can be outside and it needs more credits so it's better to have it outside */
DQUOT_DROP(inode); vfs_dq_drop(inode);
inode->i_flags |= S_NOQUOTA; inode->i_flags |= S_NOQUOTA;
make_bad_inode(inode); make_bad_inode(inode);
@ -3119,7 +3119,7 @@ int reiserfs_setattr(struct dentry *dentry, struct iattr *attr)
if (error) if (error)
goto out; goto out;
error = error =
DQUOT_TRANSFER(inode, attr) ? -EDQUOT : 0; vfs_dq_transfer(inode, attr) ? -EDQUOT : 0;
if (error) { if (error) {
journal_end(&th, inode->i_sb, journal_end(&th, inode->i_sb,
jbegin_count); jbegin_count);

View File

@ -555,7 +555,7 @@ static int reiserfs_add_entry(struct reiserfs_transaction_handle *th,
*/ */
static int drop_new_inode(struct inode *inode) static int drop_new_inode(struct inode *inode)
{ {
DQUOT_DROP(inode); vfs_dq_drop(inode);
make_bad_inode(inode); make_bad_inode(inode);
inode->i_flags |= S_NOQUOTA; inode->i_flags |= S_NOQUOTA;
iput(inode); iput(inode);
@ -563,7 +563,7 @@ static int drop_new_inode(struct inode *inode)
} }
/* utility function that does setup for reiserfs_new_inode. /* utility function that does setup for reiserfs_new_inode.
** DQUOT_INIT needs lots of credits so it's better to have it ** vfs_dq_init needs lots of credits so it's better to have it
** outside of a transaction, so we had to pull some bits of ** outside of a transaction, so we had to pull some bits of
** reiserfs_new_inode out into this func. ** reiserfs_new_inode out into this func.
*/ */
@ -586,7 +586,7 @@ static int new_inode_init(struct inode *inode, struct inode *dir, int mode)
} else { } else {
inode->i_gid = current_fsgid(); inode->i_gid = current_fsgid();
} }
DQUOT_INIT(inode); vfs_dq_init(inode);
return 0; return 0;
} }

View File

@ -1297,7 +1297,7 @@ int reiserfs_delete_item(struct reiserfs_transaction_handle *th, struct treepath
"reiserquota delete_item(): freeing %u, id=%u type=%c", "reiserquota delete_item(): freeing %u, id=%u type=%c",
quota_cut_bytes, p_s_inode->i_uid, head2type(&s_ih)); quota_cut_bytes, p_s_inode->i_uid, head2type(&s_ih));
#endif #endif
DQUOT_FREE_SPACE_NODIRTY(p_s_inode, quota_cut_bytes); vfs_dq_free_space_nodirty(p_s_inode, quota_cut_bytes);
/* Return deleted body length */ /* Return deleted body length */
return n_ret_value; return n_ret_value;
@ -1383,7 +1383,7 @@ void reiserfs_delete_solid_item(struct reiserfs_transaction_handle *th,
quota_cut_bytes, inode->i_uid, quota_cut_bytes, inode->i_uid,
key2type(key)); key2type(key));
#endif #endif
DQUOT_FREE_SPACE_NODIRTY(inode, vfs_dq_free_space_nodirty(inode,
quota_cut_bytes); quota_cut_bytes);
} }
break; break;
@ -1734,7 +1734,7 @@ int reiserfs_cut_from_item(struct reiserfs_transaction_handle *th,
"reiserquota cut_from_item(): freeing %u id=%u type=%c", "reiserquota cut_from_item(): freeing %u id=%u type=%c",
quota_cut_bytes, p_s_inode->i_uid, '?'); quota_cut_bytes, p_s_inode->i_uid, '?');
#endif #endif
DQUOT_FREE_SPACE_NODIRTY(p_s_inode, quota_cut_bytes); vfs_dq_free_space_nodirty(p_s_inode, quota_cut_bytes);
return n_ret_value; return n_ret_value;
} }
@ -1971,7 +1971,7 @@ int reiserfs_paste_into_item(struct reiserfs_transaction_handle *th, struct tree
key2type(&(p_s_key->on_disk_key))); key2type(&(p_s_key->on_disk_key)));
#endif #endif
if (DQUOT_ALLOC_SPACE_NODIRTY(inode, n_pasted_size)) { if (vfs_dq_alloc_space_nodirty(inode, n_pasted_size)) {
pathrelse(p_s_search_path); pathrelse(p_s_search_path);
return -EDQUOT; return -EDQUOT;
} }
@ -2027,7 +2027,7 @@ int reiserfs_paste_into_item(struct reiserfs_transaction_handle *th, struct tree
n_pasted_size, inode->i_uid, n_pasted_size, inode->i_uid,
key2type(&(p_s_key->on_disk_key))); key2type(&(p_s_key->on_disk_key)));
#endif #endif
DQUOT_FREE_SPACE_NODIRTY(inode, n_pasted_size); vfs_dq_free_space_nodirty(inode, n_pasted_size);
return retval; return retval;
} }
@ -2060,7 +2060,7 @@ int reiserfs_insert_item(struct reiserfs_transaction_handle *th, struct treepath
#endif #endif
/* We can't dirty inode here. It would be immediately written but /* We can't dirty inode here. It would be immediately written but
* appropriate stat item isn't inserted yet... */ * appropriate stat item isn't inserted yet... */
if (DQUOT_ALLOC_SPACE_NODIRTY(inode, quota_bytes)) { if (vfs_dq_alloc_space_nodirty(inode, quota_bytes)) {
pathrelse(p_s_path); pathrelse(p_s_path);
return -EDQUOT; return -EDQUOT;
} }
@ -2112,6 +2112,6 @@ int reiserfs_insert_item(struct reiserfs_transaction_handle *th, struct treepath
quota_bytes, inode->i_uid, head2type(p_s_ih)); quota_bytes, inode->i_uid, head2type(p_s_ih));
#endif #endif
if (inode) if (inode)
DQUOT_FREE_SPACE_NODIRTY(inode, quota_bytes); vfs_dq_free_space_nodirty(inode, quota_bytes);
return retval; return retval;
} }

View File

@ -250,7 +250,7 @@ static int finish_unfinished(struct super_block *s)
retval = remove_save_link_only(s, &save_link_key, 0); retval = remove_save_link_only(s, &save_link_key, 0);
continue; continue;
} }
DQUOT_INIT(inode); vfs_dq_init(inode);
if (truncate && S_ISDIR(inode->i_mode)) { if (truncate && S_ISDIR(inode->i_mode)) {
/* We got a truncate request for a dir which is impossible. /* We got a truncate request for a dir which is impossible.