All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] x86: Move crashkernel reservation before dma32_reserve_bootmem()
@ 2008-07-13 18:49 Bernhard Walle
  2008-07-14  2:43 ` Ken'ichi Ohmichi
  2008-07-14 13:30 ` Vivek Goyal
  0 siblings, 2 replies; 13+ messages in thread
From: Bernhard Walle @ 2008-07-13 18:49 UTC (permalink / raw)
  To: x86; +Cc: akpm, Bernhard Walle, kexec, Bernhard Walle, vgoyal

From: Bernhard Walle <bernhard.walle@gmx.de>

On a x86-64 machine (nothing special I could encounter) I had the problem that
crashkernel reservation with the usual "64M@16M" failed. While debugging that,
I encountered that dma32_reserve_bootmem() reserves a memory region which is in
that area.

Because dma32_reserve_bootmem() does not rely on a specific offset but
crashkernel does, it makes sense to move the crashkernel reservation up a bit.
I tested that patch and it works without problems. I don't see any negative
effects of that move, but maybe I oversaw something ...

While the long-term solution is to make the crashkernel reservation dynamic
(which is already done in -tip), this bug should be fixed also short-term for
2.6.26 (or 2.6.26-stable if it's too short), and that's why I made that patch.


Signed-off-by: Bernhard Walle <bwalle@suse.de>
Signed-off-by: Bernhard Walle <bernhard.walle@gmx.de>
---
 arch/x86/kernel/setup_64.c |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletions(-)

diff --git a/arch/x86/kernel/setup_64.c b/arch/x86/kernel/setup_64.c
index 6dff128..158cefe 100644
--- a/arch/x86/kernel/setup_64.c
+++ b/arch/x86/kernel/setup_64.c
@@ -444,6 +444,12 @@ void __init setup_arch(char **cmdline_p)
 	contig_initmem_init(0, end_pfn);
 #endif
 
+	/*
+	 * dma32_reserve_bootmem() allocates bootmem which may conflict
+	 * with the crashkernel command line, so do that before
+	 */
+	reserve_crashkernel();
+
 	dma32_reserve_bootmem();
 
 #ifdef CONFIG_ACPI_SLEEP
@@ -484,7 +490,6 @@ void __init setup_arch(char **cmdline_p)
 		}
 	}
 #endif
-	reserve_crashkernel();
 
 	reserve_ibft_region();
 
-- 
1.5.6.2


_______________________________________________
kexec mailing list
kexec@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/kexec

^ permalink raw reply related	[flat|nested] 13+ messages in thread

* Re: [PATCH] x86: Move crashkernel reservation before dma32_reserve_bootmem()
  2008-07-13 18:49 [PATCH] x86: Move crashkernel reservation before dma32_reserve_bootmem() Bernhard Walle
@ 2008-07-14  2:43 ` Ken'ichi Ohmichi
  2008-07-14 13:30 ` Vivek Goyal
  1 sibling, 0 replies; 13+ messages in thread
From: Ken'ichi Ohmichi @ 2008-07-14  2:43 UTC (permalink / raw)
  To: Bernhard Walle; +Cc: Bernhard Walle, akpm, x86, kexec, vgoyal

[-- Attachment #1: Type: text/plain, Size: 3952 bytes --]


Hi,

Bernhard Walle wrote:
> From: Bernhard Walle <bernhard.walle@gmx.de>
> 
> On a x86-64 machine (nothing special I could encounter) I had the problem that
> crashkernel reservation with the usual "64M@16M" failed. While debugging that,
> I encountered that dma32_reserve_bootmem() reserves a memory region which is in
> that area.

I tested your patch on x86_64 linux-2.6.26, and it works fine.
Good catching, Bernhard :-)


Before applying Bernhard's patch, kernel output the following message
and could not reserve the memory area for kdump. So kdump did not work.

 Jul 14 11:15:48 localhost kernel: Bootmem setup node 0 0000000000000000-0000000170000000
 Jul 14 11:15:48 localhost kdump: No crashkernel parameter specified for running kernel
 Jul 14 11:15:48 localhost kernel:   NODE_DATA [000000000000f000 - 0000000000014fff]
 Jul 14 11:15:48 localhost kdump: failed to start up
 Jul 14 11:15:48 localhost kernel:   bootmap [0000000000015000 -  0000000000042fff] pages 2e
 Jul 14 11:15:48 localhost kernel:   early res: 0 [0-fff] BIOS data page
 Jul 14 11:15:48 localhost kernel:   early res: 1 [6000-7fff] TRAMPOLINE
 Jul 14 11:15:48 localhost kernel:   early res: 2 [200000-9b1c97] TEXT DATA BSS
 Jul 14 11:15:48 localhost kernel:   early res: 3 [37ce4000-37fef146] RAMDISK
 Jul 14 11:15:48 localhost kernel:   early res: 4 [9b400-fffff] BIOS reserved
 Jul 14 11:15:48 localhost kernel:   early res: 5 [8000-efff] PGTABLE
 Jul 14 11:15:48 localhost kernel: crashkernel reservation failed - memory is in use

After applying Bernhard's patch, kernel outputs the following message,
and kdump works.

 Jul 14 11:27:39 localhost kernel: Bootmem setup node 0 0000000000000000-0000000170000000
 Jul 14 11:27:39 localhost kernel:   NODE_DATA [000000000000f000 - 0000000000014fff]
 Jul 14 11:27:39 localhost kernel:   bootmap [0000000000015000 -  0000000000042fff] pages 2e
 Jul 14 11:27:39 localhost kernel:   early res: 0 [0-fff] BIOS data page
 Jul 14 11:27:39 localhost kernel:   early res: 1 [6000-7fff] TRAMPOLINE
 Jul 14 11:27:39 localhost kernel:   early res: 2 [200000-9b1c97] TEXT DATA BSS
 Jul 14 11:27:39 localhost kernel:   early res: 3 [37ce4000-37fef14a] RAMDISK
 Jul 14 11:27:39 localhost kernel:   early res: 4 [9b400-fffff] BIOS reserved
 Jul 14 11:27:39 localhost kernel:   early res: 5 [8000-efff] PGTABLE
 Jul 14 11:27:39 localhost kernel: Reserving 128MB of memory at 16MB for crashkernel (System RAM: 5888MB)


> Because dma32_reserve_bootmem() does not rely on a specific offset but
> crashkernel does, it makes sense to move the crashkernel reservation up a bit.
> I tested that patch and it works without problems. I don't see any negative
> effects of that move, but maybe I oversaw something ...
> 
> While the long-term solution is to make the crashkernel reservation dynamic
> (which is already done in -tip), this bug should be fixed also short-term for
> 2.6.26 (or 2.6.26-stable if it's too short), and that's why I made that patch.

I hope so.


> Signed-off-by: Bernhard Walle <bwalle@suse.de>
> Signed-off-by: Bernhard Walle <bernhard.walle@gmx.de>

Tested-by: Ken'ichi Ohmichi <oomichi@mxs.nes.nec.co.jp>


Thanks
Ken'ichi Ohmichi


> ---
>  arch/x86/kernel/setup_64.c |    7 ++++++-
>  1 files changed, 6 insertions(+), 1 deletions(-)
> 
> diff --git a/arch/x86/kernel/setup_64.c b/arch/x86/kernel/setup_64.c
> index 6dff128..158cefe 100644
> --- a/arch/x86/kernel/setup_64.c
> +++ b/arch/x86/kernel/setup_64.c
> @@ -444,6 +444,12 @@ void __init setup_arch(char **cmdline_p)
>  	contig_initmem_init(0, end_pfn);
>  #endif
>  
> +	/*
> +	 * dma32_reserve_bootmem() allocates bootmem which may conflict
> +	 * with the crashkernel command line, so do that before
> +	 */
> +	reserve_crashkernel();
> +
>  	dma32_reserve_bootmem();
>  
>  #ifdef CONFIG_ACPI_SLEEP
> @@ -484,7 +490,6 @@ void __init setup_arch(char **cmdline_p)
>  		}
>  	}
>  #endif
> -	reserve_crashkernel();
>  
>  	reserve_ibft_region();
>  




