diff options
author | Jan Kara <jack@suse.cz> | 2009-01-26 19:47:11 -0500 |
---|---|---|
committer | Jan Kara <jack@suse.cz> | 2009-03-25 21:18:37 -0400 |
commit | 7a2435d874388271cfe5046d180751352a1d30a2 (patch) | |
tree | 57dbb588ea29976db10246add0b7d7e836d1e6a0 /fs | |
parent | bf84c82d000b9820b01f516d13d328f354f8a8ee (diff) |
quota: Remove superfluous inlines
Remove inlines of large functions to decrease code size (saved 1543
bytes).
Signed-off-by: Jan Kara <jack@suse.cz>
Diffstat (limited to 'fs')
-rw-r--r-- | fs/quota/dquot.c | 13 | ||||
-rw-r--r-- | fs/quota/quota.c | 2 | ||||
-rw-r--r-- | fs/quota/quota_tree.c | 6 |
3 files changed, 11 insertions, 10 deletions
diff --git a/fs/quota/dquot.c b/fs/quota/dquot.c index 4881db32e56d..4a37b8e32b4e 100644 --- a/fs/quota/dquot.c +++ b/fs/quota/dquot.c | |||
@@ -243,7 +243,8 @@ static inline void remove_dquot_hash(struct dquot *dquot) | |||
243 | hlist_del_init(&dquot->dq_hash); | 243 | hlist_del_init(&dquot->dq_hash); |
244 | } | 244 | } |
245 | 245 | ||
246 | static inline struct dquot *find_dquot(unsigned int hashent, struct super_block *sb, unsigned int id, int type) | 246 | static struct dquot *find_dquot(unsigned int hashent, struct super_block *sb, |
247 | unsigned int id, int type) | ||
247 | { | 248 | { |
248 | struct hlist_node *node; | 249 | struct hlist_node *node; |
249 | struct dquot *dquot; | 250 | struct dquot *dquot; |
@@ -935,7 +936,7 @@ void dquot_free_reserved_space(struct dquot *dquot, qsize_t number) | |||
935 | dquot->dq_dqb.dqb_rsvspace -= number; | 936 | dquot->dq_dqb.dqb_rsvspace -= number; |
936 | } | 937 | } |
937 | 938 | ||
938 | static inline void dquot_decr_inodes(struct dquot *dquot, qsize_t number) | 939 | static void dquot_decr_inodes(struct dquot *dquot, qsize_t number) |
939 | { | 940 | { |
940 | if (sb_dqopt(dquot->dq_sb)->flags & DQUOT_NEGATIVE_USAGE || | 941 | if (sb_dqopt(dquot->dq_sb)->flags & DQUOT_NEGATIVE_USAGE || |
941 | dquot->dq_dqb.dqb_curinodes >= number) | 942 | dquot->dq_dqb.dqb_curinodes >= number) |
@@ -947,7 +948,7 @@ static inline void dquot_decr_inodes(struct dquot *dquot, qsize_t number) | |||
947 | clear_bit(DQ_INODES_B, &dquot->dq_flags); | 948 | clear_bit(DQ_INODES_B, &dquot->dq_flags); |
948 | } | 949 | } |
949 | 950 | ||
950 | static inline void dquot_decr_space(struct dquot *dquot, qsize_t number) | 951 | static void dquot_decr_space(struct dquot *dquot, qsize_t number) |
951 | { | 952 | { |
952 | if (sb_dqopt(dquot->dq_sb)->flags & DQUOT_NEGATIVE_USAGE || | 953 | if (sb_dqopt(dquot->dq_sb)->flags & DQUOT_NEGATIVE_USAGE || |
953 | dquot->dq_dqb.dqb_curspace >= number) | 954 | dquot->dq_dqb.dqb_curspace >= number) |
@@ -974,7 +975,7 @@ static int warning_issued(struct dquot *dquot, const int warntype) | |||
974 | #ifdef CONFIG_PRINT_QUOTA_WARNING | 975 | #ifdef CONFIG_PRINT_QUOTA_WARNING |
975 | static int flag_print_warnings = 1; | 976 | static int flag_print_warnings = 1; |
976 | 977 | ||
977 | static inline int need_print_warning(struct dquot *dquot) | 978 | static int need_print_warning(struct dquot *dquot) |
978 | { | 979 | { |
979 | if (!flag_print_warnings) | 980 | if (!flag_print_warnings) |
980 | return 0; | 981 | return 0; |
@@ -1109,7 +1110,7 @@ err_out: | |||
1109 | * | 1110 | * |
1110 | * Note that this function can sleep. | 1111 | * Note that this function can sleep. |
1111 | */ | 1112 | */ |
1112 | static inline void flush_warnings(struct dquot * const *dquots, char *warntype) | 1113 | static void flush_warnings(struct dquot *const *dquots, char *warntype) |
1113 | { | 1114 | { |
1114 | int i; | 1115 | int i; |
1115 | 1116 | ||
@@ -1125,7 +1126,7 @@ static inline void flush_warnings(struct dquot * const *dquots, char *warntype) | |||
1125 | } | 1126 | } |
1126 | } | 1127 | } |
1127 | 1128 | ||
1128 | static inline char ignore_hardlimit(struct dquot *dquot) | 1129 | static int ignore_hardlimit(struct dquot *dquot) |
1129 | { | 1130 | { |
1130 | struct mem_dqinfo *info = &sb_dqopt(dquot->dq_sb)->info[dquot->dq_type]; | 1131 | struct mem_dqinfo *info = &sb_dqopt(dquot->dq_sb)->info[dquot->dq_type]; |
1131 | 1132 | ||
diff --git a/fs/quota/quota.c b/fs/quota/quota.c index d76ada914f98..89541bcbe27c 100644 --- a/fs/quota/quota.c +++ b/fs/quota/quota.c | |||
@@ -341,7 +341,7 @@ static int do_quotactl(struct super_block *sb, int type, int cmd, qid_t id, void | |||
341 | * look up a superblock on which quota ops will be performed | 341 | * look up a superblock on which quota ops will be performed |
342 | * - use the name of a block device to find the superblock thereon | 342 | * - use the name of a block device to find the superblock thereon |
343 | */ | 343 | */ |
344 | static inline struct super_block *quotactl_block(const char __user *special) | 344 | static struct super_block *quotactl_block(const char __user *special) |
345 | { | 345 | { |
346 | #ifdef CONFIG_BLOCK | 346 | #ifdef CONFIG_BLOCK |
347 | struct block_device *bdev; | 347 | struct block_device *bdev; |
diff --git a/fs/quota/quota_tree.c b/fs/quota/quota_tree.c index 3a5a90c08962..48e35a48f1c2 100644 --- a/fs/quota/quota_tree.c +++ b/fs/quota/quota_tree.c | |||
@@ -33,7 +33,7 @@ static int get_index(struct qtree_mem_dqinfo *info, qid_t id, int depth) | |||
33 | } | 33 | } |
34 | 34 | ||
35 | /* Number of entries in one blocks */ | 35 | /* Number of entries in one blocks */ |
36 | static inline int qtree_dqstr_in_blk(struct qtree_mem_dqinfo *info) | 36 | static int qtree_dqstr_in_blk(struct qtree_mem_dqinfo *info) |
37 | { | 37 | { |
38 | return (info->dqi_usable_bs - sizeof(struct qt_disk_dqdbheader)) | 38 | return (info->dqi_usable_bs - sizeof(struct qt_disk_dqdbheader)) |
39 | / info->dqi_entry_size; | 39 | / info->dqi_entry_size; |
@@ -47,7 +47,7 @@ static char *getdqbuf(size_t size) | |||
47 | return buf; | 47 | return buf; |
48 | } | 48 | } |
49 | 49 | ||
50 | static inline ssize_t read_blk(struct qtree_mem_dqinfo *info, uint blk, char *buf) | 50 | static ssize_t read_blk(struct qtree_mem_dqinfo *info, uint blk, char *buf) |
51 | { | 51 | { |
52 | struct super_block *sb = info->dqi_sb; | 52 | struct super_block *sb = info->dqi_sb; |
53 | 53 | ||
@@ -56,7 +56,7 @@ static inline ssize_t read_blk(struct qtree_mem_dqinfo *info, uint blk, char *bu | |||
56 | info->dqi_usable_bs, blk << info->dqi_blocksize_bits); | 56 | info->dqi_usable_bs, blk << info->dqi_blocksize_bits); |
57 | } | 57 | } |
58 | 58 | ||
59 | static inline ssize_t write_blk(struct qtree_mem_dqinfo *info, uint blk, char *buf) | 59 | static ssize_t write_blk(struct qtree_mem_dqinfo *info, uint blk, char *buf) |
60 | { | 60 | { |
61 | struct super_block *sb = info->dqi_sb; | 61 | struct super_block *sb = info->dqi_sb; |
62 | 62 | ||