diff options
Diffstat (limited to 'fs/hugetlbfs/inode.c')
-rw-r--r-- | fs/hugetlbfs/inode.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/fs/hugetlbfs/inode.c b/fs/hugetlbfs/inode.c index 7f4756963d05..4f4cd132b571 100644 --- a/fs/hugetlbfs/inode.c +++ b/fs/hugetlbfs/inode.c | |||
@@ -58,7 +58,7 @@ static void huge_pagevec_release(struct pagevec *pvec) | |||
58 | 58 | ||
59 | static int hugetlbfs_file_mmap(struct file *file, struct vm_area_struct *vma) | 59 | static int hugetlbfs_file_mmap(struct file *file, struct vm_area_struct *vma) |
60 | { | 60 | { |
61 | struct inode *inode = file->f_dentry->d_inode; | 61 | struct inode *inode = file->f_path.dentry->d_inode; |
62 | loff_t len, vma_len; | 62 | loff_t len, vma_len; |
63 | int ret; | 63 | int ret; |
64 | 64 | ||
@@ -176,7 +176,7 @@ static int hugetlbfs_commit_write(struct file *file, | |||
176 | 176 | ||
177 | static void truncate_huge_page(struct page *page) | 177 | static void truncate_huge_page(struct page *page) |
178 | { | 178 | { |
179 | clear_page_dirty(page); | 179 | cancel_dirty_page(page, /* No IO accounting for huge pages? */0); |
180 | ClearPageUptodate(page); | 180 | ClearPageUptodate(page); |
181 | remove_from_page_cache(page); | 181 | remove_from_page_cache(page); |
182 | put_page(page); | 182 | put_page(page); |
@@ -513,7 +513,7 @@ static void hugetlbfs_inc_free_inodes(struct hugetlbfs_sb_info *sbinfo) | |||
513 | } | 513 | } |
514 | 514 | ||
515 | 515 | ||
516 | static kmem_cache_t *hugetlbfs_inode_cachep; | 516 | static struct kmem_cache *hugetlbfs_inode_cachep; |
517 | 517 | ||
518 | static struct inode *hugetlbfs_alloc_inode(struct super_block *sb) | 518 | static struct inode *hugetlbfs_alloc_inode(struct super_block *sb) |
519 | { | 519 | { |
@@ -522,7 +522,7 @@ static struct inode *hugetlbfs_alloc_inode(struct super_block *sb) | |||
522 | 522 | ||
523 | if (unlikely(!hugetlbfs_dec_free_inodes(sbinfo))) | 523 | if (unlikely(!hugetlbfs_dec_free_inodes(sbinfo))) |
524 | return NULL; | 524 | return NULL; |
525 | p = kmem_cache_alloc(hugetlbfs_inode_cachep, SLAB_KERNEL); | 525 | p = kmem_cache_alloc(hugetlbfs_inode_cachep, GFP_KERNEL); |
526 | if (unlikely(!p)) { | 526 | if (unlikely(!p)) { |
527 | hugetlbfs_inc_free_inodes(sbinfo); | 527 | hugetlbfs_inc_free_inodes(sbinfo); |
528 | return NULL; | 528 | return NULL; |
@@ -545,7 +545,7 @@ static const struct address_space_operations hugetlbfs_aops = { | |||
545 | }; | 545 | }; |
546 | 546 | ||
547 | 547 | ||
548 | static void init_once(void *foo, kmem_cache_t *cachep, unsigned long flags) | 548 | static void init_once(void *foo, struct kmem_cache *cachep, unsigned long flags) |
549 | { | 549 | { |
550 | struct hugetlbfs_inode_info *ei = (struct hugetlbfs_inode_info *)foo; | 550 | struct hugetlbfs_inode_info *ei = (struct hugetlbfs_inode_info *)foo; |
551 | 551 | ||
@@ -774,8 +774,8 @@ struct file *hugetlb_zero_setup(size_t size) | |||
774 | d_instantiate(dentry, inode); | 774 | d_instantiate(dentry, inode); |
775 | inode->i_size = size; | 775 | inode->i_size = size; |
776 | inode->i_nlink = 0; | 776 | inode->i_nlink = 0; |
777 | file->f_vfsmnt = mntget(hugetlbfs_vfsmount); | 777 | file->f_path.mnt = mntget(hugetlbfs_vfsmount); |
778 | file->f_dentry = dentry; | 778 | file->f_path.dentry = dentry; |
779 | file->f_mapping = inode->i_mapping; | 779 | file->f_mapping = inode->i_mapping; |
780 | file->f_op = &hugetlbfs_file_operations; | 780 | file->f_op = &hugetlbfs_file_operations; |
781 | file->f_mode = FMODE_WRITE | FMODE_READ; | 781 | file->f_mode = FMODE_WRITE | FMODE_READ; |