From: Valdis.Kletnieks@vt.edu
To: Andrew Morton <akpm@linux-foundation.org>
Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org,
Peter Zijlstra <a.p.zijlstra@chello.nl>
Subject: Re: mmotm 2011-04-29 - wonky VmRSS and VmHWM values after swapping
Date: Mon, 02 May 2011 19:57:32 -0400 [thread overview]
Message-ID: <51961.1304380652@localhost> (raw)
In-Reply-To: Your message of "Mon, 02 May 2011 16:44:30 PDT." <20110502164430.eb7d451d.akpm@linux-foundation.org>
[-- Attachment #1: Type: text/plain, Size: 1137 bytes --]
On Mon, 02 May 2011 16:44:30 PDT, Andrew Morton said:
> hm, me too. After boot, hald has a get_mm_counter(mm, MM_ANONPAGES) of
> 0xffffffffffff3c27. Bisected to Pater's
> mm-extended-batches-for-generic-mmu_gather.patch, can't see how it did
> that.
Looking at it:
@@ -177,15 +205,24 @@ tlb_finish_mmu(struct mmu_gather *tlb, u
*/
static inline int __tlb_remove_page(struct mmu_gather *tlb, struct page *page)
{
+ struct mmu_gather_batch *batch;
+
tlb->need_flush = 1;
+
if (tlb_fast_mode(tlb)) {
free_page_and_swap_cache(page);
return 1; /* avoid calling tlb_flush_mmu() */
}
- tlb->pages[tlb->nr++] = page;
- VM_BUG_ON(tlb->nr > tlb->max);
- return tlb->max - tlb->nr;
+ batch = tlb->active;
+ batch->pages[batch->nr++] = page;
+ VM_BUG_ON(batch->nr > batch->max);
+ if (batch->nr == batch->max) {
+ if (!tlb_next_batch(tlb))
+ return 0;
+ }
+
+ return batch->max - batch->nr;
}
Who's intializing/setting batch->max? Perhaps whoever set up tlb->active
failed to do so?
[-- Attachment #2: Type: application/pgp-signature, Size: 227 bytes --]
next prev parent reply other threads:[~2011-05-02 23:57 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-04-29 23:26 mmotm 2011-04-29-16-25 uploaded akpm
2011-04-30 16:46 ` Randy Dunlap
2011-05-01 7:47 ` KOSAKI Motohiro
2011-05-02 15:46 ` Randy Dunlap
2011-05-01 2:35 ` [PATCH] mmotm: fix hang at startup Hugh Dickins
2011-05-01 3:25 ` Wu Fengguang
2011-05-02 0:26 ` mmotm 2011-04-29 - wonky VmRSS and VmHWM values after swapping Valdis.Kletnieks
2011-05-02 14:37 ` Valdis.Kletnieks
2011-05-02 23:44 ` Andrew Morton
2011-05-02 23:57 ` Valdis.Kletnieks [this message]
2011-05-10 16:04 ` Peter Zijlstra
2011-05-11 22:53 ` Andrew Morton
2011-05-12 1:08 ` Valdis.Kletnieks
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=51961.1304380652@localhost \
--to=valdis.kletnieks@vt.edu \
--cc=a.p.zijlstra@chello.nl \
--cc=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).