Thread (65 messages) 65 messages, 6 authors, 2012-02-28

Re: [PATCH v3 18/21] mm: add to lruvec isolated pages counters

From: Konstantin Khlebnikov <hidden>
Date: 2012-02-24 05:32:39
Also in: lkml

Konstantin Khlebnikov wrote:
quoted hunk ↗ jump to hunk
@@ -2480,8 +2494,11 @@ static int mem_cgroup_move_parent(struct page *page,

         if (nr_pages>  1)
                 compound_unlock_irqrestore(page, flags);
+       if (!ret)
+               /* This also stabilize PageLRU() sign for lruvec lock holder. */
+               mem_cgroup_adjust_isolated(lruvec, page, -nr_pages);
  put_back:
-       putback_lru_page(page);
+       __putback_lru_page(page, !ret);
  put:
         put_page(page);
  out:
Oh, no. There must be !!ret
--- a/mm/memcontrol.c
+++ b/mm/memcontrol.c
@@ -2482,7 +2482,7 @@ static int mem_cgroup_move_parent(struct page *page,
                 /* This also stabilize PageLRU() sign for lruvec lock holder. */
                 mem_cgroup_adjust_isolated(lruvec, page, -nr_pages);
  put_back:
-       __putback_lru_page(page, !ret);
+       __putback_lru_page(page, !!ret);
  put:
         put_page(page);
  out:

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help