From: David Gibson <dwg@au1.ibm.com>
To: Dave Hansen <haveblue@us.ibm.com>
Cc: Badari Pulavarty <pbadari@us.ibm.com>,
Andy Whitcroft <andyw@uk.ibm.com>,
lkml <linux-kernel@vger.kernel.org>,
"ADAM G. LITKE [imap]" <agl@us.ibm.com>
Subject: Re: 2.6.15-rc4 panic in __nr_to_section() with CONFIG_SPARSEMEM
Date: Fri, 9 Dec 2005 10:48:41 +1100 [thread overview]
Message-ID: <20051208234841.GA30254@localhost.localdomain> (raw)
In-Reply-To: <1134069335.6159.21.camel@localhost>
On Thu, Dec 08, 2005 at 11:15:35AM -0800, Dave Hansen wrote:
> On Thu, 2005-12-08 at 08:07 -0800, Badari Pulavarty wrote:
> > No. It doesn't help. It looks like ppc pmd_huge() always returns 0.
> > Don't know why ? :(
>
> The ppc64 hugetlb pages don't line up on PMD boundaries like they do on
> i386. The entries are stored in regular old PTEs.
>
> I really don't like coding the two different hugetlb cases, but I can't
> think of a better way to do it. Anyone care to test on ppc64?
> - mss->resident += PAGE_SIZE;
> + page_size = PAGE_SIZE;
> + if (is_hugepage_only_range(vma->vm_mm, addr, end - addr))
> + page_size = HPAGE_SIZE;
This is an incorrect usage of is_hugepage_only_range(). Although it
will get the right answer by accident here, that function should
*only* be used for testing whether a range is suitable for normal
pages, never for determining if hugepages are actually in use here.
You have the VMA here, so test its flag instead here.
--
David Gibson | I'll have my music baroque, and my code
david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_
| _way_ _around_!
http://www.ozlabs.org/~dgibson
next prev parent reply other threads:[~2005-12-08 23:55 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-12-07 22:37 2.6.15-rc4 panic in __nr_to_section() with CONFIG_SPARSEMEM Badari Pulavarty
2005-12-07 22:52 ` Dave Hansen
2005-12-07 23:05 ` Andy Whitcroft
2005-12-07 23:22 ` Badari Pulavarty
2005-12-07 23:34 ` Dave Hansen
2005-12-08 0:48 ` Dave Hansen
2005-12-08 16:07 ` Badari Pulavarty
2005-12-08 19:15 ` Dave Hansen
2005-12-08 19:33 ` Hugh Dickins
2005-12-08 19:47 ` Dave Hansen
2005-12-08 19:53 ` Badari Pulavarty
2005-12-08 23:48 ` David Gibson [this message]
2005-12-09 0:16 ` Dave Hansen
2005-12-12 16:19 ` Badari Pulavarty
2005-12-12 21:28 ` Dave Hansen
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=20051208234841.GA30254@localhost.localdomain \
--to=dwg@au1.ibm.com \
--cc=agl@us.ibm.com \
--cc=andyw@uk.ibm.com \
--cc=haveblue@us.ibm.com \
--cc=linux-kernel@vger.kernel.org \
--cc=pbadari@us.ibm.com \
/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