diff options
author | Dave Kleikamp <shaggy@linux.vnet.ibm.com> | 2006-12-20 16:55:35 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.osdl.org> | 2006-12-21 12:24:03 -0500 |
commit | d0e671a932cb9c653b27393cec26aec012a8d97e (patch) | |
tree | 9625f4462e2e0f6a5756b20a074dcf039761e554 | |
parent | fba2591bf4e418b6c3f9f8794c9dd8fe40ae7bd9 (diff) |
[PATCH] Fix JFS after clear_page_dirty() removal
This patch removes some questionable code that attempted to make a
no-longer-used page easier to reclaim.
Calling metapage_writepage against such a page will not result in any
I/O being performed, so removing this code shouldn't be a big deal.
[ It's likely that we could have just replaced the "clear_page_dirty()"
call with a call to "cancel_dirty_page()" instead, but in the
meantime this is cleaner and simpler anyway, so unless there is some
overriding reason (and Dave implies there isn't) I'll just use this
patch as-is. - Linus ]
Signed-off-by: Dave Kleikamp <shaggy@linux.vnet.ibm.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-rw-r--r-- | fs/jfs/jfs_metapage.c | 15 |
1 files changed, 1 insertions, 14 deletions
diff --git a/fs/jfs/jfs_metapage.c b/fs/jfs/jfs_metapage.c index b1a1c7296014..ceaf03b94935 100644 --- a/fs/jfs/jfs_metapage.c +++ b/fs/jfs/jfs_metapage.c | |||
@@ -764,22 +764,9 @@ void release_metapage(struct metapage * mp) | |||
764 | } else if (mp->lsn) /* discard_metapage doesn't remove it */ | 764 | } else if (mp->lsn) /* discard_metapage doesn't remove it */ |
765 | remove_from_logsync(mp); | 765 | remove_from_logsync(mp); |
766 | 766 | ||
767 | #if MPS_PER_PAGE == 1 | ||
768 | /* | ||
769 | * If we know this is the only thing in the page, we can throw | ||
770 | * the page out of the page cache. If pages are larger, we | ||
771 | * don't want to do this. | ||
772 | */ | ||
773 | |||
774 | /* Retest mp->count since we may have released page lock */ | ||
775 | if (test_bit(META_discard, &mp->flag) && !mp->count) { | ||
776 | clear_page_dirty(page); | ||
777 | ClearPageUptodate(page); | ||
778 | } | ||
779 | #else | ||
780 | /* Try to keep metapages from using up too much memory */ | 767 | /* Try to keep metapages from using up too much memory */ |
781 | drop_metapage(page, mp); | 768 | drop_metapage(page, mp); |
782 | #endif | 769 | |
783 | unlock_page(page); | 770 | unlock_page(page); |
784 | page_cache_release(page); | 771 | page_cache_release(page); |
785 | } | 772 | } |