All of lore.kernel.org
 help / color / mirror / Atom feed
From: Joel Stanley <joel@jms.id.au>
To: Ard Biesheuvel <ardb@kernel.org>
Cc: "Marek Szyprowski" <m.szyprowski@samsung.com>,
	"Linux ARM" <linux-arm-kernel@lists.infradead.org>,
	"Linux Samsung SOC" <linux-samsung-soc@vger.kernel.org>,
	"Krzysztof Kozlowski" <krzk@kernel.org>,
	"Linus Walleij" <linus.walleij@linaro.org>,
	"Florian Fainelli" <f.fainelli@gmail.com>,
	"Russell King" <linux@armlinux.org.uk>,
	"Rob Herring" <robh+dt@kernel.org>,
	"Nicolas Pitre" <nico@fluxnic.net>,
	"Cédric Le Goater" <clg@kaod.org>
Subject: Re: [PATCH v2 2/2] ARM: move device tree mapping out of linear region
Date: Wed, 28 Oct 2020 12:59:20 +0000	[thread overview]
Message-ID: <CACPK8Xfw0WYSxGf0PnVOF40+C-KOJnX2x_q2gXrf4JZPErKBDA@mail.gmail.com> (raw)
In-Reply-To: <CAMj1kXH90MzCUJ_DHZ_2=JcWBX=Qf1PT-A9PX9EeBTVx22EkaQ@mail.gmail.com>

On Wed, 28 Oct 2020 at 12:53, Ard Biesheuvel <ardb@kernel.org> wrote:
>
> On Wed, 28 Oct 2020 at 13:05, Joel Stanley <joel@jms.id.au> wrote:
> >
> > On Wed, 28 Oct 2020 at 09:19, Marek Szyprowski <m.szyprowski@samsung.com> wrote:
> > > This patch landed in linux-next 20201028 as commit 7a1be318f579 ("ARM:
> > > 9012/1: move device tree mapping out of linear region"). Sadly it broke
> > > booting  almost all Samsung Exynos-based boards. The only one which
> > > booted, used an appended device tree. I can provide more information if
> > > needed, just let me know what to check. "Starting kernel ..." is the
> > > last message I see here. No output from earlycon.
> >
> > A bisection lead me to this patch after the next-20201028 failed to
> > boot on the aspeed systems in testing (aspeed_g5_defconfig).
> >
> > You can reproduce this with today's next and qemu 5.1:
> >
> > qemu-system-arm -M romulus-bmc -nographic \
> >  -kernel arch/arm/boot/zImage \
> >  -dtb arch/arm/boot/dts/aspeed-bmc-opp-romulus.dtb \
> >  -initrd any-old-file
> >
> > It requires the initrd option to reproduce, but the initrd doesn't
> > need to be valid as we don't make it that far.
> >
> > There is no output but attaching gdb shows the kernel is stuck in
> > setup_machine_tags. (If we enable CONFIG_ATAGS it is instead stuck in
> > calibrate_delay).
> >
> > (gdb) bt
> > #0  setup_machine_tags (machine_nr=<optimized out>,
> > __atags_vaddr=<optimized out>) at ../arch/arm/kernel/atags.h:12
> > #1  setup_arch (cmdline_p=0x80c01fc4) at ../arch/arm/kernel/setup.c:1100
> > #2  0x80b00d2c in start_kernel () at ../init/main.c:862
> > #3  0x00000000 in ?? ()
> >
> > Reverting 7a1be318f579 on top of next allowed the system to boot again.
> >
>
> Does this help?

Yes, that boots to userspace.