[-- Attachment #2: Type: text/plain, Size: 143 bytes --]

_______________________________________________
kexec mailing list
kexec@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/kexec

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [PATCH] x86: Move crashkernel reservation before dma32_reserve_bootmem()
  2008-07-13 18:49 [PATCH] x86: Move crashkernel reservation before dma32_reserve_bootmem() Bernhard Walle
  2008-07-14  2:43 ` Ken'ichi Ohmichi
@ 2008-07-14 13:30 ` Vivek Goyal
  2008-07-14 13:37   ` Bernhard Walle
  1 sibling, 1 reply; 13+ messages in thread
From: Vivek Goyal @ 2008-07-14 13:30 UTC (permalink / raw)
  To: Bernhard Walle; +Cc: Bernhard Walle, akpm, x86, kexec

On Sun, Jul 13, 2008 at 08:49:44PM +0200, Bernhard Walle wrote:
> From: Bernhard Walle <bernhard.walle@gmx.de>
> 
> On a x86-64 machine (nothing special I could encounter) I had the problem that
> crashkernel reservation with the usual "64M@16M" failed. While debugging that,
> I encountered that dma32_reserve_bootmem() reserves a memory region which is in
> that area.
> 
> Because dma32_reserve_bootmem() does not rely on a specific offset but
> crashkernel does, it makes sense to move the crashkernel reservation up a bit.
> I tested that patch and it works without problems. I don't see any negative
> effects of that move, but maybe I oversaw something ...
> 
> While the long-term solution is to make the crashkernel reservation dynamic
> (which is already done in -tip), this bug should be fixed also short-term for
> 2.6.26 (or 2.6.26-stable if it's too short), and that's why I made that patch.
> 
> 
> Signed-off-by: Bernhard Walle <bwalle@suse.de>
> Signed-off-by: Bernhard Walle <bernhard.walle@gmx.de>
> ---
>  arch/x86/kernel/setup_64.c |    7 ++++++-
>  1 files changed, 6 insertions(+), 1 deletions(-)
> 
> diff --git a/arch/x86/kernel/setup_64.c b/arch/x86/kernel/setup_64.c
> index 6dff128..158cefe 100644
> --- a/arch/x86/kernel/setup_64.c
> +++ b/arch/x86/kernel/setup_64.c
> @@ -444,6 +444,12 @@ void __init setup_arch(char **cmdline_p)
>  	contig_initmem_init(0, end_pfn);
>  #endif
>  
> +	/*
> +	 * dma32_reserve_bootmem() allocates bootmem which may conflict
> +	 * with the crashkernel command line, so do that before
> +	 */
> +	reserve_crashkernel();
> +
>  	dma32_reserve_bootmem();
>  
>  #ifdef CONFIG_ACPI_SLEEP
> @@ -484,7 +490,6 @@ void __init setup_arch(char **cmdline_p)
>  		}
>  	}
>  #endif
> -	reserve_crashkernel();
>  
>  	reserve_ibft_region();

Looks good to me. 

Acked-by: Vivek Goyal <vgoyal@redhat.com>

Thanks
Vivek

_______________________________________________
kexec mailing list
kexec@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/kexec

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [PATCH] x86: Move crashkernel reservation before dma32_reserve_bootmem()
  2008-07-14 13:30 ` Vivek Goyal
@ 2008-07-14 13:37   ` Bernhard Walle
  2008-07-17  7:30     ` Greg KH
  0 siblings, 1 reply; 13+ messages in thread
From: Bernhard Walle @ 2008-07-14 13:37 UTC (permalink / raw)
  To: Vivek Goyal; +Cc: akpm, Bernhard Walle, kexec, x86, gregkh

* Vivek Goyal [2008-07-14 09:30]:
>
> On Sun, Jul 13, 2008 at 08:49:44PM +0200, Bernhard Walle wrote:
> > From: Bernhard Walle <bernhard.walle@gmx.de>
> > 
> > On a x86-64 machine (nothing special I could encounter) I had the problem that
> > crashkernel reservation with the usual "64M@16M" failed. While debugging that,
> > I encountered that dma32_reserve_bootmem() reserves a memory region which is in
> > that area.
> > 
> > Because dma32_reserve_bootmem() does not rely on a specific offset but
> > crashkernel does, it makes sense to move the crashkernel reservation up a bit.
> > I tested that patch and it works without problems. I don't see any negative
> > effects of that move, but maybe I oversaw something ...
> > 
> > While the long-term solution is to make the crashkernel reservation dynamic
> > (which is already done in -tip), this bug should be fixed also short-term for
> > 2.6.26 (or 2.6.26-stable if it's too short), and that's why I made that patch.
> > 
> > 
> > Signed-off-by: Bernhard Walle <bwalle@suse.de>
> > Signed-off-by: Bernhard Walle <bernhard.walle@gmx.de>
> > ---
> >  arch/x86/kernel/setup_64.c |    7 ++++++-
> >  1 files changed, 6 insertions(+), 1 deletions(-)
> > 
> > diff --git a/arch/x86/kernel/setup_64.c b/arch/x86/kernel/setup_64.c
> > index 6dff128..158cefe 100644
> > --- a/arch/x86/kernel/setup_64.c
> > +++ b/arch/x86/kernel/setup_64.c
> > @@ -444,6 +444,12 @@ void __init setup_arch(char **cmdline_p)
> >  	contig_initmem_init(0, end_pfn);
> >  #endif
> >  
> > +	/*
> > +	 * dma32_reserve_bootmem() allocates bootmem which may conflict
> > +	 * with the crashkernel command line, so do that before
> > +	 */
> > +	reserve_crashkernel();
> > +
> >  	dma32_reserve_bootmem();
> >  
> >  #ifdef CONFIG_ACPI_SLEEP
> > @@ -484,7 +490,6 @@ void __init setup_arch(char **cmdline_p)
> >  		}
> >  	}
> >  #endif
> > -	reserve_crashkernel();
> >  
> >  	reserve_ibft_region();
> 
> Looks good to me. 
> 
> Acked-by: Vivek Goyal <vgoyal@redhat.com>

Greg,

would that be something for -stable?


Bernhard
-- 
Bernhard Walle, SUSE LINUX Products GmbH, Architecture Development

_______________________________________________
kexec mailing list
kexec@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/kexec

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [PATCH] x86: Move crashkernel reservation before dma32_reserve_bootmem()
  2008-07-14 13:37   ` Bernhard Walle
@ 2008-07-17  7:30     ` Greg KH
  0 siblings, 0 replies; 13+ messages in thread
From: Greg KH @ 2008-07-17  7:30 UTC (permalink / raw)
  To: Bernhard Walle; +Cc: akpm, Bernhard Walle, kexec, x86, Vivek Goyal

On Mon, Jul 14, 2008 at 03:37:24PM +0200, Bernhard Walle wrote:
> * Vivek Goyal [2008-07-14 09:30]:
> >
> > On Sun, Jul 13, 2008 at 08:49:44PM +0200, Bernhard Walle wrote:
> > > From: Bernhard Walle <bernhard.walle@gmx.de>
> > > 
> > > On a x86-64 machine (nothing special I could encounter) I had the problem that
> > > crashkernel reservation with the usual "64M@16M" failed. While debugging that,
> > > I encountered that dma32_reserve_bootmem() reserves a memory region which is in
> > > that area.
> > > 
> > > Because dma32_reserve_bootmem() does not rely on a specific offset but
> > > crashkernel does, it makes sense to move the crashkernel reservation up a bit.
> > > I tested that patch and it works without problems. I don't see any negative
> > > effects of that move, but maybe I oversaw something ...
> > > 
> > > While the long-term solution is to make the crashkernel reservation dynamic
> > > (which is already done in -tip), this bug should be fixed also short-term for
> > > 2.6.26 (or 2.6.26-stable if it's too short), and that's why I made that patch.
> > > 
> > > 
> > > Signed-off-by: Bernhard Walle <bwalle@suse.de>
> > > Signed-off-by: Bernhard Walle <bernhard.walle@gmx.de>
> > > ---
> > >  arch/x86/kernel/setup_64.c |    7 ++++++-
> > >  1 files changed, 6 insertions(+), 1 deletions(-)
> > > 
> > > diff --git a/arch/x86/kernel/setup_64.c b/arch/x86/kernel/setup_64.c
> > > index 6dff128..158cefe 100644
> > > --- a/arch/x86/kernel/setup_64.c
> > > +++ b/arch/x86/kernel/setup_64.c
> > > @@ -444,6 +444,12 @@ void __init setup_arch(char **cmdline_p)
> > >  	contig_initmem_init(0, end_pfn);
> > >  #endif
> > >  
> > > +	/*
> > > +	 * dma32_reserve_bootmem() allocates bootmem which may conflict
> > > +	 * with the crashkernel command line, so do that before
> > > +	 */
> > > +	reserve_crashkernel();
> > > +
> > >  	dma32_reserve_bootmem();
> > >  
> > >  #ifdef CONFIG_ACPI_SLEEP
> > > @@ -484,7 +490,6 @@ void __init setup_arch(char **cmdline_p)
> > >  		}
> > >  	}
> > >  #endif
> > > -	reserve_crashkernel();
> > >  
> > >  	reserve_ibft_region();
> > 
> > Looks good to me. 
> > 
> > Acked-by: Vivek Goyal <vgoyal@redhat.com>
> 
> Greg,
> 
> would that be something for -stable?

