+ block_invalidatepage-only-release-page-if-the-full-page-was-invalidated.patch added to -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The patch titled
     Subject: block_invalidatepage(): only release page if the full page was invalidated
has been added to the -mm tree.  Its filename is
     block_invalidatepage-only-release-page-if-the-full-page-was-invalidated.patch

This patch should soon appear at
    http://ozlabs.org/~akpm/mmots/broken-out/block_invalidatepage-only-release-page-if-the-full-page-was-invalidated.patch
and later at
    http://ozlabs.org/~akpm/mmotm/broken-out/block_invalidatepage-only-release-page-if-the-full-page-was-invalidated.patch

Before you just go and hit "reply", please:
   a) Consider who else should be cc'ed
   b) Prefer to cc a suitable mailing list as well
   c) Ideally: find the original patch on the mailing list and do a
      reply-to-all to that, adding suitable additional cc's

*** Remember to use Documentation/process/submit-checklist.rst when testing your code ***

The -mm tree is included into linux-next and is updated
there every 3-4 working days

------------------------------------------------------
From: Jeff Moyer <jmoyer@xxxxxxxxxx>
Subject: block_invalidatepage(): only release page if the full page was invalidated

Prior to d47992f86b307 ("mm: change invalidatepage prototype to accept
length"), an offset of 0 meant that the full page was being invalidated. 
After that commit, we need to instead check the length.

Jan said:

: The only possible issue is that try_to_release_page() was called more
: often than necessary.  Otherwise the issue is harmless but still it's good
: to have this fixed.

Link: http://lkml.kernel.org/r/x49fu5rtnzs.fsf@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Fixes: d47992f86b307 ("mm: change invalidatepage prototype to accept length")
Signed-off-by: Jeff Moyer <jmoyer@xxxxxxxxxx>
Reviewed-by: Jan Kara <jack@xxxxxxx>
Cc: Lukas Czerner <lczerner@xxxxxxxxxx>
Cc: Hugh Dickins <hughd@xxxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

 fs/buffer.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff -puN fs/buffer.c~block_invalidatepage-only-release-page-if-the-full-page-was-invalidated fs/buffer.c
--- a/fs/buffer.c~block_invalidatepage-only-release-page-if-the-full-page-was-invalidated
+++ a/fs/buffer.c
@@ -1511,7 +1511,7 @@ void block_invalidatepage(struct page *p
 	 * The get_block cached value has been unconditionally invalidated,
 	 * so real IO is not possible anymore.
 	 */
-	if (offset == 0)
+	if (length == PAGE_SIZE)
 		try_to_release_page(page, 0);
 out:
 	return;
_

Patches currently in -mm which might be from jmoyer@xxxxxxxxxx are

block_invalidatepage-only-release-page-if-the-full-page-was-invalidated.patch

--
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux