* Crash Dump Region
@ 2007-03-06 1:56 Horms
2007-03-06 2:10 ` Zou, Nanhai
` (4 more replies)
0 siblings, 5 replies; 6+ messages in thread
From: Horms @ 2007-03-06 1:56 UTC (permalink / raw)
To: linux-ia64
Hi,
I am currently looking over the code that places the crashdump
region into /proc/iomem, and the code that determines its base
address if it is not passed on the kernel comamnd. It seems to me that
the current code allows the crashkernel to be placed incide a
/proc/iomem region of any type. Is this behaviour correct?
If not, should it be restricted to "System RAM" regions?
--
Horms
H: http://www.vergenet.net/~horms/
W: http://www.valinux.co.jp/en/
^ permalink raw reply [flat|nested] 6+ messages in thread
* RE: Crash Dump Region
2007-03-06 1:56 Crash Dump Region Horms
@ 2007-03-06 2:10 ` Zou, Nanhai
2007-03-06 2:18 ` Zou, Nanhai
` (3 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: Zou, Nanhai @ 2007-03-06 2:10 UTC (permalink / raw)
To: linux-ia64
> -----Original Message-----
> From: Horms [mailto:horms@verge.net.au]
> Sent: 2007Äê3ÔÂ6ÈÕ 9:57
> To: Zou, Nanhai
> Cc: Linux-IA64; fastboot
> Subject: Crash Dump Region
>
> Hi,
>
> I am currently looking over the code that places the crashdump
> region into /proc/iomem, and the code that determines its base
> address if it is not passed on the kernel comamnd. It seems to me that
> the current code allows the crashkernel to be placed incide a
> /proc/iomem region of any type. Is this behaviour correct?
> If not, should it be restricted to "System RAM" regions?
>
I not sure if I understand your question.
Kernel will find a big enough region inside efi memmap with WB attribute, excluding all the other reserved regions.
Zou Nanhai.
> --
> Horms
> H: http://www.vergenet.net/~horms/
> W: http://www.valinux.co.jp/en/
^ permalink raw reply [flat|nested] 6+ messages in thread
* RE: Crash Dump Region
2007-03-06 1:56 Crash Dump Region Horms
2007-03-06 2:10 ` Zou, Nanhai
@ 2007-03-06 2:18 ` Zou, Nanhai
2007-03-06 2:32 ` Zou Nan hai
` (2 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: Zou, Nanhai @ 2007-03-06 2:18 UTC (permalink / raw)
To: linux-ia64
> -----Original Message-----
> From: Zou, Nanhai
> Sent: 2007年3月6日 10:11
> To: 'Horms'
> Cc: Linux-IA64; fastboot
> Subject: RE: Crash Dump Region
>
> > -----Original Message-----
> > From: Horms [mailto:horms@verge.net.au]
> > Sent: 2007年3月6日 9:57
> > To: Zou, Nanhai
> > Cc: Linux-IA64; fastboot
> > Subject: Crash Dump Region
> >
> > Hi,
> >
> > I am currently looking over the code that places the crashdump
> > region into /proc/iomem, and the code that determines its base
> > address if it is not passed on the kernel comamnd. It seems to me that
> > the current code allows the crashkernel to be placed incide a
> > /proc/iomem region of any type. Is this behaviour correct?
> > If not, should it be restricted to "System RAM" regions?
> >
> I not sure if I understand your question.
> Kernel will find a big enough region inside efi memmap with WB attribute,
> excluding all the other reserved regions.
>
Oh,
You mean we should check is_memory_available(md) instead of only check efi_wb(md) in kdump_find_rsvd_region?
Yes, I think that is better.
Thanks
Zou Nanhai
> Zou Nanhai.
>
> > --
> > Horms
> > H: http://www.vergenet.net/~horms/
> > W: http://www.valinux.co.jp/en/
-
To unsubscribe from this list: send the line "unsubscribe linux-ia64" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Crash Dump Region
2007-03-06 1:56 Crash Dump Region Horms
2007-03-06 2:10 ` Zou, Nanhai
2007-03-06 2:18 ` Zou, Nanhai
@ 2007-03-06 2:32 ` Zou Nan hai
2007-03-06 2:44 ` Horms
2007-03-06 7:34 ` Horms
4 siblings, 0 replies; 6+ messages in thread
From: Zou Nan hai @ 2007-03-06 2:32 UTC (permalink / raw)
To: linux-ia64
On Tue, 2007-03-06 at 09:56, Horms wrote:
> Hi,
>
> I am currently looking over the code that places the crashdump
> region into /proc/iomem, and the code that determines its base
> address if it is not passed on the kernel comamnd. It seems to me that
> the current code allows the crashkernel to be placed incide a
> /proc/iomem region of any type. Is this behaviour correct?
> If not, should it be restricted to "System RAM" regions?
>
> --
> Horms
> H: http://www.vergenet.net/~horms/
> W: http://www.valinux.co.jp/en/
>
Please review the patch.
Thanks
Zou Nan hai
Signed-off-by: Zou Nan hai <nanhai.zou@intel.com>
--- a/arch/ia64/kernel/efi.c 2007-02-27 00:42:06.000000000 -0500
+++ b/arch/ia64/kernel/efi.c 2007-03-05 22:09:40.000000000 -0500
@@ -1154,7 +1154,7 @@ kdump_find_rsvd_region (unsigned long si
for (p = efi_map_start; p < efi_map_end; p += efi_desc_size) {
md = p;
- if (!efi_wb(md))
+ if (!is_memory_available(md))
continue;
start = ALIGN(md->phys_addr, alignment);
end = efi_md_end(md);
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Crash Dump Region
2007-03-06 1:56 Crash Dump Region Horms
` (2 preceding siblings ...)
2007-03-06 2:32 ` Zou Nan hai
@ 2007-03-06 2:44 ` Horms
2007-03-06 7:34 ` Horms
4 siblings, 0 replies; 6+ messages in thread
From: Horms @ 2007-03-06 2:44 UTC (permalink / raw)
To: linux-ia64
On Tue, Mar 06, 2007 at 10:18:59AM +0800, Zou, Nanhai wrote:
> > -----Original Message-----
> > From: Zou, Nanhai
> > Sent: 2007年3月6日 10:11
> > To: 'Horms'
> > Cc: Linux-IA64; fastboot
> > Subject: RE: Crash Dump Region
> >
> > > -----Original Message-----
> > > From: Horms [mailto:horms@verge.net.au]
> > > Sent: 2007年3月6日 9:57
> > > To: Zou, Nanhai
> > > Cc: Linux-IA64; fastboot
> > > Subject: Crash Dump Region
> > >
> > > Hi,
> > >
> > > I am currently looking over the code that places the crashdump
> > > region into /proc/iomem, and the code that determines its base
> > > address if it is not passed on the kernel comamnd. It seems to me that
> > > the current code allows the crashkernel to be placed incide a
> > > /proc/iomem region of any type. Is this behaviour correct?
> > > If not, should it be restricted to "System RAM" regions?
> > >
> > I not sure if I understand your question.
> > Kernel will find a big enough region inside efi memmap with WB attribute,
> > excluding all the other reserved regions.
> >
> Oh,
> You mean we should check is_memory_available(md) instead of only check efi_wb(md) in kdump_find_rsvd_region?
> Yes, I think that is better.
Thanks.
I had missed the efi_wb(), which was the cause of some confusion on my
part. But as you suggest, is_memory_available() probaly is better, I'll
comment on your patch separately.
However, what I am more worried about is the case where the base address
is passed by the end-user, in which case it seems that some kind of
check should be added to efi_initialize_iomem_resources().
A quick check on my tiger2 box shows that the following is possible. I
know its a silly example, but I think it does demonstrate the problem
that I was trying to explain in my intial email. And I think that you
have answered my question - this is not correct
crashkernel=1k@520k
00082000-00083fff : reserved
00082000-000823ff : Crash kernel
I'll make a patch to fix this up if you have no objections.
--
Horms
H: http://www.vergenet.net/~horms/
W: http://www.valinux.co.jp/en/
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Crash Dump Region
2007-03-06 1:56 Crash Dump Region Horms
` (3 preceding siblings ...)
2007-03-06 2:44 ` Horms
@ 2007-03-06 7:34 ` Horms
4 siblings, 0 replies; 6+ messages in thread
From: Horms @ 2007-03-06 7:34 UTC (permalink / raw)
To: linux-ia64
On Tue, Mar 06, 2007 at 10:32:09AM +0800, Zou Nan hai wrote:
> On Tue, 2007-03-06 at 09:56, Horms wrote:
> > Hi,
> >
> > I am currently looking over the code that places the crashdump
> > region into /proc/iomem, and the code that determines its base
> > address if it is not passed on the kernel comamnd. It seems to me that
> > the current code allows the crashkernel to be placed incide a
> > /proc/iomem region of any type. Is this behaviour correct?
> > If not, should it be restricted to "System RAM" regions?
>
> Please review the patch.
This looks good to me.
Acked-by: Simon Horman <horms@verge.net.au>
> Thanks
> Zou Nan hai
>
> Signed-off-by: Zou Nan hai <nanhai.zou@intel.com>
>
> --- a/arch/ia64/kernel/efi.c 2007-02-27 00:42:06.000000000 -0500
> +++ b/arch/ia64/kernel/efi.c 2007-03-05 22:09:40.000000000 -0500
> @@ -1154,7 +1154,7 @@ kdump_find_rsvd_region (unsigned long si
>
> for (p = efi_map_start; p < efi_map_end; p += efi_desc_size) {
> md = p;
> - if (!efi_wb(md))
> + if (!is_memory_available(md))
> continue;
> start = ALIGN(md->phys_addr, alignment);
> end = efi_md_end(md);
>
>
--
Horms
H: http://www.vergenet.net/~horms/
W: http://www.valinux.co.jp/en/
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2007-03-06 7:34 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-03-06 1:56 Crash Dump Region Horms
2007-03-06 2:10 ` Zou, Nanhai
2007-03-06 2:18 ` Zou, Nanhai
2007-03-06 2:32 ` Zou Nan hai
2007-03-06 2:44 ` Horms
2007-03-06 7:34 ` Horms
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox