* [PATCH] x86: keep the crash kernel below 896 MiB
@ 2013-04-25 8:57 Warner Wang
2013-04-25 9:51 ` Jan Beulich
2013-04-25 11:01 ` David Vrabel
0 siblings, 2 replies; 4+ messages in thread
From: Warner Wang @ 2013-04-25 8:57 UTC (permalink / raw)
To: keir, jbeulich; +Cc: Warner Wang, xen-devel
When use the crashkernel=size parameter without specifying a "@xM"
suffix, the crashkernel will be reserved at the highest suitable
address of memory, this will make the kexec-tools fail to work.
The current kexec-tools have a limitation that it can only work
with crashkernel reserved under 896 MiB. we can increase this
limit once kexec-tools are fixed.
Linux kernel itself have this code for kexec-tools limitation,
so I think Xen code should also have it.
Signed-off-by: Warner Wang <warner.wang@hp.com>
---
xen/arch/x86/setup.c | 7 +++++++
1 files changed, 7 insertions(+), 0 deletions(-)
diff --git a/xen/arch/x86/setup.c b/xen/arch/x86/setup.c
index 43301a5..ae4c947 100644
--- a/xen/arch/x86/setup.c
+++ b/xen/arch/x86/setup.c
@@ -943,6 +943,13 @@ void __init __start_xen(unsigned long mbi_p)
}
}
+ /*
+ * Keep the crash kernel below this limit. On 64 bits, kexec-tools
+ * currently limits us to 896 MiB; increase this limit once kexec-tools
+ * are fixed.
+ */
+ e = min_t(uint64_t, e, 896 << 20);
+
/* Don't overlap with modules. */
e = consider_modules(s, e, PAGE_ALIGN(kexec_crash_area.size),
mod, mbi->mods_count, -1);
--
1.7.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] x86: keep the crash kernel below 896 MiB
2013-04-25 8:57 [PATCH] x86: keep the crash kernel below 896 MiB Warner Wang
@ 2013-04-25 9:51 ` Jan Beulich
2013-04-25 10:48 ` Andrew Cooper
2013-04-25 11:01 ` David Vrabel
1 sibling, 1 reply; 4+ messages in thread
From: Jan Beulich @ 2013-04-25 9:51 UTC (permalink / raw)
To: Andrew Cooper, Warner Wang; +Cc: keir, xen-devel
>>> On 25.04.13 at 10:57, Warner Wang <warner.wang@hp.com> wrote:
> When use the crashkernel=size parameter without specifying a "@xM"
> suffix, the crashkernel will be reserved at the highest suitable
> address of memory, this will make the kexec-tools fail to work.
> The current kexec-tools have a limitation that it can only work
> with crashkernel reserved under 896 MiB. we can increase this
> limit once kexec-tools are fixed.
> Linux kernel itself have this code for kexec-tools limitation,
> so I think Xen code should also have it.
Andrew,
didn't you post something along those lines at some point too,
yet there was a reason it never got applied?
Jan
> --- a/xen/arch/x86/setup.c
> +++ b/xen/arch/x86/setup.c
> @@ -943,6 +943,13 @@ void __init __start_xen(unsigned long mbi_p)
> }
> }
>
> + /*
> + * Keep the crash kernel below this limit. On 64 bits, kexec-tools
> + * currently limits us to 896 MiB; increase this limit once kexec-tools
> + * are fixed.
> + */
> + e = min_t(uint64_t, e, 896 << 20);
> +
> /* Don't overlap with modules. */
> e = consider_modules(s, e, PAGE_ALIGN(kexec_crash_area.size),
> mod, mbi->mods_count, -1);
> --
> 1.7.1
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] x86: keep the crash kernel below 896 MiB
2013-04-25 9:51 ` Jan Beulich
@ 2013-04-25 10:48 ` Andrew Cooper
0 siblings, 0 replies; 4+ messages in thread
From: Andrew Cooper @ 2013-04-25 10:48 UTC (permalink / raw)
To: Jan Beulich, Warner Wang; +Cc: Keir (Xen.org), xen-devel@lists.xen.org
On 25/04/13 10:51, Jan Beulich wrote:
>>>> On 25.04.13 at 10:57, Warner Wang <warner.wang@hp.com> wrote:
>> When use the crashkernel=size parameter without specifying a "@xM"
>> suffix, the crashkernel will be reserved at the highest suitable
>> address of memory, this will make the kexec-tools fail to work.
>> The current kexec-tools have a limitation that it can only work
>> with crashkernel reserved under 896 MiB. we can increase this
>> limit once kexec-tools are fixed.
>> Linux kernel itself have this code for kexec-tools limitation,
>> so I think Xen code should also have it.
> Andrew,
>
> didn't you post something along those lines at some point too,
> yet there was a reason it never got applied?
>
> Jan
Jan:
I have some low crashinfo patches but they are in. It was for
positioning of the Xen per-cpu crash notes and the console ring.
Warner:
I am curious to know what this magic 896MiB limit is. Do you have a
reference to the problem.
~Andrew
>
>> --- a/xen/arch/x86/setup.c
>> +++ b/xen/arch/x86/setup.c
>> @@ -943,6 +943,13 @@ void __init __start_xen(unsigned long mbi_p)
>> }
>> }
>>
>> + /*
>> + * Keep the crash kernel below this limit. On 64 bits, kexec-tools
>> + * currently limits us to 896 MiB; increase this limit once kexec-tools
>> + * are fixed.
>> + */
>> + e = min_t(uint64_t, e, 896 << 20);
>> +
>> /* Don't overlap with modules. */
>> e = consider_modules(s, e, PAGE_ALIGN(kexec_crash_area.size),
>> mod, mbi->mods_count, -1);
>> --
>> 1.7.1
>
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] x86: keep the crash kernel below 896 MiB
2013-04-25 8:57 [PATCH] x86: keep the crash kernel below 896 MiB Warner Wang
2013-04-25 9:51 ` Jan Beulich
@ 2013-04-25 11:01 ` David Vrabel
1 sibling, 0 replies; 4+ messages in thread
From: David Vrabel @ 2013-04-25 11:01 UTC (permalink / raw)
To: Warner Wang; +Cc: keir, jbeulich, xen-devel
On 25/04/13 09:57, Warner Wang wrote:
> When use the crashkernel=size parameter without specifying a "@xM"
> suffix, the crashkernel will be reserved at the highest suitable
> address of memory, this will make the kexec-tools fail to work.
> The current kexec-tools have a limitation that it can only work
> with crashkernel reserved under 896 MiB. we can increase this
> limit once kexec-tools are fixed.
> Linux kernel itself have this code for kexec-tools limitation,
> so I think Xen code should also have it.
I don't think we should limit Xen in this way for any particular tool.
It's trivial to specify a location in the crashkernel parameter to work
around this particular tool limitation.
I also think that this limitation may well be fixed as of kexec-tools
2.0.4. 64-bit kernels are now loaded above 4 GiB.
David
> Signed-off-by: Warner Wang <warner.wang@hp.com>
> ---
> xen/arch/x86/setup.c | 7 +++++++
> 1 files changed, 7 insertions(+), 0 deletions(-)
>
> diff --git a/xen/arch/x86/setup.c b/xen/arch/x86/setup.c
> index 43301a5..ae4c947 100644
> --- a/xen/arch/x86/setup.c
> +++ b/xen/arch/x86/setup.c
> @@ -943,6 +943,13 @@ void __init __start_xen(unsigned long mbi_p)
> }
> }
>
> + /*
> + * Keep the crash kernel below this limit. On 64 bits, kexec-tools
> + * currently limits us to 896 MiB; increase this limit once kexec-tools
> + * are fixed.
> + */
> + e = min_t(uint64_t, e, 896 << 20);
> +
> /* Don't overlap with modules. */
> e = consider_modules(s, e, PAGE_ALIGN(kexec_crash_area.size),
> mod, mbi->mods_count, -1);
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2013-04-25 11:01 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-04-25 8:57 [PATCH] x86: keep the crash kernel below 896 MiB Warner Wang
2013-04-25 9:51 ` Jan Beulich
2013-04-25 10:48 ` Andrew Cooper
2013-04-25 11:01 ` David Vrabel
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).