[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20231009151513.GB3846@monkey>
Date: Mon, 9 Oct 2023 08:15:13 -0700
From: Mike Kravetz <mike.kravetz@...cle.com>
To: Konrad Dybcio <konrad.dybcio@...aro.org>
Cc: Anshuman Khandual <anshuman.khandual@....com>,
Andrew Morton <akpm@...ux-foundation.org>,
Xiongchun Duan <duanxiongchun@...edance.com>,
Barry Song <21cnbao@...il.com>,
David Rientjes <rientjes@...gle.com>,
Miaohe Lin <linmiaohe@...wei.com>,
Matthew Wilcox <willy@...radead.org>, linux-mm@...ck.org,
Naoya Horiguchi <naoya.horiguchi@...ux.dev>,
Joao Martins <joao.m.martins@...cle.com>,
David Hildenbrand <david@...hat.com>,
Michal Hocko <mhocko@...e.com>,
Oscar Salvador <osalvador@...e.de>,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH v6 2/8] hugetlb: restructure pool allocations
On 10/09/23 08:04, Mike Kravetz wrote:
> On 10/09/23 12:11, Konrad Dybcio wrote:
> > On 9.10.2023 05:29, Mike Kravetz wrote:
> > > On 10/06/23 15:35, Mike Kravetz wrote:
> > >> On 10/06/23 23:39, Konrad Dybcio wrote:
> > >>> On 6.10.2023 05:08, Mike Kravetz wrote:
> > >>>> On 10/02/23 11:57, Konrad Dybcio wrote:
> > >>>>> On 9/29/23 22:57, Mike Kravetz wrote:
> > >>>>>> On 09/27/23 13:26, Konrad Dybcio wrote:
> > >>>>>>> On 26.09.2023 01:48, Mike Kravetz wrote:
> >
> > I managed to get a boot log:
> >
> > https://pastebin.com/GwurpCw9
> >
> > This is using arch/arm64/boot/dts/qcom/sm8550-mtp.dts for reference
> >
>
> Early on in boot log before the panic, I see this in the log:
>
> [ 0.000000] efi: UEFI not found.
> [ 0.000000] [Firmware Bug]: Kernel image misaligned at boot, please fix your bootloader!
>
> Isn't that misalignment pretty serious? Or, is is possible to run with that?
>
> There are no hugetlb pages allocated at boot time:
>
> [ 0.000000] Kernel command line: PMOS_NO_OUTPUT_REDIRECT console=ttyMSM0 earlycon clk_ignore_unused pd_ignore_unused androidboot.bootdevice=1d84000.ufshc androidboot.fstab_suffix=default androidboot.boot_devices=soc/1d84000.ufshc androidboot.serialno=ab855d8d androidboot.baseband=msm
>
> So, the routine where we are panic'ing (gather_bootmem_prealloc) should be a
> noop. The first thing it does is:
> list_for_each_entry(m, &huge_boot_pages, list) {
> ...
> }
>
> However, huge_boot_pages should be empty as initialized here:
> __initdata LIST_HEAD(huge_boot_pages);
>
> At the end of the routine, we call prep_and_add_bootmem_folios to
> process the local list created withing that above loop:
>
> LIST_HEAD(folio_list);
>
> This should also be empty and a noop.
>
> Is it possible that the misaligned kernel image could make these lists
> appear as non-empty?
Actually, just saw this:
https://lore.kernel.org/linux-mm/20231009145605.2150897-1-usama.arif@bytedance.com/
Will take a look, although as mentioned above prep_and_add_bootmem_folios on
an empty list should be a noop.
--
Mike Kravetz
Powered by blists - more mailing lists