All of lore.kernel.org
 help / color / mirror / Atom feed
From: Pratyush Anand <panand@redhat.com>
To: AKASHI Takahiro <takahiro.akashi@linaro.org>,
	catalin.marinas@arm.com, will.deacon@arm.com, vgoyal@redhat.com,
	hbabus@us.ibm.com
Cc: linaro-kernel@lists.linaro.org, geoff@infradead.org,
	kexec@lists.infradead.org, linux-kernel@vger.kernel.org,
	broonie@kernel.org, david.griego@linaro.org,
	linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH 0/5] arm64: add kdump support
Date: Wed, 01 Apr 2015 21:26:39 +0530	[thread overview]
Message-ID: <551C1537.2030009@redhat.com> (raw)
In-Reply-To: <1427358533-3754-1-git-send-email-takahiro.akashi@linaro.org>

Hi Akashi,

On Thursday 26 March 2015 01:58 PM, AKASHI Takahiro wrote:
> This patch set enables kdump (crash dump kernel) support on arm64 on top of
> Geoff's kexec patchset.
>
> In this version, there are some arm64-specific usage/constraints:
> 1) "mem=" boot parameter must be specified on crash dump kernel
> 2) Kvm will not be enabled on crash dump kernel even if configured
> See commit messages and Documentation/kdump/kdump.txt for details.
>
> The only concern I have is whether or not we can use the exact same kernel
> as both system kernel and crash dump kernel. The current arm64 kernel is
> not relocatable in the exact sense but I have no problems in using the same
> binary for testing kdump.
>
> I tested the code with
> 	- ATF v1.1 + EDK2(UEFI) v3.0-rc0
> 	- kernel v4.0-rc4 + Geoff' kexec v8
> on Base fast model, using my yet-to-be-submitted kexec-tools [1].
> You may want to start a kernel with the following boot parameter:
> 	crashkernel=64M@2240M
> and try
> 	$ kexec -p --load <vmlinux> --append ...
> 	$ echo c > /proc/sysrq-trigger
>

I tried to use your kdump patches for kernel and kexec-tools. I am not 
able to load the crash kernel properly.


I passed crashkernel=64M@259G (My 8GB RAM starts at 256G) to primary kernel.

Used following to load the crash kernel
kexec -p  --load vmlinux  --append="$( cat /proc/cmdline ) maxcpus=1 
mem=64M reset_devices"

I see:

kexec_load failed: Cannot assign requested address
entry       = 0x40c40005d0 flags = 0xb70001

What I noticed that arm64_load_other_segments does not calculate correct 
load address for purgatory or if I pass initrd then for that too within 
crash kernel allocated memory.

Shouldn't we have a function similar to locate_dtb_in_crashmem for 
putgatory as well as initrd? I can try to fix this allocation, but I was 
just wondering if I understood correctly or I am missing something.

~Pratyush


> To examine vmcore (/proc/vmcore), you may use
> 	- gdb v7.7 or later
> 	- crash + a small patch (to recognize v4.0 kernel)
>
> [1] https://git.linaro.org/people/takahiro.akashi/kexec-tools.git
>
>
> AKASHI Takahiro (5):
>    arm64: kdump: reserve memory for crash dump kernel
>    arm64: kdump: implement machine_crash_shutdown()
>    arm64: kdump: do not go into EL2 before starting a crash dump kernel
>    arm64: add kdump support
>    arm64: enable kdump in the arm64 defconfig
>
>   Documentation/kdump/kdump.txt     |   31 ++++++++++++++-
>   arch/arm64/Kconfig                |   12 ++++++
>   arch/arm64/configs/defconfig      |    1 +
>   arch/arm64/include/asm/kexec.h    |   34 +++++++++++++++-
>   arch/arm64/kernel/Makefile        |    1 +
>   arch/arm64/kernel/crash_dump.c    |   71 +++++++++++++++++++++++++++++++++
>   arch/arm64/kernel/machine_kexec.c |   55 +++++++++++++++++++++++++-
>   arch/arm64/kernel/process.c       |    7 +++-
>   arch/arm64/kernel/setup.c         |   78 +++++++++++++++++++++++++++++++++++++
>   arch/arm64/kernel/smp.c           |   10 ++++-
>   10 files changed, 294 insertions(+), 6 deletions(-)
>   create mode 100644 arch/arm64/kernel/crash_dump.c
>

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

WARNING: multiple messages have this Message-ID (diff)
From: panand@redhat.com (Pratyush Anand)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 0/5] arm64: add kdump support
Date: Wed, 01 Apr 2015 21:26:39 +0530	[thread overview]
Message-ID: <551C1537.2030009@redhat.com> (raw)
In-Reply-To: <1427358533-3754-1-git-send-email-takahiro.akashi@linaro.org>

Hi Akashi,

On Thursday 26 March 2015 01:58 PM, AKASHI Takahiro wrote:
> This patch set enables kdump (crash dump kernel) support on arm64 on top of
> Geoff's kexec patchset.
>
> In this version, there are some arm64-specific usage/constraints:
> 1) "mem=" boot parameter must be specified on crash dump kernel
> 2) Kvm will not be enabled on crash dump kernel even if configured
> See commit messages and Documentation/kdump/kdump.txt for details.
>
> The only concern I have is whether or not we can use the exact same kernel
> as both system kernel and crash dump kernel. The current arm64 kernel is
> not relocatable in the exact sense but I have no problems in using the same
> binary for testing kdump.
>
> I tested the code with
> 	- ATF v1.1 + EDK2(UEFI) v3.0-rc0
> 	- kernel v4.0-rc4 + Geoff' kexec v8
> on Base fast model, using my yet-to-be-submitted kexec-tools [1].
> You may want to start a kernel with the following boot parameter:
> 	crashkernel=64M at 2240M
> and try
> 	$ kexec -p --load <vmlinux> --append ...
> 	$ echo c > /proc/sysrq-trigger
>

I tried to use your kdump patches for kernel and kexec-tools. I am not 
able to load the crash kernel properly.


I passed crashkernel=64M at 259G (My 8GB RAM starts at 256G) to primary kernel.

Used following to load the crash kernel
kexec -p  --load vmlinux  --append="$( cat /proc/cmdline ) maxcpus=1 
mem=64M reset_devices"

I see:

kexec_load failed: Cannot assign requested address
entry       = 0x40c40005d0 flags = 0xb70001

What I noticed that arm64_load_other_segments does not calculate correct 
load address for purgatory or if I pass initrd then for that too within 
crash kernel allocated memory.

Shouldn't we have a function similar to locate_dtb_in_crashmem for 
putgatory as well as initrd? I can try to fix this allocation, but I was 
just wondering if I understood correctly or I am missing something.

~Pratyush


> To examine vmcore (/proc/vmcore), you may use
> 	- gdb v7.7 or later
> 	- crash + a small patch (to recognize v4.0 kernel)
>
> [1] https://git.linaro.org/people/takahiro.akashi/kexec-tools.git
>
>
> AKASHI Takahiro (5):
>    arm64: kdump: reserve memory for crash dump kernel
>    arm64: kdump: implement machine_crash_shutdown()
>    arm64: kdump: do not go into EL2 before starting a crash dump kernel
>    arm64: add kdump support
>    arm64: enable kdump in the arm64 defconfig
>
>   Documentation/kdump/kdump.txt     |   31 ++++++++++++++-
>   arch/arm64/Kconfig                |   12 ++++++
>   arch/arm64/configs/defconfig      |    1 +
>   arch/arm64/include/asm/kexec.h    |   34 +++++++++++++++-
>   arch/arm64/kernel/Makefile        |    1 +
>   arch/arm64/kernel/crash_dump.c    |   71 +++++++++++++++++++++++++++++++++
>   arch/arm64/kernel/machine_kexec.c |   55 +++++++++++++++++++++++++-
>   arch/arm64/kernel/process.c       |    7 +++-
>   arch/arm64/kernel/setup.c         |   78 +++++++++++++++++++++++++++++++++++++
>   arch/arm64/kernel/smp.c           |   10 ++++-
>   10 files changed, 294 insertions(+), 6 deletions(-)
>   create mode 100644 arch/arm64/kernel/crash_dump.c
>

WARNING: multiple messages have this Message-ID (diff)
From: Pratyush Anand <panand@redhat.com>
To: AKASHI Takahiro <takahiro.akashi@linaro.org>,
	catalin.marinas@arm.com, will.deacon@arm.com, vgoyal@redhat.com,
	hbabus@us.ibm.com
