From mboxrd@z Thu Jan 1 00:00:00 1970 From: Tom Rini Date: Mon, 19 Apr 2021 13:33:41 -0400 Subject: [PATCH] Revert "spl: Drop bd_info in the data section" In-Reply-To: <20210408165611.1195887-1-mr.nuke.me@gmail.com> References: <20210408165611.1195887-1-mr.nuke.me@gmail.com> Message-ID: <20210419173341.GH1310@bill-the-cat> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On Thu, Apr 08, 2021 at 11:56:11AM -0500, Alexandru Gagniuc wrote: > This reverts commit 38d6b7ebdaee3e0e8426ef1b9df88bdce8ae2e75. > > struct global_data contains a pointer to the bd_info structure. This > pointer was populated spl_set_bd() to a pre-allocated bd_info in the > ".data" section. The referenced commit replaced this mechanism to one > that uses malloc(). That new mechanism is only used if SPL_ALLOC_BD=y. > which very few boards do. > > The result is that (struct global_data)->bd is NULL in SPL on most > platforms. This breaks falcon mode, since arch_fixup_fdt() tries to > access (struct global_data)->bd and set the "/memory" node in the > devicetree. The result is that the "/memory" node contains garbage > values, causing linux to panic() as it sets up the page table. > > Instead of trying to fix the mess, potentially causing other issues, > revert to the code that worked, while this change is reworked. > > Signed-off-by: Alexandru Gagniuc Applied to u-boot/master, thanks! -- Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 659 bytes Desc: not available URL: