diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2013-09-12 18:44:27 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-09-12 18:44:27 -0400 |
commit | ac4de9543aca59f2b763746647577302fbedd57e (patch) | |
tree | 40407750569ee030de56233c41c9a97f7e89cf67 /fs/nfs | |
parent | 26935fb06ee88f1188789807687c03041f3c70d9 (diff) | |
parent | de32a8177f64bc62e1b19c685dd391af664ab13f (diff) |
Merge branch 'akpm' (patches from Andrew Morton)
Merge more patches from Andrew Morton:
"The rest of MM. Plus one misc cleanup"
* emailed patches from Andrew Morton <akpm@linux-foundation.org>: (35 commits)
mm/Kconfig: add MMU dependency for MIGRATION.
kernel: replace strict_strto*() with kstrto*()
mm, thp: count thp_fault_fallback anytime thp fault fails
thp: consolidate code between handle_mm_fault() and do_huge_pmd_anonymous_page()
thp: do_huge_pmd_anonymous_page() cleanup
thp: move maybe_pmd_mkwrite() out of mk_huge_pmd()
mm: cleanup add_to_page_cache_locked()
thp: account anon transparent huge pages into NR_ANON_PAGES
truncate: drop 'oldsize' truncate_pagecache() parameter
mm: make lru_add_drain_all() selective
memcg: document cgroup dirty/writeback memory statistics
memcg: add per cgroup writeback pages accounting
memcg: check for proper lock held in mem_cgroup_update_page_stat
memcg: remove MEMCG_NR_FILE_MAPPED
memcg: reduce function dereference
memcg: avoid overflow caused by PAGE_ALIGN
memcg: rename RESOURCE_MAX to RES_COUNTER_MAX
memcg: correct RESOURCE_MAX to ULLONG_MAX
mm: memcg: do not trap chargers with full callstack on OOM
mm: memcg: rework and document OOM waiting and wakeup
...
Diffstat (limited to 'fs/nfs')
-rw-r--r-- | fs/nfs/inode.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/fs/nfs/inode.c b/fs/nfs/inode.c index 87e797640828..eda8879171c4 100644 --- a/fs/nfs/inode.c +++ b/fs/nfs/inode.c | |||
@@ -541,7 +541,6 @@ EXPORT_SYMBOL_GPL(nfs_setattr); | |||
541 | */ | 541 | */ |
542 | static int nfs_vmtruncate(struct inode * inode, loff_t offset) | 542 | static int nfs_vmtruncate(struct inode * inode, loff_t offset) |
543 | { | 543 | { |
544 | loff_t oldsize; | ||
545 | int err; | 544 | int err; |
546 | 545 | ||
547 | err = inode_newsize_ok(inode, offset); | 546 | err = inode_newsize_ok(inode, offset); |
@@ -549,11 +548,10 @@ static int nfs_vmtruncate(struct inode * inode, loff_t offset) | |||
549 | goto out; | 548 | goto out; |
550 | 549 | ||
551 | spin_lock(&inode->i_lock); | 550 | spin_lock(&inode->i_lock); |
552 | oldsize = inode->i_size; | ||
553 | i_size_write(inode, offset); | 551 | i_size_write(inode, offset); |
554 | spin_unlock(&inode->i_lock); | 552 | spin_unlock(&inode->i_lock); |
555 | 553 | ||
556 | truncate_pagecache(inode, oldsize, offset); | 554 | truncate_pagecache(inode, offset); |
557 | out: | 555 | out: |
558 | return err; | 556 | return err; |
559 | } | 557 | } |