aboutsummaryrefslogtreecommitdiffstats
path: root/mm/shmem.c
diff options
context:
space:
mode:
Diffstat (limited to 'mm/shmem.c')
-rw-r--r--mm/shmem.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/mm/shmem.c b/mm/shmem.c
index 0a43505eeaec..33222ba256fb 100644
--- a/mm/shmem.c
+++ b/mm/shmem.c
@@ -805,11 +805,10 @@ static int shmem_notify_change(struct dentry *dentry, struct iattr *attr)
805 } 805 }
806 } 806 }
807 807
808 error = simple_setsize(inode, newsize); 808 /* XXX(truncate): truncate_setsize should be called last */
809 truncate_setsize(inode, newsize);
809 if (page) 810 if (page)
810 page_cache_release(page); 811 page_cache_release(page);
811 if (error)
812 return error;
813 shmem_truncate_range(inode, newsize, (loff_t)-1); 812 shmem_truncate_range(inode, newsize, (loff_t)-1);
814 } 813 }
815 814