aboutsummaryrefslogtreecommitdiffstats
path: root/fs/quota/dquot.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/quota/dquot.c')
-rw-r--r--fs/quota/dquot.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/fs/quota/dquot.c b/fs/quota/dquot.c
index ed131318b849..78ce4c48ad77 100644
--- a/fs/quota/dquot.c
+++ b/fs/quota/dquot.c
@@ -1669,7 +1669,7 @@ EXPORT_SYMBOL(dquot_free_inode);
1669 * This operation can block, but only after everything is updated 1669 * This operation can block, but only after everything is updated
1670 * A transaction must be started when entering this function. 1670 * A transaction must be started when entering this function.
1671 */ 1671 */
1672int dquot_transfer(struct inode *inode, qid_t *chid, unsigned long mask) 1672static int __dquot_transfer(struct inode *inode, qid_t *chid, unsigned long mask)
1673{ 1673{
1674 qsize_t space, cur_space; 1674 qsize_t space, cur_space;
1675 qsize_t rsv_space = 0; 1675 qsize_t rsv_space = 0;
@@ -1766,12 +1766,11 @@ over_quota:
1766 ret = NO_QUOTA; 1766 ret = NO_QUOTA;
1767 goto warn_put_all; 1767 goto warn_put_all;
1768} 1768}
1769EXPORT_SYMBOL(dquot_transfer);
1770 1769
1771/* Wrapper for transferring ownership of an inode for uid/gid only 1770/* Wrapper for transferring ownership of an inode for uid/gid only
1772 * Called from FSXXX_setattr() 1771 * Called from FSXXX_setattr()
1773 */ 1772 */
1774int vfs_dq_transfer(struct inode *inode, struct iattr *iattr) 1773int dquot_transfer(struct inode *inode, struct iattr *iattr)
1775{ 1774{
1776 qid_t chid[MAXQUOTAS]; 1775 qid_t chid[MAXQUOTAS];
1777 unsigned long mask = 0; 1776 unsigned long mask = 0;
@@ -1786,12 +1785,12 @@ int vfs_dq_transfer(struct inode *inode, struct iattr *iattr)
1786 } 1785 }
1787 if (sb_any_quota_active(inode->i_sb) && !IS_NOQUOTA(inode)) { 1786 if (sb_any_quota_active(inode->i_sb) && !IS_NOQUOTA(inode)) {
1788 vfs_dq_init(inode); 1787 vfs_dq_init(inode);
1789 if (inode->i_sb->dq_op->transfer(inode, chid, mask) == NO_QUOTA) 1788 if (__dquot_transfer(inode, chid, mask) == NO_QUOTA)
1790 return 1; 1789 return -EDQUOT;
1791 } 1790 }
1792 return 0; 1791 return 0;
1793} 1792}
1794EXPORT_SYMBOL(vfs_dq_transfer); 1793EXPORT_SYMBOL(dquot_transfer);
1795 1794
1796/* 1795/*
1797 * Write info of quota file to disk 1796 * Write info of quota file to disk
@@ -1814,7 +1813,6 @@ EXPORT_SYMBOL(dquot_commit_info);
1814const struct dquot_operations dquot_operations = { 1813const struct dquot_operations dquot_operations = {
1815 .initialize = dquot_initialize, 1814 .initialize = dquot_initialize,
1816 .drop = dquot_drop, 1815 .drop = dquot_drop,
1817 .transfer = dquot_transfer,
1818 .write_dquot = dquot_commit, 1816 .write_dquot = dquot_commit,
1819 .acquire_dquot = dquot_acquire, 1817 .acquire_dquot = dquot_acquire,
1820 .release_dquot = dquot_release, 1818 .release_dquot = dquot_release,