If it affects 2.6.25 or 2.6.26, yes, it would be.  Just send it to
stable@kernel.org and we can take it from there as long as it is
accepted already into Linus's tree.

thanks,

greg k-h

_______________________________________________
kexec mailing list
kexec@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/kexec

^ permalink raw reply	[flat|nested] 13+ messages in thread

* [PATCH] x86: Move crashkernel reservation before dma32_reserve_bootmem()
@ 2008-07-17 22:15 ` Bernhard Walle
  0 siblings, 0 replies; 13+ messages in thread
From: Bernhard Walle @ 2008-07-17 22:15 UTC (permalink / raw)
  To: x86; +Cc: akpm, kexec, linux-kernel, vgoyal, Bernhard Walle

On a x86-64 machine (nothing special I could encounter) I had the problem that
crashkernel reservation with the usual "64M@16M" failed. While debugging that,
I encountered that dma32_reserve_bootmem() reserves a memory region which is in
that area.

Because dma32_reserve_bootmem() does not rely on a specific offset but
crashkernel does, it makes sense to move the crashkernel reservation up a bit.
I tested that patch and it works without problems. I don't see any negative
effects of that move, but maybe I oversaw something ...

While we strictly don't need that patch in 2.6.27 because we have the
automatic, dynamic offset detection, it makes sense to also include it here
because:

  - it's easier to get it in -stable then,
  - many people are still used to the 'crashkernel=...@16M' syntax,
  - not everybody may be using a reloatable kernel.

Signed-off-by: Bernhard Walle <bwalle@suse.de>
---
 arch/x86/kernel/setup.c |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletions(-)

diff --git a/arch/x86/kernel/setup.c b/arch/x86/kernel/setup.c
index 531b55b..16101c0 100644
--- a/arch/x86/kernel/setup.c
+++ b/arch/x86/kernel/setup.c
@@ -792,6 +792,12 @@ void __init setup_arch(char **cmdline_p)
 
 	initmem_init(0, max_pfn);
 
+	/*
+	 * dma32_reserve_bootmem() allocates bootmem which may conflict
+	 * with the crashkernel command line, so do that before
+	 */
+	reserve_crashkernel();
+
 #ifdef CONFIG_X86_64
 	dma32_reserve_bootmem();
 #endif
@@ -808,7 +814,6 @@ void __init setup_arch(char **cmdline_p)
 	 */
 	find_smp_config();
 #endif
-	reserve_crashkernel();
 
 	reserve_ibft_region();
 
-- 
1.5.6


_______________________________________________
kexec mailing list
kexec@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/kexec

^ permalink raw reply related	[flat|nested] 13+ messages in thread

* [PATCH] x86: Move crashkernel reservation before dma32_reserve_bootmem()
@ 2008-07-17 22:15 ` Bernhard Walle
  0 siblings, 0 replies; 13+ messages in thread
From: Bernhard Walle @ 2008-07-17 22:15 UTC (permalink / raw)
  To: x86; +Cc: vgoyal, linux-kernel, kexec, akpm, Bernhard Walle

On a x86-64 machine (nothing special I could encounter) I had the problem that
crashkernel reservation with the usual "64M@16M" failed. While debugging that,
I encountered that dma32_reserve_bootmem() reserves a memory region which is in
that area.

Because dma32_reserve_bootmem() does not rely on a specific offset but
crashkernel does, it makes sense to move the crashkernel reservation up a bit.
I tested that patch and it works without problems. I don't see any negative
effects of that move, but maybe I oversaw something ...

