+ tools-adding-support-for-idle-page-tracking-to-tool-fix.patch added to -mm tree

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

 



The patch titled
     Subject: tools-adding-support-for-idle-page-tracking-to-tool-fix
has been added to the -mm tree.  Its filename is
     tools-adding-support-for-idle-page-tracking-to-tool-fix.patch

This patch should soon appear at
    http://ozlabs.org/~akpm/mmots/broken-out/tools-adding-support-for-idle-page-tracking-to-tool-fix.patch
and later at
    http://ozlabs.org/~akpm/mmotm/broken-out/tools-adding-support-for-idle-page-tracking-to-tool-fix.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: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
Subject: tools-adding-support-for-idle-page-tracking-to-tool-fix

simplify mark_page_idle()

Cc: Christian Hansen <chansen3@xxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

 tools/vm/page-types.c |   18 ++++++------------
 1 file changed, 6 insertions(+), 12 deletions(-)

diff -puN tools/vm/page-types.c~tools-adding-support-for-idle-page-tracking-to-tool-fix tools/vm/page-types.c
--- a/tools/vm/page-types.c~tools-adding-support-for-idle-page-tracking-to-tool-fix
+++ a/tools/vm/page-types.c
@@ -597,21 +597,15 @@ static int mark_page_idle(unsigned long
 	static uint64_t buf;
 	int len;
 
-	if ((offset / 64 == off / 64) || buf == 0) {
-		buf |= 1UL << (offset % 64);
-		off = offset;
-		return 0;
+	if ((offset / 64 != off / 64) && buf != 0) {
+		len = pwrite(page_idle_fd, &buf, 8, 8 * (off / 64));
+		if (len < 0) {
+			perror("mark page idle");
+			return len;
+		}
 	}
-
-	len = pwrite(page_idle_fd, &buf, 8, 8 * (off / 64));
-	if (len < 0) {
-		perror("mark page idle");
-		return len;
-	}
-
 	buf = 1UL << (offset % 64);
 	off = offset;
-
 	return 0;
 }
 
_

Patches currently in -mm which might be from akpm@xxxxxxxxxxxxxxxxxxxx are

i-need-old-gcc.patch
arm-arch-arm-include-asm-pageh-needs-personalityh.patch
mm.patch
tools-modifying-page-types-to-include-shared-map-counts-checkpatch-fixes.patch
tools-adding-support-for-idle-page-tracking-to-tool-fix.patch
list_lru-prefetch-neighboring-list-entries-before-acquiring-lock-fix.patch
mm-oom-cgroup-aware-oom-killer-fix.patch
mm-oom-cgroup-aware-oom-killer-fix-2.patch
mm-oom-docs-describe-the-cgroup-aware-oom-killer-fix-2-fix.patch
linux-next-rejects.patch
kernel-forkc-export-kernel_thread-to-modules.patch
slab-leaks3-default-y.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