Cc: linaro-kernel@lists.linaro.org, geoff@infradead.org,
	kexec@lists.infradead.org, linux-kernel@vger.kernel.org,
	broonie@kernel.org, david.griego@linaro.org,
	linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH 0/5] arm64: add kdump support
Date: Wed, 01 Apr 2015 21:26:39 +0530	[thread overview]
Message-ID: <551C1537.2030009@redhat.com> (raw)
In-Reply-To: <1427358533-3754-1-git-send-email-takahiro.akashi@linaro.org>

Hi Akashi,

On Thursday 26 March 2015 01:58 PM, AKASHI Takahiro wrote:
> This patch set enables kdump (crash dump kernel) support on arm64 on top of
> Geoff's kexec patchset.
>
> In this version, there are some arm64-specific usage/constraints:
> 1) "mem=" boot parameter must be specified on crash dump kernel
> 2) Kvm will not be enabled on crash dump kernel even if configured
> See commit messages and Documentation/kdump/kdump.txt for details.
>
> The only concern I have is whether or not we can use the exact same kernel
> as both system kernel and crash dump kernel. The current arm64 kernel is
> not relocatable in the exact sense but I have no problems in using the same
> binary for testing kdump.
>
> I tested the code with
> 	- ATF v1.1 + EDK2(UEFI) v3.0-rc0
> 	- kernel v4.0-rc4 + Geoff' kexec v8
> on Base fast model, using my yet-to-be-submitted kexec-tools [1].
> You may want to start a kernel with the following boot parameter:
> 	crashkernel=64M@2240M
> and try
> 	$ kexec -p --load <vmlinux> --append ...
> 	$ echo c > /proc/sysrq-trigger
>

I tried to use your kdump patches for kernel and kexec-tools. I am not 
able to load the crash kernel properly.


I passed crashkernel=64M@259G (My 8GB RAM starts at 256G) to primary kernel.

Used following to load the crash kernel
kexec -p  --load vmlinux  --append="$( cat /proc/cmdline ) maxcpus=1 
mem=64M reset_devices"

I see:

kexec_load failed: Cannot assign requested address
entry       = 0x40c40005d0 flags = 0xb70001

What I noticed that arm64_load_other_segments does not calculate correct 
load address for purgatory or if I pass initrd then for that too within 
crash kernel allocated memory.

Shouldn't we have a function similar to locate_dtb_in_crashmem for 
putgatory as well as initrd? I can try to fix this allocation, but I was 
just wondering if I understood correctly or I am missing something.

~Pratyush


> To examine vmcore (/proc/vmcore), you may use
> 	- gdb v7.7 or later
> 	- crash + a small patch (to recognize v4.0 kernel)
>
> [1] https://git.linaro.org/people/takahiro.akashi/kexec-tools.git
>
>
> AKASHI Takahiro (5):
>    arm64: kdump: reserve memory for crash dump kernel
>    arm64: kdump: implement machine_crash_shutdown()
>    arm64: kdump: do not go into EL2 before starting a crash dump kernel
>    arm64: add kdump support
>    arm64: enable kdump in the arm64 defconfig
>
>   Documentation/kdump/kdump.txt     |   31 ++++++++++++++-
>   arch/arm64/Kconfig                |   12 ++++++
>   arch/arm64/configs/defconfig      |    1 +
>   arch/arm64/include/asm/kexec.h    |   34 +++++++++++++++-
>   arch/arm64/kernel/Makefile        |    1 +
>   arch/arm64/kernel/crash_dump.c    |   71 +++++++++++++++++++++++++++++++++
>   arch/arm64/kernel/machine_kexec.c |   55 +++++++++++++++++++++++++-
>   arch/arm64/kernel/process.c       |    7 +++-
>   arch/arm64/kernel/setup.c         |   78 +++++++++++++++++++++++++++++++++++++
>   arch/arm64/kernel/smp.c           |   10 ++++-
>   10 files changed, 294 insertions(+), 6 deletions(-)
>   create mode 100644 arch/arm64/kernel/crash_dump.c
>

  parent reply	other threads:[~2015-04-01 15:56 UTC|newest]

