* [patch] mm: fix rss counter being incremented when unmapping
@ 2005-05-09 12:29 Björn Steinbrink
2005-05-10 12:09 ` Rik van Riel
2005-05-10 18:15 ` Christoph Lameter
0 siblings, 2 replies; 3+ messages in thread
From: Björn Steinbrink @ 2005-05-09 12:29 UTC (permalink / raw)
To: linux-kernel; +Cc: linux-mm
This patch fixes a bug introduced by the "mm counter operations through
macros" patch, which replaced a decrement operation in with an increment
macro in try_to_unmap_one().
Signed-off-by: Bjorn Steinbrink <B.Steinbrink@gmx.de>
diff -NurpP --minimal linux-2.6.12-rc4/mm/rmap.c linux-2.6.12-rc4-fixed/mm/rmap.c
--- linux-2.6.12-rc4/mm/rmap.c 2005-05-08 17:53:49.000000000 +0200
+++ linux-2.6.12-rc4-fixed/mm/rmap.c 2005-05-09 13:38:03.000000000 +0200
@@ -586,7 +586,7 @@ static int try_to_unmap_one(struct page
dec_mm_counter(mm, anon_rss);
}
- inc_mm_counter(mm, rss);
+ dec_mm_counter(mm, rss);
page_remove_rmap(page);
page_cache_release(page);
--
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/ .
Don't email: <a href=mailto:"aart@kvack.org"> aart@kvack.org </a>
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [patch] mm: fix rss counter being incremented when unmapping
2005-05-09 12:29 [patch] mm: fix rss counter being incremented when unmapping Björn Steinbrink
@ 2005-05-10 12:09 ` Rik van Riel
2005-05-10 18:15 ` Christoph Lameter
1 sibling, 0 replies; 3+ messages in thread
From: Rik van Riel @ 2005-05-10 12:09 UTC (permalink / raw)
To: Björn Steinbrink; +Cc: linux-kernel, linux-mm
[-- Attachment #1: Type: TEXT/PLAIN, Size: 548 bytes --]
On Mon, 9 May 2005, Bjorn Steinbrink wrote:
> This patch fixes a bug introduced by the "mm counter operations through
> macros" patch, which replaced a decrement operation in with an increment
> macro in try_to_unmap_one().
Oops. Patch looks good to me.
Andrew, if you see this could you pick up the
patch from the head of this thread? ;)
--
"Debugging is twice as hard as writing the code in the first place.
Therefore, if you write the code as cleverly as possible, you are,
by definition, not smart enough to debug it." - Brian W. Kernighan
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [patch] mm: fix rss counter being incremented when unmapping
2005-05-09 12:29 [patch] mm: fix rss counter being incremented when unmapping Björn Steinbrink
2005-05-10 12:09 ` Rik van Riel
@ 2005-05-10 18:15 ` Christoph Lameter
1 sibling, 0 replies; 3+ messages in thread
From: Christoph Lameter @ 2005-05-10 18:15 UTC (permalink / raw)
To: akpm, Björn Steinbrink; +Cc: linux-kernel, linux-mm
Correct. Thanks for catching that. My latest rss patch also has that.
On Mon, 9 May 2005, Bjorn Steinbrink wrote:
> This patch fixes a bug introduced by the "mm counter operations through
> macros" patch, which replaced a decrement operation in with an increment
> macro in try_to_unmap_one().
>
> Signed-off-by: Bjorn Steinbrink <B.Steinbrink@gmx.de>
>
> diff -NurpP --minimal linux-2.6.12-rc4/mm/rmap.c linux-2.6.12-rc4-fixed/mm/rmap.c
> --- linux-2.6.12-rc4/mm/rmap.c 2005-05-08 17:53:49.000000000 +0200
> +++ linux-2.6.12-rc4-fixed/mm/rmap.c 2005-05-09 13:38:03.000000000 +0200
> @@ -586,7 +586,7 @@ static int try_to_unmap_one(struct page
> dec_mm_counter(mm, anon_rss);
> }
>
> - inc_mm_counter(mm, rss);
> + dec_mm_counter(mm, rss);
> page_remove_rmap(page);
> page_cache_release(page);
>
> --
> 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/ .
> Don't email: <a href=mailto:"aart@kvack.org"> aart@kvack.org </a>
>
--
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/ .
Don't email: <a href=mailto:"aart@kvack.org"> aart@kvack.org </a>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2005-05-10 18:15 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-05-09 12:29 [patch] mm: fix rss counter being incremented when unmapping Björn Steinbrink
2005-05-10 12:09 ` Rik van Riel
2005-05-10 18:15 ` Christoph Lameter
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox