X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=mm%2Ftruncate.c;h=cadc15653ddeeaa311c80f794b6a564ae2f36fc8;hb=65f7651788e18fadb2fbb7276af935d7871e1803;hp=aed85f0b707f3ca4665835ced9b009ad07dfb836;hpb=d00806b183152af6d24f46f0c33f14162ca1262a;p=linux-2.6 diff --git a/mm/truncate.c b/mm/truncate.c index aed85f0b70..cadc15653d 100644 --- a/mm/truncate.c +++ b/mm/truncate.c @@ -8,6 +8,7 @@ */ #include +#include #include #include #include @@ -72,6 +73,8 @@ void cancel_dirty_page(struct page *page, unsigned int account_size) struct address_space *mapping = page->mapping; if (mapping && mapping_cap_account_dirty(mapping)) { dec_zone_page_state(page, NR_FILE_DIRTY); + dec_bdi_stat(mapping->backing_dev_info, + BDI_RECLAIMABLE); if (account_size) task_io_account_cancelled_write(account_size); } @@ -82,7 +85,7 @@ EXPORT_SYMBOL(cancel_dirty_page); /* * If truncate cannot remove the fs-private metadata from the page, the page * becomes anonymous. It will be left on the LRU and may even be mapped into - * user pagetables if we're racing with filemap_nopage(). + * user pagetables if we're racing with filemap_fault(). * * We need to bale out if page->mapping is no longer equal to the original * mapping. This happens a) when the VM reclaimed the page while we waited on