Re: [OE-core] [yocto] Support UBI u-boot

Quentin Schulz

Hi JH,

On Fri, Feb 07, 2020 at 07:52:35PM +1100, JH wrote:
Hi Pelle,

Aplogize for cross posting.

On 2/7/20, Pelle Windestam <> wrote:
In my case u-boot uses a default config called imx8qxp_var_som_defconfig
stored under the configs directory in u-boot (not sure if its in the
official repositories, I use a vendor supplied u-boot repo, but the
procedure should be the same either way), then I have created a
.bbappend-file for the u-boot recipe, and added a patch that modifies the
defconfig file to include the options I want to enable. Then as u-boot is
built, it will use the patched defconfig with the appropriate options
enabled. In the meta-freescale layer the u-boot recipes are under
Thanks for the tip, that is quite helpful. I created bbappend file,
run the make menuconfig to enable NAND and CONFIG_CMD_UBI, but then
failed in build, missing all MTD, NAND, UBI references, the MTD, NAND,
UBI are all selected, what I could be missing?

undefined reference to `mtdparts_init'
This function is not defined. So you look it up in the sources, find
where it's defined.

Is it in a file which is compiled/included somewhere?
Is it surrounded by #ifdef? And by surrounded, I mean the #ifdef can
be several thousands of lines above the function definition.

In that case, I couldn't find the sources of u-boot-imx (didn't take the
time) but from upstream:

It's surrounded by #if defined(CONFIG_CMD_MTDPARTS) so you need
CMD_MTDPARTS to be enabled. Do the same for all the other calls. There's
no magic thing, you thus have to look it up yourself most of the time.
Even though arguably, that's a mistake from upstream (there should be a
dependency on MTDPARTS in Kconfig, anyway...).


Join to automatically receive all group messages.