]> git.proxmox.com Git - mirror_ubuntu-zesty-kernel.git/blobdiff - fs/ext4/readpage.c
mm, fs: get rid of PAGE_CACHE_* and page_cache_{get,release} macros
[mirror_ubuntu-zesty-kernel.git] / fs / ext4 / readpage.c
index 5dc5e95063de2a7e42749a94464f00f7c50be4b8..ea27aa1a778c177c219ab1c88a65c37be5bb498c 100644 (file)
@@ -140,7 +140,7 @@ int ext4_mpage_readpages(struct address_space *mapping,
 
        struct inode *inode = mapping->host;
        const unsigned blkbits = inode->i_blkbits;
-       const unsigned blocks_per_page = PAGE_CACHE_SIZE >> blkbits;
+       const unsigned blocks_per_page = PAGE_SIZE >> blkbits;
        const unsigned blocksize = 1 << blkbits;
        sector_t block_in_file;
        sector_t last_block;
@@ -173,7 +173,7 @@ int ext4_mpage_readpages(struct address_space *mapping,
                if (page_has_buffers(page))
                        goto confused;
 
-               block_in_file = (sector_t)page->index << (PAGE_CACHE_SHIFT - blkbits);
+               block_in_file = (sector_t)page->index << (PAGE_SHIFT - blkbits);
                last_block = block_in_file + nr_pages * blocks_per_page;
                last_block_in_file = (i_size_read(inode) + blocksize - 1) >> blkbits;
                if (last_block > last_block_in_file)
@@ -217,7 +217,7 @@ int ext4_mpage_readpages(struct address_space *mapping,
                                set_error_page:
                                        SetPageError(page);
                                        zero_user_segment(page, 0,
-                                                         PAGE_CACHE_SIZE);
+                                                         PAGE_SIZE);
                                        unlock_page(page);
                                        goto next_page;
                                }
@@ -250,7 +250,7 @@ int ext4_mpage_readpages(struct address_space *mapping,
                }
                if (first_hole != blocks_per_page) {
                        zero_user_segment(page, first_hole << blkbits,
-                                         PAGE_CACHE_SIZE);
+                                         PAGE_SIZE);
                        if (first_hole == 0) {
                                SetPageUptodate(page);
                                unlock_page(page);
@@ -319,7 +319,7 @@ int ext4_mpage_readpages(struct address_space *mapping,
                        unlock_page(page);
        next_page:
                if (pages)
-                       page_cache_release(page);
+                       put_page(page);
        }
        BUG_ON(pages && !list_empty(pages));
        if (bio)