From: Baoquan He <bhe@redhat.com>
To: Jinjie Ruan <ruanjinjie@huawei.com>
Cc: "Russell King (Oracle)" <linux@armlinux.org.uk>,
akpm@linux-foundation.org, linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org
Subject: Re: [RFC PATCH] ARM: Support allocating crashkernel above 4G for LPAE
Date: Tue, 6 Aug 2024 16:11:30 +0800 [thread overview]
Message-ID: <ZrHasuAXM2Ph9V5p@MiWiFi-R3L-srv> (raw)
In-Reply-To: <8f051483-46be-87b6-03bb-5e0d145a2ac3@huawei.com>
On 08/06/24 at 10:46am, Jinjie Ruan wrote:
>
>
> On 2024/8/5 10:56, Baoquan He wrote:
> > On 08/05/24 at 09:23am, Jinjie Ruan wrote:
> >>
> >>
> >> On 2024/8/2 19:01, Russell King (Oracle) wrote:
> >>> On Fri, Aug 02, 2024 at 05:25:10PM +0800, Jinjie Ruan wrote:
> >>>> As ARM LPAE feature support accessing memory beyond the 4G limit, define
> >>>> HAVE_ARCH_CRASHKERNEL_RESERVATION_HIGH macro to support reserving crash
> >>>> memory above 4G for ARM32 LPAE.
> >>>>
> >>>> No test because there is no LPAE ARM32 hardware.
> >>>
> >>> Why are you submitting patches for features you can't test?
> >>>
> >>> I'm not going to apply this without it being properly tested, because I
> >>> don't believe that this will work in the generic case.
> >>>
> >>> If the crash kernel is located in memory outside of the lower 4GiB of
> >>> address space, and there is no alias within physical address space
> >>> for that memory, then there is *no* *way* for such a kernel to boot.
> >>
> >> I'm sorry that I released this patch without testing it. I actually
> >> intended to bring up this issue for discussion. If anyone has the
> >> environment to test it, that would be great. In the meantime, we could
> >> have a discussion on the significance and relevance of this approach.
> >
> > I don't know arm32 and its LPAE. I know a little about x86_32 where
> > crashkernel can only be reserved below 896M because of the virtual
> > memory layout, and all memory above that is high memory which can't be
> > used as kernel memory directly. So from this patch, arm32 is different
> > than x86_32.
>
> Hi,Baoquan
>
> Does the following code make sense? Now parse_crashkernel() use
> HAVE_ARCH_CRASHKERNEL_RESERVATION_HIGH macro to parse "high", but use
> CONFIG_64BIT when reserving "low" memory in reserve_crashkernel_low().
I am fine with it. BUT have you addressed Russell's concern, e.g how to
test it actually?
>
> And when LPAE is enabled in ARM32, and "high" is reserved,
> reserve_crashkernel_low() need also function ok.
>
> --- a/kernel/crash_reserve.c
> +++ b/kernel/crash_reserve.c
> @@ -354,7 +354,7 @@ early_param("crashkernel", parse_crashkernel_dummy);
> #ifdef CONFIG_ARCH_HAS_GENERIC_CRASHKERNEL_RESERVATION
> static int __init reserve_crashkernel_low(unsigned long long low_size)
> {
> -#ifdef CONFIG_64BIT
> +#ifdef HAVE_ARCH_CRASHKERNEL_RESERVATION_HIGH
> unsigned long long low_base;
>
>
> >
> >>
> >>>
> >>> So, right now I believe this patch to be *fundamentally* wrong.
> >>>
> >>
> >
> >
>
next prev parent reply other threads:[~2024-08-06 8:12 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-02 9:25 [RFC PATCH] ARM: Support allocating crashkernel above 4G for LPAE Jinjie Ruan
2024-08-02 11:01 ` Russell King (Oracle)
2024-08-05 1:23 ` Jinjie Ruan
2024-08-05 2:56 ` Baoquan He
2024-08-06 2:46 ` Jinjie Ruan
2024-08-06 8:11 ` Baoquan He [this message]
2024-08-06 8:34 ` Russell King (Oracle)
2024-08-06 11:02 ` Baoquan He
2024-08-06 11:10 ` Jinjie Ruan
2024-08-06 11:08 ` Jinjie Ruan
2024-08-05 13:18 ` Catalin Marinas
2024-08-06 2:19 ` Jinjie Ruan
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=ZrHasuAXM2Ph9V5p@MiWiFi-R3L-srv \
--to=bhe@redhat.com \
--cc=akpm@linux-foundation.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=ruanjinjie@huawei.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 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).