While we strictly don't need that patch in 2.6.27 because we have the
automatic, dynamic offset detection, it makes sense to also include it here
because:

  - it's easier to get it in -stable then,
  - many people are still used to the 'crashkernel=...@16M' syntax,
  - not everybody may be using a reloatable kernel.

Signed-off-by: Bernhard Walle <bwalle@suse.de>
---
 arch/x86/kernel/setup.c |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletions(-)

diff --git a/arch/x86/kernel/setup.c b/arch/x86/kernel/setup.c
index 531b55b..16101c0 100644
--- a/arch/x86/kernel/setup.c
+++ b/arch/x86/kernel/setup.c
@@ -792,6 +792,12 @@ void __init setup_arch(char **cmdline_p)
 
 	initmem_init(0, max_pfn);
 
+	/*
+	 * dma32_reserve_bootmem() allocates bootmem which may conflict
+	 * with the crashkernel command line, so do that before
+	 */
+	reserve_crashkernel();
+
 #ifdef CONFIG_X86_64
 	dma32_reserve_bootmem();
 #endif
@@ -808,7 +814,6 @@ void __init setup_arch(char **cmdline_p)
 	 */
 	find_smp_config();
 #endif
-	reserve_crashkernel();
 
 	reserve_ibft_region();
 
-- 
1.5.6


^ permalink raw reply related	[flat|nested] 13+ messages in thread

* Re: [PATCH] x86: Move crashkernel reservation before dma32_reserve_bootmem()
  2008-07-17 22:15 ` Bernhard Walle
@ 2008-07-17 22:50   ` Yinghai Lu
  -1 siblings, 0 replies; 13+ messages in thread
From: Yinghai Lu @ 2008-07-17 22:50 UTC (permalink / raw)
  To: Bernhard Walle; +Cc: akpm, x86, kexec, linux-kernel, vgoyal

On Thu, Jul 17, 2008 at 3:15 PM, Bernhard Walle <bwalle@suse.de> wrote:
> On a x86-64 machine (nothing special I could encounter) I had the problem that
> crashkernel reservation with the usual "64M@16M" failed. While debugging that,
> I encountered that dma32_reserve_bootmem() reserves a memory region which is in
> that area.
>
> Because dma32_reserve_bootmem() does not rely on a specific offset but
> crashkernel does, it makes sense to move the crashkernel reservation up a bit.
> I tested that patch and it works without problems. I don't see any negative
> effects of that move, but maybe I oversaw something ...
>
> While we strictly don't need that patch in 2.6.27 because we have the
> automatic, dynamic offset detection, it makes sense to also include it here
> because:
>
>  - it's easier to get it in -stable then,
>  - many people are still used to the 'crashkernel=...@16M' syntax,
>  - not everybody may be using a reloatable kernel.
>
> Signed-off-by: Bernhard Walle <bwalle@suse.de>
> ---
>  arch/x86/kernel/setup.c |    7 ++++++-
>  1 files changed, 6 insertions(+), 1 deletions(-)
>
> diff --git a/arch/x86/kernel/setup.c b/arch/x86/kernel/setup.c
> index 531b55b..16101c0 100644
> --- a/arch/x86/kernel/setup.c
> +++ b/arch/x86/kernel/setup.c
> @@ -792,6 +792,12 @@ void __init setup_arch(char **cmdline_p)
>
>        initmem_init(0, max_pfn);
>
> +       /*
> +        * dma32_reserve_bootmem() allocates bootmem which may conflict
> +        * with the crashkernel command line, so do that before
> +        */
> +       reserve_crashkernel();
> +
>  #ifdef CONFIG_X86_64
>        dma32_reserve_bootmem();
>  #endif
> @@ -808,7 +814,6 @@ void __init setup_arch(char **cmdline_p)
>         */
>        find_smp_config();
>  #endif
> -       reserve_crashkernel();
>
>        reserve_ibft_region();
>

Joe Jin already had another one to move dma32_reserve_bootmem later

YH