>
> diff --git a/arch/arm/include/asm/memory.h b/arch/arm/include/asm/memory.h
> index bb79e52aeb90..4f355bda872a 100644
> --- a/arch/arm/include/asm/memory.h
> +++ b/arch/arm/include/asm/memory.h
> @@ -68,8 +68,8 @@
>  #define XIP_VIRT_ADDR(physaddr)  (MODULES_VADDR + ((physaddr) & 0x000fffff))
>
>  #define FDT_FIXED_BASE         UL(0xff800000)
> -#define FDT_FIXED_SIZE         (2 * PMD_SIZE)
> -#define FDT_VIRT_ADDR(physaddr)        ((void *)(FDT_FIXED_BASE |
> (physaddr) % PMD_SIZE))
> +#define FDT_FIXED_SIZE         (2 * SECTION_SIZE)
> +#define FDT_VIRT_ADDR(physaddr)        ((void *)(FDT_FIXED_BASE |
> (physaddr) % SECTION_SIZE))
>
>  #if !defined(CONFIG_SMP) && !defined(CONFIG_ARM_LPAE)
>  /*

WARNING: multiple messages have this Message-ID (diff)
From: Joel Stanley <joel@jms.id.au>
To: Ard Biesheuvel <ardb@kernel.org>
Cc: "Florian Fainelli" <f.fainelli@gmail.com>,
	"Nicolas Pitre" <nico@fluxnic.net>,
	"Linus Walleij" <linus.walleij@linaro.org>,
	"Russell King" <linux@armlinux.org.uk>,
	"Krzysztof Kozlowski" <krzk@kernel.org>,
	"Rob Herring" <robh+dt@kernel.org>,
	"Linux Samsung SOC" <linux-samsung-soc@vger.kernel.org>,
	"Cédric Le Goater" <clg@kaod.org>,
	"Linux ARM" <linux-arm-kernel@lists.infradead.org>,
	"Marek Szyprowski" <m.szyprowski@samsung.com>
Subject: Re: [PATCH v2 2/2] ARM: move device tree mapping out of linear region
Date: Wed, 28 Oct 2020 12:59:20 +0000	[thread overview]
Message-ID: <CACPK8Xfw0WYSxGf0PnVOF40+C-KOJnX2x_q2gXrf4JZPErKBDA@mail.gmail.com> (raw)
In-Reply-To: <CAMj1kXH90MzCUJ_DHZ_2=JcWBX=Qf1PT-A9PX9EeBTVx22EkaQ@mail.gmail.com>

On Wed, 28 Oct 2020 at 12:53, Ard Biesheuvel <ardb@kernel.org> wrote:
>
> On Wed, 28 Oct 2020 at 13:05, Joel Stanley <joel@jms.id.au> wrote:
> >
> > On Wed, 28 Oct 2020 at 09:19, Marek Szyprowski <m.szyprowski@samsung.com> wrote:
> > > This patch landed in linux-next 20201028 as commit 7a1be318f579 ("ARM:
> > > 9012/1: move device tree mapping out of linear region"). Sadly it broke
> > > booting  almost all Samsung Exynos-based boards. The only one which
> > > booted, used an appended device tree. I can provide more information if
> > > needed, just let me know what to check. "Starting kernel ..." is the
> > > last message I see here. No output from earlycon.
> >
> > A bisection lead me to this patch after the next-20201028 failed to
> > boot on the aspeed systems in testing (aspeed_g5_defconfig).
> >
> > You can reproduce this with today's next and qemu 5.1:
> >
> > qemu-system-arm -M romulus-bmc -nographic \
> >  -kernel arch/arm/boot/zImage \
> >  -dtb arch/arm/boot/dts/aspeed-bmc-opp-romulus.dtb \
> >  -initrd any-old-file
> >
> > It requires the initrd option to reproduce, but the initrd doesn't
> > need to be valid as we don't make it that far.
> >
> > There is no output but attaching gdb shows the kernel is stuck in
> > setup_machine_tags. (If we enable CONFIG_ATAGS it is instead stuck in
> > calibrate_delay).
> >
> > (gdb) bt
> > #0  setup_machine_tags (machine_nr=<optimized out>,
> > __atags_vaddr=<optimized out>) at ../arch/arm/kernel/atags.h:12
> > #1  setup_arch (cmdline_p=0x80c01fc4) at ../arch/arm/kernel/setup.c:1100
> > #2  0x80b00d2c in start_kernel () at ../init/main.c:862
> > #3  0x00000000 in ?? ()
> >
> > Reverting 7a1be318f579 on top of next allowed the system to boot again.
> >
>
> Does this help?

Yes, that boots to userspace.

>
> diff --git a/arch/arm/include/asm/memory.h b/arch/arm/include/asm/memory.h
> index bb79e52aeb90..4f355bda872a 100644
> --- a/arch/arm/include/asm/memory.h
> +++ b/arch/arm/include/asm/memory.h
> @@ -68,8 +68,8 @@
>  #define XIP_VIRT_ADDR(physaddr)  (MODULES_VADDR + ((physaddr) & 0x000fffff))
>
>  #define FDT_FIXED_BASE         UL(0xff800000)
> -#define FDT_FIXED_SIZE         (2 * PMD_SIZE)
> -#define FDT_VIRT_ADDR(physaddr)        ((void *)(FDT_FIXED_BASE |
> (physaddr) % PMD_SIZE))
> +#define FDT_FIXED_SIZE         (2 * SECTION_SIZE)
> +#define FDT_VIRT_ADDR(physaddr)        ((void *)(FDT_FIXED_BASE |
> (physaddr) % SECTION_SIZE))
>
>  #if !defined(CONFIG_SMP) && !defined(CONFIG_ARM_LPAE)
>  /*

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2020-10-28 22:03 UTC|newest]

Thread overview: 37+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-10-07  8:39 [PATCH v2 0/2] ARM: move FDT mapping out of linear region Ard Biesheuvel
2020-10-07  8:39 ` [PATCH v2 1/2] ARM: centralize phys-to-virt conversion of DT/ATAGS address Ard Biesheuvel
2020-10-07 15:28   ` Nicolas Pitre
2020-10-07  8:39 ` [PATCH v2 2/2] ARM: move device tree mapping out of linear region Ard Biesheuvel
2020-10-07 15:28   ` Nicolas Pitre
2020-10-07 15:32     ` Ard Biesheuvel
2020-10-07 16:38       ` Nicolas Pitre
2020-10-07 16:40       ` Nicolas Pitre
2020-10-07 21:32     ` Russell King - ARM Linux admin
2020-10-07 22:05       ` Nicolas Pitre
     [not found]   ` <CGME20201028091912eucas1p13fb9cd947faa6bfd79199ea79648b6af@eucas1p1.samsung.com>
2020-10-28  9:19     ` Marek Szyprowski
2020-10-28  9:19       ` Marek Szyprowski
2020-10-28  9:22       ` Ard Biesheuvel
2020-10-28  9:22         ` Ard Biesheuvel
2020-10-28  9:24         ` Ard Biesheuvel
2020-10-28  9:24           ` Ard Biesheuvel
2020-10-28  9:43           ` Marek Szyprowski
2020-10-28  9:43             ` Marek Szyprowski
2020-10-28 12:05       ` Joel Stanley
2020-10-28 12:05         ` Joel Stanley
2020-10-28 12:52         ` Ard Biesheuvel
2020-10-28 12:52           ` Ard Biesheuvel
2020-10-28 12:59           ` Joel Stanley [this message]
2020-10-28 12:59             ` Joel Stanley
2020-10-28 13:00             ` Ard Biesheuvel
2020-10-28 13:00               ` Ard Biesheuvel
2020-10-28 13:06               ` Joel Stanley
2020-10-28 13:06                 ` Joel Stanley
2020-10-28 13:00           ` Russell King - ARM Linux admin
2020-10-28 13:00             ` Russell King - ARM Linux admin
2020-10-28 13:04             ` Ard Biesheuvel
2020-10-28 13:04               ` Ard Biesheuvel
2020-10-28 13:09               ` Russell King - ARM Linux admin
2020-10-28 13:09                 ` Russell King - ARM Linux admin
2020-10-28 13:16           ` Marek Szyprowski
2020-10-28 13:16             ` Marek Szyprowski
2020-10-11 16:39 ` [PATCH v2 0/2] ARM: move FDT " Ard Biesheuvel

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=CACPK8Xfw0WYSxGf0PnVOF40+C-KOJnX2x_q2gXrf4JZPErKBDA@mail.gmail.com \
    --to=joel@jms.id.au \
    --cc=ardb@kernel.org \
    --cc=clg@kaod.org \
    --cc=f.fainelli@gmail.com \
    --cc=krzk@kernel.org \
    --cc=linus.walleij@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-samsung-soc@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=m.szyprowski@samsung.com \
    --cc=nico@fluxnic.net \
    --cc=robh+dt@kernel.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 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.