lkml.org 
[lkml]   [2008]   [Mar]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
SubjectRe: [RFC] use realmode code to reserve end-of-conventional-memory to 1MB
From
Date
On Thu, 2008-02-28 at 23:16 +0000, Ian Campbell wrote:
> On Thu, 2008-02-28 at 13:14 -0800, H. Peter Anvin wrote:
> >
> > You need to set up your memory map more sensibly; it's not just the
> > kernel, user space tries to access these areas too.
>
> Agreed, I think it's pure luck that Xen kernels have gotten away with it
> in the past.
>
> The patch below seems like the right thing to do. It certainly boots in
> a domU without the DMI problem (without any of the other related patches
> such as Alexander's).

Yep, this patch on its own fixes 2.6.25-rc3 DomU boot for me here.

> x86/xen: Construct e820 map with a hole between 640K-1M.
>
> Signed-off-by: Ian Campbell <ijc@hellion.org.uk>
> Cc: Thomas Gleixner <tglx@linutronix.de>
> Cc: Ingo Molnar <mingo@redhat.com>
> Cc: H. Peter Anvin <hpa@zytor.com>
> Cc: Jeremy Fitzhardinge <jeremy@goop.org>
> ---
> arch/x86/xen/setup.c | 3 ++-
> 1 files changed, 2 insertions(+), 1 deletions(-)
>
> diff --git a/arch/x86/xen/setup.c b/arch/x86/xen/setup.c
> index 3bad477..2341492 100644
> --- a/arch/x86/xen/setup.c
> +++ b/arch/x86/xen/setup.c
> @@ -38,7 +38,8 @@ char * __init xen_memory_setup(void)
> unsigned long max_pfn = xen_start_info->nr_pages;
>
> e820.nr_map = 0;
> - add_memory_region(0, PFN_PHYS(max_pfn), E820_RAM);
> + add_memory_region(0, LOWMEMSIZE(), E820_RAM);
> + add_memory_region(HIGH_MEMORY, PFN_PHYS(max_pfn)-HIGH_MEMORY, E820_RAM);

Seems to me to be the right thing to do ...

Acked-by: Mark McLoughlin <markmc@redhat.com>

Cheers,
Mark.



\
 
 \ /
  Last update: 2008-03-04 12:45    [W:1.946 / U:0.104 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site