_______________________________________________
kexec mailing list
kexec@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/kexec

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [PATCH] x86: Move crashkernel reservation before dma32_reserve_bootmem()
@ 2008-07-17 22:50   ` Yinghai Lu
  0 siblings, 0 replies; 13+ messages in thread
From: Yinghai Lu @ 2008-07-17 22:50 UTC (permalink / raw)
  To: Bernhard Walle; +Cc: x86, vgoyal, linux-kernel, kexec, akpm

On Thu, Jul 17, 2008 at 3:15 PM, Bernhard Walle <bwalle@suse.de> wrote:
> On a x86-64 machine (nothing special I could encounter) I had the problem that
> crashkernel reservation with the usual "64M@16M" failed. While debugging that,
> I encountered that dma32_reserve_bootmem() reserves a memory region which is in
> that area.
>
> Because dma32_reserve_bootmem() does not rely on a specific offset but
> crashkernel does, it makes sense to move the crashkernel reservation up a bit.
> I tested that patch and it works without problems. I don't see any negative
> effects of that move, but maybe I oversaw something ...
>
> While we strictly don't need that patch in 2.6.27 because we have the
> automatic, dynamic offset detection, it makes sense to also include it here
> because:
>
>  - it's easier to get it in -stable then,
>  - many people are still used to the 'crashkernel=...@16M' syntax,
>  - not everybody may be using a reloatable kernel.
>
> Signed-off-by: Bernhard Walle <bwalle@suse.de>
> ---
>  arch/x86/kernel/setup.c |    7 ++++++-
>  1 files changed, 6 insertions(+), 1 deletions(-)
>
> diff --git a/arch/x86/kernel/setup.c b/arch/x86/kernel/setup.c
> index 531b55b..16101c0 100644
> --- a/arch/x86/kernel/setup.c
> +++ b/arch/x86/kernel/setup.c
> @@ -792,6 +792,12 @@ void __init setup_arch(char **cmdline_p)
>
>        initmem_init(0, max_pfn);
>
> +       /*
> +        * dma32_reserve_bootmem() allocates bootmem which may conflict
> +        * with the crashkernel command line, so do that before
> +        */
> +       reserve_crashkernel();
> +
>  #ifdef CONFIG_X86_64
>        dma32_reserve_bootmem();
>  #endif
> @@ -808,7 +814,6 @@ void __init setup_arch(char **cmdline_p)
>         */
>        find_smp_config();
>  #endif
> -       reserve_crashkernel();
>
>        reserve_ibft_region();
>

Joe Jin already had another one to move dma32_reserve_bootmem later

YH

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [PATCH] x86: Move crashkernel reservation before dma32_reserve_bootmem()
  2008-07-17 22:50   ` Yinghai Lu
@ 2008-07-18  9:52     ` Bernhard Walle
  -1 siblings, 0 replies; 13+ messages in thread
From: Bernhard Walle @ 2008-07-18  9:52 UTC (permalink / raw)
  To: Yinghai Lu; +Cc: akpm, x86, kexec, linux-kernel, vgoyal

* Yinghai Lu [2008-07-17 15:50]:
>
> > +       /*
> > +        * dma32_reserve_bootmem() allocates bootmem which may conflict
> > +        * with the crashkernel command line, so do that before
> > +        */
> > +       reserve_crashkernel();
> > +
> >  #ifdef CONFIG_X86_64
> >        dma32_reserve_bootmem();
> >  #endif
> > @@ -808,7 +814,6 @@ void __init setup_arch(char **cmdline_p)
> >         */
> >        find_smp_config();
> >  #endif
> > -       reserve_crashkernel();
> >
> >        reserve_ibft_region();
> 
> Joe Jin already had another one to move dma32_reserve_bootmem later

Commit id? Current status?


Bernhard
-- 
Bernhard Walle, SUSE LINUX Products GmbH, Architecture Development

_______________________________________________
kexec mailing list
kexec@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/kexec

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [PATCH] x86: Move crashkernel reservation before dma32_reserve_bootmem()
@ 2008-07-18  9:52     ` Bernhard Walle
  0 siblings, 0 replies; 13+ messages in thread
From: Bernhard Walle @ 2008-07-18  9:52 UTC (permalink / raw)
  To: Yinghai Lu; +Cc: akpm, x86, kexec, linux-kernel, vgoyal

* Yinghai Lu [2008-07-17 15:50]:
>
> > +       /*
> > +        * dma32_reserve_bootmem() allocates bootmem which may conflict
> > +        * with the crashkernel command line, so do that before
> > +        */
> > +       reserve_crashkernel();
> > +
> >  #ifdef CONFIG_X86_64
> >        dma32_reserve_bootmem();
> >  #endif
> > @@ -808,7 +814,6 @@ void __init setup_arch(char **cmdline_p)
> >         */
> >        find_smp_config();
> >  #endif
> > -       reserve_crashkernel();
> >
> >        reserve_ibft_region();
> 
> Joe Jin already had another one to move dma32_reserve_bootmem later

