All of lore.kernel.org
 help / color / mirror / Atom feed
From: Rob Herring <robh@kernel.org>
To: Guenter Roeck <linux@roeck-us.net>
Cc: Frank Rowand <frowand.list@gmail.com>,
	Stephen Boyd <sboyd@kernel.org>,
	linux-kernel@vger.kernel.org, Dinh Nguyen <dinguyen@kernel.org>
Subject: Re: [PATCH v2] nios2: Only use built-in devicetree blob if configured to do so
Date: Wed, 3 Apr 2024 14:36:36 -0500	[thread overview]
Message-ID: <171217296117.18436.10335458241355667114.robh@kernel.org> (raw)
In-Reply-To: <20240322065419.162416-1-linux@roeck-us.net>


On Thu, 21 Mar 2024 23:54:19 -0700, Guenter Roeck wrote:
> Starting with commit 7b937cc243e5 ("of: Create of_root if no dtb provided
> by firmware"), attempts to boot nios2 images with an external devicetree
> blob result in a crash.
> 
> Kernel panic - not syncing: early_init_dt_alloc_memory_arch:
> 	Failed to allocate 72 bytes align=0x40
> 
> For nios2, a built-in devicetree blob always overrides devicetree blobs
> provided by ROMMON/BIOS. This includes the new dummy devicetree blob.
> Result is that the dummy devicetree blob is used even if an external
> devicetree blob is provided. Since the dummy devicetree blob does not
> include any memory information, memory allocations fail, resulting in
> the crash.
> 
> To fix the problem, only use the built-in devicetree blob if
> CONFIG_NIOS2_DTB_SOURCE_BOOL is enabled.
> 
> Fixes: 7b937cc243e5 ("of: Create of_root if no dtb provided by firmware")
> Cc: Frank Rowand <frowand.list@gmail.com>
> Cc: Stephen Boyd <sboyd@kernel.org>
> Cc: Rob Herring <robh@kernel.org>
> Signed-off-by: Guenter Roeck <linux@roeck-us.net>
> ---
> v2: Mark 'dtb' as __maybe_unused
> 
>  arch/nios2/kernel/prom.c | 6 +++++-
>  1 file changed, 5 insertions(+), 1 deletion(-)
> 

As Dinh has not yet picked this up, I applied it, thanks!


      parent reply	other threads:[~2024-04-03 19:36 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-03-22  6:54 [PATCH v2] nios2: Only use built-in devicetree blob if configured to do so Guenter Roeck
2024-03-27 21:37 ` Rob Herring
2024-04-03 19:36 ` Rob Herring [this message]

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=171217296117.18436.10335458241355667114.robh@kernel.org \
    --to=robh@kernel.org \
    --cc=dinguyen@kernel.org \
    --cc=frowand.list@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@roeck-us.net \
    --cc=sboyd@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.