From: Martin Schwidefsky <schwidefsky@de.ibm.com>
To: "Uwe Kleine-König" <Uwe.Kleine-Koenig@digi.com>
Cc: Andrew Morton <akpm@linux-foundation.org>,
Linus Torvalds <torvalds@linux-foundation.org>,
linux-arch@vger.kernel.org
Subject: Re: regression: 2f569af (CONFIG_HIGHPTE vs. sub-page page tables.)
Date: Tue, 26 Feb 2008 18:57:46 +0100 [thread overview]
Message-ID: <1204048666.21725.6.camel@localhost> (raw)
In-Reply-To: <20080226143858.GA11590@digi.com>
Hi Uwe,
On Tue, 2008-02-26 at 15:38 +0100, Uwe Kleine-König wrote:
> Moreover a "grep PageTables /proc/meminfo" resulted in
>
> 9x __dec_zone_state with item == NR_PAGETABLE
> 7x __inc_zone_state with item == NR_PAGETABLE
>
> All those 16 calles where done via __(inc|dec)_zone_page_state.
>
> ... some time later ...
>
> I got it. This code is currently in free_pgd_slow():
>
> pte = pmd_page(*pmd);
> pmd_clear(pmd);
> dec_zone_page_state(virt_to_page((unsigned long *)pgd), NR_PAGETABLE);
> pte_lock_deinit(pte);
> pte_free(mm, pte);
> pmd_free(mm, pmd);
>
> So because (since 2f569af) pte_free does dec_zone_page_state and
> pte_lock_deinit, these two happen twice here.
Ah, good. I wonder if there are any other pte_lock_deinit hidden in the
arch code... nope, arm is the only architecture that does it.
> Removing the calls to dec_zone_page_state() and pte_lock_deinit() in
> free_pgd_slow() fixed it for me.
That is imho the best way to fix it.
> For a complete fix we might want to change the type of pte?
You mean instead of a "struct page *" use a pgtable_t ? Yes, that would
be cleaner even if it is the same type.
--
blue skies,
Martin.
"Reality continues to ruin my life." - Calvin.
next prev parent reply other threads:[~2008-02-26 17:57 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-02-25 13:26 regression: 2f569af (CONFIG_HIGHPTE vs. sub-page page tables.) Uwe Kleine-König
2008-02-25 13:38 ` Russell King
2008-02-25 15:32 ` Uwe Kleine-König
2008-02-25 15:45 ` let __dec_zone_page_state use __dec_zone_state Uwe Kleine-König
2008-02-27 19:10 ` Christoph Lameter
2008-02-29 7:45 ` Uwe Kleine-König
2008-02-29 19:32 ` Christoph Lameter
2008-02-25 16:56 ` regression: 2f569af (CONFIG_HIGHPTE vs. sub-page page tables.) Martin Schwidefsky
2008-02-26 14:38 ` Uwe Kleine-König
2008-02-26 17:57 ` Martin Schwidefsky [this message]
2008-02-26 19:49 ` Russell King
2008-02-27 12:44 ` Uwe Kleine-König
2008-02-27 14:21 ` Martin Schwidefsky
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=1204048666.21725.6.camel@localhost \
--to=schwidefsky@de.ibm.com \
--cc=Uwe.Kleine-Koenig@digi.com \
--cc=akpm@linux-foundation.org \
--cc=linux-arch@vger.kernel.org \
--cc=torvalds@linux-foundation.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