Commit id? Current status?


Bernhard
-- 
Bernhard Walle, SUSE LINUX Products GmbH, Architecture Development

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [PATCH] x86: Move crashkernel reservation before dma32_reserve_bootmem()
  2008-07-18  9:52     ` Bernhard Walle
@ 2008-07-18 16:22       ` Yinghai Lu
  -1 siblings, 0 replies; 13+ messages in thread
From: Yinghai Lu @ 2008-07-18 16:22 UTC (permalink / raw)
  To: Bernhard Walle; +Cc: akpm, x86, kexec, linux-kernel, vgoyal

On Fri, Jul 18, 2008 at 2:52 AM, Bernhard Walle <bwalle@suse.de> wrote:
> * Yinghai Lu [2008-07-17 15:50]:
>>
>> > +       /*
>> > +        * dma32_reserve_bootmem() allocates bootmem which may conflict
>> > +        * with the crashkernel command line, so do that before
>> > +        */
>> > +       reserve_crashkernel();
>> > +
>> >  #ifdef CONFIG_X86_64
>> >        dma32_reserve_bootmem();
>> >  #endif
>> > @@ -808,7 +814,6 @@ void __init setup_arch(char **cmdline_p)
>> >         */
>> >        find_smp_config();
>> >  #endif
>> > -       reserve_crashkernel();
>> >
>> >        reserve_ibft_region();
>>
>> Joe Jin already had another one to move dma32_reserve_bootmem later
>
> Commit id? Current status?

it seems commit description from you is more good.
please create one version move dma32_reserve_boot_mem after
reserve_crashkernel and use your commit description.

YH

_______________________________________________
kexec mailing list
kexec@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/kexec

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [PATCH] x86: Move crashkernel reservation before dma32_reserve_bootmem()
@ 2008-07-18 16:22       ` Yinghai Lu
  0 siblings, 0 replies; 13+ messages in thread
From: Yinghai Lu @ 2008-07-18 16:22 UTC (permalink / raw)
  To: Bernhard Walle; +Cc: akpm, x86, kexec, linux-kernel, vgoyal

On Fri, Jul 18, 2008 at 2:52 AM, Bernhard Walle <bwalle@suse.de> wrote:
> * Yinghai Lu [2008-07-17 15:50]:
>>
>> > +       /*
>> > +        * dma32_reserve_bootmem() allocates bootmem which may conflict
>> > +        * with the crashkernel command line, so do that before
>> > +        */
>> > +       reserve_crashkernel();
>> > +
>> >  #ifdef CONFIG_X86_64
>> >        dma32_reserve_bootmem();
>> >  #endif
>> > @@ -808,7 +814,6 @@ void __init setup_arch(char **cmdline_p)
>> >         */
>> >        find_smp_config();
>> >  #endif
>> > -       reserve_crashkernel();
>> >
>> >        reserve_ibft_region();
>>
>> Joe Jin already had another one to move dma32_reserve_bootmem later
>
> Commit id? Current status?

it seems commit description from you is more good.
please create one version move dma32_reserve_boot_mem after
reserve_crashkernel and use your commit description.

YH

^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2008-07-18 16:22 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-07-13 18:49 [PATCH] x86: Move crashkernel reservation before dma32_reserve_bootmem() Bernhard Walle
2008-07-14  2:43 ` Ken'ichi Ohmichi
2008-07-14 13:30 ` Vivek Goyal
2008-07-14 13:37   ` Bernhard Walle
2008-07-17  7:30     ` Greg KH
  -- strict thread matches above, loose matches on Subject: below --
2008-07-17 22:15 Bernhard Walle
2008-07-17 22:15 ` Bernhard Walle
2008-07-17 22:50 ` Yinghai Lu
2008-07-17 22:50   ` Yinghai Lu
2008-07-18  9:52   ` Bernhard Walle
2008-07-18  9:52     ` Bernhard Walle
2008-07-18 16:22     ` Yinghai Lu
2008-07-18 16:22       ` Yinghai Lu

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.