reiserfs: Use lowercase names of quota functions
[linux-block.git] / fs / reiserfs / stree.c
index 981027d1187bb49f33b0798cd9cfb790a2d8e549..73aaa33f6735661fe7932843faada42866663efc 100644 (file)
@@ -559,7 +559,7 @@ static int is_tree_node(struct buffer_head *bh, int level)
 /* The function is NOT SCHEDULE-SAFE! */
 static void search_by_key_reada(struct super_block *s,
                                struct buffer_head **bh,
-                               unsigned long *b, int num)
+                               b_blocknr_t *b, int num)
 {
        int i, j;
 
@@ -611,7 +611,7 @@ int search_by_key(struct super_block *p_s_sb, const struct cpu_key *p_s_key,        /*
                                           DISK_LEAF_NODE_LEVEL */
     )
 {
-       int n_block_number;
+       b_blocknr_t n_block_number;
        int expected_level;
        struct buffer_head *p_s_bh;
        struct path_element *p_s_last_element;
@@ -619,7 +619,7 @@ int search_by_key(struct super_block *p_s_sb, const struct cpu_key *p_s_key,        /*
        int right_neighbor_of_leaf_node;
        int fs_gen;
        struct buffer_head *reada_bh[SEARCH_BY_KEY_READA];
-       unsigned long reada_blocks[SEARCH_BY_KEY_READA];
+       b_blocknr_t reada_blocks[SEARCH_BY_KEY_READA];
        int reada_count = 0;
 
 #ifdef CONFIG_REISERFS_CHECK
@@ -1297,7 +1297,7 @@ int reiserfs_delete_item(struct reiserfs_transaction_handle *th, struct treepath
                       "reiserquota delete_item(): freeing %u, id=%u type=%c",
                       quota_cut_bytes, p_s_inode->i_uid, head2type(&s_ih));
 #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 n_ret_value;
@@ -1383,7 +1383,7 @@ void reiserfs_delete_solid_item(struct reiserfs_transaction_handle *th,
                                               quota_cut_bytes, inode->i_uid,
                                               key2type(key));
 #endif
-                               DQUOT_FREE_SPACE_NODIRTY(inode,
+                               vfs_dq_free_space_nodirty(inode,
                                                         quota_cut_bytes);
                        }
                        break;
@@ -1419,8 +1419,7 @@ int reiserfs_delete_object(struct reiserfs_transaction_handle *th,
 
                inode_generation =
                    &REISERFS_SB(th->t_super)->s_rs->s_inode_generation;
-               *inode_generation =
-                   cpu_to_le32(le32_to_cpu(*inode_generation) + 1);
+               le32_add_cpu(inode_generation, 1);
        }
 /* USE_INODE_GENERATION_COUNTER */
 #endif
@@ -1458,9 +1457,6 @@ static void unmap_buffers(struct page *page, loff_t pos)
                                }
                                bh = next;
                        } while (bh != head);
-                       if (PAGE_SIZE == bh->b_size) {
-                               cancel_dirty_page(page, PAGE_CACHE_SIZE);
-                       }
                }
        }
 }
@@ -1738,7 +1734,7 @@ int reiserfs_cut_from_item(struct reiserfs_transaction_handle *th,
                       "reiserquota cut_from_item(): freeing %u id=%u type=%c",
                       quota_cut_bytes, p_s_inode->i_uid, '?');
 #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;
 }
 
@@ -1975,7 +1971,7 @@ int reiserfs_paste_into_item(struct reiserfs_transaction_handle *th, struct tree
                       key2type(&(p_s_key->on_disk_key)));
 #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);
                return -EDQUOT;
        }
@@ -2031,7 +2027,7 @@ int reiserfs_paste_into_item(struct reiserfs_transaction_handle *th, struct tree
                       n_pasted_size, inode->i_uid,
                       key2type(&(p_s_key->on_disk_key)));
 #endif
-       DQUOT_FREE_SPACE_NODIRTY(inode, n_pasted_size);
+       vfs_dq_free_space_nodirty(inode, n_pasted_size);
        return retval;
 }
 
@@ -2064,7 +2060,7 @@ int reiserfs_insert_item(struct reiserfs_transaction_handle *th, struct treepath
 #endif
                /* We can't dirty inode here. It would be immediately written but
                 * 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);
                        return -EDQUOT;
                }
@@ -2116,6 +2112,6 @@ int reiserfs_insert_item(struct reiserfs_transaction_handle *th, struct treepath
                       quota_bytes, inode->i_uid, head2type(p_s_ih));
 #endif
        if (inode)
-               DQUOT_FREE_SPACE_NODIRTY(inode, quota_bytes);
+               vfs_dq_free_space_nodirty(inode, quota_bytes);
        return retval;
 }