From: takahiro.akashi@linaro.org (AKASHI Takahiro)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 13/16] arm64: kdump: add kdump support
Date: Thu, 22 Oct 2015 18:57:14 +0900 [thread overview]
Message-ID: <5628B2FA.80209@linaro.org> (raw)
In-Reply-To: <20151022051548.GD11227@dhcp-129-115.nay.redhat.com>
(added Ard to Cc.)
On 10/22/2015 02:15 PM, Dave Young wrote:
> On 10/22/15 at 01:29pm, AKASHI Takahiro wrote:
>> Hi Dave,
>>
>> Thank you for your comment.
>>
>> On 10/22/2015 12:25 PM, Dave Young wrote:
>>> Hi, AKASHI,
>>>
>>> On 10/19/15 at 11:38pm, Geoff Levand wrote:
>>>> From: AKASHI Takahiro <takahiro.akashi@linaro.org>
>>>>
>>>> On crash dump kernel, all the information about primary kernel's core
>>>> image is available in elf core header specified by "elfcorehdr=" boot
>>>> parameter. reserve_elfcorehdr() will set aside the region to avoid any
>>>> corruption by crash dump kernel.
>>>>
>>>> Crash dump kernel will access the system memory of primary kernel via
>>>> copy_oldmem_page(), which reads one page by ioremap'ing it since it does
>>>> not reside in linear mapping on crash dump kernel.
>>>> Please note that we should add "mem=X[MG]" boot parameter to limit the
>>>> memory size and avoid the following assertion at ioremap():
>>>> if (WARN_ON(pfn_valid(__phys_to_pfn(phys_addr))))
>>>> return NULL;
>>>> when accessing any pages beyond the usable memories of crash dump kernel.
>>>
>>> How does kexec-tools pass usable memory ranges to kernel? using dtb?
>>> Passing an extra mem=X sounds odd in the design. Kdump kernel should get
>>> usable ranges and hanle the limit better than depending on an extern kernel
>>> param.
>>
>> Well, regarding "depending on an external kernel param,"
>> - this limitation ("mem=") is compatible with arm(32) implementation although
>> it is not clearly described in kernel's Documentation/kdump/kdump.txt.
>> - "elfcorehdr" kernel parameter is mandatory on x86 as well as on arm/arm64.
>> The parameter is explicitly generated and added by kexec-tools.
>>
>> Do I miss your point?
>
> Arm previously use atag_mem tag for memory kernel uses, with dtb, Booting.txt
> says: The boot loader must pass at a minimum the size and location of the
> system memory
>
> In arm64 booting.txt, it does mentions about dtb but without above sentence.
>
> So if you are using dtb to pass memory I think the extra mem= should be not
> necessary unless there's other limitations dtb can not been used.
I would expect comments from arm64 maintainers here.
In my old implementation, I added "usablemem" attributes, along with "reg," to
"memory" nodes in dtb to specify the usable memory region on crash dump kernel.
But I removed this feature partly because, on uefi system, uefi might pass
no memory information in dtb.
> One thing I'm confused is mem= only pass the memory size, where does you pass
> the start addresses?
In the current arm64 implementation, any regions below the start address will
be ignored as system ram.
> What if there's multiple sections such as some reserved
> ranges 2nd kernel also need?
My patch utilizes only a single contiguous region of memory as system ram.
One exception that I notice is uefi's runtime data. They will be ioremap'ed separately.
Please let me know if there is any other case that should be supported.
Thanks,
-Takahiro AKASHI
> Thanks
> Dave
>
next prev parent reply other threads:[~2015-10-22 9:57 UTC|newest]
Thread overview: 36+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-10-19 23:38 [PATCH 00/16] arm64 kexec kernel patches v10 Geoff Levand
2015-10-19 23:38 ` [PATCH 04/16] arm64: kvm: allows kvm cpu hotplug Geoff Levand
2015-10-20 18:57 ` [PATCH v10.1 " Geoff Levand
2015-10-19 23:38 ` [PATCH 06/16] arm64: Add EL2 switch to cpu_reset Geoff Levand
2015-10-19 23:38 ` [PATCH 08/16] arm64/kexec: Add core kexec support Geoff Levand
2015-10-20 8:56 ` Pratyush Anand
2015-10-20 17:19 ` Geoff Levand
2015-10-23 7:29 ` Pratyush Anand
2015-10-21 18:30 ` [PATCH v10.2 " Geoff Levand
2015-10-30 16:29 ` [PATCH " James Morse
2015-10-30 16:54 ` Mark Rutland
2015-11-02 9:26 ` Pratyush Anand
2015-11-03 0:30 ` Geoff Levand
2015-10-19 23:38 ` [PATCH 01/16] arm64: Fold proc-macros.S into assembler.h Geoff Levand
2015-10-19 23:38 ` [PATCH 05/16] arm64: Add back cpu_reset routines Geoff Levand
2015-10-19 23:38 ` [PATCH 07/16] Revert "arm64: remove dead code" Geoff Levand
2015-10-19 23:38 ` [PATCH 02/16] arm64: Convert hcalls to use HVC immediate value Geoff Levand
2015-10-19 23:38 ` [PATCH 03/16] arm64: Add new hcall HVC_CALL_FUNC Geoff Levand
2015-10-19 23:38 ` [PATCH 15/16] arm64: kdump: enable kdump in the arm64 defconfig Geoff Levand
2015-10-19 23:38 ` [PATCH 11/16] arm64: kdump: reserve memory for crash dump kernel Geoff Levand
2015-10-19 23:38 ` [PATCH 09/16] arm64/kexec: Add pr_devel output Geoff Levand
2015-10-19 23:38 ` [PATCH 13/16] arm64: kdump: add kdump support Geoff Levand
2015-10-22 3:25 ` Dave Young
2015-10-22 4:29 ` AKASHI Takahiro
2015-10-22 5:15 ` Dave Young
2015-10-22 9:57 ` AKASHI Takahiro [this message]
2015-10-23 9:50 ` Dave Young
2015-10-29 5:55 ` AKASHI Takahiro
2015-10-29 6:40 ` Dave Young
2015-10-29 6:53 ` AKASHI Takahiro
2015-10-29 7:01 ` Dave Young
2015-10-19 23:38 ` [PATCH 10/16] arm64/kexec: Enable kexec in the arm64 defconfig Geoff Levand
2015-10-19 23:38 ` [PATCH 12/16] arm64: kdump: implement machine_crash_shutdown() Geoff Levand
2015-10-20 18:54 ` [PATCH v10.1 " Geoff Levand
2015-10-19 23:38 ` [PATCH 16/16] arm64: kdump: relax BUG_ON() if more than one cpus are still active Geoff Levand
2015-10-19 23:38 ` [PATCH 14/16] arm64: kdump: update a kernel doc Geoff Levand
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=5628B2FA.80209@linaro.org \
--to=takahiro.akashi@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
/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).