From: "Jan Beulich" <JBeulich@novell.com>
To: Keir Fraser <keir.fraser@eu.citrix.com>
Cc: MaoXiaoyun <tinnycloud@hotmail.com>,
xen devel <xen-devel@lists.xensource.com>
Subject: Re: Xen-unstable panic: FATAL PAGE FAULT
Date: Wed, 01 Sep 2010 08:54:02 +0100 [thread overview]
Message-ID: <4C7E22BA02000078000139D1@vpn.id2.novell.com> (raw)
In-Reply-To: <C8A2EDE0.21912%keir.fraser@eu.citrix.com>
>>> On 31.08.10 at 18:35, Keir Fraser <keir.fraser@eu.citrix.com> wrote:
> On 31/08/2010 17:22, "Jan Beulich" <JBeulich@novell.com> wrote:
>
>>> Where is even that constraint ensured in the code? I can't see it (I would
>>> have assumed that pfn_pdx_hole_setup() would be ensuring it).
>>
>> That's somewhat implicit: srat_parse_regions() gets passed an
>> address that is at least BOOTSTRAP_DIRECTMAP_END (i.e. 4G).
>> Thus srat_parse_regions() starts off with a mask with the lower
>> 32 bits all set (only more bits can get set subsequently). Thus
>> the earliest zero bit pfn_pdx_hole_setup() can find is bit 20
>> (due to the >> PAGE_SHIFT in the invocation). Consequently
>> the smallest chunk where arithmetic is valid really is 4Gb, not
>> 256Mb as I first wrote.
>
> Well, that's a bit too implicit for me. How about we initialise 'j' to
> MAX_ORDER in pfn_pdx_hole_setup() with a comment about supporting page_info
> pointer arithmetic within allocatable multi-page regions?
>
> Something like the appended (but with a code comment)?
Yes, that would seem reasonable (and not affecting current behavior).
Jan
> --- a/xen/arch/x86/x86_64/mm.c Mon Aug 30 14:59:12 2010 +0100
> +++ b/xen/arch/x86/x86_64/mm.c Tue Aug 31 17:34:34 2010 +0100
> @@ -165,7 +165,8 @@
> {
> unsigned int i, j, bottom_shift, hole_shift;
>
> - for ( hole_shift = bottom_shift = j = 0; ; )
> + hole_shift = bottom_shift = 0;
> + for ( j = MAX_ORDER-1; ; )
> {
> i = find_next_zero_bit(&mask, BITS_PER_LONG, j);
> j = find_next_bit(&mask, BITS_PER_LONG, i);
next prev parent reply other threads:[~2010-09-01 7:54 UTC|newest]
Thread overview: 39+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <SNT0-MC2-F12iKC1rdi000797d9@snt0-mc2-f12.Snt0.hotmail.com>
2010-08-26 4:49 ` Re:Re: Xen-unstable panic: FATAL PAGE FAULT MaoXiaoyun
2010-08-26 7:39 ` Keir Fraser
2010-08-26 8:59 ` MaoXiaoyun
2010-08-26 9:11 ` Keir Fraser
2010-08-30 8:47 ` MaoXiaoyun
2010-08-30 9:02 ` Keir Fraser
2010-08-30 13:03 ` MaoXiaoyun
2010-08-30 13:16 ` Keir Fraser
2010-08-31 13:49 ` MaoXiaoyun
2010-08-31 14:49 ` Keir Fraser
2010-08-31 15:00 ` Keir Fraser
2010-08-31 15:07 ` Jan Beulich
2010-08-31 16:01 ` Keir Fraser
2010-08-31 16:22 ` Jan Beulich
2010-08-31 16:35 ` Keir Fraser
2010-08-31 17:03 ` Keir Fraser
2010-09-01 7:17 ` MaoXiaoyun
2010-09-01 7:40 ` Keir Fraser
2010-09-01 8:05 ` Jan Beulich
2010-09-01 8:32 ` MaoXiaoyun
2010-09-01 8:02 ` Jan Beulich
2010-09-01 8:49 ` Keir Fraser
2010-09-01 9:01 ` Jan Beulich
2010-09-01 9:28 ` Keir Fraser
2010-09-01 9:48 ` MaoXiaoyun
2010-09-01 10:09 ` Jan Beulich
2010-09-01 9:06 ` MaoXiaoyun
2010-09-01 9:23 ` MaoXiaoyun
2010-09-01 9:58 ` Keir Fraser
2010-09-01 10:21 ` MaoXiaoyun
2010-09-01 10:25 ` Keir Fraser
2010-09-01 10:28 ` Keir Fraser
2010-09-01 10:34 ` Jan Beulich
2010-09-01 11:32 ` MaoXiaoyun
2010-09-01 7:54 ` Jan Beulich [this message]
2010-09-01 3:17 ` MaoXiaoyun
2010-02-06 22:56 Mark Hurenkamp
2010-02-07 11:56 ` Keir Fraser
2010-04-30 20:52 ` Bastian Blank
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=4C7E22BA02000078000139D1@vpn.id2.novell.com \
--to=jbeulich@novell.com \
--cc=keir.fraser@eu.citrix.com \
--cc=tinnycloud@hotmail.com \
--cc=xen-devel@lists.xensource.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;
as well as URLs for NNTP newsgroup(s).