Thread overview: 60+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-26  8:28 [PATCH 0/5] arm64: add kdump support AKASHI Takahiro
2015-03-26  8:28 ` AKASHI Takahiro
2015-03-26  8:28 ` AKASHI Takahiro
2015-03-26  8:28 ` [PATCH 1/5] arm64: kdump: reserve memory for crash dump kernel AKASHI Takahiro
2015-03-26  8:28   ` AKASHI Takahiro
2015-03-26  8:28   ` AKASHI Takahiro
2015-03-26 18:30   ` Geoff Levand
2015-03-26 18:30     ` Geoff Levand
2015-03-26 18:30     ` Geoff Levand
2015-03-27  4:43   ` Geoff Levand
2015-03-27  4:43     ` Geoff Levand
2015-03-27  4:43     ` Geoff Levand
2015-03-30  2:35     ` AKASHI Takahiro
2015-03-30  2:35       ` AKASHI Takahiro
2015-03-30  2:35       ` AKASHI Takahiro
2015-04-09 13:09   ` Pratyush Anand
2015-04-09 13:09     ` Pratyush Anand
2015-04-09 13:09     ` Pratyush Anand
2015-04-10  5:57     ` AKASHI Takahiro
2015-04-10  5:57       ` AKASHI Takahiro
2015-04-10  5:57       ` AKASHI Takahiro
2015-04-10  6:35       ` Pratyush Anand
2015-04-10  6:35         ` Pratyush Anand
2015-04-10  6:35         ` Pratyush Anand
2015-03-26  8:28 ` [PATCH 2/5] arm64: kdump: implement machine_crash_shutdown() AKASHI Takahiro
2015-03-26  8:28   ` AKASHI Takahiro
2015-03-26  8:28   ` AKASHI Takahiro
2015-03-26  8:28 ` [PATCH 3/5] arm64: kdump: do not go into EL2 before starting a crash dump kernel AKASHI Takahiro
2015-03-26  8:28   ` AKASHI Takahiro
2015-03-26  8:28   ` AKASHI Takahiro
2015-03-26 22:29   ` Geoff Levand
2015-03-26 22:29     ` Geoff Levand
2015-03-26 22:29     ` Geoff Levand
2015-03-30  3:21     ` AKASHI Takahiro
2015-03-30  3:21       ` AKASHI Takahiro
2015-03-30  3:21       ` AKASHI Takahiro
2015-03-26  8:28 ` [PATCH 4/5] arm64: add kdump support AKASHI Takahiro
2015-03-26  8:28   ` AKASHI Takahiro
2015-03-26  8:28   ` AKASHI Takahiro
2015-03-26  8:28 ` [PATCH 5/5] arm64: enable kdump in the arm64 defconfig AKASHI Takahiro
2015-03-26  8:28   ` AKASHI Takahiro
2015-03-26  8:28   ` AKASHI Takahiro
2015-04-01 15:56 ` Pratyush Anand [this message]
2015-04-01 15:56   ` [PATCH 0/5] arm64: add kdump support Pratyush Anand
2015-04-01 15:56   ` Pratyush Anand
2015-04-01 23:27   ` AKASHI Takahiro
2015-04-01 23:27     ` AKASHI Takahiro
2015-04-01 23:27     ` AKASHI Takahiro
2015-04-02  4:58     ` Pratyush Anand
2015-04-02  4:58       ` Pratyush Anand
2015-04-02  4:58       ` Pratyush Anand
2015-04-02  5:37       ` AKASHI Takahiro
2015-04-02  5:37         ` AKASHI Takahiro
2015-04-02  5:37         ` AKASHI Takahiro
2015-04-02  6:01         ` Pratyush Anand
2015-04-02  6:01           ` Pratyush Anand
2015-04-02  6:01           ` Pratyush Anand
2015-04-02  7:48           ` AKASHI Takahiro
2015-04-02  7:48             ` AKASHI Takahiro
2015-04-02  7:48             ` AKASHI Takahiro

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=551C1537.2030009@redhat.com \
    --to=panand@redhat.com \
    --cc=broonie@kernel.org \
    --cc=catalin.marinas@arm.com \
    --cc=david.griego@linaro.org \
    --cc=geoff@infradead.org \
    --cc=hbabus@us.ibm.com \
    --cc=kexec@lists.infradead.org \
    --cc=linaro-kernel@lists.linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=takahiro.akashi@linaro.org \
    --cc=vgoyal@redhat.com \
    --cc=will.deacon@arm.com \
    /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 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.